Table of Contents

Struct PixelSize

Namespace
ScottPlot
Assembly
ScottPlot.dll
public struct PixelSize : IEquatable<PixelSize>
Implements
Inherited Members
Extension Methods

Constructors

PixelSize(double, double)

public PixelSize(double width, double height)

Parameters

width double
height double

PixelSize(float, float)

public PixelSize(float width, float height)

Parameters

width float
height float

Fields

Height

public readonly float Height

Field Value

float

Width

public readonly float Width

Field Value

float

Properties

Area

public float Area { get; }

Property Value

float

Diagonal

public float Diagonal { get; }

Property Value

float

Infinity

public static PixelSize Infinity { get; }

Property Value

PixelSize

NaN

public static PixelSize NaN { get; }

Property Value

PixelSize

Zero

public static PixelSize Zero { get; }

Property Value

PixelSize

Methods

Contains(PixelSize)

public bool Contains(PixelSize size)

Parameters

size PixelSize

Returns

bool

Contracted(PixelPadding)

public PixelSize Contracted(PixelPadding pad)

Parameters

pad PixelPadding

Returns

PixelSize

Equals(PixelSize)

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

public bool Equals(PixelSize other)

Parameters

other PixelSize

An object to compare with this object.

Returns

bool

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

Equals(object?)

Indicates whether this instance and a specified object are equal.

public override bool Equals(object? obj)

Parameters

obj object

The object to compare with the current instance.

Returns

bool

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

Expanded(PixelPadding)

public PixelSize Expanded(PixelPadding pad)

Parameters

pad PixelPadding

Returns

PixelSize

GetHashCode()

Returns the hash code for this instance.

public override int GetHashCode()

Returns

int

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

Max(PixelSize)

public PixelSize Max(PixelSize rect2)

Parameters

rect2 PixelSize

Returns

PixelSize

ToPixelRect()

public PixelRect ToPixelRect()

Returns

PixelRect

ToPixelRect(Pixel, Alignment)

public PixelRect ToPixelRect(Pixel pixel, Alignment alignment)

Parameters

pixel Pixel
alignment Alignment

Returns

PixelRect

ToString()

Returns the fully qualified type name of this instance.

public override string ToString()

Returns

string

The fully qualified type name.

Operators

operator ==(PixelSize, PixelSize)

public static bool operator ==(PixelSize a, PixelSize b)

Parameters

a PixelSize
b PixelSize

Returns

bool

operator !=(PixelSize, PixelSize)

public static bool operator !=(PixelSize a, PixelSize b)

Parameters

a PixelSize
b PixelSize

Returns

bool