Previous Next Chapter

GETATTR command

Purpose:

This command will retrieve information from the Workbench database, such the names of the drawers currently open and the icons currently selected.

Format:

GETATTR [OBJECT] <Object name> [NAME <Item name>][STEM <Name of stem variable>] [VAR <Variable name>]

Template:

GETATTR OBJECT/A,NAME/K,STEM/K,VAR/K

Parameters:

OBJECT

Name of the database entry to retrieve. For a list of valid entries see below.

NAME

For some datatabase entries further information is required to identify the data to retrieve. This is when you will need to provide a name.

STEM

If you request more than one database entry you will need to provide a variable to store the information in. For an example of its use, see below.

VAR

If you want the queried information to be stored in a specific variable (other than the RESULT variable), this is where you provive its name.

Attributes:

You can obtain information on the following attributes:

APPLICATION.VERSION

Version number of workbench.library".

APPLICATION.SCREEN

Name of the public screen Workbench uses.

APPLICATION.AREXX

Name of the Workbench ARexx port.

APPLICATION.LASTERROR

Number of the last error caused by the ARexx interface.

APPLICATION.ICONBORDER

Sizes of the icon borders, returned as four numbers separated by blank spaces, e.g. 4 3 4 3". The four numbers represent the left border width, the top border height, the right border width and the bottom border height (in exactly that order).

APPLICATION.FONT.SCREEN.NAME

Name of the Workbench screen font.

APPLICATION.FONT.SCREEN.WIDTH APPLICATION.FONT.SCREEN.HEIGHT

Size of a single character of the Workbench screen font. Please note that since the font in question may be proportional spaced the width information may be of little value. To measure the accurate pixel width of a text in reference to the font, use the .SIZE attribute.

APPLICATION.FONT.SCREEN.SIZE

Size of a text, measured in pixels, in reference to the screen font. The text to measure must be provided with the NAME parameter of the GETATTR command.

APPLICATION.FONT.ICON.NAME

Name of the Workbench icon font.

APPLICATION.FONT.ICON.WIDTH APPLICATION.FONT.ICON.HEIGHT

Size of a single character of the Workbench icon font. Please note that since the font in question may be proportional spaced the width information may be of little value. To measure the accurate pixel width of a text in reference to the font, use the .SIZE attribute.

APPLICATION.FONT.ICON.SIZE

Size of a text, measured in pixels, in reference to the icon font. The text to measure must be provided with the NAME parameter of the GETATTR command.

APPLICATION.FONT.SYSTEM.NAME

Name of the system font.

APPLICATION.FONT.SYSTEM.WIDTH
APPLICATION.FONT.SYSTEM.HEIGHT

Size of a single character of the system font.

APPLICATION.FONT.SYSTEM.SIZE

Size of a text, measured in pixels, in reference to the system font. The text to measure must be provided with the NAME parameter of the GETATTR command.

WINDOWS.COUNT

Number of the drawer windows currently open. This can be 0.

WINDOWS.0 .. WINDOWS.N

Names of the windows currently open.

WINDOWS.ACTIVE

Name of the currently active Workbench window; this will be " if none of Workbench`s windows is currently active.

KEYCOMMANDS.COUNT

Number of keyboard commands assigned. This can be 0.

KEYCOMMANDS.0 .. KEYCOMMANDS.N

Information on all the keyboard commands assigned.

KEYCOMMANDS.<n>.NAME

Name of the keyboard command.

KEYCOMMANDS.<n>.KEY

The key combination assigned to this keyboard command.

KEYCOMMANDS.<n>.COMMAND

The ARexx command assigned to this key combination.

MENUCOMMANDS.COUNT

Number of menu commands assigned (through the MENU ADD .." command). This can be 0.

MENUCOMMANDS.0 .. MENUCOMMANDS.N

Information on all the menu commands assigned.

MENUCOMMANDS.<n>.NAME

Name of this menu item.

MENUCOMMANDS.<n>.TITLE

Title of this menu item.

MENUCOMMANDS.<n>.SHORTCUT

The keyboard shortcut assigned to this menu item.

MENUCOMMANDS.<n>.COMMAND

The ARexx command assigned to this menu item.

The following attributes require that the name of the window to obtain information on is provided.

Example:

WINDOW.LEFT

Left edge of the window.

WINDOW.TOP

Top edge of the window.

WINDOW.WIDTH

Width of the window.

WINDOW.HEIGHT

Height of the window.

WINDOW.MIN.WIDTH

Minimum width of the window.

Top Previous Next Chapter