Struct SizeI
Represents the size of a rectangular region with an ordered pair of width and height.
[Serializable]
public struct SizeI : IEquatable<SizeI>
- Implements
Constructors
- SizeI(PointI)
Initializes a new instance of the SizeI class from the specified PointI.
- SizeI(int)
Initializes a new instance of the SizeI struct with equal width and height.
- SizeI(int, int)
Initializes a new instance of the SizeI class from the specified dimensions.
Fields
- MinusOne
Gets a size with (-1, -1) values.
- One
Gets a size with (1, 1) values.
Properties
- AnyIsEmpty
Tests whether this SizeI has zero width or height.
- PixelCount
Gets number of pixels (Width * Height).
Methods
- Add(SizeI, SizeI)
Performs vector addition of two SizeI objects.
- Ceiling(SizeD)
Converts a SizeF to a Size by performing a ceiling operation on all the coordinates.
- Equals(SizeI)
Indicates whether the current object is equal to another object of the same type.
- Equals(object?)
Tests to see whether the specified object is a SizeI with the same dimensions as this SizeI.
- GetHashCode()
Returns a hash code.
- Max(SizeI, SizeI)
Gets maximal width and height from the two specified SizeI values.
- PixelToDip(double?)
Converts pixels to device-independent units using specified scale factor.
- Round(SizeD)
Converts a SizeF to a Size by performing a round operation on all the coordinates.
- ToString()
Creates a human-readable string that represents this SizeI.
- Truncate(SizeD)
Converts a SizeF to a Size by performing a truncate operation on all the coordinates.
Operators
- operator +(SizeI, SizeI)
Performs vector addition of two SizeI objects.
- operator ==(SizeI, SizeI)
Tests whether two SizeI objects are identical.
- implicit operator SizeI(int)
Converts the specified int to a SizeI. Width and height are set to the
value
.
- implicit operator SizeI((int, int))
Implicit operator convertion from tuple with two int values to SizeI.
- operator !=(SizeI, SizeI)
Tests whether two SizeI objects are different.