r16188 by jghali - some enhancements to line properties widget

scribus-commit scribus-commit at lists.scribus.net
Fri Dec 31 03:21:43 CET 2010


Author: jghali
Date: Fri Dec 31 02:21:43 2010
New Revision: 16188

URL: http://scribus.info/websvn/listing.php?repname=Scribus&sc=1&rev=16188
Log:
some enhancements to line properties widget

Modified:
    branches/ScribusOIF/scribus/ui/propertywidget_line.cpp
    branches/ScribusOIF/scribus/ui/propertywidget_linebase.ui

Modified: branches/ScribusOIF/scribus/ui/propertywidget_line.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16188&path=/branches/ScribusOIF/scribus/ui/propertywidget_line.cpp
==============================================================================
--- branches/ScribusOIF/scribus/ui/propertywidget_line.cpp (original)
+++ branches/ScribusOIF/scribus/ui/propertywidget_line.cpp Fri Dec 31 02:21:43 2010
@@ -62,6 +62,9 @@
 	//lineJoinLabel->setBuddy(lineJoinStyle);
 	//lineEndLabel->setBuddy(lineEndStyle);
 
+	edgesLayout->setAlignment(Qt::AlignRight);
+	endingsLayout->setAlignment(Qt::AlignRight);
+
 	mitterJoinEdge->setIcon(loadIcon("16/stroke-join-miter.png"));
 	bevelJoinEdge->setIcon(loadIcon("16/stroke-join-bevel.png"));
 	roundJoinEdge->setIcon(loadIcon("16/stroke-join-round.png"));
@@ -79,6 +82,7 @@
 	languageChange();
 
 	stackedWidget->setCurrentIndex(0);
+	stackedWidget->setVisible(false);
 }
 
 void PropertyWidget_Line::changeEvent(QEvent *e)
@@ -252,6 +256,7 @@
 	if ((m_item->isTableItem) && (m_item->isSingleSel))
 	{
 		stackedWidget->setCurrentIndex(2);
+		stackedWidget->setVisible(true);
 		topLine->setChecked(m_item->TopLine);
 		leftLine->setChecked(m_item->LeftLine);
 		rightLine->setChecked(m_item->RightLine);
@@ -260,6 +265,7 @@
 	else if ((m_item->asLine()) || (m_item->asPolyLine()))
 	{
 		stackedWidget->setCurrentIndex(1);
+		stackedWidget->setVisible(true);
 		startArrow->setCurrentIndex(m_item->startArrowIndex());
 		endArrow->setCurrentIndex(m_item->endArrowIndex());
 		endArrowScale->setValue(m_item->endArrowScale());
@@ -268,6 +274,7 @@
 	else
 	{
 		stackedWidget->setCurrentIndex(0);
+		stackedWidget->setVisible(false);
 	}
 
 	if ((m_item->isGroup()) && (!m_item->isSingleSel))

Modified: branches/ScribusOIF/scribus/ui/propertywidget_linebase.ui
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16188&path=/branches/ScribusOIF/scribus/ui/propertywidget_linebase.ui
==============================================================================
--- branches/ScribusOIF/scribus/ui/propertywidget_linebase.ui (original)
+++ branches/ScribusOIF/scribus/ui/propertywidget_linebase.ui Fri Dec 31 02:21:43 2010
@@ -80,117 +80,6 @@
        </property>
       </widget>
      </item>
-     <item row="2" column="2">
-      <layout class="QHBoxLayout" name="edgesLayout">
-       <item>
-        <widget class="QToolButton" name="mitterJoinEdge">
-         <property name="text">
-          <string/>
-         </property>
-         <property name="checkable">
-          <bool>true</bool>
-         </property>
-         <property name="autoExclusive">
-          <bool>true</bool>
-         </property>
-         <attribute name="buttonGroup">
-          <string>lineJoinBtnGroup</string>
-         </attribute>
-        </widget>
-       </item>
-       <item>
-        <widget class="QToolButton" name="bevelJoinEdge">
-         <property name="text">
-          <string/>
-         </property>
-         <property name="checkable">
-          <bool>true</bool>
-         </property>
-         <property name="autoExclusive">
-          <bool>true</bool>
-         </property>
-         <attribute name="buttonGroup">
-          <string>lineJoinBtnGroup</string>
-         </attribute>
-        </widget>
-       </item>
-       <item>
-        <widget class="QToolButton" name="roundJoinEdge">
-         <property name="text">
-          <string/>
-         </property>
-         <property name="checkable">
-          <bool>true</bool>
-         </property>
-         <property name="autoExclusive">
-          <bool>true</bool>
-         </property>
-         <attribute name="buttonGroup">
-          <string>lineJoinBtnGroup</string>
-         </attribute>
-        </widget>
-       </item>
-      </layout>
-     </item>
-     <item row="3" column="1">
-      <widget class="QLabel" name="lineEndLabel">
-       <property name="text">
-        <string>&amp;Endings:</string>
-       </property>
-      </widget>
-     </item>
-     <item row="3" column="2">
-      <layout class="QHBoxLayout" name="endingsLayout">
-       <item>
-        <widget class="QToolButton" name="flatCapEnd">
-         <property name="text">
-          <string/>
-         </property>
-         <property name="checkable">
-          <bool>true</bool>
-         </property>
-         <property name="autoExclusive">
-          <bool>true</bool>
-         </property>
-         <attribute name="buttonGroup">
-          <string>lineEndBtnGroup</string>
-         </attribute>
-        </widget>
-       </item>
-       <item>
-        <widget class="QToolButton" name="squareCapEnd">
-         <property name="text">
-          <string/>
-         </property>
-         <property name="checkable">
-          <bool>true</bool>
-         </property>
-         <property name="autoExclusive">
-          <bool>true</bool>
-         </property>
-         <attribute name="buttonGroup">
-          <string>lineEndBtnGroup</string>
-         </attribute>
-        </widget>
-       </item>
-       <item>
-        <widget class="QToolButton" name="roundCapEnd">
-         <property name="text">
-          <string/>
-         </property>
-         <property name="checkable">
-          <bool>true</bool>
-         </property>
-         <property name="autoExclusive">
-          <bool>true</bool>
-         </property>
-         <attribute name="buttonGroup">
-          <string>lineEndBtnGroup</string>
-         </attribute>
-        </widget>
-       </item>
-      </layout>
-     </item>
      <item row="4" column="1" colspan="2">
       <widget class="QStackedWidget" name="stackedWidget">
        <property name="currentIndex">
@@ -326,6 +215,117 @@
         <string>Style:</string>
        </property>
       </widget>
+     </item>
+     <item row="3" column="1">
+      <layout class="QHBoxLayout" name="edgesLayout">
+       <item>
+        <widget class="QToolButton" name="mitterJoinEdge">
+         <property name="text">
+          <string/>
+         </property>
+         <property name="checkable">
+          <bool>true</bool>
+         </property>
+         <property name="autoExclusive">
+          <bool>true</bool>
+         </property>
+         <attribute name="buttonGroup">
+          <string>lineJoinBtnGroup</string>
+         </attribute>
+        </widget>
+       </item>
+       <item>
+        <widget class="QToolButton" name="bevelJoinEdge">
+         <property name="text">
+          <string/>
+         </property>
+         <property name="checkable">
+          <bool>true</bool>
+         </property>
+         <property name="autoExclusive">
+          <bool>true</bool>
+         </property>
+         <attribute name="buttonGroup">
+          <string>lineJoinBtnGroup</string>
+         </attribute>
+        </widget>
+       </item>
+       <item>
+        <widget class="QToolButton" name="roundJoinEdge">
+         <property name="text">
+          <string/>
+         </property>
+         <property name="checkable">
+          <bool>true</bool>
+         </property>
+         <property name="autoExclusive">
+          <bool>true</bool>
+         </property>
+         <attribute name="buttonGroup">
+          <string>lineJoinBtnGroup</string>
+         </attribute>
+        </widget>
+       </item>
+      </layout>
+     </item>
+     <item row="2" column="2">
+      <widget class="QLabel" name="lineEndLabel">
+       <property name="text">
+        <string>&amp;Endings:</string>
+       </property>
+      </widget>
+     </item>
+     <item row="3" column="2">
+      <layout class="QHBoxLayout" name="endingsLayout">
+       <item>
+        <widget class="QToolButton" name="flatCapEnd">
+         <property name="text">
+          <string/>
+         </property>
+         <property name="checkable">
+          <bool>true</bool>
+         </property>
+         <property name="autoExclusive">
+          <bool>true</bool>
+         </property>
+         <attribute name="buttonGroup">
+          <string>lineEndBtnGroup</string>
+         </attribute>
+        </widget>
+       </item>
+       <item>
+        <widget class="QToolButton" name="squareCapEnd">
+         <property name="text">
+          <string/>
+         </property>
+         <property name="checkable">
+          <bool>true</bool>
+         </property>
+         <property name="autoExclusive">
+          <bool>true</bool>
+         </property>
+         <attribute name="buttonGroup">
+          <string>lineEndBtnGroup</string>
+         </attribute>
+        </widget>
+       </item>
+       <item>
+        <widget class="QToolButton" name="roundCapEnd">
+         <property name="text">
+          <string/>
+         </property>
+         <property name="checkable">
+          <bool>true</bool>
+         </property>
+         <property name="autoExclusive">
+          <bool>true</bool>
+         </property>
+         <attribute name="buttonGroup">
+          <string>lineEndBtnGroup</string>
+         </attribute>
+        </widget>
+       </item>
+      </layout>
      </item>
     </layout>
    </item>




More information about the scribus-commit mailing list