qdosmsq:pe:struct:windef

Window Definition

This section details all the various data structures required to set up and display various menus, windows etc under the Pointer Environment.

In a Pointer Environment program the details of size, position and contents of its window are stored in ram in a structure called Window Working Definition. A typical window can be resized or turned into a button, in which case the contents of the Working Definition will have to be redefined. To enable this to happen the structure Window Definition is used. This contains details of all the possible forms of window. The form is as follows:

  • Fixed Section which includes the maximum size of window. This is followed by one or more instances of a
  • Repeated Section. Each of these has a size which must be less in at least one dimension than that in the previous section and never exceeding the maximum size in the fixed section. Each repeated section has pointers to lists of loose items, information windows and application windows.

A Working Definition is produced by using wm_setup with one parameter indicating which of the repeated sections applies and another pointing to the Window Definition.

The forms of both the Window Definition and the Window Working Definition are similar, but there are three significant differences.

  • There are no repeated sections in the Window Working Definition.
  • The pointers in the Window Definition are word relative. That is, the address of the target is equal to the address of the pointer plus its value. The pointers in the Window Working Definition are long word absolute.
  • In the Window Definition all sizes and positions can include scaling factors to allow resizing. There are, obviously, no scaling factors in the Window Working Definition.

Note that this page doesn't discuss the parts of the working definition which is set up internally when you call wm_setup, for example. The discussion consists of what a programmer would have to define in his or her source code.

  • qdosmsq/pe/struct/windef.txt
  • Last modified: 2011/11/08 13:58
  • by george.gwilt