Struct Rectangle

Struct Rectangle

名称: Aspose.OCR 集合: Aspose.OCR.dll (25.4.0)

存储四个整体,代表一个直角的位置和大小。

public struct Rectangle

继承人

object.GetType() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()

Constructors

Rectangle(int , int , int , int , int)

启动 Aspose.OCR.Rectangle 结构的新例子,指定位置和尺寸。

public Rectangle(int x, int y, int width, int height)

Parameters

x int

直角的右上角的X协调。

y int

直角的右上角的 y 协调。

width int

直角的宽度。

height int

直角的高度。

Fields

Height

直角宽度。

public int Height

领域价值

int

Width

直角高度。

public int Width

领域价值

int

X

直角 x 位置。

public int X

领域价值

int

Y

直角和位置。

public int Y

领域价值

int

Properties

Bottom

接收或设置的 y 坐标,是 Aspose.OCR.Rectangle.Y 和 Aspose.OCR.Rectangle.High 属性值这个 Aspose.OCR.Rectangle 结构的总值。

public int Bottom { get; set; }

财产价值

int

Empty

收到 Aspose.OCR.Rectangle 结构的新例子,具有 Aspose.OCR.Rectangle.X, Aspose.OCR.Rectangle.Y, Aspose.OCR.Rectangle. 宽度和 Aspose.OCR.Rectangle. 高度值设置为零。

public static Rectangle Empty { get; }

财产价值

Rectangle

IsEmpty

收到一个值,表明此 Aspose.OCR.Rectangle 的所有数字属性是否具有零值。

public bool IsEmpty { get; }

财产价值

bool

Left

接收或设置这个 Aspose.OCR..Rectangle 结构的左边的 x 协调器。

public int Left { get; set; }

财产价值

int

Right

接收或设置为 Aspose.OCR.Rectangle.X 和 Aspose.OCR.Rectangle.With 这个 Aspose.OCR.Rectangle 结构的属性值的 x 协调。

public int Right { get; set; }

财产价值

int

Top

接收或设置这个 Aspose.OCR.Rectangle 结构的顶端的 y 协调。

public int Top { get; set; }

财产价值

int

Methods

Contains(int , int , int)

确定所指定的点是否包含在本 Aspose.OCR.Rectangle 结构中。

public bool Contains(int x, int y)

Parameters

x int

测试点的 x 协调。

y int

测试点的 y 协调。

Returns

bool

此方法返回真相,如果 x’ 和 y’ 所定义的点在本 Aspose.OCR.Rectangle 结构中包含;否则是虚假的。

Equals(对象)

测试是否 obj’ 是一个 Aspose.OCR.Rectangle 结构,该 Aspose.OCR.Rectangle 结构的位置和大小相同。

public override bool Equals(object obj)

Parameters

obj object

系统对象进行测试。

Returns

bool

这个方法是真实的,如果 obj’ 是一个 Aspose.OCR.Rectangle 结构和它的 Aspose.OCR.Rectangle.X, Aspose.OCR.Rectangle.Y, Aspose.OCR.Rectangle.Width,和 Aspose.OCR.Rectangle.High 属性等同于相应的属性这个 Aspose.OCR.Rectangle 结构;否则,虚假。

GetHashCode()

返回此 Aspose.OCR.Rectangle 结构的 hash 代码。

public override int GetHashCode()

Returns

int

一个代表这个直角的哈什代码的整体。

ToString()

将此 Aspose.OCR.Rectangle 的属性转换为人类可读的链条。

public override string ToString()

Returns

string

包含这个 Aspose.OCR.Rectangle 结构的位置、宽度和高度的线条。

Operators

主持人 =(直角,直角)

测试两个 Aspose.OCR.Rectangle 结构是否具有相同的位置和大小。

public static bool operator ==(Rectangle left, Rectangle right)

Parameters

left Rectangle

Aspose.OCR.Rectangle 结构位于平等运营商的左侧。

right Rectangle

Aspose.OCR.Rectangle 是平等运营商的权利。

Returns

bool

这个运营商返回真相,如果两个 Aspose.OCR.Rectangle 结构具有相同的 Aspose.OCR.Rectangle.X, Aspose.OCR.Rectangle.Y, Aspose.OCR.Rectangle.Width,和 Aspose.OCR.Rectangle.High 属性。

运营商 !=(直角,直角)

测试两个 Aspose.OCR.Rectangle 结构是否在位置或大小上有所不同。

public static bool operator !=(Rectangle left, Rectangle right)

Parameters

left Rectangle

Aspose.OCR.Rectangle 结构位于不平等运营商的左侧。

right Rectangle

Aspose.OCR.Rectangle 结构是不平等运营商的权利。

Returns

bool

本运营商返回真实的,如果任何一个 Aspose.OCR.Rectangle.X, Aspose.OCR.Rectangle.Y, Aspose.OCR.Rectangle.Width 或 Aspose.OCR.Rectangle.High 属性两个 Aspose.OCR.Rectangle 结构是不平等的;否则是假的。

 中文