-
Notifications
You must be signed in to change notification settings - Fork 19
News and Hints
Useful Links
Microsoft Windows Ribbon Framework
Table of Content for Documentation
Windows Ribbon Framework for Delphi From this page you can get a very good tutorial for the Ribbon.
When using ApplicationModes to a Tab or Group then you should define ApplicationMode to all Tabs and Groups in the RibbonMarkup.xml. If you don't do this you can get an Application shutdown when switching the ApplicationMode.
In the Ribbon controls classes RibbonButton, RibbonComboBox etc. you have different properties dependent to the control. Some of these properties you can define in the markup at a Command. Following table will show the property names in markup and in the control classes.
Markup | Control class |
---|---|
LabelTitle | Label |
LabelDescription | LabelDescription |
TooltipTitle | ToolTipTitle |
TooltipDescription | ToolTipDescription |
Keytip | Keytip |
Command.SmallImages | SmallImage |
Command.LargeImages | LargeImage |
Command.SmallHighContrastImages | SmallHighContrastImage |
Command.LargeHighContrastImages | LargeHighContrastImage |
!Note:
If you define these properties in markup, you can't read the values in the code behind of the control classes.
If you want to write the listed properties in the code behind, it is recommended that you don't specify the values in the markup. You can do it in the Load event of the Form or later on. In this case it is possible to read the values in code behind.
For some Ribbon Controls there are line breaks possible for the Properties LabelTitle (Label), LabelDescription, TooltipTitle and TooltipDescription. You can set a line break in the markup by a Text Editor, in the code behind or since RibbonTools version 1.3.7 also in the RibbonTools.
In the following example we have defined a Command for a RibbonButton with the name "ButtonHeatCurve". In Code behind you can write:
ButtonHeatCurve.TooltipDescription = "Heating" + (char)0xa + "Curve";
In Xml markup you can write this with a text editor to the TooltipDescription:
Heating
Curve
In RibbonTools you write to TooltipDescription:
Heating\nCurve
You can try to use a ComboBox with the Markup Property IsEditable="true"
You can try to use a Button with the "Extra Label" in the Markup Property Label. In Code behind you have to set this Button Property Enabled = false. See Samples\CS\Mainform, Tab "Page Layout", Group3, Button cmdButtonLabel. Also have a look to the Size Definition in Group3.
See Samples\CS\Mainform, Tab "Page Layout", Group1, Group2, Group4. Also have a look to the Markup element Size Definition in the Groups.
All Ribbon Controls like RibbonButton now have a free Tag Property with the type Object. You can use it like you want.
There is also a new Property CommandType with the enum type RibbonLib.Interop.CommandType. This property is set by the Framework when the Framework uses this Ribbon Control in the view.
Since Ribbon V2.15.0 there is a Name property. This can be set by user after instantiation. This maybe helpful for debugging.
MDI is not supported by the Windows Ribbon framework directly. See an older: MDI support, commented by a Microsoft employee.
But the only thing I know is, that one can't use the Maximize Button or a WindowState.Maximized property in the MDI Forms. If one want a maximized MDI Form inside the Mainform, you have to do extra effort for sizing the MDI Form.
Alternatively, one can use a TabControl with some effort for closing, hiding, .... If there are other ideas you're welcome to write an issue or discussion
For the LabelTitle (Label) property you should set a Line break as last character. This will avoid an extra Line break for the last character in the Label text. See also, Hints for Line breaks in String-Properties in this document.
Todo ?
-
Basics
- Introduction, Background on the windows ribbon
- Basic Ribbon Wrapper Basic .NET wrappers for windows ribbon.
- Quickstart Tutorial
- First WinForms Ribbon Application How to create an empty WinForms application with ribbon support.
-
Working with Ribbon Controls
- Application Menu with Buttons How to use the ribbon application menu.
- Application Menu with SplitButton and DropDownButton How to use the ribbon application menu with ribbon split button and ribbon dropdown button controls.
- Tabs, Groups and HelpButton How to use ribbon tabs, groups and the ribbon help button control.
- Spinner How to use the ribbon spinner control.
- ComboBox How to use the ribbon combo box control.
- DropDownGallery, SplitButtonGallery and InRibbonGallery How to use the ribbon drop down gallery, split button gallery and in ribbon gallery controls.
- CheckBox and ToggleButton How to use the ribbon check box and toggle button controls.
- DropDownColorPicker How to use the ribbon drop down color picker control.
- FontControl How to use the ribbon font control.
- ContextualTabs How to work with ribbon contextual tabs.
- ContextPopup How to work with ribbon context popup.
- RecentItems How to work with ribbon recent items control.
- QuickAccessToolbar How to work with the ribbon quick access toolbar.
- The Ribbon Class How to work with the ribbon class. Methods, Properties, Events
- EventLogger Since Windows 8: Logging ribbon events
- UICollectionChangedEvent How to work with the ChangedEvent in an IUICollection
-
Working with miscellany Ribbon features
- ApplicationModes How to work with ribbon application modes.
- SizeDefinition How to define custom size definitions for ribbon group elements.
- Localization How to localize a ribbon.
- Changing Ribbon Colors How to change the ribbon colors.
- Working with Images How to work with images in the ribbon.
- Use Ribbon as External DLL How to load ribbon resources from external DLLs.
- Wrapper class RibbonItems An auto generated wrapper class from the ribbon markup.
-
Designing, building, previewing Windows Ribbon with RibbonTools
- RibbonTools basics Settings, Command line, ...
- Create a new project Create a WordPad sample project
- Preview the Ribbon
- Specifying Ribbon Commands
- Designing Ribbon Views
- Convert Images to Alpha Bitmaps
-
Modeling Guidelines
-
How to ...