4 ; Reports errors in an error box
6 ; © 1994-1998 Straylight
9 ;----- Licensing note -------------------------------------------------------
11 ; This file is part of Straylight's Sapphire library.
13 ; Sapphire is free software; you can redistribute it and/or modify
14 ; it under the terms of the GNU General Public License as published by
15 ; the Free Software Foundation; either version 2, or (at your option)
18 ; Sapphire is distributed in the hope that it will be useful,
19 ; but WITHOUT ANY WARRANTY; without even the implied warranty of
20 ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 ; GNU General Public License for more details.
23 ; You should have received a copy of the GNU General Public License
24 ; along with Sapphire. If not, write to the Free Software Foundation,
25 ; 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
27 ;----- Overview -------------------------------------------------------------
35 [ :LNOT::DEF:errorBox__dfn
38 ; --- errorBox_init ---
40 ; On entry: R0 == pointer to application name
44 ; Use: Initialises the errorBox system nicely. It creates the
45 ; dialogue box now, and just uses it for the rest of the
50 ; --- errorBox_beep ---
56 ; Use: Sounds the bell (VDU 7) if the CMOS settings dictate that
57 ; error boxes should cause a beep.
63 ; On entry: R0 == pointer to error block
64 ; R1 == button style code, or pointer to buttons block
66 ; On exit: R0 == icon number clicked (ordered from the right)
67 ; CS if R0 == 0, else CC
69 ; Use: Displays an error box on the screen. The error block
70 ; doesn't have to have a sensible error number, and doesn't
71 ; have to be word aligned, either.
73 ; Since errorBox claims a dialogue box handle on
74 ; initialisation, it isn't possible for this call to fail.
75 ; Hence it is ideal for reporting problems like `Out of
76 ; memory' or `Too many windows'.
78 ; The buttons in the error box may be given either by a code
79 ; or by a pointer to a buttons block (these may easily be
80 ; distinguished, since the codes are lower than &8000).
82 ; Standard button arrangements are given by codes, as follows:
88 ; 5 == OK, Cancel, Help
94 ;----- That's all, folks ----------------------------------------------------