SD_BORDR/IOW_DEFB
This trap sets a window's colour and size.
Call Parameters | Return Parameters | ||
---|---|---|---|
D0.B | $0C | D0.L | Error return. |
D1.B | Colour | D1.L | Corrupted. |
D2.W | Width | D2.L | Preserved. |
D3.W | Timeout | D3.L | Preserved. |
A0.L | Channel ID | A0.L | Preserved. |
A1.L | A1.L | Corrupted. |
Errors
ERR_NC | Not complete. |
ERR_NO | Channel not open. |
Notes
- All registers not shown above are not used on entry and are preserved on exit.
- The width of the border is doubled on the vertical edges.
- The border is set inside the window's limits.
- All subsequent screen traps (except this one) use the reduced window size for defining cursor position and window limits.
- If the call changes the width of the border, the cursor is reset to the home position at top left.
- As a special case if the colour is set to $80 the border is made transparent.
Example
The example below shows the use of this trap call to set a border. It is assumed that A0 contains the window's ID.
brdr moveq #sd_brdr,d0 ; $0C moveq #-1,d1 ; Grey border moveq #3,d2 ; Width 3 moveq #-1,d3 ; Timeout trap #3 ; Set the border tst.l d0 ; OK? . . bne error ; . . no!