Ribbons XML
Format of customized ribbon page .xml files.
XML Overview
The ribbon .xml structure consists of action lists and page tabs. Action lists contain all instances of unique actions that are then referenced when needed in the individual page tabs. They can be placed anywhere in the file as long as they appear outside page tags and before the page that references them. Page tabs contain the remaining groups, action groups, and actions necessary to build the overall ribbon.
Changing Solver Interfaces
When changing solver interfaces, all pages are reloaded into the menu bar and their visibility is filtered based on whether the interface has been included in the visible attribute. More information on using using the visible attribute can be found below.
Tags
root
- Attributes
- translationcontext
- Children
- page, actionlisto
page
- Attributes
- tag, text, spotlighttext, tooltip, visible, homepage, helpcommand
- Children
- group
- Example XML
-
<root> <page tag="HMX_Assembly" text="Assembly"> ... </page> <page tag="HMX_Geometry" text="Geometry"> ... </page> <page tag="HMX_Mesh" text="Mesh"> ... </page> </root>
group
- Attributes
- tag, text, spotlighttext, tooltip, visible
- Children
- actiongroup, menu
- Example XML
-
<page tag="HMX_Assembly" text="Assembly"> <group tag="HMX_Organize_G" text="Organize"> ... </group> <group tag="HMX_Parts_G" text="Parts"> ... </group> </page>
actiongroup
- Attributes
- tag, text, spotlighttext, tooltip, visible, type, defaultaction, dropdownsmallicons
- Children
- spriteaction, secondaryribbon
- Example XML
-
<page tag="HMX_Assembly" text="Assembly"> <group tag="HMX_Organize_G" text="Organize"> <actiongroup tag="HMX_Organize_AG" text="Organize"> ... </actiongroup> <actiongroup tag="HMX_Collaborate_AG" text="Collaborate"> ... </actiongroup> <actiongroup tag="HMX_ID_Manager_AG" text="ID Manager"> ... </actiongroup> </group> </page>
actionlist
- Attributes
- None
- Children
- spriteaction
spriteaction
- Attributes
- Inside actionlist tags: tag, text, tooltip, image, command, picmask, spotlighttext, enabled, linktoe
- Children
- spriteaction
- Example XML
-
<root> <actionlist> <spriteaction tag="HMX_Collaborate" text="Collaborate" tooltip="Collaboration Tools" image="ribbonCollaborateStrip-80.png" command="tcl: ::hw::OpenDataManager"/> <spriteaction tag="HMX_Subscribe" text="Subscribe" tooltip="Subscribe" image="ribbonSatelliteSubscribeStrip-80.png" command="tcl: ::hw::InitSubscribe"/> ... </actionlist> <page tag="HMX_Assembly" text="Assembly"> <group tag="HMX_Organize_G" text="Organize"> ... <actiongroup tag="HMX_Collaborate_AG" text="Collaborate"> <spriteaction actiontag="HMX_Collaborate"/> <spriteaction actiontag="HMX_Subscribe" assatellite="True"/> </actiongroup> ... </group> </page> </root>
secondaryribbon
- Attributes
- tag, text, spotlighttext, tooltip, visible, command, assatellite, enabled, linkto, picmask, image
- Children
- spriteaction
- Example XML
-
<root> <actionlist> <spriteaction tag="HMX_Parts" text="Parts" image="ribbonPartsStrip-64.png" command="tcl: ::hm::context::listentityreview::PostEE Part"/> <spriteaction tag="HMX_PartsAssems" text="Part Assems" image="ribbonAssembliesStrip-64.png" command="tcl: ::hm::context::listentityreview::PostEE PartAssembly"/> ... </actionlist> <page tag="HMX_Assembly" text="Assembly"> ... <group tag="HMX_Parts_G" text="Parts"> ... <actiongroup tag="HMX_Parts_AG" text="Parts" tooltip=""> <secondaryribbon tag="HMX_Parts_SR" text="Parts" image="ribbonPartsStrip-80.png"> <spriteaction actiontag="HMX_Parts"/> <spriteaction actiontag="HMX_PartAssems"/> </secondaryribbon> </actiongroup> ... </group> ... </page> </root>
menu
- Attributes
- Visible
- Children
- spriteaction, separator
separator
- Attributes
- Visible
- Children
- None
- Example XML
-
<page tag="HMX_Connectors" text="Connectors"> <group tag="HMX_Create_G" text="Create"> ... <menu> <spriteaction actiontag="HMX_ConnectorPanels"/> <separator/> <spriteaction actiontag="HMX_Absorption"/> <spriteaction actiontag="HMX_AutoPitch"/> <spriteaction actiontag="HMX_Comparison_1"/> <spriteaction actiontag="HMX_Quality"/> <spriteaction actiontag="HMX_HoleDetection"/> <separator/> <spriteaction actiontag="HMX_ConnectorOptions"/> </menu> </group> </page>
if
- Attributes
- eval
- Children
- page, group, actiongroup, spriteaction, menu, separator
- Operators
- ==, !=, <, > <=, >=, in, ni
- Format
-
eval="expr: $ENVIRONMENT_VARIABLE == VALUE"<br> eval="expr: $HM_UNITS > 1"<br> eval="tcl: ::HM_Framework::SomeProc %T"<br> eval="py: hwf.frwk.test()"
- Example XML
-
<page tag="HMX_Assembly" text="Assembly"> <if eval="expr: $PLATFORM == win64"> <group tag="HMX_Parts_G" text="Parts"> <if eval="tcl: ::HM_Framework::SomeProc %N %T"> <spriteaction actiontag="HMX_Assemblies"/> </if> <if eval="py: hwf.frwk.test()"> <spriteaction actiontag="HMX_Verification"/> </if> </group> </if> </page>
- Output
- The Parts group will only be displayed if the environment variable plateform is set to win64. The Assemblies and Verification actions will only be displayed if the .tcl and Python commands return true.
Attributes
tag
Unique identifier of the tag
text
Text that is displayed to the screen
spotlighttext
Boolean value for adding a blue highlight to the text displayed
tooltip
Tooltop text displayed when hovering the region
visible
Conditional attribute to show/hide any tags contained within it based on the profiles specified
- Format
-
visible="expr: {ProfileName1, ProfileName2, ProfileName3}"
- Example XML
-
<page tag="HMX_Analyze" text="Analyze" visible="expr: $HMPROFILE in {Abaqus, Ansys, Exodus}"> <group tag="HMX_Structural_G" text="Structural"> <actiongroup tag="HMX_Loads_AG" text="Loads" visible="expr: $HMPROFILE in {Abaqus}"> <spriteaction actiontag="HMX_PressureBack"/> <spriteaction actiontag="HMX_Moments"/> <spriteaction actiontag="HMX_List_Loads" assatellite="True"/> </actiongroup> <actiongroup tag="HMX_Loads_AG" text="Loads" tooltip=""> <spriteaction actiontag="HMX_BaseArc"/> <spriteaction actiontag="HMX_Forces"/> </actiongroup> </group> </page>
- Result
- The entire analyze page will only display when the solver interface is set to Abaqus, ANSYS, or EXODUS. The first loads actiongroup inside will only be displayed in Abaqus.
actiontag
Unique identifier for the spriteaction tag inside a page which corresponds with the actiontag inside an actionlist
command
- Supported commands
- Python, TCL, Panel, Context
- Operators
- ==, !=, <, > <=, >=, in, ni
- Format
-
command="py: hwf.frwk.test()"<br> command="tcl: tcl: ::HM_Framework::Unity::PopUpPanel {config edit}"<br> command="panel: {count} {} {}"<br> command="context: Patch"
- Example XML
-
<actionlist> <spriteaction tag="HMX_Open" text="Open" image="ribbonFilesOpenStrip-80.png" command="py: filemenu.OpenFile()"/> <spriteaction tag="HMX_Reorder" text="Reorder" command="tcl: ::HM_Framework::Unity::PopUpPanel {reorder}"/> <spriteaction tag="HMX_Count" text="Count" command="panel: {count} {} {}"/> <spriteaction tag="HMX_Patch" text="Patch" image="ribbonPatchStrip-64.png" command="context: Patch"/> </actionlist>
assatellite
Boolean value that sets the spriteaction tag to a satellite image
xoffset
Sets the horizontal offset for satellite actions
Used only when assatellite is active
enabled
Boolean value to disable/enable any spriteaction
Disabled spriteactions appear greyed out and have no action when selected
linkto
Links one spriteaction to another, based on the tag attribute value, to copy its command when selected
image
Image file for spriteaction and secondaryribbon tags
picmask
Image used to define the selection region for an action
type
- Example XML
-
<page tag="HMX_OptiStructModel" text="Model" visible="expr: $HMPROFILE in {OptiStruct}"> <group tag="HMX_Setup_G" text="Setup"> ... <actiongroup tag="HMX_Masses_AG" text="Masses" image="ribbonConcentratedMassesStrip-80.png" type="menu" defaultaction="HMX_Point_Mass_1" dropdownsmallicons="true"> <spriteaction actiontag="HMX_Point_Mass_1"/> <spriteaction actiontag="HMX_NSM_1"/> <spriteaction actiontag="HMX_Rigid_Mass_1"/> <spriteaction actiontag="HMX_FE_Absorb_1"/> <spriteaction actiontag="HMX_Review_Masses_1" assatellite="True"/> </actiongroup> ... </group> ... </page>
defaultaction
Sets the default spriteaction to be selected in an actiongroup drop-down menu based on the actiontag attribute
dropdownsmallicons
Boolean value to enable small action icons next to the spriteaction text in an actiongroup down menu
eval
Conditional attribute used with the if tag to show/hide all tags contained within it based on environment variables
homepage
Boolean value that sets the page tag to be a home group
This group will remain visible at the beginning of every page
helpcommand
Support for page level help command with F1
In idle context it will execute this command instead of default help
Follows same format as the command attribute
Mesh Page Example
<root>
<actionlist>
<spriteaction tag="HMX_criteria" text="criteria" tooltip="Open the Criteria Editor"
image="ribbonMeshParametersCriteriaCriteriaStrip-80.png"
command="tcl: ::hwt::Source CriteriaEditor.tcl;
::CriteriaEditor::OpenDialogWithArgs
-open_mode hm -show_mode crit_both"/>
<spriteaction tag="HMX_Parameters" text="Parameters" tooltip="Review Parameters"
command="tcl: ::hm::context::listentityreview::OnSatelliteButtonClick parameters"/>
<spriteaction tag="HMX_Mesh" text="Mesh Controls" tooltip="Mesh Controls"
image="ribbonMeshControlsStrip-80.png"
command="tcl: ::hm::br::PostBrowser meshcontrols"/>
<spriteaction tag="HMX_LineMesh" text="Line Mesh" tooltip="Create 1D Element Mesh"
image="hwd1DMeshing-80.png" command="panel: {line mesh} {} {}"/>
<spriteaction tag="HMX_BatchMesher" text="BatchMesher" tooltip="Altair
BatchMesher" image="ribbonSurfaceMeshBatchStrip-80.png"
command="context: 2DMCSBatchMesher" spotlighttext="True"/>
<spriteaction tag="HMX_CFD_2D_Mesh" text="CFD 2D Mesh" tooltip="Generate 2D CFD Meshes"
image="ribbonSurfaceMeshCFDStrip-80.png" command="context: 2DMCSCfd"
spotlighttext="True"/>
<spriteaction tag="HMX_Selection_General" text="Create" enabled="True"
tooltip="Mesh Surfaces" image="ribbonMeshSelectionStrip-64.png"
command="context: 2DMCSGeneral" spotlighttext="True"/>
<spriteaction tag="HMX_Density_General" text="Density" enabled="False"
tooltip="Edit Edge Density Values" image="ribbonMeshDensityStrip-64.png"
command="context: 2DMCEEDensity_General" spotlighttext="True"/>
<spriteaction tag="HMX_Biasing_General" text="Biasing" enabled="False"
tooltip="Edit Edge Biasing Values" image="ribbonMeshBiasStrip-64.png"
command="context: 2DMCEEBiasing_General" spotlighttext="True"/>
<spriteaction tag="HMX_FaceEdit_General" text="Face Edit" enabled="False"
tooltip="Edit Surface Mesh Properties" image="ribbonMeshTypeStrip-64.png"
command="context: 2DMCFaceEdit_General" spotlighttext="True"/>
<spriteaction tag="HMX_Selection_Panel" text="Create" enabled="True"
tooltip="Mesh Surfaces" image="ribbonMeshSelectionStrip-64.png"
command="context: 2DMCSPanelMesh" spotlighttext="True"/>
<spriteaction tag="HMX_Density_Panel" text="Density" enabled="False"
tooltip="Edit Edge Density Values" image="ribbonMeshDensityStrip-64.png"
command="context: 2DMCEEDensity_Panel" spotlighttext="True"/>
<spriteaction tag="HMX_Biasing_Panel" text="Biasing" enabled="False"
tooltip="Edit Edge Biasing Values" image="ribbonMeshBiasStrip-64.png"
command="context: 2DMCEEBiasing_Panel" spotlighttext="True"/>
<spriteaction tag="HMX_FaceEdit_Panel" text="Face Edit" enabled="False"
tooltip="Edit Surface Mesh Properties" image="ribbonMeshTypeStrip-64.png"
command="context: 2DMCFaceEdit_Panel" spotlighttext="True"/>
<spriteaction tag="HMX_Rigid_Body_Mesh" text="Rigid Body Mesh"
tooltip="Generate 2D Rigid Body Meshes"
image="ribbonSurfaceMeshRigidBodyStrip-80.png"
command="context: 2DMCSRigidBody" spotlighttext="True"/>
<spriteaction tag="HMX_Create" text="Automatic" tooltip="Create Midmesh"
image="ribbonMidmeshCreateStrip-64.png" command="context: 2DMidmeshCreate"
spotlighttext="True"/>
<spriteaction tag="HMX_Repair" text="Repair/Fill" tooltip="Repair/Fill"
image="ribbonMidmeshRepairStrip-64.png" command="context: 2DMidmeshRepair"
spotlighttext="True"/>
<spriteaction tag="HMX_CreateMidedge" text="Create Midedge"
tooltip="Create Midedge" image="ribbonMidmeshMidedgeStrip-64.png"
command="context: 2DMidmeshCreateMidedge" spotlighttext="True"/>
<spriteaction tag="HMX_EditTopology" text="Edit Topology"
tooltip="Edit Midmesh Topology" image="ribbonMidmeshEditStrip-64.png"
command="context: 2DMidmeshEditTopology" spotlighttext="True"/>
<spriteaction tag="HMX_Align" text="Align" tooltip="Align Midmesh"
image="ribbonMidmeshAlignStrip-64.png"
command="context: 2DMidmeshAlign" spotlighttext="True"/>
<spriteaction tag="HMX_Create_1" text="Create" tooltip="Create Feature Edges"
image="ribbonFeatureEdgesCreateStrip-64.png"
command="context: FeatureEdgesCreate" spotlighttext="True"/>
<spriteaction tag="HMX_Edit" text="Edit" tooltip="Edit Feature Edges"
image="ribbonFeatureEdgesEditStrip-64.png"
command="context: FeatureEdgesEdit" spotlighttext="True"/>
<spriteaction tag="HMX_Rebuild" text="Rebuild" tooltip="Rebuild Mesh"
image="ribbonMeshRebuildStrip-80.png"
command="context: 2DMeshRebuild" spotlighttext="True"/>
<spriteaction tag="HMX_AdaptiveWrap" text="Adaptive Wrap"
tooltip="Adaptive Wrap" command="tcl: ::hwt::Source AdaptiveWrap.tcl"/>
<spriteaction tag="HMX_EMLattice" text="EM Lattice" tooltip="EM Lattice"
command="tcl: ::hwt::Source VoxelLattice.tcl"/>
<spriteaction tag="HMX_ShrinkWrap" text="Shrink Wrap" tooltip="Shrink Wrap"
command="tcl: ::HM_Framework::Unity::PopUpPanel {shrink wrap}"/>
<spriteaction tag="HMX_Create_2" text="Create" tooltip="Create Tetra Meshes"
image="ribbonSolidMeshTetraCreateStrip-64.png"
command="context: 3DTetrameshCreate" spotlighttext="True"/>
<spriteaction tag="HMX_Remesh" text="Remesh" tooltip="Remesh Tetra Meshes"
image="ribbonSolidMeshTetraRemeshStrip-64.png"
command="context: 3DTetrameshRemesh" spotlighttext="True"/>
<spriteaction tag="HMX_Hex" text="Hex" tooltip="Hex Mesh"
image="ribbonSolidMeshHexStrip-80.png"
command="panel: {solid map} {multi solids} {}"/>
<spriteaction tag="HMX_Create_3" text="Create" tooltip="Create Voxel Meshes"
image="ribbonVoxelCreateStrip-64.png"
command="context: 3DVoxelMeshCreate" spotlighttext="True"/>
<spriteaction tag="HMX_Edit_1" text="+/-" tooltip="Edit Voxel Meshes"
image="ribbonVoxelEditStrip-64.png" command="context: 3DVoxelMeshEdit"
spotlighttext="True"/>
<spriteaction tag="HMX_AcousticCavity" text="Acoustic Cavity" tooltip="Acoustic Cavity"
command="tcl: ::hwt::Source ACM/hmAcousticMeshGUI.tcl;
::hmAcousticMeshGui::PostAcousticMesh;"/>
<spriteaction tag="HMX_Morph_Freehand_Nodes" text="Morph Mesh"
tooltip="Morph Meshes by Moving Nodes or Mapping to Geometry"
image="ribbonMorphingMeshStrip-80.png"
command="context: MorphFreehandNodes" spotlighttext="True"/>
<spriteaction tag="HMX_Morph_Shapes" text="Morph Shapes"
tooltip="Create, Edit, and Apply Shapes" image="ribbonMorphShapesMainStrip-80.png"
command="context: MorphShapes"/>
<spriteaction tag="HMX_Morph_Shapes_List" text="Morph Shapes List"
tooltip="Create Shapes" image="ribbonMorphShapesSaveNewStrip-80.png"
command="tcl: ::hm::context::shapetable::CreateEntity"/>
<spriteaction tag="HMX_Morph_Shapes_Record" text="Morph Shapes Record"
tooltip="Record Node Movements" image="ribbonMorphShapesRecordStrip-80.png"
command="tcl: ::hm::context::shapetable::MorphRecord 0"/>
<actionlist>
<page tag="HMX_Mesh" text="Mesh" spotlighttext="True">
<group tag="HMX_Controls_G" text="Controls">
<actiongroup tag="HMX_Param_Criteria_AG" text="Param/Criteria" tooltip="">
<spriteaction actiontag="HMX_criteria"/>
<spriteaction actiontag="HMX_param"/>
</actiongroup>
<actiongroup tag="HMX_Mesh_AG" text="Mesh Controls">
<spriteaction actiontag="HMX_Mesh"/>
</actiongroup>
</group>
<group tag="HMX_1D_Mesh_G" text="1D Mesh">
<actiongroup tag="HMX_LineMesh_AG" text="Line Mesh">
<spriteaction actiontag="HMX_LineMesh"/>
</actiongroup>
</group>
<group tag="HMX_2D_Mesh_G" text="2D Mesh">
<actiongroup tag="HMX_SurfaceMesh_AG" text="Surface Mesh" tooltip="" type="menu"
dropdownsmallicons="true" defaultaction="HMX_General_2D_Mesh_SR"
image="ribbonSurfaceMeshGeneralStrip-80.png" spotlighttext="True">
<spriteaction actiontag="HMX_BatchMesher"/>
<spriteaction actiontag="HMX_CFD_2D_Mesh"/>
<secondaryribbon tag="HMX_General_2D_Mesh_SR" text="General 2D Mesh"
defaultaction="HMX_Selection_General" tooltip="Generate 2D Meshes"
image="ribbonSurfaceMeshGeneralStrip-80.png" spotlighttext="True">
<spriteaction actiontag="HMX_Selection_General"/>
<spriteaction actiontag="HMX_Density_General"/>
<spriteaction actiontag="HMX_Biasing_General"/>
<spriteaction actiontag="HMX_FaceEdit_General"/>
</secondaryribbon>
<secondaryribbon tag="HMX_Panel_Mesh_SR" text="Panel Mesh"
defaultaction="HMX_Selection_Panel" tooltip="Generate 2D mapped meshes"
image="ribbonSurfaceMeshPanelStrip-80.png" spotlighttext="True">
<spriteaction actiontag="HMX_Selection_Panel"/>
<spriteaction actiontag="HMX_Density_Panel"/>
<spriteaction actiontag="HMX_Biasing_Panel"/>
<spriteaction actiontag="HMX_FaceEdit_Panel"/>
</secondaryribbon>
<spriteaction actiontag="HMX_Rigid_Body_Mesh"/>
</actiongroup>
<secondaryribbon tag="HMX_Midmesh_SR" text="Midmesh" tooltip="Create Edit Midmesh"
image="ribbonMidsurfaceMidmeshStrip-80.png" defaultaction="HMX_Create"
spotlighttext="True">
<spriteaction actiontag="HMX_Create"/>
<spriteaction actiontag="HMX_Repair"/>
<spriteaction actiontag="HMX_CreateMidedge"/>
<spriteaction actiontag="HMX_EditTopology"/>
<spriteaction actiontag="HMX_Align"/>
</secondaryribbon>
<secondaryribbon tag="HMX_FeatureEdges_SR" text="Feature Edges"
tooltip="Create and Edit Mesh Feature Edges"
image="ribbonFeatureEdgesStrip-80.png"
defaultaction="HMX_Create_1" spotlighttext="True">
<spriteaction actiontag="HMX_Create_1"/>
<spriteaction actiontag="HMX_Edit"/>
</secondaryribbon>
<actiongroup tag="HMX_Rebuild_AG" text="Rebuild" spotlighttext="True">
<spriteaction actiontag="HMX_Rebuild"/>
</actiongroup>
<menu>
<spriteaction actiontag="HMX_AdaptiveWrap"/>
<spriteaction actiontag="HMX_EMLattice"/>
<spriteaction actiontag="HMX_ShrinkWrap"/>
</menu>
</group>
<group tag="HMX_3D_Mesh_G" text="3D Mesh">
<secondaryribbon tag="HMX_Tetra_SR" text="Tetra" tooltip="Create Edit Tetra Meshes"
image="ribbonSolidMeshTetraStrip-80.png" defaultaction="HMX_Create_2"
spotlighttext="True">
<spriteaction actiontag="HMX_Create_2"/>
<spriteaction actiontag="HMX_Remesh"/>
</secondaryribbon>
<actiongroup tag="HMX_Hex_AG" text="Hex">
<spriteaction actiontag="HMX_Hex"/>
</actiongroup>
<secondaryribbon tag="HMX_Voxel_SR" text="Voxel" tooltip="Create Edit Voxel Meshes"
image="ribbonVoxelStrip-80.png" defaultaction="HMX_Create_3"
spotlighttext="True">
<spriteaction actiontag="HMX_Create_3"/>
<spriteaction actiontag="HMX_Edit_1"/>
</secondaryribbon>
<menu>
<spriteaction actiontag="HMX_AcousticCavity"/>
</menu>
</group>
<group tag="HMX_Morph_G" text="Morph">
<actiongroup tag="HMX_Morph_Freehand_Nodes_AG" text="Morph Mesh"
spotlighttext="True">
<spriteaction actiontag="HMX_Morph_Freehand_Nodes"/>
</actiongroup>
<actiongroup tag="HMX_Morph_Shapes_AG" text="Shapes"
tooltip="Create, Edit, and Apply Shapes"
spotlighttext="True">
<spriteaction actiontag="HMX_Morph_Shapes"/>
<spriteaction actiontag="HMX_Morph_Shapes_List" assatellite="True"/>
<spriteaction actiontag="HMX_Morph_Shapes_Record" assatellite="True"/>
</actiongroup>
</group>
</page>
</root>