BordersDrawHandler
Contains all the complex paint code to paint different style borders.
Methoden
DrawBorder(Border, RGraphics, CssBox, RBrush, RRect)
Draw simple border.
- border
- Desired border
- g
- the device to draw to
- box
- Box which the border corresponds
- brush
- the brush to use
- rectangle
- the bounding rectangle to draw in
Rückgabe: Beveled border path, null if there is no rounded corners
DrawBorder(Border, CssBox, RGraphics, RRect, bool, bool)
Draw specific border (top/bottom/left/right) with the box data (style/width/rounded).
- border
- desired border to draw
- box
- the box to draw its borders, contain the borders data
- g
- the device to draw into
- rect
- the rectangle the border is enclosing
- isLineStart
- Specifies if the border is for a starting line (no bevel on left)
- isLineEnd
- Specifies if the border is for an ending line (no bevel on right)
DrawBoxBorders(RGraphics, CssBox, RRect, bool, bool)
Draws all the border of the box with respect to style, width, etc.
- g
- the device to draw into
- box
- the box to draw borders for
- rect
- the bounding rectangle to draw in
- isFirst
- is it the first rectangle of the element
- isLast
- is it the last rectangle of the element
GetColor(Border, CssBoxProperties, string) : RColor
Get the border color for the given box border.
GetPen(RGraphics, string, RColor, double) : RPen
Get pen to be used for border draw respecting its style.
GetRoundedBorderPath(RGraphics, Border, CssBox, RRect) : RGraphicsPath
Makes a border path for rounded borders. To support rounded dotted/dashed borders we need to use arc in the border path. Return null if the border is not rounded.
- g
- the device to draw into
- border
- Desired border
- b
- Box which the border corresponds
- r
- the rectangle the border is enclosing
Rückgabe: Beveled border path, null if there is no rounded corners
GetStyle(Border, CssBoxProperties) : string
Get the border style for the given box border.
GetWidth(Border, CssBoxProperties) : double
Get the border width for the given box border.
SetInOutsetRectanglePoints(Border, CssBox, RRect, bool, bool)
Set rectangle for inset/outset border as it need diagonal connection to other borders.
- border
- Desired border
- b
- Box which the border corresponds
- r
- the rectangle the border is enclosing
- isLineStart
- Specifies if the border is for a starting line (no bevel on left)
- isLineEnd
- Specifies if the border is for an ending line (no bevel on right)
Rückgabe: Beveled border path, null if there is no rounded corners
Felder
_borderPts : RPoint[]
used for all border paint to use the same points and not create new array each time.