Getting Started | Documentation | Glish | Learn More | Programming | Contact Us |
Version 1.9 Build 1556 |
|
Package | display | |
Module | widgets | |
Tool | twodactionoptionmenu |
Construct an optionmenu
Synopsis
twodactionoptionmenu(parent, images, names, values, ncolumn, hlp, hlp2, padx, pady, borderwidth, widgetset)
Arguments
parent
Parent of the menu
Allowed:
Widget
images
Filenames of bitmaps to use
Allowed:
Vector of strings
Default:
Empty menu
names
The menu item names
Allowed:
Vector of strings
Default:
Empty menu
values
The menu item values
Allowed:
Vector of anything
Default:
Empty menu
ncolumn
Number of columns of buttons
Allowed:
Integer
Default:
3
hlp
Short popuphelp text
Allowed:
String
Default:
No help
hlp2
Long popuphelp text
Allowed:
String
Default:
No help
padx
Horizontal padding around text
Allowed:
Integer
Default:
2
pady
Vertical padding around text
Allowed:
Integer
Default:
2
borderwidth
Border width
Allowed:
Integer
Default:
2
widgetset
The widget server to use
Allowed:
widgetserver tool
Default:
dws
Returns
Agent
Description
This is the constructor. The menu either uses icons (images),
or text labels (names). The array provided with the most elements is
used. The number of elements in the array used must equal the number
of elements in labels. The menu is built by construction the
specified number of columns * required rows in order to fit all menu
options on the pop up frame.
Example
- include 'twodactionoptionmenu.g'
- names := ['Absolute', 'Relative to ref. pixel', 'Relative to center'];
- values := [1,2,3];
- f := frame();
- hlp := 'Select type of coordinate';
- m := twodactionoptionmenu(parent = f, names = names,
values = values, ncolumn = 2, hlp = hlp);
Creates a two dimensional option menu with 2 columns and required rows
(in this case 2). If bitmaps were required instead:
- include 'twodactionoptionmenu.g'
- images := ['abs.xbm', 'rel.xbm', 'relcent.xbm'];
- values := [1,2,3];
- f := frame();
- hlp := 'Select type of coordinate';
- m := twodactionoptionmenu(parent = f, names = names,
values = values, ncolumn = 2, hlp = hlp);
Next: twodactionoptionmenu.currentvalue - Function
Up: twodactionoptionmenu - Tool
Previous: twodactionoptionmenu - Tool
  Contents
  Index
Please send questions or comments about AIPS++ to aips2-request@nrao.edu.
Copyright © 1995-2000 Associated Universities Inc.,
Washington, D.C.
Return to AIPS++ Home Page
2006-10-15