Rectangle
Rectangle Public class
Description
A Rectangle is the representation of a geometric figure.
Diagram
flowchart LR
classDef interfaceStyle stroke-dasharray: 5 5;
classDef abstractStyle stroke-width:4px
subgraph iTextSharp.text
iTextSharp.text.Rectangle[[Rectangle]]
iTextSharp.text.IElement[[IElement]]
class iTextSharp.text.IElement interfaceStyle;
iTextSharp.text.Element[[Element]]
end
iTextSharp.text.IElement --> iTextSharp.text.Rectangle
iTextSharp.text.Element --> iTextSharp.text.Rectangle
Members
Properties
Public properties
| Type | Name | Methods |
|---|---|---|
BaseColor | BackgroundColorGet/set the backgroundcolor. | get, set |
int | BorderGet/set the border | get, set |
BaseColor | BorderColorGet/set the color of the border. | get, set |
BaseColor | BorderColorBottom | get, set |
BaseColor | BorderColorLeft | get, set |
BaseColor | BorderColorRight | get, set |
BaseColor | BorderColorTop | get, set |
float | BorderWidthGet/set the borderwidth. | get, set |
float | BorderWidthBottom | get, set |
float | BorderWidthLeft | get, set |
float | BorderWidthRight | get, set |
float | BorderWidthTop | get, set |
float | BottomGet/set the lower left y-coordinate. | get, set |
IList<Chunk> | ChunksGets all the chunks in this element. | get |
float | GrayFillGet/set the grayscale of the rectangle. | get, set |
float | HeightReturns the height of the rectangle. | get |
float | LeftGet/set the lower left x-coordinate. | get, set |
float | RightGet/set the upper right x-coordinate. | get, set |
int | RotationSet/gets the rotation | get, set |
float | TopGet/set the upper right y-coordinate. | get, set |
int | TypeGets the type of the text element. | get |
bool | UseVariableBorders | get, set |
float | WidthReturns the width of the rectangle. | get, set |
Methods
Public methods
| Returns | Name |
|---|---|
void | CloneNonPositionParameters(Rectangle rect) |
void | DisableBorderSide(int side) |
void | EnableBorderSide(int side) |
bool | Equals(object obj) |
float | GetBottom(float margin)Returns the lower left y-coordinate, considering a given margin. |
float | GetLeft(float margin)Returns the lower left x-coordinate, considering a given margin. |
Rectangle | GetRectangle(float top, float bottom)Gets a Rectangle that is altered to fit on the page. |
float | GetRight(float margin)Returns the upper right x-coordinate, considering a given margin. |
float | GetTop(float margin)Returns the upper right y-coordinate, considering a given margin. |
bool | HasBorder(int type)Indicates if the table has a some type of border. |
bool | HasBorders()Indicates if the table has borders. |
bool | IsContent() |
bool | IsNestable() |
void | Normalize() |
bool | Process(IElementListener listener)Processes the element by adding it (or the different parts) to an IElementListener. |
Rectangle | Rotate()Swaps the values of urx and ury and of lly and llx in order to rotate the rectangle. |
void | SoftCloneNonPositionParameters(Rectangle rect) |
string | ToString() |
Details
Summary
A Rectangle is the representation of a geometric figure.
Inheritance
Constructors
Rectangle [1/6]
Source codepublic Rectangle(float llx, float lly, float urx, float ury)
Arguments
| Type | Name | Description |
|---|---|---|
float | llx | lower left x |
float | lly | lower left y |
float | urx | upper right x |
float | ury | upper right y |
Summary
Constructs a Rectangle-object.
Rectangle [2/6]
Source codepublic Rectangle(float llx, float lly, float urx, float ury, int rotation)
Arguments
| Type | Name | Description |
|---|---|---|
float | llx | |
float | lly | |
float | urx | |
float | ury | |
int | rotation |
Rectangle [3/6]
Source codepublic Rectangle(float urx, float ury)
Arguments
| Type | Name | Description |
|---|---|---|
float | urx | upper right x |
float | ury | upper right y |
Summary
Constructs a Rectangle-object starting from the origin (0, 0).
Rectangle [4/6]
Source codepublic Rectangle(float urx, float ury, int rotation)
Arguments
| Type | Name | Description |
|---|---|---|
float | urx | |
float | ury | |
int | rotation |
Rectangle [5/6]
Source codepublic Rectangle(Rectangle rect)
Arguments
| Type | Name | Description |
|---|---|---|
Rectangle | rect | another Rectangle |
Summary
Constructs a Rectangle-object.
Rectangle [6/6]
Source codepublic Rectangle(RectangleJ rect)
Arguments
| Type | Name | Description |
|---|---|---|
RectangleJ | rect |
Methods
CloneNonPositionParameters
Source codepublic virtual void CloneNonPositionParameters(Rectangle rect)
Arguments
| Type | Name | Description |
|---|---|---|
Rectangle | rect |
SoftCloneNonPositionParameters
Source codepublic virtual void SoftCloneNonPositionParameters(Rectangle rect)
Arguments
| Type | Name | Description |
|---|---|---|
Rectangle | rect |
Process
Source codepublic virtual bool Process(IElementListener listener)
Arguments
| Type | Name | Description |
|---|---|---|
IElementListener | listener | an IElementListener |
Summary
Processes the element by adding it (or the different parts) to an IElementListener.
Returns
true if the element was processed successfully
IsContent
Source codepublic virtual bool IsContent()
IsNestable
Source codepublic virtual bool IsNestable()
Normalize
Source codepublic virtual void Normalize()
GetRectangle
Source codepublic virtual Rectangle GetRectangle(float top, float bottom)
Arguments
| Type | Name | Description |
|---|---|---|
float | top | the top position |
float | bottom | the bottom position |
Summary
Gets a Rectangle that is altered to fit on the page.
Returns
a Rectangle
Rotate
Source codepublic virtual Rectangle Rotate()
Summary
Swaps the values of urx and ury and of lly and llx in order to rotate the rectangle.
Returns
a Rectangle
EnableBorderSide
Source codepublic virtual void EnableBorderSide(int side)
Arguments
| Type | Name | Description |
|---|---|---|
int | side |
DisableBorderSide
Source codepublic virtual void DisableBorderSide(int side)
Arguments
| Type | Name | Description |
|---|---|---|
int | side |
GetLeft
Source codepublic virtual float GetLeft(float margin)
Arguments
| Type | Name | Description |
|---|---|---|
float | margin | a margin |
Summary
Returns the lower left x-coordinate, considering a given margin.
Returns
the lower left x-coordinate
GetRight
Source codepublic virtual float GetRight(float margin)
Arguments
| Type | Name | Description |
|---|---|---|
float | margin | a margin |
Summary
Returns the upper right x-coordinate, considering a given margin.
Returns
the upper right x-coordinate
GetTop
Source codepublic virtual float GetTop(float margin)
Arguments
| Type | Name | Description |
|---|---|---|
float | margin | a margin |
Summary
Returns the upper right y-coordinate, considering a given margin.
Returns
the upper right y-coordinate
GetBottom
Source codepublic virtual float GetBottom(float margin)
Arguments
| Type | Name | Description |
|---|---|---|
float | margin | a margin |
Summary
Returns the lower left y-coordinate, considering a given margin.
Returns
the lower left y-coordinate
HasBorders
Source codepublic virtual bool HasBorders()
Summary
Indicates if the table has borders.
Returns
a bool
HasBorder
Source codepublic virtual bool HasBorder(int type)
Arguments
| Type | Name | Description |
|---|---|---|
int | type | the type of border |
Summary
Indicates if the table has a some type of border.
Returns
a bool
ToString
Source codepublic override string ToString()
Equals
Source codepublic override bool Equals(object obj)
Arguments
| Type | Name | Description |
|---|---|---|
object | obj |
Properties
Type
public virtual int Type { get; }
Summary
Gets the type of the text element.
Value
a type
Chunks
public virtual IList<Chunk> Chunks { get; }
Summary
Gets all the chunks in this element.
Value
an ArrayList
Top
public virtual float Top { get; set; }
Summary
Get/set the upper right y-coordinate.
Value
a float
Border
public virtual int Border { get; set; }
Summary
Get/set the border
Value
a int
GrayFill
public virtual float GrayFill { get; set; }
Summary
Get/set the grayscale of the rectangle.
Value
a float
Left
public virtual float Left { get; set; }
Summary
Get/set the lower left x-coordinate.
Value
a float
Right
public virtual float Right { get; set; }
Summary
Get/set the upper right x-coordinate.
Value
a float
Bottom
public virtual float Bottom { get; set; }
Summary
Get/set the lower left y-coordinate.
Value
a float
BorderColorBottom
public virtual BaseColor BorderColorBottom { get; set; }
BorderColorTop
public virtual BaseColor BorderColorTop { get; set; }
BorderColorLeft
public virtual BaseColor BorderColorLeft { get; set; }
BorderColorRight
public virtual BaseColor BorderColorRight { get; set; }
Width
public virtual float Width { get; set; }
Summary
Returns the width of the rectangle.
Value
a width
Height
public virtual float Height { get; }
Summary
Returns the height of the rectangle.
Value
a height
BorderWidth
public virtual float BorderWidth { get; set; }
Summary
Get/set the borderwidth.
Value
a float
BorderColor
public virtual BaseColor BorderColor { get; set; }
Summary
Get/set the color of the border.
Value
a BaseColor
BackgroundColor
public virtual BaseColor BackgroundColor { get; set; }
Summary
Get/set the backgroundcolor.
Value
a BaseColor
Rotation
public virtual int Rotation { get; set; }
Summary
Set/gets the rotation
Value
a int
BorderWidthLeft
public virtual float BorderWidthLeft { get; set; }
BorderWidthRight
public virtual float BorderWidthRight { get; set; }
BorderWidthTop
public virtual float BorderWidthTop { get; set; }
BorderWidthBottom
public virtual float BorderWidthBottom { get; set; }
UseVariableBorders
public virtual bool UseVariableBorders { get; set; }
Generated with ModularDoc