DrawTextNoPrefix Property
Description
The DrawTextNoPrefix property is used to change how the '&' mnemonic is processed in the tab button captions.
Property Type
Read-write property
Syntax (Visual Basic)
Public Property DrawTextNoPrefix() As Boolean
Remarks
- If set to FALSE, then an ampersand '&' in the tab button caption will be ignored and the character immediately following the ampersand will be underlined. A double ampersand '&&' will display a single ampersand '&'.
For example, if the tab caption was "Te&xt", then the resulting caption would look like "Text".
- If set to TRUE, then the caption will be displayed unmodified. This can be used to indicate to the user that a hot key is associated with the tab. Please note that a key cannot be directly bound to a tab; you will need to manually handle the key bindings and then the appropriate tab can be selected.
Example
This sample illustrates how to underline a character in a tab button caption. This lets the user know that a hot key is associated with the tab.
' Indicates that a single '&' in the tab button caption will result in the following
' character being underlined.
wndTabControl.PaintManager.DrawTextNoPrefix = False
See Also
Copyright (c) 1998-2024 Codejock Technologies. All rights reserved.