Ribbon Class
- Namespace
TXTextControl.Windows. Forms. Ribbon
- Package
TXTextControl.from the private NuGet feed or Text Control Offline PackagesTextControl. WinForms. SDK
- Assembly
TXTextControl.Windows. Forms. dll
- Install
dotnet add package TXTextControl..NET 8 and later. For .NET Framework, referenceTextControl. WinForms. SDK TXTextControl.from the setup.Windows. Forms. dll
- Inherits
- Tab
Control - Ribbon
- Tab
Description
The Ribbon class is a command bar that organizes the features of an application into a series of tabs at the top of the application window. It replaces both the traditional menu bar and toolbars. It hosts an Application Menu, and one or more RibbonTab controls. These controls then host a variety of button and menu controls that enable access to application commands. To add or remove objects of type RibbonTab it is recommended to use the Ribbon's Controls property. The Ribbon class is inherited from the System.Windows.Forms.TabControl class. The following describes only the properties, methods and events defined through the Ribbon class. For a list of properties, methods and events inherited from the System.Windows.Forms.TabControl class see the .NET Framework reference. A ribbon can be connected with a TextControl through the TextControl.Ribbon property.
Syntax
public class Ribbon : TabControlPublic Class Ribbon
Inherits TabControlExamples
The following example creates a Ribbon instance and configures its minimized setting for a document workflow.
using TXTextControl.Windows.Forms.Ribbon.Ribbon ribbon = new();
ribbon.Minimized = true;Dim ribbon As New TXTextControl.Windows.Forms.Ribbon.Ribbon()
ribbon.Minimized = TrueMembers
Constructors
| Constructor | Description |
|---|---|
| Ribbon | Initializes a new instance of the Ribbon class. |
Properties
| Property | Description |
|---|---|
| ApplicationMenuHelpPaneItems | Gets a collection of all items which are displayed on the help pane of the Application Menu. The Application Menu has a help pane that can host additional content and is typically used to display a list of recent documents. The collection can be used to add or remove items and to set item properties. The property value is an object of the type Windows.Forms.Ribbon.RibbonItemCollection. |
| ApplicationMenuItems | Gets a collection of all items which are displayed on the Application Menu. Every ribbon includes an Application Menu as the first tab in the ribbon. Other ribbon tabs contain controls for working with the document content. In contrast, the Application Menu presents a menu of commands for working with the file. The collection can be used to add or remove items and to set item properties. The property value is an object of the type Windows.Forms.Ribbon.RibbonItemCollection. |
| ContextualTabGroups | Gets a collection of all contextual tab groups of this ribbon. The collection can be used to add or remove items and to set item properties. The property value is an object of the type Windows.Forms.Ribbon.ContextualTabGroupCollection |
| DisplayColors | Gets or sets the colors of the ribbon. The property value is an object of the type Windows.Forms.Ribbon.Ribbon.Colors. |
| HasApplicationMenu | Gets or sets a value defining whether the first tab of the ribbon is an application menu. |
| Minimized | Gets or sets a value determining whether the ribbon is shown minimized. |
| ReadOnly | Gets or sets a value determining the ribbon's read only mode. When the ribbon is set to read only, it still shows all formatting attributes of the connected TextControl, but formatting attributes cannot be changed. |
Methods
| Method | Description |
|---|---|
| ResetDisplayColors | Not described in the reference. public void ResetDisplayColors(); |