The separate document Customization and User Interface News describes all additions and modifications in respect to the customization capabilities of Creo Elements/Direct Modeling and its default menus, toolbars and context menus.
With every new Creo Elements/Direct Modeling release this document is updated to make the upgrade of Creo Elements/Direct Modeling in respect to customization as smooth as possible.
This chapter contains general information about the concepts used in Creo Elements/Direct Modeling to fully leverage the power of a multi-level customization approach. All components and technical details will be explained in specific sections below.
Creo Elements/Direct Modeling and all of its add-on modules and
applications support a consistent and generic approach to multi-level
customization.
There are four levels of customization:
The SD level is the factory level of customization. For example, if no other customization has taken place (yet) Creo Elements/Direct Modeling 20.3 and its modules/applications will show up and behave as defined by Creo Elements/Direct Modeling.
A big company can add/modify or even replace the initial look and behavior of Creo Elements/Direct Modeling and all its modules/applications by providing a Corp (= Corporate) customization.
Single sites within a company can decide to overwrite, modify or enhance customizations done on corporate level. This can be done by providing a Site customization. It is not mandatory to have a Corp customization to make a Site customization. If there is no Corp customization given, a Site customization will tweak the default Creo Elements/Direct Modeling customization.
Finally, the user has the choice to tweak his system to his needs by changing defaults, UI layouts, toolbars, etc., either interactively or by editing files in the User customization directory. Usually all User customization files are written automatically as soon as the user modifies a setting during runtime of Creo Elements/Direct Modeling and its add-on modules/applications. In rare cases the user might need to edit a file such as the standard customization file (sd_customize) to make more sophisticated customizations. User settings can overwrite customizations given by Site, Corp or SD.
The following UI components can be customized either interactively by the user at run-time or by providing specific definition files in site and/or corp customization directories:
In addition to that, Creo Elements/Direct Modeling and each add-on module/application features their own specific customize files which allow the user to further tweak module specific functionality or settings.
The basis for all user interface customizations at run-time is a list of Available Commands. This list of available commands is provided by Creo Elements/Direct Modeling itself and by its add-on applications and modules like Annotation or Sheet Metal.
A corporate (corp) customization can add corp specific commands or can modify core Creo Elements/Direct Modeling commands. Having a specific variable set, corp can even completely replace the definitions of core Creo Elements/Direct Modeling. A site administrator also can add site specific commands or can modify corp or core Creo Elements/Direct Modeling commands.
A user usually modifies or adds to the list of available commands in an interactive way by means of the New ... or Modify ... buttons in the Customize UI. In addition to that he can also provide an available commands file just like a site administrator or or corp customization.
An available command defines a command within Creo Elements/Direct Modeling and all its add-on applications and modules uniquely. This unique identifier is a triple of three strings:
Application Name - Group Name - Command Name
This unique identifier is used to build up toolbars and context menus. Each entry in such definition files references the unique identifier of an available command.
When Creo Elements/Direct Modeling (and its add-on applications and modules) starts up, several toolbar and context menu definition files are loaded from various places (for more details see here).
If at this time the definition of an available command which is referenced in one of the toolbar/context menu files is found in the list of available commands, the toolbar/context menu button is created based on the information given in the available command definition: icon, tooltip, label, action, etc.
If a toolbar/context menu file references an available command which is not part of the list of available commands (yet), a proxy button is created with a reference to a (yet) unknown command. If at some point in time Creo Elements/Direct Modeling loads in additional available command files and the formerly referenced unknown command now became a known command, Creo Elements/Direct Modeling replaces the proxy button with a button created from the now available data.
Please note that the correct case-sensitive spelling is important when identifying a command in the list of available commands.
User customizations interactively done at runtime of Creo Elements/Direct Modeling are automatically stored to a place which Creo Elements/Direct Modeling always visits when the user starts up the next time. This guarantees that Creo Elements/Direct Modeling's user interface will appear to the user as it was in the previous session.
All changes the user does to the UI at run-time like creation or deletion of toolbars, modification of context menus or toolbar contents, rearranging the UI layout etc. are automatically stored to text files in the user's personal customization directory. This enables the user to easily reuse his customizations on a different computer or to leverage his customizations in a future release of Creo Elements/Direct Modeling. Also these generated files can be copied to a site or corp customization directory to make these changes available for site users or even on a corporate level.
From CoCreate OneSpace Modeling 2007 onwards, the default encodings for customization files are UTF-8 and UTF-16. Creo Elements/Direct Modeling recognizes these encodings automatically if the customization files start with a BOM. For background information on Unicode, encodings and BOMs, please consult the separate document on Unicode concepts.
This section decribes the exact syntax of all necessary definition files to allow user interface customization. Usually these files are written automatically by Creo Elements/Direct Modeling, but this section should serve as reference to understand the contents of each file.
An available commands file contains definitions of commands which are the basis for the ribbon definition and can be used in user-defined toolbars, viewport popup menus and in preselection context menus.
The default Creo Elements/Direct Modeling available commands file is:
INSTALLDIR/personality/sd_customize/sd_avail_cmds.cmdor
INSTALLDIR/personality/<language>/sd_customize/sd_avail_cmds.cmd
where <language> is one of the local languages (french, german, italian, spanish, japanese). This file contains a number of commands that you can use to customize toolbars etc.
This section describes the syntax that is used to define an available command. The syntax is similar to LISP; however, you need a special Creo Elements/Direct Modeling function to read in such a file. The standard LISP function load cannot be used for this purpose.
Creo Elements/Direct Modeling will read additional command files
automatically at startup if you put them into certain directories
(corp/site/user) which are checked during startup. See here for more information.
Each command defined in such additional available command files is
appended to the list of available commands. If you specify a command
with the same command name, group and application as an
existing command, the existing command is overwritten (redefined). The last
definition in the order SD-corp-site-user wins.
(:Application "SolidDesigner") (:Group "Machine" :title "Machine") ("Linear Pull Profile" :title "Linear Pull Profile" :action (ui::uic-call-pull-action :linear-pull-profile) :description "Linear pull profile with immediate distance specification" :image "SolidDesigner/Machine/linear_pull_profile" :ui-behavior :relative :cmt-ui-behavior :on-request :context-enable (agent::workplane-enable-context-menu-entry :any-closed-profile))
Each expression is enclosed in parenthesis. If the first element of the list is a string, then that string represents a command name and that expression specifies a command. In the above example, "Linear Pull Profile" is a command name. Several other parameters follow the command string that describe the behavior of the command. All of these parameters are optional. If you omit such a parameter, a useful default will be taken.
Each command can be uniquely identified by the triple
"Application" - "Group" - "Command Name"
Thus, in this example the triple
"SolidDesigner" - "Machine" - "Linear Pull Profile"
describes the path to the command specification given above. The triple is used in customization files to uniquely specify the command that is related to an entry in a toolbar or in a popup menu.
Note that the same command name can occur several times in different groups and applications, and yet represents very different commands.
An expression of the type
(:Application "application")
marks the beginning of the definitions for a given application. All following command definitions will belong to the specified "application" until the ocurrence of another application entry in the available commands file.
An important application is the special virtual application "All". Commands belonging to the All application will be accessible in all add-on applications as well as in core Creo Elements/Direct Modeling itself. For example, if you run Annotation, commands belonging to "All" will be accessible.
The specification
(:Group "group" :title "title")
marks the beginning of a group. All following command definitions will belong to the specified group "group" until another group specification occurs in the available commands file. The group "title" is a localized string that will be presented to the user, in contrast to the "group" name itself.
Note that the "group" name is used to uniquely identify a command and not its "title". In the english sd_avail_cmds.cmd file "group" and "title" are usually the same strings.
(:Group "Help" :title "Help" :all-in-sd-access :yes)
The parameters for specifying an available command are provided below:
("command-name" :title title :action action :description description :image image-name :ui-behavior ui-behavior :sysCmdId sysCmd-id :range range :enable enable :context-enable context-enable :context-is-visible context-is-visible :context-action context-action :sd-access sd-access-flag :deleted deleted)
A LISP form will be evaluated immediately when you hit the button.
NOTE: If you pass a LISP form here, you need to prefix the LISP function with the package and two double colons. The package must to be known by Creo Elements/Direct Modeling at the time when the available commands file is loaded. If this is not possible in your case, enclose your LISP form in double quotes to make sure it is evaluated at run-time rather than during startup.
This image has to be in BMP or PNG format and will be searched in the directory
bitmaps/bmp/commands/"image-name"where "image-name" can contain further directories like "application"/"group". The physical image file in the specified directory has to have the file extension ".bmp".
The directory search order is the following:
If no image is found or none is specified for this command, Creo Elements/Direct Modeling uses the command title as string instead of an icon.
Note: :enable expressions are called by the Windows framework very frequently. Make sure that your :enable form performs very fast and does not create LISP garbage!
At run-time of Creo Elements/Direct Modeling you can create new or modify existing available commands using a built-in UI. Open the Customize menu and make the Commands page current: Click on New ... or Modify ... (accessible only if you selected a command) to open the User defined Command UI.
As soon as you leave the dialog to create/modify a user defined command, Creo Elements/Direct Modeling stores the information automatically to a file named
user_avail_cmds.cmd
in your personal customization directory.
This file is loaded (if available) automatically with every startup of
Creo Elements/Direct Modeling after all corp/site/user
sd_avail_cmds.cmd files were loaded.
The syntax used in this file is equivalent to the one described above.
Toolbar and context menu files are written automatically to your personal customization directory if you interactively modified one of these while the Options or accordingly the Customize menu was open.
<application-prefix>_ribbon.lsp
All module based customization files are saved into Modules folder under customization directory. Naming convention of customized files for modules:
Modules/<module-prefix>_ribbon.lsp
Module Name Prefix ---------------------------------------- Application Interface appl_int Model Manager(Annotation) mm_am Model Manager(Modeling) mm_sd Basic Sheets bas_sheet Surfacing surf part Library (Annotation) prt_lib_am part Library (Modeling) prt_lib_sd
Utility(shared) group customization exists separately for Annotation and Modeling. File name for Utility group customization is:
<application-prefix>_utility_ribbon.lsp
The contents of Ribbon Customization files are, a list of Integration Kit function calls used for creation of Ribbon Bar.
On startup of Creo Elements/Direct Modeling or Annotation Utility Group: the first file found in the directories user, site, corp or SD is considered to define the contents of it. Rest of Ribbon Bar Customization: loads every file found in any SD, corp, site or user directories.
sd_qat_contents.lsp
ANNOTATION/am_qat_contents.lsp
The contents of these files consist of a list of available commands which are defined by the unique triple Application - Group - Command.
On startup of Creo Elements/Direct Modeling or Annotation the first file found in the directories user, site, corp or SD is considered to define the contents of the quick access toolbar.
<application-prefix>_cmt_contents.lsp
Different command mini toolbars exist for the following applications:
All other modules and applications use the command mini toolbars defined for Modeling.
The file contain a list of available commands for a number of system defined keywords. Each keyword represent a specific type of preselection contents. If for example a single planar face is selected the contents of the mini toolbar is equal to the list of available commands listed after the keyword :planar-face.
On startup of Creo Elements/Direct Modeling or one of the other specified applications the first file found in the directories user, site, corp or SD is considered to define the contents of the command mini toolbars.
Each toolbar is represented through a separate file named:
Toolbar-Name.tlb
The load sequence of toolbar files defines the initial UI layout of Creo Elements/Direct Modeling in case no UI layout file file is present. To determine the initial UI layout Creo Elements/Direct Modeling does the following:
To achieve a deterministic initial UI layout, a file name convention as follows has been estabilished:
Name is a useful name which identifies the toolbar.
A sample toolbar customization file looks like this:
(toolbar-filing-revision "20.3") (win-user-toolbar :name "Model 3D" :application "SolidDesigner" :title "Model 3D" :docking :left) ("Linear Pull Profile" :application "SolidDesigner" :group "Machine") ("Angular Pull Profile") (separator) ("Blend Create" :group "Modify 3D")
The entry (toolbar-filing-revision "20.3") indicates that this toolbar definition file was last adapted for Creo Elements/Direct Modeling 20.3 (aka 20.3). Usually such files are not downwards compatible and should not be used in older Creo Elements/Direct Modeling versions.
win-user-toolbar describes the toolbar and its specific attributes. Here a complete listing and description of all valid toolbar attributes:
All other entries in the toolbar file fill this toolbar. You can have button entries, separator entries and even submenu entries. Submenus are defined by enclosing the submenu entries by the expressions
(start-submenu "Submenu-Name")
and
(end-submenu)
All button, separator and submenu entries which follow the start-submenu entry will appear in that submenu. This technique allows you to have any number of further menus cascading from this menu. To end a submenu definition, you need an end-submenu entry.
A "&" sign in the name of a submenu has a special meaning and indicates that the character which follows the "&" sign will be used for keyboard traversal and will appear underlined in the UI.
Any button, submenu or separator entry which appears before win-user-toolbar is ignored. It is not possible to have a second win-user-toolbar entry in the same toolbar file.
A button entry identifies an available command uniquely by the identifier
triple Command Name - Group Name - Application.
"Linear Pull Profile" above is an example for this. This command
references the Linear Pull Profile command from the application
SolidDesigner in the group Machine. All further references to
available commands like "Angular Pull Profile" are taken from the
same group and the same application until a command defines a new group
and/or application.
The command "Blend Create" redefines the actual group to be
Modify 3D. Therefore Blend Create refers to the command in the
Modify 3D group also in the SolidDesigner application.
Creo Elements/Direct Modeling defines a couple of preselection context menus which can be popped up in viewports depending on the type of previously selected elements and objects. If nothing was selected, the regular Viewing or Catch/Select/Show (if you hold the SHIFT key) popup menus will appear.
The files which describe the contents of the regular viewport popup menus are:
sd_vp_rmb.pum - the Viewing popup menu (Right-Mouse-Button)
sd_vp_srmb.pum - the Catch/Select/Show popup menu (Shift-Right-Mouse-Button)
sd_command_specific.pum - the Command Specific popup menu which will be filled at run-time with entries specific to the current active command
The files for the various preselectable objects are:
sd_presel_assembly.pum - the Assembly preselection menu
sd_presel_part.pum - the Part preselection menu
sd_presel_wp.pum - the Workplane preselection menu
sd_presel_face.pum - the Face preselection menu
sd_presel_edge.pum - the Edge preselection menu
sd_presel_edge_2d.pum - the Edge preselection menu
sd_presel_3d_anno.pum - the 3D Annotation preselection menu
sd_presel_docuplane.pum - the Docuplane preselection menu
The Viewing viewport popup menu file ("sd_vp_rmb.pum") may look like this:
;; Default Creo Elements/Direct Modeling Viewport-Right-Mouse-Button Menu: (popup-menu-filing-revision "20.3") (popup-menu-attributes :title "Viewing") ("Fit" :application "All" :group "View") ("Window") ("Redraw") ("Last View") (start-submenu "Zoom") ("Zoom Out 10") ("Zoom Out 5") ("Zoom Out 2") ("Zoom In 2") ("Zoom In 5") ("Zoom In 10") (end-submenu) ;; "Zoom" (start-submenu "Rotate Center") ("Rotate View Center Follow Mouse") (separator) ("Rotate View Center Camera Reference Point") ("Rotate View Center Viewport Center") ("Rotate View Center Model Center") ("Rotate View Center Select") (end-submenu) ;; Rotate center (separator) ("Full Screen") (separator) ("Flip View") ("View by Curr WP") ("View by Curr WP and Fit") ("View by Any WP") ("View by Face") (start-submenu "Isometric") ("Isometric XYZ") ("Isometric XY-Z") (end-submenu) ;; "Isometric" (separator) ("Deactivate Configuration" :application "SolidDesigner" :group "Configuration") ("Capture Camera In Active Configuration") ("Capture Drawlist In Active Configuration") ("Capture Camera And Drawlist In Active Configuration") (separator) ("Show Settings ..." :application "All" :group "View") ("Light Settings ...") ("Viewport Settings ...")
A preselection context menu file looks very similar. The following is the default Face Preselection Context Menu definition file ("sd_presel_face.pum"):
;; Default Creo Elements/Direct Modeling context menu if a face is preselected: (popup-menu-filing-revision "20.3") ;; Reference to the regular viewing popup menu ... (cascading-popup :type :viewport-right-mouse-button :title "Viewing") (separator) ;; Context sensitive commands ... ("Line/Arc" :group "2D CoPilot" :application "SolidDesigner" :title "2D CoPilot (Line/Arc)") (separator) ("Taper" :group "Modify 3D") ("Move 3D") ("Stretch") ("Linear Pull Faces") ("Cut Faces") ("Copy Faces") ("Offset") ("Radial Offset") ("Radial Move") ("Change Radius") ("Align") ("Delete Face" :group "Surfacing") (separator) ("Blend Modify" :group "Modify 3D") ("Chamfer Modify") ("Blend Remove") ("Chamfer Remove") (separator) ("Position Dynamic" :application "SolidDesigner" :group "Part and Assy" :title "Position Part") (separator) ("MM Reload Lightweight" :application "SolidDesigner" :group "ModelManager") (separator) ("Clipped Cross Section" :group "Measure") ("Define Clipping On Face" :group "Clipping") ("Define Clipping On Axis") ("Face Mass Properties" :group "Measure") ("Face Properties" :group "Settings")
The difference in this example to the regular Viewing popup menu definition file is the entry cascading-popup.
This entry allows you to reference other popup or preselection context menus from this one. At run-time if the user clicks this Viewing (see :title) button in this face preselection menu, the regular Viewing popup menu will appear as cascading submenu.
The following keywords as value for :type are supported:
and the following if you have activated the Annotation module:
The functionality which is called if a user clicks a mouse button without any modifier key or with any combination of the modifier keys SHIFT, CTRL and ALT is defined in this file:
all_mouse_defs.lsp
This file contains LISP functions like this:
(defun ShiftControlButton1 ("rest args) (declare (ignore args)) (oli:sd-put-buffer "set_catch_parameters :next_catch") (oli:sd-put-buffer "set_catch_parameters :center") (oli:sd-put-buffer (oli:sd-get-last-vp-pick)))
The LISP function names are fixed and must not be changed, otherwise they
will not be executed at all. Some LISP functions can't be customized. These
functions are marked with a comment in their body.
You can copy the all_mouse_defs.lsp file to a corp, site or user customization directory to
apply any changes to the bodies of the defined LISP functions. Functions you
don't want to change can be removed from the copied file(s), because Creo
Elements/Direct Modeling will load every file found in any SD, corp, site or
user directories. The last definition of a mouse button function wins.
Keyboard shortcuts and command abbreviations can be defined interactively at run-time. You can assign a specific keyboard combination or character sequence as abbreviation to any existing available command of any currently active application. This information is kept in a file named:
'app-specific-subdir'/app-prefix_shortcuts.acc
By default Creo Elements/Direct Modeling ships three keyboard shortcut and abbreviation definition files:
The contents of such a file (here sd_shortcuts.acc) looks like this:
(keyboard-filing-revision "20.3") (start-keyboard-accelerators) ("F4" :command "3D Hidden On/Off" :group "Show" :application "SolidDesigner") ("F5" :command "3D Geometry On/Off") ("F6" :command "Shaded/Wire") ("F7" :command "WP Borders On/Off") ("F8" :command "WP Axes On/Off") ("CTRL F" :command "Search" :group "Miscellaneous") ("CTRL N" :command "New Session" :group "Filing") ("CTRL O" :command "Load ...") ("CTRL S" :command "Save ...") ("CTRL TAB" :command "Flyby Probe" :group "Select") ("TAB" :command "Flyby Feat Select Next") ("SHIFT TAB" :command "Flyby Feat Select Previous") ("DELETE" :command "Universal Delete" :group "Delete") (start-command-abbreviations) ("dac" :command "Delete All 3D" :group "Delete" :application "SolidDesigner")
As you can see, each .acc file has two sections which are initiated with (start-keyboard-accelerators) and (start-command-abbreviations).
In the first section, keyboard shortcuts are defined. The first string of each line defines the shortcut. This can be a combination of the following:
separated by a space character.
Examples: "Shift Ctrl A" or "Ctrl NumPad5"
After the keyboard shortcut string you need to identify the available command which you want this keyboard shortcut to be used for. This is done by the unique triple Application - Group - Command. This is equivalent to available command references in toolbar or context menu definition files.
In the secend section of this file you define command abbreviations for specific available commands. The first string of such an entry is a sequence of characters which the user has to enter (including the ENTER key!) to call the available command.
Each application like Creo Elements/Direct Modeling, Annotation or Sheet Metal can have its own 'prefix'_shortcuts.acc file. On startup of Creo Elements/Direct Modeling or any other add-on application the first file found in the directories user, site, corp or SD is considered to define the keyboard shortcuts and command abbreviations for an application.
The following speciality is possible if you edit .acc files, but
which is not possible in an interactive way at run-time:
You can define the same keyboard shortcut for different commands within
different applications although both commands can be accessed. For example
you can define CTRL-O in Creo Elements/Direct Modeling to
call the Load ... command whereas you can assign CTRL-O to
Create new Sheet by Outline in the Sheet Metal application.
Depending on which application is current, Creo Elements/Direct Modeling
will call the one or the other command. That way it is possible to
shadow single command shortcuts.
This speciality does not apply to Annotation. Because all
Annotation commands can exclusively be accessed in Annotation
only and no Creo Elements/Direct Modeling (or other add-on
application) commands, the user can easily assign a shortcut key to an
Annotation command interactively at run-time, even though this
shortcut may already be defined for a Creo Elements/Direct Modeling
command. I.e. in this case it is not necessary to edit .acc files
to shadow e.g. Creo Elements/Direct Modeling commands.
Creo Elements/Direct Modeling and each add-on application store their actual screen layout to so-called UI Layout files. These files contain information about toolbar positions, toolbar states like docked, floating, visibility or size of all toolbars which can be accessed in this application plus some more information. Such files are written automatically to your personal customization directory and respective application subdirectories every time you switch between activated Creo Elements/Direct Modeling add-on applications and on termination of the main application.
UI layout files allow Creo Elements/Direct Modeling to reconstruct the exact same screen layout of Modeling or any add-on application the next time you start up Creo Elements/Direct Modeling.
By default Creo Elements/Direct Modeling does not ship any UI layout file for any application. The initial look is defined by the steps described here. You as a corp or site administrator can place UI layout files into a corp or site customization directory to preconfigure the initial UI layout for your users. To do so, just layout out the toolbars etc. as you like and copy the UI layout file(s) which were written to your personal customization directory to the site or corp customization directory. This approach has the additional advantage that if your users screwed up their UI they can not just reset the contents of all toolbars but also reset the UI layout to the definition given by site or corp. That means if Creo Elements/Direct Modeling detects a UI layout file in a site or corp directory which fits to the current active application, it enables the button Including UI Layout in the Reset All Toolbars menu.
The UI layout file for Creo Elements/Direct Modeling has the name sd_fluentui_layout.def and may look like this:
;; Automatically written on ... ;; Application: SolidDesigner (docking-filing-revision "20.3") (:application :normal (128 77 1664 1005) :screen (1920 1200)) (:PromptBar :visible nil :docking :bottom :auto-hide nil :dock-alignment 32768 :dock-rowindex 1 :mru-width 32767 :float-pos (10 10) :float-width 100 :float-height 100 :dock-location (1 0 0 34) :dock-width 1931 :dock-height 34 :docked-size (1920 0) :float-size (1513 0) ) (:BrowserBar :visible t :docking :left :auto-hide nil :dock-alignment 4096 :dock-rowindex 0 :mru-width 32767 :float-pos (57 57) :float-width 150 :float-height 200 :dock-location (0 0 0 145) :dock-width 150 :dock-height 711 :docked-size (150 300) :float-size (200 500) :hybrid-dockwidth 530 :hybrid-floatwidth 530 ) ... ("Standard" :application "SolidDesigner" :source "sd_t11_standard.tlb" :visible nil :docking :float :auto-hide nil :dock-alignment 4096 :dock-rowindex 0 :mru-width 32767 :float-pos (960 569) :float-width 421 :float-height 66 :dock-location (0 0 0 0) :dock-width 0 :dock-height 0 :docked-size (0 0) :float-size (0 0) ) ...
Because a user, site or corp administrator is not supposed to edit such UI layout files, the contents of such files and the parameter meanings are not explained in detail.
In case a user has created his own toolbars (i.e. a site or corp provided
UI layout file does not contain any information about these user toolbars)
and the user does a Reset All Toolbars with the button Including
UI Layout set, his user toolbars will not be visible in the UI after
that. Now, if the user switches one of his toolbars on, this toolbar will
appear floating in the center of the application although it may have been
docked before he did the reset operation. This information is lost as soon
as a UI layout file is reapplied which does not contain information about
such user toolbars.
As soon as the user docks his toolbar somewhere and he toggles to a
different application or terminates Creo Elements/Direct Modeling, the new
location is stored again in the user's UI layout file.
Settings within Creo Elements/Direct Modeling like Units which are changed interactively at run-time and which are persistent are stored to PDS files automatically on termination of the main application or on deactivation of an add-on module.
The name of a PDS file is:
'app-specific-subdir'/app-prefix_data.lsp
These files contain settings which were changed by the user and which don't match the built-in default setting anymore.
An example all_data.lsp PDS file which contains settings valid in all applications may look like this:
;; Automatically written on ... ;; Module ALL (in-package :mei) (persistent-data-revision "20.3") (persistent-data-module "ALL") (persistent-data :key "UNITS" :value '( :MASS ( :G 1 ) :ANGLE ( :DEG 1 ) :LENGTH ( :INCH 1 ) ) ) (persistent-data :key "STARTUPDIR" :value "C:\\temp") ...
All PDS files found in SD, corp, site and user directories are loaded on startup of Creo Elements/Direct Modeling or on activation of an add-on module. The most recent setting defined in the above given order wins and becomes the active setting. That way a user can redefine a setting preconfigured by a site or corp customization.
If you as a site or corp administrator want to make specific settings which vary from the default Creo Elements/Direct Modeling settings, the default for your users, copy the required PDS file(s) from your personal customization directory to the site or corp directory. Edit the copied file(s) and remove settings which you don't want to set/change on corp or site level and just leave the statement(s) about the setting(s) you want to change.
If you change default settings at run-time by means of the Default Settings Browser those changes are stored on module or latest on Creo Elements/Direct Modeling exit to default setting files in your personal customization directory.
Depending on whether style or global user data are written to the default settings file, the filename and contents looks different. The generated filenames are as follows:
As an example the contents of an Annotation text style file with name am_General_TextStyle_STANDARD.lsp may look like this:
;% Automatically written on ... ;% Creo Elements/Direct Modeling Revision: 2023 (20.3) (oli:sd-set-setting-values :application "Annotation" :style-path "Annotation/General/TextStyle" :style :STANDARD :title "Standard" :values '("Font" "Arial" "Size" 3.2 "Color" 40959 "Ratio" 1 ) )
For a detailed explanation of this contents and when which files are stored, please see the concepts section of the Default Settings manual.
On startup of Creo Elements/Direct Modeling or one of its add-on modules those default setting files are loaded automatically whenever a module implements default settings. Each individual style or global default value for a specific setting may be overwritten by a corp, site or user definition (in this order).
The Viewport Settings menu on page Background offers the ability to predefine viewport background colors. These predefined colors are defined via bitmap files with specific naming conventions in specific directories. All files which meet the specific conventions which are found in the following directories are loaded upon startup:
All BMP files found in these directories are ordered lexically (filename) and this order determines the order presented to the user on the Background page.
Each bitmap file must follow the following conventions:
Examples:
Note:
The upper left pixel of such bitmaps determines the transparent color of the
bitmap. In case you want to avoid this transparency, please make sure that
the color of this pixel does not occur somewhere else in the bitmap.
The contents of the Modules UI is defined in the file
all_modules.dat
This file can exist in a user, site, corp or SD customization directory. The first file found in this order defines the contents of the UI.
The file contents may look like this:
" (:page "Modules" :title "Modules") ("-" :title "Included") ("CADCAM_LINK" :label "Machining" :act-fun (load "CadCamAdapter") :deact-fun (module-deactivate "CADCAM_LINK") :special :demo) ("RENDERING" :label "Rendering" :act-fun (activate-rendering) :deact-fun (deactivate-rendering) :special :sd-access) ... (:page "Applications" :title "Applications") ("-" :title "Included") ("ANNOTATION" :label "Annotation" :act-fun (activate-annotation) :deact-fun (deactivate-annotation) :special :demo) ("3DDOCU" :label "3D Documentation" :act-fun (activate-3ddocu) :deact-fun (deactivate-3ddocu) :special :demo) ...
The documentation of every possible entry and parameter is given in the default all_modules.dat file which is shipped with Creo Elements/Direct Modeling. Please see e.g. INSTALLDIR/personality/sd_customize/all_modules.dat for more details.
Note: In this file you can't reference a LISP function in a LISP package which is created in custom code, because the custom code will be initialized after the Modules UI file is loaded. To solve this problem you have two possibilities:
:act-fun "(my-package::my-module-activation-function)"
Modules which should be activated right with startup of Creo Elements/Direct Modeling are kept in the PDS key "Startup Modules" in the All application PDS file all_data.lsp. Usually this value is stored automatically as soon as the user modifies the default startup activation sequence using the Module Activation at Startup UI. This entry can be provided in a all_data.lsp PDS file located in a site or corp customization to predefine the modules which should be activated automatically for your group of users.
All save and load operations in Creo Elements/Direct Modeling are controlled by means of a file manager. The selection of a file type in the file manager not only influences the display of the files but also immediately triggers a command that takes over the control for collecting further user inputs and for carrying out the desired operation.
By contrast, the normal file browser is used as an input tool in a dialog for collecting a file name. Changing the file type merely impacts the display of the files in the file browser.
Both the file manager and the file browser support the specification of any number of user customizable project directories. These directories can be added/modified/deleted interactively by the user and/or can be set up through a corp, site or user specific customization file with name:
all_filer_project_dirs
The first file found in the order user, site, corp, SD is taken to build the list of project directories.
The user specific file will be written automatically when the user hits the buttons Add current or Edit in the popup menu that changes the current directory. The popup menu appears when right clicking in the combobox to the right of the Look in: (Load) or Save in: (Save) label.
The above files can contain any number of the following project dir specifications:
"c:/temp" ;; Physical directory and display name (nickname) are identical ("c:/users/joe_engineer") ;; same as before (physical = display) ("Package Files" "c:/users/joe_engineer/Modeling/pkg_files") ;; in this case the physical directory name is hidden from the user ;; and the UI will only display its "nickname" here "Package Files"
Above the user defined project directories are three fixed entries:
The file types of the file manager can be customized by means of the following file:
all_load_save_file_types.dat
The first file found in the order user, site, corp, SD is considered to define the order in which the file types appear in the file manager. The above file can also be used to modify the behavior of individual file types.
See File Manager Customization for more possibilities to customize the file manager.
You as a corp or site administrator can add additional browser views or browser queries (searches and filters) to Creo Elements/Direct Modeling. A user can add new browser queries (or modify existing) at runtime in an interactive way. These new (or modified) browser searches and filters are automatically stored on termination of Creo Elements/Direct Modeling.
During startup of Creo Elements/Direct Modeling files with name sd_browser_views.lsp are loaded automatically from SD, corp, site and user directories if available. These files can contain any number of browser views, configurations and column specifications.
On activation of ModelManager additional views etc. are loaded from files with name mm_browser_views.lsp in subdirectories with name ModelManager within SD, corp, site and user directories.
For more information about the contents of such xxx_browser_views.lsp files, please see Browser Views.
In addition to Browser Views, Creo Elements/Direct Modeling automatically loads files with name sd_browser_search_and_filter.lsp during startup from the SD, corp, site and user directories if available. These files can contain any number of preconfigured browser filters and searches for the Structure Browser and/or the Clash Analysis Browser.
On activation of ModelManager additional browser searches and filters are loaded from files with name mm_browser_search_and_filter.lsp in subdirectories with name ModelManager within SD, corp, site and user directories.
For more information about the contents of such xxx_browser_search_and_filter.lsp files, please see Browser Queries.
Creo Elements/Direct Modeling supports two ways of providing multi-language site and corp customizations:
(ui::multi-lang "Text in English" :german "Text in German" :french "Text in French" :italian "Text in Italian" :spanish "Text in Spanish" :japanese "Text in Japanese")At runtime, Creo Elements/Direct Modeling picks the appropriate string which fits to the current language. Note that all language definitions are optional, so you may provide just the first string and an additional string in e.g. German. If you run Creo Elements/Direct Modeling in a language for which you did not specify a string for, the first string - also known as fallback string - is used. Therefore the first string is most likely the English one.
If you run Creo Elements/Direct Modeling in a semi-supported language the keyword which matches
the language string as passed to the $LANG or $SDLANG
system variable can be used to define a multi-lang string in that
semi-supported language.
Example: (ui::multi-lang "Text in English" :chinese_s "Text in
simplified chinese")
SDLANGDEPCUSTOMIZEDIRSto any value (e.g. 1), you can tell Creo Elements/Direct Modeling to look for language-specific subdirectories in user, site and corp directories. That means Creo Elements/Direct Modeling will look in the following directories for corp customization files if Creo Elements/Direct Modeling runs in the following languages:
The same is true for site and user customizations. Just replace
$SDCORPCUSTOMIZEDIR with $SDSITECUSTOMIZEDIR or the
personal customization directory in the list above.
This approach mirrors the directory structure that comes with core Creo
Elements/Direct Modeling in INSTALLDIR/personality.
This section describes the system variables and directories which are considered in an english Creo Elements/Direct Modeling environment. For more details on localized versions of Creo Elements/Direct Modeling, see here.
INSTALLDIR denotes the installation directory of your Creo Elements/Direct Modeling. Usually this is
C:/Program Files/PTC/Creo Elements/Direct Modeling 20.3.5.0
Note: Corp and Site customization directories are optional. If the respective system variable (see above) is not set, no Corp and/or Site customization is considered.
If the default user customization does not exist the first time Creo Elements/Direct Modeling 20.3 starts up it will be created automatically. If $SDUSERCUSTOMIZEDIR is set to a non-existing directory, Creo Elements/Direct Modeling 20.3 tries to create that directory at first startup. If the directory creation fails, Creo Elements/Direct Modeling takes the default user customization directory as fallback.
At runtime go to Edit -> Settings -> UI Settings -> Customizations tab -> Show Directories ... to display the actual used and set SD/Corp/Site/User directories.
If you run Creo Elements/Direct Modeling as a localized version in:
the following customization directories are considered:
where $LANG is one of the strings (lowercase) in the list above.
As you can see just the SD directory has changed compared to an english Creo Elements/Direct Modeling. That is because users usually run just one language of Creo Elements/Direct Modeling and not any mixed environment.
If a Site and/or Corp customization wants to support multiple languages they can do so by means of sd-multi-lang-string or ui:multi-lang.
If you want to have language dependent Corp/Site/User directories you can set the system variable:
SDLANGDEPCUSTOMIZEDIRS
to the value 1. In that case the following directories become active:
Note: Creo Elements/Direct Modeling will search for customization files only in the above-mentioned directories. There is no fallback search in the not localized english directory.
If you want to run Creo Elements/Direct Modeling as a localized version in a language which is not provided by PTC (not one of english, german, italian, french, spanish, japanese) some degree of support is provided.
Basically the same mechanism as described above including support of SDLANGDEPCUSTOMIZEDIRS apply to other locales as well. The language specific subdirectory which is searched in user/site/corp/sd directories corresponds to the language string which you passed to the $LANG or $SDLANG system variable (in lower case).
For example if you set $LANG="chinese_s" for simplified chinese, the following customization directories are searched (with SDLANGDEPCUSTOMIZEDIRS set):
Note: If Creo Elements/Direct Modeling finds the file
sd_avail_cmds.cmd in the SD Customization Directory INSTALLDIR/personality/$LANG/sd_customize this
directory will be used as exclusive SD customization directory (no fallback
load in non-localized english directory).
If this file could not be located in that directory, the normal english SD
customiztion directory is taken: INSTALLDIR/personality/sd_customize.
That means, if you want to provide a factory (SD) customization for a
semi-supported language, you have to copy all contents of the english
customization directory to that language directory (and localize messages in
these files to your needs), otherwise Creo Elements/Direct Modeling will
startup with an almost empty UI.
The language strings accepted by $LANG or $SDLANG which are supported to some degree can be inquired from your local PTC support on request.
Usually only the default user customization directory is dependent on the Creo Elements/Direct Modeling version. If you want to have version dependent Corp/Site/User directories you can set the system variable:
SDVERSIONDEPCUSTOMIZEDIRS
to the value 1. In that case the following directories become active:
If you set SDLANGDEPCUSTOMIZEDIRS in addition to SDVERSIONDEPCUSTOMIZEDIRS you need to add the $LANG specific subdirectory to each directory described above.
If you set SDLANGDEPCUSTOMIZEDIRS in addition to SDVERSIONDEPCUSTOMIZEDIRS you need to add the $LANG specific subdirectory to each directory described above.
Creo Elements/Direct Modeling distinguishes between two types of files loaded from one or more customization directories:
So, each file found in any of these directories is loaded in the above-specified order. That way, a Site file can overwrite a setting done by a Corp customization without the need to duplicate the complete Corp customization.
Examples:
Examples:
The Integration Kit supports these two concepts by providing two functions:
If you start Creo Elements/Direct Modeling in verbose mode (-v command line option) you'll see in the console window which customization files are loaded from which directory.
Note: The system variable SDCORPISADDITIVE is set to 1 by default since OneSpace Designer 2005 (= 13.00). So, by default Corp customizations don't replace factory customizations but rather add or modify Creo Elements/Direct customizations.
If you really want to replace any Creo Elements/Direct customization with a Corp customization (this was the default before OneSpace Designer 2004) you need to set SDCORPISADDITIVE=0.
Customization filenames and directories follow a unified naming
convention.
Filenames have a specific module/application prefix and are located in a
specific module/application subdirectory:
'Directory Name'/'Prefix'_'Filename'
At startup of Creo Elements/Direct Modeling a README.txt is written automatically to your personal customization directory. This file contains a table which maps the module/application name to its specific customization subdirectory and its specific filename prefix.
A few examples:
Product Name Subdirectory Prefix (Internal Name) --------------------------------------------------------------------------- Modeling sd (SolidDesigner) Annotation ANNOTATION am (Annotation) Sheet Metal SheetAdvisor sha (SheetAdvisor) 3D Documentation 3D_DOCUMENTATION d3d (3D Documentation) ...
With this table you can easily determine from which customization subdirectory (relative to any SD/Corp/Site/User directory) a module/application specific customize file is loaded with which filename prefix.
Note: Customize files which are valid in Creo Elements/Direct Modeling and in all add-on modules/applications have the prefix all_ and are loaded from the Creo Elements/Direct Modeling subdirectory (i.e. no subdirectory).
The following table illustrates which customization files are loaded when and from where during startup of Creo Elements/Direct Modeling:
Seq | Filename(s) | Load Sequence | Description |
---|---|---|---|
1 | sd_data.lsp |
All files found in:
|
PDS file for Creo Elements/Direct Modeling |
2 | all_data.lsp |
All files found in:
|
PDS file for All applications |
3 | sd_*.lsp |
All files found in:
|
Default setting files (default, style, profile) |
4 | sd_avail_cmds.cmd |
All files found in:
|
Available commands file with All and Creo Elements/Direct Modeling commands |
5 | user_avail_cmds.cmd | If found in User | User Available Commands defined by New ... or Modify ... in Customize dialog |
6 | all_shortcuts.acc |
First file found in:
|
Keyboard shortcuts and command abbreviations for All applications |
7 | *.tlb |
All files found in:
|
Toolbar definition files. Load order and creation sequence depend on lexical order of filenames and file contents. For more information see here. |
8 | sd_vp_rmb.pum sd_vp_srmb.pum |
First file found in:
|
Viewport Right-Mouse-Button and SHIFT-Right-Mouse-Button context menu definition files |
9 | sd_presel_assembly.pum sd_presel_part.pum sd_presel_wp.pum sd_presel_face.pum sd_presel_edge.pum sd_presel_edge_2d.pum sd_presel_3d_anno.pum sd_presel_docuplane.pum |
First file found in:
|
Preselection context menu definition files |
10 | sd_command_specific.pum |
First file found in:
|
Command specific context menu definition file. Contents mainly filled at run-time. |
11 | sd_shortcuts.acc |
First file found in:
|
Keyboard shortcuts and command abbreviations for Creo Elements/Direct Modeling |
12 | sd_cmt_contents.lsp |
First file found in:
|
Command Mini Toolbar (CMT) contents definition file for Modeling. |
13 | dif_customize |
All files found in:
|
Custom Feature customize file |
14 | hrd_customize |
All files found in:
|
High Resolution Dump customize file |
15 | *.bmp |
All files found in:
|
Predefined viewport background color file |
16 | sd_qat_contents.lsp |
First file found in:
|
Quick Access Toolbar (QAT) contents definition file for Modeling and all modules and applications except Annotation. |
17 | all_ribbon.lsp |
All files found in:
|
Ribbon Bar customization definition file for All applications |
18 | sd_ribbon.lsp |
All files found in:
|
Ribbon Bar customization definition file for Modeling |
19 | sd_utility_ribbon.lsp |
First File found in:
|
Ribbon Bar Utility group definition file for Modeling |
20 | all_modules.dat |
First file found in:
|
Modules UI definition file |
21 | pesd_startup | First file found according to (search-directories) | Creo Elements/Direct Modeling startup file. File can be customized with -l command line parameter. |
22 | ani_customize |
All files found in:
|
Animation customize file |
23 | sd_fluentui_layout.def |
First file found in:
|
UI layout definition file for Creo Elements/Direct Modeling |
24 | all_load_save_file_types.dat |
First file found in:
|
File type definition list to be used in File Manager |
25 | all_filer_project_dirs |
First file found in:
|
Definition file for project directories to be used in File Manager context menu |
26 | all_mouse_defs.lsp |
All files found in:
|
Mouse button shortcuts definition file |
27 | sd_browser_views.lsp |
All files found in:
|
Browser views, configurations and column specifications |
28 | sd_browser_search_and_filter.lsp |
All files found in:
|
Browser searches and filters |
29 | sd_lights.lsp |
First file found in:
|
Viewport lights definition file |
30 | pesd.env |
First file found in:
|
Environment file |
31 | sd_customize |
All files found in:
|
Main Creo Elements/Direct Modeling customization file |
Image files to be used as images for the Fluent UI must be of BMP or PNG format. Buttons displayed in the Fluent UI appear in 3 different sizes: small, medium and large.
Button Size | Image Size | File Name | Extension |
---|---|---|---|
small | 16x16 | "image-name"_16 | .bmp or .png |
medium (default) | 24x24 | "image-name" | .bmp or .png |
large | 32x32 | "image-name"_32 | .bmp or .png |
The image is only referenced by its base name "image-name" without any size specification. One image file must exist without size specification. The real size of this image, if it is one of the 3 above mentioned sizes, is not important. The other image files are optional. Images of size 16x16 and 32x32 are used for ribbon user interface, images of size 24x24 are still referenced in toolbars. If only one image is available the necessary sizes of images to be shown in the Fluent UI are created by automatic scaling of the image. If all 3 files exist no scaling is necessary. The look and feel of the user interface is much better.
To ensure a transparent background of the image on a button
For an indepth explanation of where image files are searched in which order see the description of the :image parameter of an available command definition.
An example of where to put an image file for your own available command:
Suppose you have defined the following available command in your personal sd_avail_cmds.cmd file:
(:Application "SolidDesigner") (:Group "My Group" :title "My Group") ("Create Cube" :title "Create Cube" :action "create_workplane :new complete rectangle 0,0 100,100 extrude :distance 100 complete" :description "Creates a 100x100x100 cube." :image "SolidDesigner/My_Group/create_cube" :ui-behavior :none)For this command you need to create a BMP (or PNG) image of size 16x16 with name "create_cube_16.bmp" and put this into the following directory:
$ProfileDir/Application Data/PTC/Creo Elements Direct Modeling 20.3.5.0/20.3/bitmaps/bmp/commands/SolidDesigner/My_Group
An easier way to create new commands with toolbar images is to use the New ... functionality from the Customize menu to create user defined commands at run-time.
A summary of environment (system or user) variables which can be set via Control Panel -> System Properties -> Advanced -> Environment Variables to tweak Creo Elements/Direct Modeling:
Variable | Value | Description |
---|---|---|
SDUSERCUSTOMIZEDIR | String | Path to the user customization directory |
SDSITECUSTOMIZEDIR | String | Path to the site customization directory |
SDCORPCUSTOMIZEDIR | String | Path to the corp customization directory |
SDCORPISADDITIVE | Any | see here |
SDLANG (or LANG) | String |
One of:
|
SDLANGDEPCUSTOMIZEDIRS | Any | see here |
SDVERSIONDEPCUSTOMIZEDIRS | Any | see here |
SDDONTSTOREUILAYOUTFILES | Any | Set this variable to prevent Creo Elements/Direct Modeling and all add-on modules to write *_fluentui_layout.def files. The user can still mess up the Creo Elements/Direct Modeling UI, but the next time he starts Creo Elements/Direct Modeling, the UI layout will be the one which was preconfigured at site or corp level or Creo Elements/Direct Modeling will appear with the default layout if no site or corp layout was given. |
SDDISALLOWINTERACTIVECUSTOMIZATION | Any | Set this variable to disable the Customize ..., Options and More Commands... (in Quick Access Toolbar) buttons in Creo Elements/Direct Modeling. That way the user can't customize any toolbars, popup menus, ribbonbar, quick access toolbar, command mini toolbar or keyboard shortcuts interactively at runtime. |
SDEDITOR | String | Path to the external editor to be used when the user calls File -> Edit File ... By default Notepad++ is used. |
SDTOOLBARICONEDITOR | String | Path to the external icon editor to be used to create or modify icons for existing or new available commands as well as for template (symbols, text) icons. By default Paint is used. |
SDPROJECTDIRHOME | String | Path to the directory which will be used as HOME in the right-click context menu of the Load - Look in: or Save - Save in: directory chooser. |
SDDEBUGOUTPUT | String |
Allows to specify where debug output messages should go to. This can be either:
|
SDDONTUSESAFELOAD | Any | Usually all customization files are loaded with
a special safe-load command to trap LISP errors and to
guarantee a successful startup of Creo Elements/Direct Modeling. If you rather want to use the regular LISP load command, set this variable to any value. That way, the startup process stops at the first LISP error. |
Note: Any as value for a variable means that this variable is defined and true. If you want this variable set to false you have to delete the environment variable.
Alternatively you can manually rename/remove your personal customization directory by doing these steps:
$ProfileDir/Application Data/PTC/Creo Elements Direct Modeling 20.3.5.0/20.3to something else.
If you frequently work with mixed languages, consider setting the system variable SDLANGDEPCUSTOMIZEDIRS to avoid these kind of problems.
The most likely reason for this is that you added LISP forms to a customization file like sd_avail_cmds.cmd, toolbar and popup menu files which contain LISP syntax errors. You might have forgotten a closing parenthesis, opened a string without closing it again with another double quote and things like this. Please check you customization files in respect to these potential errors.
Another reason why Creo Elements/Direct Modeling might end up in a LISP error during startup is that you defined a LISP form as action for an available command definition which refers to a symbol in a package which is not present at the time the sd_avail_cmds.cmd files are loaded. Avoid this by wrapping the available command action in double quotes.
© 2023 Parametric
Technology GmbH (a subsidiary of PTC Inc.), All Rights Reserved |