PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Overview
  • Characteristics of a menu option
  • Caption of a menu option
  • Translating the menu options
  • Marking/Unmarking a menu option
  • Image associated with a menu option
  • Modifying the background color of menus and menu options
  • Keyboard shortcut associated with a menu option
  • Displaying the code of a menu option
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Overview
WINDEV and WINDEV Mobile manage two types of menus:
  • WindowsLinuxAndroidWindows MobileUniversal Windows 10 AppJava the main menus of windows.
    A main menu is necessarily associated with a window. Depending on the runtime platform used, this menu can be:
    • displayed below the title bar of window (Windows applications for example).
    • displayed at the bottom of window (Windows Mobile applications for example).
    • displayed in an Action Bar control (mobile applications for example).
    For more details, see:
  • WindowsLinuxAndroidiPhone/iPadWindows MobileUniversal Windows 10 AppJava the custom popup menus.
    A popup menu can be opened by the user via a right mouse click.
    See Custom popup menu for more details.
Versions 20 and later
iPhone/iPad The custom popup menus are now available for the iPhone/iPad applications.
New in version 20
iPhone/iPad The custom popup menus are now available for the iPhone/iPad applications.
iPhone/iPad The custom popup menus are now available for the iPhone/iPad applications.
Versions 21 and later
Universal Windows 10 App The custom popup menus are now available in Universal Windows 10 App mode.
New in version 21
Universal Windows 10 App The custom popup menus are now available in Universal Windows 10 App mode.
Universal Windows 10 App The custom popup menus are now available in Universal Windows 10 App mode.
A menu (main menu or popup menu) includes one or more options and sub-options. Each option is used to run a WLanguage code.
For example:
Main menu
Popup menu
In the editor, the operations performed on the menu options are the same for a main menu and for a custom popup menu. To handle the menu options, all you have to do is edit the relevant menu.
To edit (or display in the editor):
  • WindowsLinuxWindows Mobile The main menu of a window:
    • open the relevant window in the window editor.
    • select one of the menu options. The options and the sub-options are automatically displayed.
  • A custom popup menu, select "Window .. Popup menu .. <NamePopupMenu>".A custom popup menu: on the "Window" pane, in the "Bars and menus" group, expand "Popup menus" and select one of the existing popup menus.
Note: WINDEV and WINDEV Mobile also allow you to:
Characteristics of a menu option

Caption of a menu option

The caption of a menu option can be modified in the window in edit:
  1. Select a menu option.
  2. Press the [Space] key.
  3. Modify the caption in the input area.
    Modifying the caption of the option
  4. Press the [Enter] key to validate the input.
Note: You also have the ability to select "Edit the caption" from the popup menu of menu option.
Tip: To write text in bold in the caption of menu option, all you have to do is enclose the text that must be written in bold between <B> and </B> by programming. For example:
OPT_New..Caption = "Rename Sheet 1"

Translating the menu options

To translate the caption of menu options in the editor:
  1. Display the window in the translation language:
    • Select "Display .. Displayed language...". On the "Display" pane, in the "Options" group, expand "Language displayed" and choose the requested language.
    • The captions of controls and menu options are displayed in the selected language.
  2. Type the text of options in the selected language ([Space] key on the menu options).
Reminder: The caption entered when creating a menu option is carried over to all the languages supported by the current window.

Marking/Unmarking a menu option

Each menu option can be preceded (or not) by the checkmark Checkmark . This checkmark is used to view the active features for example.
Menu option with checkmark
To mark a menu option in the editor:
  1. Select the menu option to mark.
  2. Display the "GUI" tab in the description window of menu option ("Option description" from the popup menu).
  3. Check "Checkmark". The Checkmark checkmark will be displayed in front of the current menu option when the menu is displayed.
Notes:
  • At run time, to hide and/or display the Checkmark checkmark, use MenuMark and MenuUnmark. You also have the ability to use ..Checked.
    AndroidWindows Mobile Only ..Checked is available.
  • In most cases, a menu option cannot be preceded by both a checkmark and an image.
  • iPhone/iPadUniversal Windows 10 App You don't have the ability to check or not an option.

Image associated with a menu option

Each menu option can be preceded (or not) by an image.
Menu option with image
To display an image in front of a menu option:
  1. Select the menu option in front of which the image must be displayed.
  2. Display the "GUI" tab in the description window of menu option ("Option description" from the popup menu).
  3. Select the image to display. This image can be chosen in the image catalog ("Catalog" button).Select the image to display. This image can be chosen in the image catalog (click the Drop-down button button and select the "Catalog" option).
Notes:
  • To find out and/or modify the image associated with a menu option, use ..Image.
  • In most cases, a menu option cannot be preceded by both a checkmark and an image.
Formats of images:
Windows The following image formats are supported in Windows:
  • Bitmap (*.BMP)
  • Graphics Interchange Format (*.gif)
  • Joint Picture Experts Group (*.jpg ; *.jpeg)
  • Kodak Photo CD (*.pcd)
  • PaintBrush (*.pcx)
  • Adobe Photoshop Format (*.psd)
  • TrueVision TARGA (*.tga)
  • Tagged Image File Format (*.tif ; *.tiff)
    Note: the "tiled tiff" option of the tiff 6.0 standard is not supported. In this case, we advise you to save the image in tiff 5.0 standard.
  • Portable Network Graphics (*.png)
  • Windows MetaFiles (*.emf ; *.wmf)
  • Icons (*.ico ; *.icw)
    Versions 22 and later
    Notes:
    • HQ display (High Quality) available.
    • Management of sheets in transparent BMP format (32 bits).
    New in version 22
    Notes:
    • HQ display (High Quality) available.
    • Management of sheets in transparent BMP format (32 bits).
    Notes:
    • HQ display (High Quality) available.
    • Management of sheets in transparent BMP format (32 bits).
  • Cursors (*.cur)
  • Portable Document Format (*.pdf)
  • Versions 15 and later
    Scalable Vector Graphics (*.svg)
    New in version 15
    Scalable Vector Graphics (*.svg)
    Scalable Vector Graphics (*.svg)
Note: To manage the pdf and svg formats, GDIPLUS.DLL must be installed for the computers running Windows 2000 and earlier. For the later versions, this DLL is supplied with Windows. See GDI+ framework for more details.
Windows Mobile The supported image formats are:
  • Bitmap (*.BMP)
  • Graphics Interchange Format (*.gif)
  • Joint Picture Experts Group (*.jpg ; *.jpeg)
  • Icons (*.ico ; *.icw)
Android The supported image formats are:
  • Bitmap (*.BMP)
  • Graphics Interchange Format (*.gif)
  • Joint Picture Experts Group (*.jpeg)
  • Portable Network Graphics (*.png)
Universal Windows 10 App The supported image formats are:
  • Portable Network Graphics (*.png)
  • Joint Picture Experts Group (*.jpg ; *.jpeg)
Java The supported image formats are:
  • Graphics Interchange Format (*.gif)
  • Joint Picture Experts Group (*.jpeg)
  • Portable Network Graphics (*.png)
WindowsLinux

Modifying the background color of menus and menu options

To modify the background color of menus and menu options
  1. Select the menu or one of its options.
  2. Display the description window ("Option description" from the popup menu).
  3. In the "Style" tab, configure:
    • the color of menu bar when it is inactive or during rollover.
    • the color of options when they are idle or during rollover.
The "Automatic" color is used to find out the default color managed by Windows.
Note: In order for the colors to be taken into account, uncheck "Display the menu in XP style" in the "Style" tab of window description.
WindowsLinuxWindows MobileUniversal Windows 10 AppJava

Keyboard shortcut associated with a menu option

Each menu option can be associated (or not) with a keyboard shortcut.
Reminder: A keyboard shortcut corresponds to an alphanumeric character, a keyboard key or a combination of keyboard keys. This shortcut gives direct access to a menu option from the keyboard.
To associate a keyboard shortcut with a menu option:
  1. Select the menu option to which a keyboard shortcut must be associated.
  2. Display the description window of current option ("Option description" from the popup menu).
  3. Select the elements that constitute the keyboard shortcut of menu option.
    Shortcut in the editor
  4. Validate the description window. The selected keyboard shortcut will be displayed after the caption of the menu option:
    Shortcuts in the menu options
Notes:
  • If an option of a popup menu and a control have the same keyboard shortcut, the control will have priority over the option of the popup menu.
  • The shortcuts are not available in the popup menus. Only the keyboard shortcuts can be used.
Tip: To avoid displaying the keyboard shortcut after the menu option, all you have to do is modify the caption of the option by programming (..Caption). For example:
OPT_New..Caption = "New"

Displaying the code of a menu option

To display the code of a menu option:
  1. Select the menu option whose source code must be displayed.
  2. Display the popup menu of the current menu option (right mouse click).
  3. Select "Code". The code window of the current menu option is displayed.
Notes:
  • The code of a menu option can also be displayed from its description window. To do so, click Code icon . This code corresponds to the code run when the menu option is selected by the user. You have the ability to add optional processes via the icon bar displayed at the bottom of the code window:
    Optional processes
  • Only the menu options without sub-menu can start a WLanguage process.
Minimum required version
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment