C# Class Svg.SvgTextBase

Inheritance: SvgVisualElement
Show file Open project: vvvv/SVG Class Usage Examples

Private Properties

Property Type Description
GetContentNodes IEnumerable
SetPath void
SetPath void

Public Methods

Method Description
Path ( ISvgRenderer renderer ) : GraphicsPath

Gets the GraphicsPath for this element.

RegisterEvents ( ISvgEventCaller caller ) : void
ShouldWriteElement ( ) : bool

Empty text elements are not legal - only write this element if it has children.

ToString ( ) : string

Returns a T:System.String that represents the current T:System.Object.

UnregisterEvents ( ISvgEventCaller caller ) : void

Protected Methods

Method Description
GetAuthorPathLength ( ) : float
GetBaselinePath ( ISvgRenderer renderer ) : GraphicsPath
OnChange ( string newString, string sessionID ) : void
PrepareText ( string value ) : string

Prepare the text according to the whitespace handling rules. SVG Spec.

RaiseChange ( object sender, StringArg s ) : void
Render ( ISvgRenderer renderer ) : void

Renders the SvgElement and contents to the specified Graphics object.

Necessary to make sure that any internal tspan elements get rendered as well

Private Methods

Method Description
GetContentNodes ( ) : IEnumerable
SetPath ( TextDrawingState state ) : void
SetPath ( TextDrawingState state, bool doMeasurements ) : void

Sets the path on this element and all child elements. Uses the state object to track the state of the drawing

Method Details

GetAuthorPathLength() protected method

protected GetAuthorPathLength ( ) : float
return float

GetBaselinePath() protected method

protected GetBaselinePath ( ISvgRenderer renderer ) : GraphicsPath
renderer ISvgRenderer
return System.Drawing.Drawing2D.GraphicsPath

OnChange() protected method

protected OnChange ( string newString, string sessionID ) : void
newString string
sessionID string
return void

Path() public method

Gets the GraphicsPath for this element.
public Path ( ISvgRenderer renderer ) : GraphicsPath
renderer ISvgRenderer
return System.Drawing.Drawing2D.GraphicsPath

PrepareText() protected method

Prepare the text according to the whitespace handling rules. SVG Spec.
protected PrepareText ( string value ) : string
value string Text to be prepared
return string

RaiseChange() protected method

protected RaiseChange ( object sender, StringArg s ) : void
sender object
s StringArg
return void

RegisterEvents() public method

public RegisterEvents ( ISvgEventCaller caller ) : void
caller ISvgEventCaller
return void

Render() protected method

Renders the SvgElement and contents to the specified Graphics object.
Necessary to make sure that any internal tspan elements get rendered as well
protected Render ( ISvgRenderer renderer ) : void
renderer ISvgRenderer The object to render to.
return void

ShouldWriteElement() public method

Empty text elements are not legal - only write this element if it has children.
public ShouldWriteElement ( ) : bool
return bool

ToString() public method

Returns a T:System.String that represents the current T:System.Object.
public ToString ( ) : string
return string

UnregisterEvents() public method

public UnregisterEvents ( ISvgEventCaller caller ) : void
caller ISvgEventCaller
return void