BinaryRibbonGalleryControlColumnsCollectionConverter
class.NET 6 / 8 / 10.NET Framework 4.8Binarymission.WPF.Controls.Office
Reads the XAML text of BinaryRibbonGallery.RenderableGalleryColumnsProperty –
"6,4,0" – into a BinaryRibbonGalleryControlColumns.
public class BinaryRibbonGalleryControlColumnsCollectionConverter : TypeConverter
Inherits from / implements: TypeConverter
Remarks
XAML uses it on its own; there is no need to call it. Each comma-separated entry is a whole number of columns.
See also
Members at a glance
| Methods | |
|---|---|
CanConvertFrom | Reports whether a value of the given type can be read: only a string can. |
ConvertFrom | Reads a comma-separated list of column counts into a BinaryRibbonGalleryControlColumns. |
Methods
CanConvertFrom
public override bool CanConvertFrom(ITypeDescriptorContext context, Type sourceType)
Reports whether a value of the given type can be read: only a string can.
Parameters
context- Not used.
sourceType- The type of the value.
Returns
true for string; otherwise false.
ConvertFrom
public override object ConvertFrom(ITypeDescriptorContext context, System.Globalization.CultureInfo culture, object value)
Reads a comma-separated list of column counts into a BinaryRibbonGalleryControlColumns.
Parameters
context- Not used.
culture- Not used.
value- The text, such as
"6,4,0".
Returns
The column counts in the order given, or null for text that is only white
space.
Exceptions
System.NotSupportedExceptionvalueisnull, empty or not a string.System.FormatException- An entry is not a whole number.