Struct
SizeU

Stores an ordered pair of Unit-based numbers, typically the width and height of a rectangle.

Definition

Namespace:Telerik.Reporting.Drawing

Assembly:Telerik.Reporting.dll

Syntax:

cs-api-definition
[TypeConverter(typeof(SizeUConverter))]
public struct SizeU

Constructors

SizeU(Size)

Initializes a new instance of the SizeU class from the specified existing Size in device-independent pixels.

Declaration

cs-api-definition
public SizeU(Size sizeDips)

Parameters

sizeDips

Size

The Size from which to create the new SizeU.

SizeU(SizeF)

Initializes a new instance of the SizeU class from the specified existing SizeF in device-independent pixels.

Declaration

cs-api-definition
public SizeU(SizeF sizeDips)

Parameters

sizeDips

SizeF

The SizeF from which to create the new SizeU.

SizeU(Unit, Unit)

Initializes a new instance of the SizeU class from the specified dimensions.

Declaration

cs-api-definition
public SizeU(Unit width, Unit height)

Parameters

width

Unit

The width component of the new SizeU.

height

Unit

The height component of the new SizeU.

Fields

Empty

Initializes a new instance of the SizeU class.

Declaration

cs-api-definition
public static readonly SizeU Empty

Field Value

SizeU

Properties

Height

Gets or sets the vertical component of this SizeU.

Declaration

cs-api-definition
public Unit Height { get; set; }

Property Value

Unit

The vertical component of this SizeU.

IsEmpty

Gets a value indicating whether this SizeU has zero width and height.

Declaration

cs-api-definition
[Browsable(false)]
public bool IsEmpty { get; }

Property Value

bool

This property returns true when this SizeU has both a width and height of zero; otherwise, false.

Width

Gets or sets the horizontal component of this SizeU.

Declaration

cs-api-definition
public Unit Width { get; set; }

Property Value

Unit

The horizontal component of this SizeU.

Methods

Equals(object)

Tests to see whether the specified object is a SizeU with the same dimensions as this SizeU.

Declaration

cs-api-definition
public override bool Equals(object obj)

Parameters

obj

object

The object to test.

Returns

bool

This method returns true if obj is a SizeU and has the same width and height as this SizeU; otherwise, false.

Overrides ValueType.Equals(object)

GetHashCode()

Returns a hash code for this SizeU structure.

Declaration

cs-api-definition
public override int GetHashCode()

Returns

int

An integer value that specifies a hash value for this SizeU structure.

Overrides ValueType.GetHashCode()

ToString()

Creates a human-readable string that represents this SizeU.

Declaration

cs-api-definition
public override string ToString()

Returns

string

A string that represents this SizeU.

Overrides ValueType.ToString()

ToString(CultureInfo)

Creates a human-readable string that represents this SizeU.

Declaration

cs-api-definition
public string ToString(CultureInfo culture)

Parameters

culture

CultureInfo

A CultureInfo object according to which to format the string.

Returns

string

A string that represents this SizeU.

Operators

explicit operator Size(SizeU)

Converts the specified SizeU to a Size in device-dependent pixels.

Declaration

cs-api-definition
public static explicit operator Size(SizeU size)

Parameters

size

SizeU

The SizeU structure to be converted.

Returns

Size

The Size structure to which this operator converts.

explicit operator SizeF(SizeU)

Converts the specified SizeU to a

Declaration

cs-api-definition
public static explicit operator SizeF(SizeU size)

Parameters

size

SizeU

The SizeU structure to be converted.

Returns

SizeF

The SizeF structure to which this operator converts.

operator !=(SizeU, SizeU)

Tests whether two SizeU structures are different.

Declaration

cs-api-definition
public static bool operator !=(SizeU size1, SizeU size2)

Parameters

size1

SizeU

The SizeU structure on the left side of the equality operator.

size2

SizeU

The SizeU structure on the right side of the equality operator.

Returns

bool

This operator returns true if size1 and size2 differ either in width or height; false if size1 and size2 are equal.

operator *(SizeU, double)

Multiplies a SizeU by a specified value.

Declaration

cs-api-definition
public static SizeU operator *(SizeU size, double value)

Parameters

size

SizeU

The SizeU to multiply.

value

double

A double value to multiply by.

Returns

SizeU

A SizeU that is the product of size and value.

operator +(SizeU, SizeU)

Adds the width and height of one SizeU structure to the width and height of another SizeU structure.

Declaration

cs-api-definition
public static SizeU operator +(SizeU size1, SizeU size2)

Parameters

size1

SizeU

The first SizeU to add.

size2

SizeU

The second SizeU to add.

Returns

SizeU

A SizeU structure that is the result of the addition operation.

operator -(SizeU, SizeU)

Subtracts the width and height of one SizeU structure from the width and height of another SizeU structure.

Declaration

cs-api-definition
public static SizeU operator -(SizeU size1, SizeU size2)

Parameters

size1

SizeU

The SizeU on the left side of the subtraction operator.

size2

SizeU

The SizeU on the right side of the subtraction operator.

Returns

SizeU

A SizeU structure that is the result of the subtraction operation.

operator /(SizeU, double)

Devides a SizeU by a specified value.

Declaration

cs-api-definition
public static SizeU operator /(SizeU size, double value)

Parameters

size

SizeU

The SizeU to divide (scale).

value

double

A double value to divide by.

Returns

SizeU

A SizeU that is the quotient of size and value.

operator ==(SizeU, SizeU)

Tests whether two SizeU structures are equal.

Declaration

cs-api-definition
public static bool operator ==(SizeU size1, SizeU size2)

Parameters

size1

SizeU

The SizeU structure on the left side of the equality operator.

size2

SizeU

The SizeU structure on the right side of the equality operator.

Returns

bool

This operator returns true if size1 and size2 have equal width and height; otherwise, false.