VectSharp
2.2.1
A light library for C# vector graphics
|
Contains methods to render a Page to an Avalonia.Controls.Canvas. More...
Public Types | |
enum | TextOptions { TextOptions.AlwaysConvert, TextOptions.ConvertIfNecessary, TextOptions.NeverConvert } |
Defines whether text items should be converted into paths when drawing. More... | |
Static Public Member Functions | |
static Avalonia.Controls.Canvas | PaintToCanvas (this Page page, TextOptions textOption=TextOptions.ConvertIfNecessary, FilterOption filterOption=default) |
Render a Page to an Avalonia.Controls.Canvas. More... | |
static Avalonia.Controls.Canvas | PaintToCanvas (this Page page, bool graphicsAsControls, TextOptions textOption=TextOptions.ConvertIfNecessary, FilterOption filterOption=default) |
Render a Page to an Avalonia.Controls.Canvas. More... | |
static Avalonia.Controls.Canvas | PaintToCanvas (this Page page, bool graphicsAsControls, Dictionary< string, Delegate > taggedActions, bool removeTaggedActionsAfterExecution=true, TextOptions textOption=TextOptions.ConvertIfNecessary, FilterOption filterOption=default) |
Render a Page to an Avalonia.Controls.Canvas. More... | |
static Avalonia.Controls.Canvas | PaintToCanvas (this Page page, Dictionary< string, Delegate > taggedActions, bool removeTaggedActionsAfterExecution=true, TextOptions textOption=TextOptions.ConvertIfNecessary, FilterOption filterOption=default) |
Render a Page to an Avalonia.Controls.Canvas. More... | |
Contains methods to render a Page to an Avalonia.Controls.Canvas.
Definition at line 2492 of file AvaloniaContext.cs.
Defines whether text items should be converted into paths when drawing.
Definition at line 2497 of file AvaloniaContext.cs.
|
static |
Render a Page to an Avalonia.Controls.Canvas.
page | The Page to render. |
graphicsAsControls | If this is true, each graphics object (e.g. paths, text...) is rendered as a separate Avalonia.Controls.Control. Otherwise, they are directly rendered onto the drawing context (which is faster, but does not allow interactivity). |
taggedActions | A Dictionary<String, Delegate> containing the Actions that will be performed on items with the corresponding tag. If graphicsAsControls is true, the delegates should be voids that accept one parameter of type TextBlock or Path (depending on the tagged item), otherwise, they should accept one parameter of type RenderAction and return an IEnumerable<RenderAction> of the actions that will actually be performed. |
removeTaggedActionsAfterExecution | Whether the Actions should be removed from taggedActions after their execution. Set to false if the same Action should be performed on multiple items with the same tag. |
textOption | Defines whether text items should be converted into paths when drawing. |
filterOption | Defines how and whether image filters should be rasterised when rendering the image. |
Definition at line 2568 of file AvaloniaContext.cs.
|
static |
Render a Page to an Avalonia.Controls.Canvas.
page | The Page to render. |
graphicsAsControls | If this is true, each graphics object (e.g. paths, text...) is rendered as a separate Avalonia.Controls.Control. Otherwise, they are directly rendered onto the drawing context (which is faster, but does not allow interactivity). |
textOption | Defines whether text items should be converted into paths when drawing. |
filterOption | Defines how and whether image filters should be rasterised when rendering the image. |
Definition at line 2543 of file AvaloniaContext.cs.
|
static |
Render a Page to an Avalonia.Controls.Canvas.
page | The Page to render. |
taggedActions | A Dictionary<String, Delegate> containing the Actions that will be performed on items with the corresponding tag. The delegates should accept one parameter of type TextBlock or Path (depending on the tagged item). |
removeTaggedActionsAfterExecution | Whether the Actions should be removed from taggedActions after their execution. Set to false if the same Action should be performed on multiple items with the same tag. |
textOption | Defines whether text items should be converted into paths when drawing. |
filterOption | Defines how and whether image filters should be rasterised when rendering the image. |
Definition at line 2592 of file AvaloniaContext.cs.
|
static |
Render a Page to an Avalonia.Controls.Canvas.
page | The Page to render. |
textOption | Defines whether text items should be converted into paths when drawing. |
filterOption | Defines how and whether image filters should be rasterised when rendering the image. |
Definition at line 2522 of file AvaloniaContext.cs.