Predefined list of commands that can be used by buttons anywhere on the ribbon.

Parent Elements

This element can appear as a child of the following elements.

ElementDescriptionVersion IntroducedPro Version Introduced
<Control>The root element for the SRP Ribbon Control.1.03.2

Child Elements

The following elements can be children of this one.

ElementDescriptionAppearsVersion IntroducedPro Version Introduced
<Command>A single command that is associated to one or more buttons on the ribbon.Zero or more1.03.2

Attributes

No attributes.

Remarks

The Command element contains the commands that can be used by the buttons scattered throughout the controls. A button must be associated to a command, and it's up to whether you want to define that command within the button itself or within this Commands element. In general, it's best to define those commands which you suspect will be used by multiple buttons. For example, you might have a save button in multiple places that uses the same SAVE command. See the <Command> element for more details.

Example

<Commands>
  <Command Key="FONTSIZEINCREASE" Caption="Increase Font Size" SmallIcon="Images\16x16\font_grow.png" Tooltip="Increases font size by one point." />
  <Command Key="FONTSIZEDECREASE" Caption="Decrease Font Size" SmallIcon="Images\16x16\font_shrink.png" Tooltip="Decreases font size by one point." />
  <Command Key="CHANGECASE" Caption="Change Case" SmallIcon="Images\16x16\character_change_case.png" Tooltip="Sets the selection to uppercase." />
  <Command Key="CLEARFORMATTING" Caption="Clear Formatting" SmallIcon="Images\16x16\font-remove.png" Tooltip="Removes all text formatting." />
  <Command Key="BOLD" Caption="Bold" SmallIcon="Images\16x16\character_bold_small.png" Tooltip="Sets the weight to bold." />
  <Command Key="ITALICS" Caption="Italics" SmallIcon="Images\16x16\character_italic_small.png" Tooltip="Sets the style to italics." />
  <Command Key="UNDERLINE" Caption="Underline" SmallIcon="Images\16x16\character_underline_small.png" Tooltip="Underlines the selection." />
  <Command Key="STRIKETHROUGH" Caption="Strikethrough" SmallIcon="Images\16x16\character_strikethrough_small.png" Tooltip="Strikes out the selection." />
  <Command Key="SUBSCRIPT" Caption="Subscript" SmallIcon="Images\16x16\character_subscript_small.png" Tooltip="Turns the selection into a subscript." />
  <Command Key="SUPERSCRIPT" Caption="Superscript" SmallIcon="Images\16x16\character_superscript_small.png" Tooltip="Turns the selection into a superscript." />
</Commands>
  • No labels