The mcTabset component is a descendant of Delphi standard TTabSet.
It provides the following new usefull features:
- Rename tabs inplace
- Change tabs order using mouse drag'n'drop
To rename a tab user can either:
- Click and hold mouse pointer for about a second over the tab
- Hold Ctrl key and then click a tab by mouse
- Use an application-provided context menu
User can type a new tab name and press 'Enter' to confirm changes.
Or, abandon changes by pressing 'Esc' or clicking mouse outside of the editor.
To change the Tab Order, user can simply drag any tab by mouse to a new position.
Component displays a target indicator (a colored triangle) during the drag'n'drop process.
See the Demo Project for examples on use.
property RenameTimeout: Cardinal;
A timeout (in milliseconds) before the tab name editor will be displayed (when user click and hold a mouse over the tab).
The property is Read/Write. Its default value is 700 ms.
procedure ShowEditor(Index: Integer);
Shows an inplace editor for the tab of a given
An application can provide a context menu with 'Rename' command for the TabSet control.
Its event handler can be as follows:
// ts: TMCTabset
// pmTabs: TPopupMenu
// pmTabsRename: TMenuItem
procedure TForm1.pmTabsRenameClick(Sender: TObject);
// Activates the inplace editor for the target tab
This component should be installed into the Delphi Component Palette.
Use the component registration unit 'mcTabsReg.pas' for this purpose.
Example registration for Delphi 7:
- From main Delphi menu select 'Component', 'Install Component…'. Dialog window will appear.
- Browse 'Unit File Name' field to the location of mcTabsReg.pas file.
- Press 'OK' to compile the component and register it in Delphi Component Palette.
Get It From Here!
- Try the demo including the project source code and executable (220K download size).
- Buy the component source code using a safe payment processing service from Share*it!.