mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-17 20:50:34 +01:00
Shape item propertie widget : hide filling group box when shape is a line or an opened polyline
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@4344 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -63,6 +63,7 @@ void ShapeGraphicsItemPropertiesWidget::setItem(QetShapeItem *shape)
|
|||||||
|
|
||||||
m_shape = shape;
|
m_shape = shape;
|
||||||
ui->m_close_polygon->setVisible(m_shape->shapeType() == QetShapeItem::Polygon);
|
ui->m_close_polygon->setVisible(m_shape->shapeType() == QetShapeItem::Polygon);
|
||||||
|
ui->m_filling_gb->setHidden(m_shape->shapeType() == QetShapeItem::Line);
|
||||||
|
|
||||||
if (m_live_edit)
|
if (m_live_edit)
|
||||||
{
|
{
|
||||||
@@ -157,7 +158,11 @@ void ShapeGraphicsItemPropertiesWidget::updateUi()
|
|||||||
ui->m_style_cb->setCurrentIndex(static_cast<int>(m_shape->pen().style()) - 1);
|
ui->m_style_cb->setCurrentIndex(static_cast<int>(m_shape->pen().style()) - 1);
|
||||||
ui->m_size_dsb ->setValue(m_shape->pen().widthF());
|
ui->m_size_dsb ->setValue(m_shape->pen().widthF());
|
||||||
setPenColorButton(m_shape->pen().color());
|
setPenColorButton(m_shape->pen().color());
|
||||||
|
|
||||||
//Brush
|
//Brush
|
||||||
|
if (m_shape->shapeType() == QetShapeItem::Polygon)
|
||||||
|
ui->m_filling_gb->setVisible(m_shape->isClosed());
|
||||||
|
|
||||||
ui->m_brush_style_cb->setCurrentIndex(static_cast<int>(m_shape->brush().style()));
|
ui->m_brush_style_cb->setCurrentIndex(static_cast<int>(m_shape->brush().style()));
|
||||||
setBrushColorButton(m_shape->brush().color());
|
setBrushColorButton(m_shape->brush().color());
|
||||||
|
|
||||||
|
|||||||
@@ -115,7 +115,7 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QGroupBox" name="groupBox_2">
|
<widget class="QGroupBox" name="m_filling_gb">
|
||||||
<property name="title">
|
<property name="title">
|
||||||
<string>Remplissage</string>
|
<string>Remplissage</string>
|
||||||
</property>
|
</property>
|
||||||
|
|||||||
Reference in New Issue
Block a user