VectSharp 2.6.1
A light library for C# vector graphics
Loading...
Searching...
No Matches
VectSharp.Markdown.RectangleFragment Class Reference

Represents a rectangle. More...

Inheritance diagram for VectSharp.Markdown.RectangleFragment:

Public Member Functions

 RectangleFragment (Point topLeft, Size size, Colour colour, string tag)
 Create a new RectangleFragment. More...
 
override void Translate (double deltaX, double deltaY)
 Applies the specified translation to the line fragment.
Parameters
deltaXThe translation in the horizontal direction.
deltaYThe translation in the vertical direction.
More...
 
override double GetAscent (double lineAscent)
 Get the ascent of the LineFragment.
Parameters
lineAscentThe ascent of the Line on which the fragment should be drawn.
Returns
The ascent of the LineFragment.
More...
 
override double GetMaxY ()
 Get the vertical coordinate of the bottom of the LineFragment.
Returns
The vertical coordinates of the bottom of the LineFragment.
More...
 
override double GetMaxX ()
 Get the horizontal coordinate of the right side of the LineFragment.
Returns
The horizontal coordinate of the right side of the LineFragment.
More...
 
override? Point Render (Graphics graphics, double deltaY)
 Render the LineFragment on the specified graphics surface.
Parameters
graphicsThe Graphics surface on which the LineFragment will be drawn.
deltaYAdditional translation on the vertical axis.
Returns
If a text element has been drawn, this method should return the bottom-right corner of the drawn text element, otherwise null. This is used to update the MarkdownContext.BottomRight property.
More...
 
abstract void Translate (double deltaX, double deltaY)
 Applies the specified translation to the line fragment. More...
 
abstract double GetAscent (double lineAscent)
 Get the ascent of the LineFragment. More...
 
abstract double GetMaxY ()
 Get the vertical coordinate of the bottom of the LineFragment. More...
 
abstract double GetMaxX ()
 Get the horizontal coordinate of the right side of the LineFragment. More...
 
abstract ? Point Render (Graphics graphics, double deltaY)
 Render the LineFragment on the specified graphics surface. More...
 

Properties

Point TopLeft [get]
 The top-left corner of the rectangle, relative to the cursor at the start of the line. More...
 
Size Size [get]
 The size of the rectangle. More...
 
Colour Colour [get]
 The colour used to draw the rectangle. More...
 
- Properties inherited from VectSharp.Markdown.LineFragment
string Tag [get]
 Graphics action tag for the fragment. More...
 

Detailed Description

Represents a rectangle.

Definition at line 222 of file Line.cs.

Constructor & Destructor Documentation

◆ RectangleFragment()

VectSharp.Markdown.RectangleFragment.RectangleFragment ( Point  topLeft,
Size  size,
Colour  colour,
string  tag 
)

Create a new RectangleFragment.

Parameters
topLeftThe top-left corner of the rectangle.
sizeThe size of the rectangle.
colourThe colour used to draw the rectangle.
tagGraphics action tag for the rectangle.

Definition at line 246 of file Line.cs.

Member Function Documentation

◆ GetAscent()

override double VectSharp.Markdown.RectangleFragment.GetAscent ( double  lineAscent)
virtual

Get the ascent of the LineFragment.

Parameters
lineAscentThe ascent of the Line on which the fragment should be drawn.
Returns
The ascent of the LineFragment.

Implements VectSharp.Markdown.LineFragment.

Definition at line 261 of file Line.cs.

◆ GetMaxX()

override double VectSharp.Markdown.RectangleFragment.GetMaxX ( )
virtual

Get the horizontal coordinate of the right side of the LineFragment.

Returns
The horizontal coordinate of the right side of the LineFragment.

Implements VectSharp.Markdown.LineFragment.

Definition at line 273 of file Line.cs.

◆ GetMaxY()

override double VectSharp.Markdown.RectangleFragment.GetMaxY ( )
virtual

Get the vertical coordinate of the bottom of the LineFragment.

Returns
The vertical coordinates of the bottom of the LineFragment.

Implements VectSharp.Markdown.LineFragment.

Definition at line 267 of file Line.cs.

◆ Render()

override? Point VectSharp.Markdown.RectangleFragment.Render ( Graphics  graphics,
double  deltaY 
)
virtual

Render the LineFragment on the specified graphics surface.

Parameters
graphicsThe Graphics surface on which the LineFragment will be drawn.
deltaYAdditional translation on the vertical axis.
Returns
If a text element has been drawn, this method should return the bottom-right corner of the drawn text element, otherwise null. This is used to update the MarkdownContext.BottomRight property.

Implements VectSharp.Markdown.LineFragment.

Definition at line 279 of file Line.cs.

◆ Translate()

override void VectSharp.Markdown.RectangleFragment.Translate ( double  deltaX,
double  deltaY 
)
virtual

Applies the specified translation to the line fragment.

Parameters
deltaXThe translation in the horizontal direction.
deltaYThe translation in the vertical direction.

Implements VectSharp.Markdown.LineFragment.

Definition at line 255 of file Line.cs.

Property Documentation

◆ Colour

Colour VectSharp.Markdown.RectangleFragment.Colour
get

The colour used to draw the rectangle.

Definition at line 237 of file Line.cs.

◆ Size

Size VectSharp.Markdown.RectangleFragment.Size
get

The size of the rectangle.

Definition at line 232 of file Line.cs.

◆ TopLeft

Point VectSharp.Markdown.RectangleFragment.TopLeft
get

The top-left corner of the rectangle, relative to the cursor at the start of the line.

Definition at line 227 of file Line.cs.


The documentation for this class was generated from the following file: