# HtmlRenderRectangle

Immutable axis-aligned rectangle in CSS-pixel coordinates.

Struct 

`OfficeIMO.Html`

**Namespace**

`OfficeIMO.Html`

**Assembly**

`OfficeIMO.Html`

**Source revision**

`3b680b1b6fb1` with working tree changes

**Source**

[HtmlRenderGeometry.cs:44](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L44)

**Base**

`ValueType`

**Implements**

`IEquatable<HtmlRenderRectangle>`

**Modifiers**

sealed

Immutable axis-aligned rectangle in CSS-pixel coordinates.

## Inheritance

- ValueType
- HtmlRenderRectangle

## Usage

Explore 11 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 5

- Property [HtmlRenderHitTestResult.Bounds](/api/html/officeimo-html-htmlrenderhittestresult/#property-bounds)
- Property [HtmlRenderSourcePlacement.OutputBounds](/api/html/officeimo-html-htmlrendersourceplacement/#property-outputbounds)
- Property [HtmlRenderSourcePlacement.SourceBounds](/api/html/officeimo-html-htmlrendersourceplacement/#property-sourcebounds)
- Property [HtmlRenderSurface.Bounds](/api/html/officeimo-html-htmlrendersurface/#property-bounds)
- Property [HtmlRenderSurfaceResult.Bounds](/api/html/officeimo-html-htmlrendersurfaceresult/#property-bounds)

### Accepted by parameters 6

- Method [HtmlRenderRectangle.Equals](/api/html/officeimo-html-htmlrenderrectangle/#method-equals-officeimo-html-htmlrenderrectangle) parameter `other`
- Method [HtmlRenderRectangle.Intersects](/api/html/officeimo-html-htmlrenderrectangle/#method-intersects-officeimo-html-htmlrenderrectangle) parameter `other`
- Method [HtmlRenderRectangle.op_Equality](/api/html/officeimo-html-htmlrenderrectangle/#method-op-equality-officeimo-html-htmlrenderrectangle-officeimo-html-htmlrenderrectangle) parameter `left`
- Method [HtmlRenderRectangle.op_Equality](/api/html/officeimo-html-htmlrenderrectangle/#method-op-equality-officeimo-html-htmlrenderrectangle-officeimo-html-htmlrenderrectangle) parameter `right`
- Method [HtmlRenderRectangle.op_Inequality](/api/html/officeimo-html-htmlrenderrectangle/#method-op-inequality-officeimo-html-htmlrenderrectangle-officeimo-html-htmlrenderrectangle) parameter `left`
- Method [HtmlRenderRectangle.op_Inequality](/api/html/officeimo-html-htmlrenderrectangle/#method-op-inequality-officeimo-html-htmlrenderrectangle-officeimo-html-htmlrenderrectangle) parameter `right`

Filter members 

Show inherited

## Constructors

`public HtmlRenderRectangle(double x, double y, double width, double height)` [#](#constructor-ctor-double-double-double-double)

[HtmlRenderGeometry.cs:44](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L44)

Creates a finite rectangle with non-negative dimensions.

Parameters

**x double required**

**y double required**

**width double required**

**height double required**

## Methods

`public bool Contains(HtmlRenderPoint point)` [#](#method-contains-officeimo-html-htmlrenderpoint)

[HtmlRenderGeometry.cs:69](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L69)

Returns whether the point lies in the closed rectangle.

Parameters

**point OfficeIMO.Html.HtmlRenderPoint required**

Returns

`bool`

Equals 2 overloads

`public bool Equals(HtmlRenderRectangle other)` [#](#method-equals-officeimo-html-htmlrenderrectangle)

[HtmlRenderGeometry.cs:77](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L77)

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

Parameters

**other OfficeIMO.Html.HtmlRenderRectangle required**

An object to compare with this object.

Returns

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

`public override bool Equals(object? obj)` [#](#method-equals-object)

[HtmlRenderGeometry.cs:79](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L79)

Indicates whether this instance and a specified object are equal.

Parameters

**obj object? required**

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.

`public override int GetHashCode()` [#](#method-gethashcode)

[HtmlRenderGeometry.cs:83](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L83)

Returns the hash code for this instance.

Returns

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

`public bool Intersects(HtmlRenderRectangle other)` [#](#method-intersects-officeimo-html-htmlrenderrectangle)

[HtmlRenderGeometry.cs:73](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L73)

Returns whether this rectangle overlaps another rectangle.

Parameters

**other OfficeIMO.Html.HtmlRenderRectangle required**

Returns

`bool`

`public static bool op_Equality(HtmlRenderRectangle left, HtmlRenderRectangle right)` [#](#method-op-equality-officeimo-html-htmlrenderrectangle-officeimo-html-htmlrenderrectangle)

[HtmlRenderGeometry.cs:91](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L91)

Compares two rectangles.

Parameters

**left OfficeIMO.Html.HtmlRenderRectangle required**

**right OfficeIMO.Html.HtmlRenderRectangle required**

Returns

`bool`

`public static bool op_Inequality(HtmlRenderRectangle left, HtmlRenderRectangle right)` [#](#method-op-inequality-officeimo-html-htmlrenderrectangle-officeimo-html-htmlrenderrectangle)

[HtmlRenderGeometry.cs:93](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L93)

Compares two rectangles.

Parameters

**left OfficeIMO.Html.HtmlRenderRectangle required**

**right OfficeIMO.Html.HtmlRenderRectangle required**

Returns

`bool`

## Inherited Methods

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public override string? ToString()` [#](#method-tostring)

Inherited from ValueType

Returns

`string?`

## Properties

`public double X { get; }` [#](#property-x)

[HtmlRenderGeometry.cs:55](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L55)

Left coordinate.

`public double Y { get; }` [#](#property-y)

[HtmlRenderGeometry.cs:57](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L57)

Top coordinate.

`public double Width { get; }` [#](#property-width)

[HtmlRenderGeometry.cs:59](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L59)

Width.

`public double Height { get; }` [#](#property-height)

[HtmlRenderGeometry.cs:61](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L61)

Height.

`public double Right { get; }` [#](#property-right)

[HtmlRenderGeometry.cs:63](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L63)

Right coordinate.

`public double Bottom { get; }` [#](#property-bottom)

[HtmlRenderGeometry.cs:65](https://github.com/EvotecIT/OfficeIMO/blob/3b680b1b6fb15a268ff5525a4ca6cdd70b2f6613/OfficeIMO.Html/Rendering/HtmlRenderGeometry.cs#L65)

Bottom coordinate.

<!-- PowerForge markdown artifact sha256:C3B139B184470456EB21C7761069D1D7A10EC0F794A50AE0FC2C5A0EDAF51AFC -->
