Struct Margin
Margin struct
Namespace: Terminaux.Base.Structures
Assembly: Terminaux.dll
Syntax
public struct Margin
Constructors
| Edit this page View SourceMargin(int, int, int, int, int, int)
Makes a new margin instance
Declaration
public Margin(int left, int top, int right, int bottom, int width, int height)
Parameters
Type | Name | Description |
---|---|---|
int | left | A left margin |
int | top | A top margin |
int | right | A right margin |
int | bottom | A bottom margin |
int | width | Width to subtract from to get margins |
int | height | Height to subtract from to get margins |
Margin(Padding, int, int)
Makes a new margin instance
Declaration
public Margin(Padding margins, int width, int height)
Parameters
Type | Name | Description |
---|---|---|
Padding | margins | Margins |
int | width | Width to subtract from to get margins |
int | height | Height to subtract from to get margins |
Properties
| Edit this page View SourceHeight
Gets the final height with margins applied
Declaration
public readonly int Height { get; }
Property Value
Type | Description |
---|---|
int |
Margins
Gets the margin values
Declaration
public readonly Padding Margins { get; }
Property Value
Type | Description |
---|---|
Padding |
Width
Gets the final width with margins applied
Declaration
public readonly int Width { get; }
Property Value
Type | Description |
---|---|
int |
Methods
| Edit this page View SourceEquals(object?)
Declaration
public override bool Equals(object? obj)
Parameters
Type | Name | Description |
---|---|---|
object | obj |
Returns
Type | Description |
---|---|
bool |
Overrides
System.ValueType.Equals(object)
|
Edit this page
View Source
Equals(Margin)
Declaration
public bool Equals(Margin other)
Parameters
Type | Name | Description |
---|---|---|
Margin | other |
Returns
Type | Description |
---|---|
bool |
GetHashCode()
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
int |
Overrides
System.ValueType.GetHashCode()
Operators
| Edit this page View Sourceoperator ==(Margin, Margin)
Declaration
public static bool operator ==(Margin left, Margin right)
Parameters
Type | Name | Description |
---|---|---|
Margin | left | |
Margin | right |
Returns
Type | Description |
---|---|
bool |
operator !=(Margin, Margin)
Declaration
public static bool operator !=(Margin left, Margin right)
Parameters
Type | Name | Description |
---|---|---|
Margin | left | |
Margin | right |
Returns
Type | Description |
---|---|
bool |