The TXDrawingCore class provides properties and methods to specify the type and format of shapes rendered as a Scalable Vector Graphics (SVG). The class implements the System.ComponentModel.INotifyPropertyChanged interface. Changes to the shapes that require updating the view can be listend via the Changed event. The following describes only the properties, methods and events defined through the TXDrawingCore class. For a list of properties, methods and events inherited from the System.ComponentModel.INotifyPropertyChanged interface see the .NET Framework reference.

Syntax

public class TXDrawingCore : System.ComponentModel.INotifyPropertyChanged
Public Class TXDrawingCore
  Implements System.ComponentModel.INotifyPropertyChanged

Introduced: 33.0.

Constructors

Constructor Description
TXDrawingCore Initializes a new instance of the TXDrawingCore class.

Events

Event Description
AdaptBounds Indicates that the visible bounds of the displayed shapes have been changed (by changing the shape's angle, outline width, yellow adjust rectangles or the canvas' border width) in so far that the canvas requires an update of its bounds.
Changed Indicates that the number or formatting of the displayed shapes has been changed.
ShapeCreated Occurs when a new shape has been created.
ShapeDeleted Occurs when a shape has been deleted from the TXDrawingCore's shapes collection.
ShapeDeselected Occurs when a shape has been deselected.
ShapeFlipped Occurs when a shape has been flipped.
ShapeFormatChanged Occurs when shape formatting attributes have been changed.
ShapeMoved Occurs when a shape has been moved.
ShapeSelected Occurs when a shape has been selected.
ShapeSized Occurs when a shape has been sized.
ViewChanged Occurs selection changing have caused the view to change.

Methods

Method Description
ClearUndo Clears the undo buffer of the TXDrawingCore instance.
Copy Copies the current selected shapes to the Clipboard.
Cut Moves the current selected shapes to the Clipboard.
GetSVG Creates and returns a string representing a Scalable Vector Graphics (SVG) of the shapes.
Load Loads shapes data into the canvas from a specified object of type System.IO.Stream.
Paste Pastes the content of the clipboard into the canvas.
Redo Redoes the last TXDrawingCore operation.
Save Saves the shapes data to the given object of type System.IO.Stream.
SelectAll Selects all shapes.
SizeToContent If any changes of the the displayed shapes' visible bounds require an adaption of the canvas bounds, its size and/or location is expanded respectively decreased by the considering value of the considering shape's side(s).
Undo Undoes the last TXDrawingCore's edit operation.

Properties

Property Description
BackColor Gets or sets the back color of the canvas.
BorderColor Gets or sets the border line color of the canvas.
BorderWidth Gets or sets the border line width of the canvas.
CanCopy Informs whether shapes are selected which can be copied to the internal clipboard.
CanPaste Informs whether the internal clipboard contains shapes that can be pasted into the canvas.
CanRedo Informs whether an operation can be re-done using the Redo method.
CanUndo Gets a value indicating whether the user can undo the previous TXDrawingCore operation.
IsCanvasVisible Gets a value whether the cavas is visible or not.
Selection Gets an object of type Drawing.Selection that represents the current selected shapes inside the canvas.
Shapes Gets an object of type ShapeCollection that represents those shapes which are displayed inside the canvas.
Size Gets or sets the size of the canvas.