Edit this page

Text Tool

This article describes the TextTool that was exposed with the Q1 2013 release.

The TextTool allows you to enter the edit mode of a RadDiagramItem as soon as you click on it. Furthermore, you can use this tool to draw text shapes. As it isn't active by default, you can use the RadDiagram ActiveTool property to activate it in XAML:

<telerik:RadDiagram x:Name="xDiagram" ActiveTool="TextTool"/>

or in code-behind:

xDiagram.ActiveTool = Telerik.Windows.Diagrams.Core.MouseTool.TextTool;
xDiagram.ActiveTool = Telerik.Windows.Diagrams.Core.MouseTool.TextTool

Let's consider the following sample RadDiagram definition:

<telerik:RadDiagram x:Name="xDiagram" ActiveTool="TextTool">
    <telerik:RadDiagramShape Content="RectangleShape" Position="50,50" />
</telerik:RadDiagram>

In it we have one shape and a TextTool activated by default. This is why as soon as you click on the shape, you will enter its edit mode. This way you can easily modify its content.
Rad Diagram Tools Text Tool

And what is more, as soon as you activate the TextTool, you can dynamically create a text shape by dragging a rectangle on the diagramming surface:
Rad Diagram Tools Text Shape

See Also