Skip to content

Commit

Permalink
Show appearance for local polygon
Browse files Browse the repository at this point in the history
  • Loading branch information
magnesj committed Feb 21, 2024
1 parent 5db14e1 commit 4f069c0
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,10 @@ void RimPolygonFilter::defineUiOrdering( QString uiConfigName, caf::PdmUiOrderin
{
caf::PdmUiGroup* polyDefinitionGroup = uiOrdering.addNewGroup( "Polygon Definition" );
m_polygonEditor()->uiOrderingForLocalPolygon( uiConfigName, *polyDefinitionGroup );

caf::PdmUiGroup* appearanceGroup = uiOrdering.addNewGroup( "Appearance" );
appearanceGroup->setCollapsedByDefault();
m_internalPolygon->uiOrderingForLocalPolygon( uiConfigName, *appearanceGroup );
}
}

Expand Down
8 changes: 8 additions & 0 deletions ApplicationLibCode/ProjectDataModel/Polygons/RimPolygon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,14 @@ cvf::ref<RigPolyLinesData> RimPolygon::polyLinesData() const
return pld;
}

//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RimPolygon::uiOrderingForLocalPolygon( QString uiConfigName, caf::PdmUiOrdering& uiOrdering )
{
m_appearance->uiOrdering( uiConfigName, uiOrdering );
}

//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
Expand Down
2 changes: 2 additions & 0 deletions ApplicationLibCode/ProjectDataModel/Polygons/RimPolygon.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ class RimPolygon : public RimNamedObject, public RimPolylinesDataInterface

cvf::ref<RigPolyLinesData> polyLinesData() const override;

void uiOrderingForLocalPolygon( QString uiConfigName, caf::PdmUiOrdering& uiOrdering );

protected:
void defineUiOrdering( QString uiConfigName, caf::PdmUiOrdering& uiOrdering ) override;
void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override;
Expand Down

0 comments on commit 4f069c0

Please sign in to comment.