Thanks, the NB. comments are wrong, but the behavior is as intended.

On Fri, Jun 13, 2014 at 8:58 AM, Tom Arneson <[email protected]> wrote:

> I was testing several message box items in J802 and found the following:
>
> NB. mb (message box) demo
> NB.
> NB. the message box syntax is:
> NB.   wd 'mb type buttons title message'
> NB.
> NB. type specifies the icon and default behaviour:
> NB.  info      (default OK button)
> NB.  warn      (default OK button)
> NB.  critical  (default OK button)
> NB.  query     (requires two or three buttons, default is first given)
> NB.             note - display order is platform-dependent
> NB.
> NB. if 1 buttons, there is no result,
> NB. otherwise the result is the button numeric value  <<<--- NOT TRUE IN
> J802. The button label is returned
> NB.
> NB. buttons (with numeric values) are from the set:
> NB.  0 mb_ok
> NB.  1 mb_cancel
> NB.  2 mb_yes
> NB.  3 mb_no
> NB.  4 mb_save
> NB.  5 mb_discard
>
>    [b=. wd'mb query mb_yes mb_no mb_cancel mb_discard mb_ok mb_save "title
> 1" "Do you want to quit"'
> discard
>    [b=. wd'mb query mb_yes mb_no mb_cancel mb_discard mb_ok mb_save "This
> is
> the title!" "Do you want to quit"'
> cancel
>    [b=. wd'mb query mb_yes mb_no mb_cancel mb_discard mb_ok mb_save "This
> is
> the title!" "Do you want to quit"'
> save
>
>
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to