4D v16.3

Get menu item style

Home

 
4D v16.3
Get menu item style

Get menu item style 


 

Get menu item style ( menu ; menuItem {; process} ) -> Function result 
Parameter Type   Description
menu  Longint, MenuRef in Menu number or Menu reference
menuItem  Longint in Menu item number or -1 for last item added
process  Longint in Process reference number
Function result  Longint in Current menu item style

The Get menu item style command returns the font style of the menu item whose number or reference is passed in menu and whose item number is passed in menuItem. You can pass -1 in menuItem in order to indicate the last item added to menu.

If you omit the process parameter, Get menu item style applies to the menu bar for the current process. Otherwise, Get menu item style applies to the menu bar for the process whose reference number is passed in process.

Note: If you pass a MenuRef in menu, the process parameter serves no purpose and will be ignored.

Get menu item style returns a combination (one or a sum) of the following predefined constants, found in the Font Styles theme:

Constant Type Value
Bold Longint 1
Italic Longint 2
Plain Longint 0
Underline Longint 4

Example  

To test if a menu item is displayed in bold, you write:

 If((Get menu item style($vlMenu;$vlItem)&Bold)#0)
  `...
 End if



See also 

SET MENU ITEM STYLE

 
PROPERTIES 

Product: 4D
Theme: Menus
Number: 426

Not for server

 
HISTORY 

Modified: 4D v11 SQL

 
ARTICLE USAGE

4D Language Reference ( 4D v16)
4D Language Reference ( 4D v16.1)
4D Language Reference ( 4D v16.2)
4D Language Reference ( 4D v16.3)