Class HorizontalLinePainter
Mark painter implementation that draws a horizontal line.
Implements
Inherited Members
Object.ToString()
Object.Equals(Object)
Object.Equals(Object, Object)
Object.ReferenceEquals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Namespace: Sdl.DesktopEditor.EditorApi.Implementation
Assembly: Sdl.DesktopEditor.EditorApi.dll
Syntax
public class HorizontalLinePainter : AbstractMarkPainter, ITextMarkPainter
Constructors
HorizontalLinePainter()
Mark painter implementation that draws a horizontal line.
Declaration
public HorizontalLinePainter()
Methods
DrawLine(Graphics, Rectangle)
Implementation used by DrawMarkPart(Graphics, ITextMark, Rectangle, Rectangle, Boolean, Boolean) to draw the line.
Declaration
protected Rectangle DrawLine(Graphics g, Rectangle contentRectangle)
Parameters
Type | Name | Description |
---|---|---|
Graphics | g | |
Rectangle | contentRectangle |
Returns
Type | Description |
---|---|
Rectangle |
DrawMarkPart(Graphics, ITextMark, Rectangle, Rectangle, Boolean, Boolean)
Draw the line.
Declaration
public override void DrawMarkPart(Graphics g, ITextMark mark, Rectangle boundingRectangle, Rectangle contentRectangle, bool isFirstLine, bool isLastLine)
Parameters
Type | Name | Description |
---|---|---|
Graphics | g | |
ITextMark | mark | |
Rectangle | boundingRectangle | |
Rectangle | contentRectangle | |
Boolean | isFirstLine | |
Boolean | isLastLine |
Overrides
GetLineRectangle(Rectangle, Int32)
Implementation used by GetMarkPartBounds(Graphics, ITextMark, Rectangle, Boolean, Boolean) to calculate the line rectangle.
Declaration
protected Rectangle GetLineRectangle(Rectangle contentRectangle, int penWidth)
Parameters
Type | Name | Description |
---|---|---|
Rectangle | contentRectangle | |
Int32 | penWidth |
Returns
Type | Description |
---|---|
Rectangle |
GetMarkPartBounds(Graphics, ITextMark, Rectangle, Boolean, Boolean)
Returns a rectangle that represents the line that will be drawn.
Declaration
public override Rectangle GetMarkPartBounds(Graphics g, ITextMark mark, Rectangle contentRectangle, bool isFirstLine, bool isLastLine)
Parameters
Type | Name | Description |
---|---|---|
Graphics | g | |
ITextMark | mark | |
Rectangle | contentRectangle | |
Boolean | isFirstLine | |
Boolean | isLastLine |
Returns
Type | Description |
---|---|
Rectangle |