Show / Hide Table of Contents

Struct PaddingLength

Describes the length of one side of the padding around the content of a PaddedViewbox.

Implements
IEquatable<PaddingLength>
object.Equals(object, object)
object.GetType()
object.ReferenceEquals(object, object)
Namespace: Sartorius.SAF.Presentation.Controls
Assembly: Sartorius.SAF.Presentation.Controls.dll
Syntax
[TypeConverter(typeof(PaddingLengthConverter))]
public struct PaddingLength : IEquatable<PaddingLength>

Constructors

View Source

PaddingLength(double)

Initializes a new instance of the PaddingLength structure that has the specified length (supplied as double) in pixels.

Declaration
public PaddingLength(double pixels)
Parameters
Type Name Description
double pixels
View Source

PaddingLength(double, PaddingUnitType)

Initializes a new instance of the PaddingLength structure and specifies what kind of value it holds.

Declaration
public PaddingLength(double value, PaddingUnitType type)
Parameters
Type Name Description
double value

The initial value of this instance of PaddingLength.

PaddingUnitType type

The PaddingUnitType held by this instance of PaddingLength.

Fields

View Source

Empty

Represents an empty PaddingLength.

Declaration
public static readonly PaddingLength Empty
Field Value
Type Description
PaddingLength
Remarks

This is not a PaddingLength with a Value of 0.

Properties

View Source

IsEmpty

Gets a value indicating whether this instance is empty.

Declaration
public bool IsEmpty { get; }
Property Value
Type Description
bool
View Source

IsStar

Gets a value indicating whether the PaddingLength holds a value that is expressed as a weighted proportion of the contents size.

Declaration
public bool IsStar { get; }
Property Value
Type Description
bool
View Source

Type

Gets or sets the associated PaddingUnitType for the PaddingLength.

Declaration
public PaddingUnitType Type { readonly get; set; }
Property Value
Type Description
PaddingUnitType
View Source

Value

Gets or sets a double that represents the value of the PaddingLength.

Declaration
public double Value { readonly get; set; }
Property Value
Type Description
double

Methods

View Source

Equals(PaddingLength)

Compares this PaddingLength structure to another PaddingLength for equality.

Declaration
public bool Equals(PaddingLength other)
Parameters
Type Name Description
PaddingLength other

The padding to compare.

Returns
Type Description
bool

true if the two instances of PaddingLength do not have the same value and PaddingUnitType; otherwise false.

View Source

Equals(object)

Compares this PaddingLength structure to another object for equality.

Declaration
public override bool Equals(object obj)
Parameters
Type Name Description
object obj

The object to compare.

Returns
Type Description
bool

true if the two objects are equal; otherwise false.

Overrides
ValueType.Equals(object)
View Source

GetHashCode()

Returns the hash code for this instance.

Declaration
public override int GetHashCode()
Returns
Type Description
int

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

Overrides
ValueType.GetHashCode()
View Source

ToString()

Returns the string representation if the PaddingLength structure.

Declaration
public override string ToString()
Returns
Type Description
string

A string that represents the PaddingLength structure.

Overrides
ValueType.ToString()
View Source

ToString(CultureInfo)

Returns the string representation if the PaddingLength structure according to the specified CultureInfo.

Declaration
public string ToString(CultureInfo cultureInfo)
Parameters
Type Name Description
CultureInfo cultureInfo

The culture used to format the string representation.

Returns
Type Description
string

A string that represents the PaddingLength structure.

Operators

View Source

operator ==(PaddingLength, PaddingLength)

Compares two PaddingLength structures for equality.

Declaration
public static bool operator ==(PaddingLength a, PaddingLength b)
Parameters
Type Name Description
PaddingLength a

The first instance of PaddingLength to compare.

PaddingLength b

The second instance of PaddingLength to compare.

Returns
Type Description
bool

true if the two instances of PaddingLength have the same value and PaddingUnitType; otherwise false.

View Source

operator !=(PaddingLength, PaddingLength)

Compares two PaddingLength structures for inequality.

Declaration
public static bool operator !=(PaddingLength a, PaddingLength b)
Parameters
Type Name Description
PaddingLength a

The first instance of PaddingLength to compare.

PaddingLength b

The second instance of PaddingLength to compare.

Returns
Type Description
bool

true if the two instances of PaddingLength do not have the same value and PaddingUnitType; otherwise false.

Implements

IEquatable<T>

Extension Methods

CollectionExtensions.AddRange<T, TCollection>(TCollection, IEnumerable<T>)
SerializableObjectCloneExtension.Clone<T>(T)
  • View Source
Back to top Generated by DocFX