Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision |
module:ddlightbarmenu.js [2018/03/26 10:43] – Added more information to the Add() method description nightfox | module:ddlightbarmenu.js [2018/03/26 13:12] – Added borderEnabled to the list of properties nightfox |
---|
The user can navigate the list using the up & down arrows, PageUp, PageDown, Home, and End keys. The enter key selects an item. The ESC key will exit the menu and return null. This menu library requires the use of an ANSI terminal. By default, this menu library does not display a border around the menu. If you want this library to draw a border around the menu, you can set the borderEnabled property to true. Without a border, the menu gains 2 characters of width and 2 lines of height. | The user can navigate the list using the up & down arrows, PageUp, PageDown, Home, and End keys. The enter key selects an item. The ESC key will exit the menu and return null. This menu library requires the use of an ANSI terminal. By default, this menu library does not display a border around the menu. If you want this library to draw a border around the menu, you can set the borderEnabled property to true. Without a border, the menu gains 2 characters of width and 2 lines of height. |
| |
This script provides a class, DDLightbarMenu. To create a new DDLightbarMenu object: new DDLightbarMenu(width, height); | This script provides a class, DDLightbarMenu. To create a new DDLightbarMenu object: new DDLightbarMenu(x, y, width, height); |
| |
**DDLightbarMenu methods** | **DDLightbarMenu methods** |
^ Name ^ Type ^ Description^ | ^ Name ^ Type ^ Description^ |
| colors | object | An object that contains color codes (as strings) for various things. Contains the following properties: itemColor, selectedItemColor, itemTextCharHighlightColor, borderColor | | | colors | object | An object that contains color codes (as strings) for various things. Contains the following properties: itemColor, selectedItemColor, itemTextCharHighlightColor, borderColor | |
| | borderEnabled | boolean | Whether or not to draw a border around the menu items | |
| wrapNavigation | boolean | Whether or not to wrap around to the beginning/end when using the down/up arrows. Defaults to true. | | | wrapNavigation | boolean | Whether or not to wrap around to the beginning/end when using the down/up arrows. Defaults to true. | |
| hotkeyCaseSensitive | boolean | Whether or not hotkeys are case-sensitive. Defaults to false. | | | hotkeyCaseSensitive | boolean | Whether or not hotkeys are case-sensitive. Defaults to false. | |