In This Article

SizeVariant Class

Defines a size to be applied to a target control within a Ribbon.

public class SizeVariant : VariantBase, ISealable, ISizeVariant, IVariant
Inheritance:
System.Object System.Windows.Threading.DispatcherObject System.Windows.DependencyObject System.Windows.Freezable VariantBase Object

Constructors

SizeVariant()

Initializes a new instance of the SizeVariant class.

public SizeVariant()

SizeVariant(String, VariantSize)

Initializes a new instance of the SizeVariant class.

public SizeVariant(string targetKey, VariantSize size)
Parameter Type Description
targetKey System.String

The KeyProperty of the group which is the target of this definition.

size VariantSize

The size to be applied to VariantSizeProperty by this definition.

Properties

Size

Gets or sets the VariantSize to be applied to the target control's VariantSizeProperty by this definition.

public VariantSize Size { get; set; }

Property Value

VariantSize:

One of the VariantSize values. The default value is Small.

TargetKey

Gets or sets the string KeyProperty of the target control for this definition.

[Localizability(LocalizationCategory.NeverLocalize)]
public string TargetKey { get; set; }

Property Value

System.String:

A a string KeyProperty that identifies the target control.

Methods

CreateInstanceCore()

When implemented in a derived class, creates a new instance of the System.Windows.Freezable derived class.

protected override Freezable CreateInstanceCore()

Returns

System.Windows.Freezable:

The new instance.

Fields

SizeProperty

Identifies the Size dependency property.

public static readonly DependencyProperty SizeProperty

TargetKeyProperty

Identifies the TargetKey dependency property.

public static readonly DependencyProperty TargetKeyProperty

Inherited Members

  • System.Object.ToString()
  • System.Object.Equals(System.Object)
  • System.Object.Equals(System.Object, System.Object)
  • System.Object.ReferenceEquals(System.Object, System.Object)
  • System.Object.GetHashCode()
  • System.Object.GetType()
  • System.Object.MemberwiseClone()