Class
DecorationUIConverter

Provides methods for converting text decoration settings to and from UI representations.

Definition

Namespace:Telerik.Windows.Documents.UI.TextDecorations.DecorationProviders

Assembly:Telerik.Windows.Controls.RichTextBox.dll

Syntax:

cs-api-definition
public class DecorationUIConverter : TypeConverter

Inheritance: objectTypeConverterDecorationUIConverter

Inherited Members TypeConverter.CanConvertFrom(Type)TypeConverter.CanConvertTo(Type)TypeConverter.ConvertFrom(object)TypeConverter.ConvertFromInvariantString(string)TypeConverter.ConvertFromInvariantString(ITypeDescriptorContext, string)TypeConverter.ConvertFromString(string)TypeConverter.ConvertFromString(ITypeDescriptorContext, string)TypeConverter.ConvertFromString(ITypeDescriptorContext, CultureInfo, string)TypeConverter.ConvertTo(object, Type)TypeConverter.ConvertToInvariantString(object)TypeConverter.ConvertToInvariantString(ITypeDescriptorContext, object)TypeConverter.ConvertToString(object)TypeConverter.ConvertToString(ITypeDescriptorContext, object)TypeConverter.ConvertToString(ITypeDescriptorContext, CultureInfo, object)TypeConverter.CreateInstance(IDictionary)TypeConverter.CreateInstance(ITypeDescriptorContext, IDictionary)TypeConverter.GetConvertFromException(object)TypeConverter.GetConvertToException(object, Type)TypeConverter.GetCreateInstanceSupported()TypeConverter.GetCreateInstanceSupported(ITypeDescriptorContext)TypeConverter.GetProperties(object)TypeConverter.GetProperties(ITypeDescriptorContext, object)TypeConverter.GetProperties(ITypeDescriptorContext, object, Attribute[])TypeConverter.GetPropertiesSupported()TypeConverter.GetPropertiesSupported(ITypeDescriptorContext)TypeConverter.GetStandardValues()TypeConverter.GetStandardValues(ITypeDescriptorContext)TypeConverter.GetStandardValuesExclusive()TypeConverter.GetStandardValuesExclusive(ITypeDescriptorContext)TypeConverter.GetStandardValuesSupported()TypeConverter.GetStandardValuesSupported(ITypeDescriptorContext)TypeConverter.IsValid(object)TypeConverter.IsValid(ITypeDescriptorContext, object)TypeConverter.SortProperties(PropertyDescriptorCollection, string[])

Constructors

DecorationUIConverter()

Declaration

cs-api-definition
public DecorationUIConverter()

Methods

CanConvertFrom(ITypeDescriptorContext, Type)

Determines whether the provided source type can be converted from the specified type.

Declaration

cs-api-definition
public override bool CanConvertFrom(ITypeDescriptorContext typeDescriptorContext, Type sourceType)

Parameters

typeDescriptorContext

ITypeDescriptorContext

An ITypeDescriptorContext that provides a format context.

sourceType

Type

The type to check for conversion.

Returns

bool

Returns true if the source type can be converted; otherwise, false.

Overrides TypeConverter.CanConvertFrom(ITypeDescriptorContext, Type)

CanConvertTo(ITypeDescriptorContext, Type)

Determines whether the conversion from a specified source type to a target type is supported.

Declaration

cs-api-definition
public override bool CanConvertTo(ITypeDescriptorContext typeDescriptorContext, Type destinationType)

Parameters

typeDescriptorContext

ITypeDescriptorContext

An instance of ITypeDescriptorContext that provides a format context.

destinationType

Type

The Type that represents the type to convert to.

Returns

bool

True if the conversion is supported; otherwise, false.

Overrides TypeConverter.CanConvertTo(ITypeDescriptorContext, Type)

ConvertFrom(ITypeDescriptorContext, CultureInfo, object)

Converts the specified object to a text decoration representation based on the provided context and culture information.

Declaration

cs-api-definition
public override object ConvertFrom(ITypeDescriptorContext typeDescriptorContext, CultureInfo cultureInfo, object source)

Parameters

typeDescriptorContext

ITypeDescriptorContext

The context in which the conversion is being performed, providing information about the environment.

cultureInfo

CultureInfo

The culture information used for the conversion process.

source

object

The object to be converted to a text decoration representation.

Returns

object

A value of type T that represents the converted text decoration.

Overrides TypeConverter.ConvertFrom(ITypeDescriptorContext, CultureInfo, object)

ConvertTo(ITypeDescriptorContext, CultureInfo, object, Type)

Converts the specified value to a specified type using the provided context and culture information.

Declaration

cs-api-definition
public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType)

Parameters

context

ITypeDescriptorContext

An object that provides a format context for the conversion.

culture

CultureInfo

A CultureInfo object that specifies the culture to be used for the conversion.

value

object

The value to convert.

destinationType

Type

The Type to which the value should be converted.

Returns

object

The converted value of the specified type. If the conversion fails, it may return null or throw an exception, depending on the implementation.

Overrides TypeConverter.ConvertTo(ITypeDescriptorContext, CultureInfo, object, Type)