New to Telerik UI for WPFStart a free 30-day trial

Represents the width unit of a table in the Telerik document model.

Definition

Namespace:Telerik.Windows.Documents.Model

Assembly:Telerik.Windows.Controls.RichTextBox.dll

Syntax:

C#
[TypeConverter(typeof(TableWidthUnitConverter))]
public class TableWidthUnit

Inheritance: objectTableWidthUnit

Constructors

C#
public TableWidthUnit(double value)
Parameters:valuedouble
C#
public TableWidthUnit(TableWidthUnitType type, double value)
Parameters:typeTableWidthUnitTypevaluedouble
C#
public TableWidthUnit(TableWidthUnitType type)
Parameters:typeTableWidthUnitType

Properties

Represents the different types of table width units that can be used in a table.

C#
public TableWidthUnitType Type { get; }

Represents the width unit for a table in Telerik's document model.

C#
public double Value { get; }

Methods

Calculates the value of the table width in a specified unit based on the given float value.

C#
public float? Calculate(float availableWidth)
Parameters:availableWidthfloat

The float value representing the width, which will be used for the calculation.

Returns:

float?

The calculated width as a unit of type Telerik.Windows.Documents.Model.TableWidthUnit.

Determines whether the specified object is equal to the current TableWidthUnit instance.

C#
public override bool Equals(object obj)
Parameters:objobject

The object to compare with the current TableWidthUnit instance.

Returns:

bool

true if the specified object is equal to the current instance; otherwise, false.

Overrides: object.Equals(object)

Returns a hash code for the current instance of the TableWidthUnit class.

C#
public override int GetHashCode()
Returns:

int

A 32-bit signed integer that is the hash code for the current instance.

Overrides: object.GetHashCode()

Operators

C#
public static bool operator !=(TableWidthUnit left, TableWidthUnit right)
Parameters:leftTableWidthUnitrightTableWidthUnitReturns:

bool

C#
public static bool operator ==(TableWidthUnit left, TableWidthUnit right)
Parameters:leftTableWidthUnitrightTableWidthUnitReturns:

bool