GiD offers you the opportunity to customize the pull-down menus. You can add new menus or to change the existing ones. If you are creating a problem type, these functions should be called from the InitGIDProject or InitGIDPostProcess functions (see TCL AND TK EXTENSION).
Note: Menus and option menus are identified by their names.
Note: It is not necessary to restore the menus when leaving the problem type, GiD does this automatically.
The Tcl functions are:
...
To remove separators, the option_name is — , but you can append an index (starting from 0) to specify wich which separator must be removed, if there are more than one.
e.g.
GiDMenu::RemoveOption "Geometry" [list "Create" "---2"] PRE
- GiDMenu::ModifyOption { menu_name_untranslated option_name_untranslated prepost new_option_name {new_command -default-} {new_acceler -default-} {new_icon -default-} {translationfunc _} }
Edit an existent option from a given menu
some parameters can be '-default-' to keep the current value for the command, accelerator, etc
...
e.g. a plugin can modify a menu to add some entry, but this entry will be lost when GiD create again all menus, for example when starting a new model. Registering the procedure will be applied again when recreating re-creating menus.
- GiD_RegisterExtensionProc and GiD_UnRegisterExtensionProc
...