Skip to content

Size

Namespace: Hex1b.Layout

Assembly: Hex1b.dll

Represents a 2D size with width and height.

csharp
public readonly struct Size : IEquatable<Size>

Implements

Constructors

Size(int, int)

Parameters:

csharp
public Size(int width, int height)

Properties

Height

Returns: Int32

csharp
public int Height { get; }

Width

Returns: Int32

csharp
public int Width { get; }

Zero

Returns: Size

csharp
public static Size Zero { get; }

Methods

Equals(object?)

Indicates whether this instance and a specified object are equal.

Parameters:

  • obj (Object): The object to compare with the current instance.

Returns: Boolean

true if obj and this instance are the same type and represent the same value; otherwise, false.

csharp
public override bool Equals(object? obj)

Equals(Size)

Indicates whether the current object is equal to another object of the same type.

Parameters:

  • other (Size): An object to compare with this object.

Returns: Boolean

true if the current object is equal to the other parameter; otherwise, false.

csharp
public bool Equals(Size other)

GetHashCode()

Returns the hash code for this instance.

Returns: Int32

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

csharp
public override int GetHashCode()

ToString()

Returns the fully qualified type name of this instance.

Returns: String

The fully qualified type name.

csharp
public override string ToString()

Members

operator !=(Size, Size)

Parameters:

Returns: Boolean

csharp
public static bool operator !=(Size left, Size right)

operator ==(Size, Size)

Parameters:

Returns: Boolean

csharp
public static bool operator ==(Size left, Size right)

Released under the MIT License.