Drawings and Shapes

TX Text Control supports the insertion of drawings and shapes. A drawing can be positioned like an image or textframe, either geometrically or as a single character. Geometrically, its position can either be relative to a paragraph to which it is anchored or relative to the complete document. The DrawingFrame class handles the positioning of the drawing in the document. A drawing frame is always associated with a Drawing.TXDrawingControl or WPF.Drawing.TXDrawingControl which handles the appearance and the data of the drawing. A drawing can be activated and its contained shapes can be altered through the user with built-in mouse and keyboard interfaces. A drawing control is also fully programmable, its contained shapes are accessible through a Drawing.ShapeCollection. All drawings in a document are contained in a DrawingCollection. The collection can also be used to add drawings to or to remove drawings from the document. The drawing collection can be obtained through the TextControl.Drawings, WPF.TextControl.Drawings or ServerTextControl.Drawings property. The TextControl.DrawingLayoutDialog and WPF.TextControl.DrawingLayoutDialog methods opens a dialog box, which offers layout settings such as positioning, size and text distances. A drawing can be saved and loaded with the TX Text Control format and the Microsoft Word format (.docx). With other formats the drawing's bitmap image is saved.

Classes

Class Description
TXTextControl.DataVisualization.DrawingCollection An instance of the DrawingCollection class contains all drawings in a document represented through objects of the type DataVisualization.DrawingFrame.
TXTextControl.DataVisualization.DrawingEventArgs The DrawingEventArgs class provides data for all events that occur with drawings.
TXTextControl.DataVisualization.DrawingFrame An instance of the DrawingFrame class represents a drawing and its layout in a Text Control document.
TXTextControl.Drawing.MenuItem The Drawing.MenuItem class represents a bindable Windows Forms ToolStripMenuItem.
TXTextControl.Drawing.Selection The Drawing.Selection class represents all selected shapes.
TXTextControl.Drawing.Shape The Drawing.Shape class represents a shape which can be displayed inside the TX Drawing Control.
TXTextControl.Drawing.Shape.Fill The Drawing.Shape.Fill class determines the fill properties of a shape.
TXTextControl.Drawing.Shape.Outline The Drawing.Shape.Outline class determines the line properties of a shape.
TXTextControl.Drawing.ShapeCollection An instance of the ShapeCollection class contains all displayed shapes represented through objects of type Shape.
TXTextControl.Drawing.ShapeEventArgs The ShapeEventArgs class provides data for all events that occur with shapes.
TXTextControl.Drawing.ShapesContextMenuStrip The Drawing.ShapesContextMenuStrip class represents the default context menu of the Windows Forms TXDrawingControl.
TXTextControl.Drawing.TXDrawingControl The TXDrawingControl class implements a Windows Forms control with features to draw custom or predefined shapes.
TXTextControl.Drawing.ViewChangedEventArgs The ViewChangedEventArgs class provides data for the TXDrawingControl.ViewChanged event.
TXTextControl.Windows.Forms.Ribbon.RibbonListView.RibbonListViewItemEventArgs The RibbonListViewItemEventArgs class provides data for the RibbonListView.ItemClick, ItemMouseEnter or ItemMouseLeave event.
TXTextControl.WPF.Drawing.ShapesContextMenu The WPF.Drawing.ShapesContextMenu class represents the default context menu of the WPF TXDrawingControl.
TXTextControl.WPF.Drawing.TXDrawingControl The WPF.TXDrawingControl class implements a WPF FrameworkElement with features to draw custom or predefined shapes.

Properties

Property Description
TXTextControl.ServerTextControl.Drawings Gets a collection of all drawings in a document.
TXTextControl.TextControl.DrawingMarkerLines Specifies whether a marker frame is shown around a drawing to indicate its position and size.
TXTextControl.TextControl.Drawings Gets a collection of all drawings contained in the text part with the input focus.
TXTextControl.WPF.TextControl.DrawingMarkerLines Specifies whether a marker frame is shown around a drawing to indicate its position and size.
TXTextControl.WPF.TextControl.Drawings Gets a collection of all drawings contained in the text part with the input focus.

Methods

Method Description
TXTextControl.ServerTextControl.OnDrawingCreated Raises the DrawingCreated event.
TXTextControl.ServerTextControl.OnDrawingDeleted Raises the DrawingDeleted event.
TXTextControl.TextControl.DrawingLayoutDialog Invokes the built-in dialog box for alter the layout settings, the size and the text distances of a drawing.
TXTextControl.TextControl.OnDrawingActivated Raises the DrawingActivated event.
TXTextControl.TextControl.OnDrawingClicked Raises the DrawingClicked event.
TXTextControl.TextControl.OnDrawingCreated Raises the DrawingCreated event.
TXTextControl.TextControl.OnDrawingDeactivated Raises the DrawingDeactivated event.
TXTextControl.TextControl.OnDrawingDeleted Raises the DrawingDeleted event.
TXTextControl.TextControl.OnDrawingDeselected Raises the DrawingDeselected event.
TXTextControl.TextControl.OnDrawingDoubleClicked Raises the DrawingDoubleClicked event.
TXTextControl.TextControl.OnDrawingMoved Raises the DrawingMoved event.
TXTextControl.TextControl.OnDrawingRightClicked Raises the DrawingRightClicked event.
TXTextControl.TextControl.OnDrawingSelected Raises the DrawingSelected event.
TXTextControl.TextControl.OnDrawingSized Raises the DrawingSized event.
TXTextControl.WPF.TextControl.DrawingLayoutDialog Invokes the built-in dialog box for alter the layout settings, the size and the text distances of a drawing.
TXTextControl.WPF.TextControl.OnDrawingActivated Raises the DrawingActivated event.
TXTextControl.WPF.TextControl.OnDrawingClicked Raises the DrawingClicked event.
TXTextControl.WPF.TextControl.OnDrawingCreated Raises the DrawingCreated event.
TXTextControl.WPF.TextControl.OnDrawingDeactivated Raises the DrawingDeactivated event.
TXTextControl.WPF.TextControl.OnDrawingDeleted Raises the DrawingDeleted event.
TXTextControl.WPF.TextControl.OnDrawingDeselected Raises the DrawingDeselected event.
TXTextControl.WPF.TextControl.OnDrawingDoubleClicked Raises the DrawingDoubleClicked event.
TXTextControl.WPF.TextControl.OnDrawingMoved Raises the DrawingMoved event.
TXTextControl.WPF.TextControl.OnDrawingRightClicked Raises the DrawingRightClicked event.
TXTextControl.WPF.TextControl.OnDrawingSelected Raises the DrawingSelected event.
TXTextControl.WPF.TextControl.OnDrawingSized Raises the DrawingSized event.

Events

Event Description
TXTextControl.ServerTextControl.DrawingCreated Occurs when a new drawing has been created.
TXTextControl.ServerTextControl.DrawingDeleted Occurs when a drawing has been deleted.
TXTextControl.TextControl.DrawingActivated Occurs when a drawing has been activated.
TXTextControl.TextControl.DrawingClicked Occurs when a drawing has been clicked on.
TXTextControl.TextControl.DrawingCreated Occurs when a new drawing has been created.
TXTextControl.TextControl.DrawingDeactivated Occurs when a drawing has been deactivated.
TXTextControl.TextControl.DrawingDeleted Occurs when a drawing has been deleted.
TXTextControl.TextControl.DrawingDeselected Occurs when a drawing has been deselected.
TXTextControl.TextControl.DrawingDoubleClicked Occurs when a drawing has been doubleclicked on.
TXTextControl.TextControl.DrawingMoved Occurs when a drawing has been moved.
TXTextControl.TextControl.DrawingRightClicked Occurs when a drawing has been clicked on with the right mouse button.
TXTextControl.TextControl.DrawingSelected Occurs when a drawing has been selected.
TXTextControl.TextControl.DrawingSized Occurs when a drawing has been sized.
TXTextControl.WPF.TextControl.DrawingActivated Occurs when a drawing has been activated.
TXTextControl.WPF.TextControl.DrawingClicked Occurs when a drawing has been clicked on.
TXTextControl.WPF.TextControl.DrawingCreated Occurs when a new drawing has been created.
TXTextControl.WPF.TextControl.DrawingDeactivated Occurs when a drawing has been deactivated.
TXTextControl.WPF.TextControl.DrawingDeleted Occurs when a drawing has been deleted.
TXTextControl.WPF.TextControl.DrawingDeselected Occurs when a drawing has been deselected.
TXTextControl.WPF.TextControl.DrawingDoubleClicked Occurs when a drawing has been doubleclicked on.
TXTextControl.WPF.TextControl.DrawingMoved Occurs when a drawing has been moved.
TXTextControl.WPF.TextControl.DrawingRightClicked Occurs when a drawing has been clicked on with the right mouse button.
TXTextControl.WPF.TextControl.DrawingSelected Occurs when a drawing has been selected.
TXTextControl.WPF.TextControl.DrawingSized Occurs when a drawing has been sized.