qdosmsq:pe:struct:winvar

Window Definition - Completion

The window definition, from which window working definitions are set, contains the information for all the sizes of window required.

Name     Off Size Description
-------------------------------------------------------------------------
wd_xmin  $00 word x (minimum) size for this layout + scaling flag
wd_ymin  $02 word y (minimum) size for this layout + scaling flag
wd_pinfo $04 word pointer to information window definition list
wd_plitm $06 word pointer to loose item list
wd_pappl $08 word pointer to application window list
wd.elen  $0A      repeated entry length
-------------------------------------------------------------------------
  • The scaling flag indicates how items in a variable window are to be sized and placed. this occupies the top nibble of the size or origin of the object. It has five values as shown below. The scaling flags in wd_xmin and wd_ymin above can only take the values 0000% or 0100%.
  • The pointers in the window definition are all of length one word. The value of the pointer is the position of the object less the position of the pointer. If the distance to the object is greater than a word the pointer points instead to a long word containing the address of the object. In that case the word pointer's least significant bit is set as an indication of this.
  • The justification rule which applies to loose items and menu items, shows where the object is to be placed. The value 0 means centralised; -k means k pixels from the right or bottom; +k means k pixels from the left or top.
Value %Meaning
0000invariant
00011/4 times increase
00101/2 times increase
00113/4 times increase
01001 times increase

The list of loose items is terminated by a word containing -1.

Name     Off Size Description
-------------------------------------------------------------------------
wdl_xsiz $00 word hit area x size + scaling
wdl_ysiz $02 word hit area y size + scaling
wdl_xorg $04 word hit area x origin + scaling
wdl_yorg $06 word hit area y origin + scaling
wdl_xjst $08 byte x justification rule
wdl_yjst $09 byte y justification rule
wdl_type $0A byte object type (0=test, 2=sprite, 4=blob, 6=pattern
wdl_skey $0B byte selection key (letters upper case)
wdl_pobj $0C word pointer to object
wdl_item $0E word item number
wdl_pact $10 word pointer to action routine
wdl.elen $12      list entry length
-------------------------------------------------------------------------

The list of information sub-windows is terminated by a word containing -1.

Name     Off Size Description
-------------------------------------------------------------------------
wdi_xsiz $00 word sub-window x size + scaling
wdi_ysiz $02 word sub-window y size + scaling
wdi_xorg $04 word sub-window x origin + scaling
wdi_yorg $06 word sub-window y origin + scaling
wdi_watt $08      sub-window attributes
wdi_pobl $10 word pointer to information object list
wdi.elen $12      information list entry length
-------------------------------------------------------------------------

The information sub-window origin is the pixel position of the top left hand corner of the inside of the sub-window with respect to the top left hand corner of the window.

The list of objects is terminated by a word containing -1.

Name     Off Size Description
-------------------------------------------------------------------------
wdo_xsiz $00 word object width in pixels + scaling
wdo_ysiz $02 word object height in pixels + scaling
wdo_xorg $04 word object x origin + scaling
wdo_yorg $06 word object y origin + scaling
wdo_type $08 byte object type (See Notes below)
wdo_spar $09 byte spare = 0

Either (See Notes below)

wdo_ink  $0A word text ink colour
wdo_csiz $0C text character size

Or

wdo_comb $0A word pattern or blob (See Notes)
wdo.elen $10      information object list entry length
-------------------------------------------------------------------------
  • The object types are:
    • 0 = text
    • 2 = sprite
    • 4 = blob
    • 6 = pattern
  • The alternatives at offset $0A depend on the type of object. The first alternative is for type 0, text. The second alternative is for types 4 and 6. For type 4, a blob, a pattern is needed. For type 6, a pattern, a blob is needed.

The application window list consists simply of a set of word pointers to the individual application window definitions. This list is terminated by a zero long word.

Name     Off Size Description
-------------------------------------------------------------------------
wda_xsiz $00 word sub-window width in pixels + scaling
wda_ysiz $02 word sub-window height in pixels + scaling
wda_xorg $04 word sub-window x origin + scaling
wda_yorg $06 word sub-window y origin + scaling
wda_watt $08      sub-window attributes
wda_pspr $10 word pointer to sprite for this sub-window
wda_setr $12 word pointer to setup routine
wda_draw $14 word pointer to draw routine
wda_hit  $16 word pointer to hit routine
wda_ctrl $18 word pointer to control routine
wda_nxsc $1A word maximum number of x control sections
wda_nysc $1C word maximum number of y control sections
wda_skey $1E byte sub-window selection keystroke
wda_ext  $1F byte zero
wda.blen $20 sub-window base definition length
-------------------------------------------------------------------------     

The following section does not appear if both wda_nxsc and wda_nysc are zero. If both of these are non-zero there are two sections, the first being for pannable and the second for scrollable sub-windows.

Name     Off Size Description
-------------------------------------------------------------------------
wda_part $00 word pointer to control block (relative to window status area)
wda_insz $02 16 spare bytes   
wda_psac $12 word pan or scroll arrow colour
wda_psbc $14 word pan or scroll bar background colour
wda_pssc $16 word pan or scroll bar section colour
wda.clen     control definition length
-------------------------------------------------------------------------

This only appears for application sub-windows which have a menu in them. This will be processed by WM_SMENU called by the setup routine. (See wda_setr.)

Name     Off Size Description
-------------------------------------------------------------------------
wda_mstt $00 word pointer to menu status block (relative to window status area)
wda_iatt $02      item attributes
wda_ncol $1E word number of actual columns
wda_nrow $20 word number of actual rows
wda_xoff $22 word x offset to start of menu (section)
wda_yoff $24 word y offset to start of menu (section)
wda_xspc $26 word pointer to column spacing list
wda_yspc $28 word pointer to row spacing list
wda_xind $2A long spare
wda_rowl $2E word pointer to menu row list
wda.mlen $30      menu definition length
-------------------------------------------------------------------------
Name     Off Size Description
-------------------------------------------------------------------------
wdm_size $00 word object hit size + scaling
wdm_spce $02 word object spacing + scaling
wdm.blen $04      object spacing list length
-------------------------------------------------------------------------
Name     Off Size Description
-------------------------------------------------------------------------
wdm_rows $00 word pointer to object row list start
wdm_rowe $02 word pointer to object row list end
wdm.rlen $04      row list length
-------------------------------------------------------------------------

Menu Object List entry

Name     Off Size Description
-------------------------------------------------------------------------
wdm_xjst $00 byte object x justification rule
wdm_yjst $01 byte object y justification rule
wdm_type $02 byte object type (see Notes under Information Object List)
wdm_skey $03 byte selection keystroke
wdm_pobj $04 word pointer to object
wdm_item $06 word item number
wdm_pact $08 word pointer to action routine
wdm.olen $0A      menu object length
-------------------------------------------------------------------------

The format of window attributes is given here.

The attributes for both loose items and the menu items in an application window are given in the fixed section.

  • qdosmsq/pe/struct/winvar.txt
  • Last modified: 2016/03/28 09:14
  • by george.gwilt