This quick start is intended to get you up and running with the TagEditor control. It guides you through the steps of creating a new Visual Studio project with a C1TagEditor control, add content to it and run the application to view the output.
The following image shows how the TagEditor control in action.
XAML |
Copy Code
|
---|---|
<c1:C1TagEditor Name="te" Height="40" Width="400"/> <TextBlock Margin="108,250,108,164" Text="Enter content to add to Tageditor" Height="20" /> <TextBox x:Name="AddInput" Height="30" Margin="108,283,108,121"/> <Button Content="Click to add tag content" Margin="108,335,337,68" Click="button_click"/> |
C# |
Copy Code
|
---|---|
using C1.WPF.Input;
|
C# |
Copy Code
|
---|---|
public MainWindow() { InitializeComponent(); te.InsertTag("WPF"); } private void button_click(object sender, RoutedEventArgs e) { string text = AddInput.Text; if (!string.IsNullOrEmpty(text)) { te.InsertTag(text); if (te.DisplayMode == DisplayMode.Text) te.UpdateTextFromTags(); AddInput.Text = ""; } } |