TX Text Control .NET for WPF

Ribbon and UI

Topic

Which commands do your users need, and where should they find them? TX Text Control .NET for WPF answers with a set of XAML elements around the TextControl: ribbon tabs for Microsoft's WPF Ribbon, a button bar, mini toolbars, rulers, a status bar, sidebars, context menus and dialog boxes. Declaring and connecting them in XAML, the contents of each tab, commands of your own, and styling, translation and right-to-left mirroring each have a page of their own.

A WPF window with a ribbon that shows the Home and Insert tabs of TX Text Control, two rulers, the editor and a status bar.

How the Parts Fit Together

All elements are in the namespace TXTextControl.WPF, which the XAML maps to the prefix WPF, as the Visual Studio toolbox writes it. They find each other by name: the TextControl stores the x:Name of each ribbon tab, ruler, status bar and button bar it works with, the ribbon tabs store the names of the sidebars their buttons open, and a sidebar stores the name of its TextControl.

ElementWhat users do with it
RibbonFormattingTab and eleven more tabs, in a WPF RibbonAll commands of the editor, grouped in tabs
ButtonBarFont and paragraph formatting in a WPF ToolBar
TextMiniToolbar, ObjectMiniToolbarQuick formatting next to the selection
RulerBar, StatusBarMargins, indents and tabs; page, line and zoom information
SidebarPanels for find and replace, styles, comments, tracked changes, fields and document settings

The ribbon itself, the application menu and the Quick Access Toolbar are WPF classes from System.Windows.Controls.Ribbon; TX Text Control provides the tabs. Ribbon Tabs, Toolbars, Rulers, and Status Bar introduces each element.

Find the Right Page

If you want toRead
Know which ribbon tab contains which commands, and change or remove themBuilt-in Ribbon Tabs
Declare the ribbon in XAML and connect its tabs to the editorConnecting Ribbon Tabs in XAML
Add tabs, groups and buttons of your own, fill the application menuCustom Tabs and Commands
Use a button bar, or show mini toolbarsToolbars and Mini Toolbars
Set the scale unit of the rulers or the areas of the status barRulers and Status Bar
Open panels such as find, styles or comments beside the documentSidebar and Panels
Change the menu that opens with the right mouse buttonContext Menus
Open the dialog boxes for fonts, paragraphs, tables and moreBuilt-in Dialog Boxes
Style the elements and match them to your applicationStyles, Resources, and Themes
Show the interface in another languageLocalization and Resource Kit
Build an interface for Arabic or HebrewRight-to-Left UI

Where to Start

  1. Build a first editor with Create a WPF Ribbon Application or, without a ribbon, Connect Rulers, Toolbars, and a Status Bar.
  2. Read Connecting Ribbon Tabs in XAML to understand the connections by name.
  3. Choose the tabs your users need in Built-in Ribbon Tabs, and add your own commands with Custom Tabs and Commands.
  4. Look at the TX Words Sample Application, which combines all elements in one window.

Pages in This Section