-
Notifications
You must be signed in to change notification settings - Fork 35
AttributeUsage
CrypTool has specific attributes to support the plugin developer with GUI development. Some are optional, some essential and some attributes are only used for editor plugins:
- AuthorAttribute
Useability: Optional
Parameters:
- string author: the author's name
- string email: the author's e-mail address
- string institute: the author's institute
- string url: an url to the author's web site
- ComponentCategoryAttribute
Useability: Essential
Parameters:
- ComponentCategory category: set the plugin's category
- ContextMenuAttribute
Useability: Obsolete
- DontSaveAttribute
Useability: Optional
Parameters: none
Example:
- EditorInfoAttribute
Used to provide information about the editor's abilities.
Useability: Insignificant
Parameters:
- string defaultExtension: represents the editor's default file extension
- bool showAsNewButton: adds the editor to the "new"-button; default: true
- bool showLogPanel: show the log panel; default: true
- bool showSettingsPanel: show the settings panel; default: false
- bool showComponentPanel: show the component panel; default: true
- bool singleton: only one editor instance is allowed, if true; default: false
- bool canEdit: activates the buttons "Add Image" and "Add Text" at the category "Edit" of the ribbon bar; default: false
- LocalizationAttribute
Useability: Optional
Parameters:
- string resourceClassPath: the path to the resource class (i.e. namespace.classname)
- PluginInfoAttribute
Useability: Essential
Parameters:
- string resourceFile: the resource file - optional
- string caption: general name of the method
- string toolTip: the tooltip's text
- string descriptionUrl: URI to description, if provided
- params string[] icons: URIs to the plugin's icons
Example:
- PropertyInfoAttribute
Useability: Essential
Parameters:
- mandatory
- Direction direction: direction of the data
- string caption: the property's name
- string toolTip: description of the property
- optional
- bool mandatory: property is mandatory if set to true
- PropertySaveOrderAttribute
Useability: Obsolete
- RibbonBarAttribute
Useability: Obsolete
- SettingsFormatAttribute
Useability: Optional
Parameters:
- mandatory
- int indent: moves the property caption to the choosen indent
- string fontWeight: set the font weight
- string fontStyle: set the font style
- optional
- string foreGroundColor: set the foreground color
- string backGroundColor: set the background color
- Orientation orientation: set the orientation
- string widthCol1: Column width of column one. Is only used when no group is selected. Value samples: Auto, Auto or 1*, 2*. Last sample indicates that column 1 wants to be given twice as much of the available space as the row marked with 1*.
- string widthCol2: Column width of column two. Is only used when no group is selected.
- string verticalGroup: group some properties
- SettingsTabAttribute
Useability: Insignificant
Parameters:
- string caption: the settings' tabs name
- string address: the position in the settings tree
- double priority: A double that represents the settings tab priority. Tabs with higher priority will be shown first. default: 0.5
- TabColorAttribute
Useability: Insignificant
Parameters:
- string brush: the brush color
- TaskPaneAttribute
Useability: Essential
Parameters:
- mandatory
- string caption: parameter's name
- string toolTip: parameter's tooltip
- string groupName: parameter's group
- int order: A number to change the order of the parameters in the same group. Parameters with a lower number are displayed first. Parameters with same number are alphabetically arranged.
- bool changeableWhileExecuting: parameter is during the execution changable, if set to true
- ControlType controlType: parameter's control type
- optional
- params string[] controlValues: control values used to display in ComboBox
- ValidationType validationType: possibility to validate the input's type
- int integerMinValue: minimum value for instance for ControlType.NumericUpDown
- int integerMaxValue: maximum value for instance for ControlType.NumericUpDown
- double doubleMinValue: minimum value
- double doubleMaxValue: maximum value
- string regularExpression: regex validation for ControlType.TextBox
Example:
All supported attributes can be found in the project browser of your IDE at "CrypPluginBase/Attributes/xxx.cs".