In This Article

RibbonControlService Class

Represents a service that provides properties and events for controls that are intended to be hosted in a Ribbon.

public static class RibbonControlService
Inheritance:
object object

Methods

GetCommand(DependencyObject)

Gets the value of the Command attached property for the specified object.

public static ICommand GetCommand(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

ICommand:

The object's value.

GetCommandParameter(DependencyObject)

Gets the value of the CommandParameter attached property for the specified object.

public static object GetCommandParameter(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

object:

The object's value.

GetCommandTarget(DependencyObject)

Gets the value of the CommandTarget attached property for the specified object.

public static IInputElement GetCommandTarget(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

IInputElement:

The object's value.

GetContext(DependencyObject)

Gets the value of the Context attached property for the specified object.

public static ControlContext GetContext(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

ControlContext:

The object's value.

GetHasImage(DependencyObject)

Gets the value of the HasImage attached property for the specified object.

public static bool GetHasImage(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

bool:

The object's value.

GetHasLabel(DependencyObject)

Gets the value of the HasLabel attached property for the specified object.

public static bool GetHasLabel(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

bool:

The object's value.

GetId(DependencyObject)

Gets the value of the Id attached property for the specified object.

public static string GetId(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

string:

The object's value.

GetImageSourceLarge(DependencyObject)

Gets the value of the ImageSourceLarge attached property for the specified object.

public static ImageSource GetImageSourceLarge(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

ImageSource:

The object's value.

GetImageSourceSmall(DependencyObject)

Gets the value of the ImageSourceSmall attached property for the specified object.

public static ImageSource GetImageSourceSmall(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

ImageSource:

The object's value.

GetIsExternalContentSupported(DependencyObject)

Gets the value of the IsExternalContentSupported attached property for the specified object.

public static bool GetIsExternalContentSupported(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

bool:

The object's value.

GetIsHighlighted(DependencyObject)

Gets the value of the IsHighlighted attached property for the specified object.

public static bool GetIsHighlighted(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

bool:

The object's value.

GetLabel(DependencyObject)

Gets the value of the Label attached property for the specified object.

public static string GetLabel(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

string:

The object's value.

GetMenuItemDescription(DependencyObject)

Gets the value of the MenuItemDescription attached property for the specified object.

public static string GetMenuItemDescription(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

string:

The object's value.

GetUseMonochromeImage(DependencyObject)

Gets the value of the UseMonochromeImage attached property for the specified object.

public static bool GetUseMonochromeImage(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

bool:

The object's value.

GetVariantSize(DependencyObject)

Gets the value of the VariantSize attached property for the specified object.

public static VariantSize GetVariantSize(DependencyObject obj)
Parameter Type Description
obj DependencyObject

The object from which the property value is read.

Returns

VariantSize:

The object's value.

SetCommand(DependencyObject, ICommand)

Sets the value of the Command attached property to the specified object.

public static void SetCommand(DependencyObject obj, ICommand value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value ICommand

The value to set.

SetCommandParameter(DependencyObject, object)

Sets the value of the CommandParameter attached property to the specified object.

public static void SetCommandParameter(DependencyObject obj, object value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value object

The value to set.

SetCommandTarget(DependencyObject, IInputElement)

Sets the value of the CommandTarget attached property to the specified object.

public static void SetCommandTarget(DependencyObject obj, IInputElement value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value IInputElement

The value to set.

SetContext(DependencyObject, ControlContext)

Sets the value of the Context attached property to the specified object.

public static void SetContext(DependencyObject obj, ControlContext value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value ControlContext

The value to set.

SetHasImage(DependencyObject, bool)

Sets the value of the HasImage attached property to the specified object.

public static void SetHasImage(DependencyObject obj, bool value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value bool

The value to set.

SetHasLabel(DependencyObject, bool)

Sets the value of the HasLabel attached property to the specified object.

public static void SetHasLabel(DependencyObject obj, bool value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value bool

The value to set.

SetId(DependencyObject, string)

Sets the value of the Id attached property to the specified object.

public static void SetId(DependencyObject obj, string value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value string

The value to set.

SetImageSourceLarge(DependencyObject, ImageSource)

Sets the value of the ImageSourceLarge attached property to the specified object.

public static void SetImageSourceLarge(DependencyObject obj, ImageSource value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value ImageSource

The value to set.

SetImageSourceSmall(DependencyObject, ImageSource)

Sets the value of the ImageSourceSmall attached property to the specified object.

public static void SetImageSourceSmall(DependencyObject obj, ImageSource value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value ImageSource

The value to set.

SetIsExternalContentSupported(DependencyObject, bool)

Sets the value of the IsExternalContentSupported attached property to the specified object.

public static void SetIsExternalContentSupported(DependencyObject obj, bool value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value bool

The value to set.

SetIsHighlighted(DependencyObject, bool)

Sets the value of the IsHighlighted attached property to the specified object.

public static void SetIsHighlighted(DependencyObject obj, bool value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value bool

The value to set.

SetLabel(DependencyObject, string)

Sets the value of the Label attached property to the specified object.

public static void SetLabel(DependencyObject obj, string value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value string

The value to set.

SetMenuItemDescription(DependencyObject, string)

Sets the value of the MenuItemDescription attached property to the specified object.

public static void SetMenuItemDescription(DependencyObject obj, string value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value string

The value to set.

SetUseMonochromeImage(DependencyObject, bool)

Sets the value of the UseMonochromeImage attached property to the specified object.

public static void SetUseMonochromeImage(DependencyObject obj, bool value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value bool

The value to set.

SetVariantSize(DependencyObject, VariantSize)

Sets the value of the VariantSize attached property to the specified object.

public static void SetVariantSize(DependencyObject obj, VariantSize value)
Parameter Type Description
obj DependencyObject

The object to which the attached property is written.

value VariantSize

The value to set.

Fields

ActiveItemChangedEvent

Identifies the ActiveItemChanged routed event. This field is read-only.

public static readonly RoutedEvent ActiveItemChangedEvent

ClickEvent

Identifies the Click routed event. This field is read-only.

public static readonly RoutedEvent ClickEvent

CommandParameterProperty

Identifies the CommandParameter dependency property. This field is read-only.

public static readonly DependencyProperty CommandParameterProperty

CommandProperty

Identifies the Command dependency property. This field is read-only.

public static readonly DependencyProperty CommandProperty

CommandTargetProperty

Identifies the CommandTarget dependency property. This field is read-only.

public static readonly DependencyProperty CommandTargetProperty

ContextProperty

Identifies the Context dependency property. This field is read-only.

public static readonly DependencyProperty ContextProperty

HasImageProperty

Identifies the HasImage dependency property. This field is read-only.

public static readonly DependencyProperty HasImageProperty

HasLabelProperty

Identifies the HasLabel dependency property. This field is read-only.

public static readonly DependencyProperty HasLabelProperty

IdProperty

Identifies the Id dependency property. This field is read-only.

public static readonly DependencyProperty IdProperty

ImageSourceLargeProperty

Identifies the ImageSourceLarge dependency property. This field is read-only.

public static readonly DependencyProperty ImageSourceLargeProperty

ImageSourceSmallProperty

Identifies the ImageSourceSmall dependency property. This field is read-only.

public static readonly DependencyProperty ImageSourceSmallProperty

IsExternalContentSupportedProperty

Identifies the IsExternalContentSupported dependency property. This field is read-only.

public static readonly DependencyProperty IsExternalContentSupportedProperty

IsHighlightedProperty

Identifies the IsHighlighted dependency property. This field is read-only.

public static readonly DependencyProperty IsHighlightedProperty

ItemClickEvent

Identifies the ItemClick routed event. This field is read-only.

public static readonly RoutedEvent ItemClickEvent

LabelProperty

Identifies the Label dependency property. This field is read-only.

public static readonly DependencyProperty LabelProperty

MenuItemDescriptionProperty

Identifies the MenuItemDescription dependency property. This field is read-only.

public static readonly DependencyProperty MenuItemDescriptionProperty

PreviewClickEvent

Identifies the PreviewClick routed event. This field is read-only.

public static readonly RoutedEvent PreviewClickEvent

UseMonochromeImageProperty

Identifies the UseMonochromeImage dependency property. This field is read-only.

public static readonly DependencyProperty UseMonochromeImageProperty

VariantSizeProperty

Identifies the VariantSize dependency property. This field is read-only.

public static readonly DependencyProperty VariantSizeProperty

Inherited Members