Mercurial > hg > xemacs-beta
comparison man/widget.texi @ 153:25f70ba0133c r20-3b3
Import from CVS: tag r20-3b3
author | cvs |
---|---|
date | Mon, 13 Aug 2007 09:38:25 +0200 |
parents | 538048ae2ab8 |
children | 43dd3413c7c7 |
comparison
equal
deleted
inserted
replaced
152:4c132ee2d62b | 153:25f70ba0133c |
---|---|
11 | 11 |
12 @node Top, Introduction, (dir), (dir) | 12 @node Top, Introduction, (dir), (dir) |
13 @comment node-name, next, previous, up | 13 @comment node-name, next, previous, up |
14 @top The Emacs Widget Library | 14 @top The Emacs Widget Library |
15 | 15 |
16 Version: 1.97 | 16 Version: 1.98 |
17 | 17 |
18 @menu | 18 @menu |
19 * Introduction:: | 19 * Introduction:: |
20 * User Interface:: | 20 * User Interface:: |
21 * Programming Example:: | 21 * Programming Example:: |
55 @item menu-choice | 55 @item menu-choice |
56 Allows the user to choose one of multiple options from a menu, each | 56 Allows the user to choose one of multiple options from a menu, each |
57 option is itself a widget. Only the selected option will be visible in | 57 option is itself a widget. Only the selected option will be visible in |
58 the buffer. | 58 the buffer. |
59 @item radio-button-choice | 59 @item radio-button-choice |
60 Allows the user to choose one of multiple options by pushing radio | 60 Allows the user to choose one of multiple options by activating radio |
61 buttons. The options are implemented as widgets. All options will be | 61 buttons. The options are implemented as widgets. All options will be |
62 visible in the buffer. | 62 visible in the buffer. |
63 @item item | 63 @item item |
64 A simple constant widget intended to be used in the @code{menu-choice} and | 64 A simple constant widget intended to be used in the @code{menu-choice} and |
65 @code{radio-button-choice} widgets. | 65 @code{radio-button-choice} widgets. |
66 @item choice-item | 66 @item choice-item |
67 An button item only intended for use in choices. When pushed, the user | 67 An button item only intended for use in choices. When activated, the user |
68 will be asked to select another option from the choice widget. | 68 will be asked to select another option from the choice widget. |
69 @item toggle | 69 @item toggle |
70 A simple @samp{on}/@samp{off} switch. | 70 A simple @samp{on}/@samp{off} switch. |
71 @item checkbox | 71 @item checkbox |
72 A checkbox (@samp{[ ]}/@samp{[X]}). | 72 A checkbox (@samp{[ ]}/@samp{[X]}). |
231 @item The @samp{@b{[ ]}} and @samp{@b{[X]}} buttons. | 231 @item The @samp{@b{[ ]}} and @samp{@b{[X]}} buttons. |
232 Activating one of these will convert it to the other. This is useful | 232 Activating one of these will convert it to the other. This is useful |
233 for implementing multiple-choice fields. You can create it wit | 233 for implementing multiple-choice fields. You can create it wit |
234 @item The @samp{@b{( )}} and @samp{@b{(*)}} buttons. | 234 @item The @samp{@b{( )}} and @samp{@b{(*)}} buttons. |
235 Only one radio button in a @code{radio-button-choice} widget can be | 235 Only one radio button in a @code{radio-button-choice} widget can be |
236 selected at any time. When you push one of the unselected radio | 236 selected at any time. When you activate one of the unselected radio |
237 buttons, it will be selected and the previous selected radio button will | 237 buttons, it will be selected and the previous selected radio button will |
238 become unselected. | 238 become unselected. |
239 @item The @samp{@b{[Apply Form]}} @samp{@b{[Reset Form]}} buttons. | 239 @item The @samp{@b{[Apply Form]}} @samp{@b{[Reset Form]}} buttons. |
240 These are explicit buttons made with the @code{push-button} widget. The main | 240 These are explicit buttons made with the @code{push-button} widget. The main |
241 difference from the @code{link} widget is that the buttons are will be | 241 difference from the @code{link} widget is that the buttons are will be |
443 @table @samp | 443 @table @samp |
444 @item %[ | 444 @item %[ |
445 @itemx %] | 445 @itemx %] |
446 The text inside will be marked as a button. | 446 The text inside will be marked as a button. |
447 | 447 |
448 By default, the text will be shown in @code{widget-button-face}, and | |
449 surrounded by brackets. | |
450 | |
451 @defopt widget-button-prefix | |
452 String to prefix buttons. | |
453 @end defopt | |
454 | |
455 @defopt widget-button-suffix | |
456 String to suffix buttons. | |
457 @end defopt | |
458 | |
448 @item %@{ | 459 @item %@{ |
449 @itemx %@} | 460 @itemx %@} |
450 The text inside will be displayed with the face specified by | 461 The text inside will be displayed with the face specified by |
451 @code{:sample-face}. | 462 @code{:sample-face}. |
452 | 463 |
474 Insert a literal @samp{%}. | 485 Insert a literal @samp{%}. |
475 @end table | 486 @end table |
476 | 487 |
477 @item :button-face | 488 @item :button-face |
478 Face used to highlight text inside %[ %] in the format. | 489 Face used to highlight text inside %[ %] in the format. |
490 | |
491 @item :button-prefix | |
492 @itemx :button-suffix | |
493 | |
494 Text around %[ %] in the format. | |
495 | |
496 These can be | |
497 @table @emph | |
498 @item nil | |
499 No text is inserted. | |
500 | |
501 @item a string | |
502 The string is inserted literally. | |
503 | |
504 @item a symbol | |
505 The value of the symbol is expanded according to this table. | |
506 @end table | |
479 | 507 |
480 @item :doc | 508 @item :doc |
481 The string inserted by the @samp{%d} escape in the format | 509 The string inserted by the @samp{%d} escape in the format |
482 string. | 510 string. |
483 | 511 |
610 | 638 |
611 The @var{value}, if present, is used to initialize the @code{:value} | 639 The @var{value}, if present, is used to initialize the @code{:value} |
612 property. The value should be a string, which will be inserted in the | 640 property. The value should be a string, which will be inserted in the |
613 buffer. | 641 buffer. |
614 | 642 |
643 By default the link will be shown in brackets. | |
644 | |
645 @defopt widget-link-prefix | |
646 String to prefix links. | |
647 @end defopt | |
648 | |
649 @defopt widget-link-suffix | |
650 String to suffix links. | |
651 @end defopt | |
652 | |
615 @node url-link, info-link, link, Basic Types | 653 @node url-link, info-link, link, Basic Types |
616 @comment node-name, next, previous, up | 654 @comment node-name, next, previous, up |
617 @subsection The @code{url-link} Widget | 655 @subsection The @code{url-link} Widget |
618 | 656 |
619 Syntax: | 657 Syntax: |
650 | 688 |
651 The @var{value}, if present, is used to initialize the @code{:value} | 689 The @var{value}, if present, is used to initialize the @code{:value} |
652 property. The value should be a string, which will be inserted in the | 690 property. The value should be a string, which will be inserted in the |
653 buffer. | 691 buffer. |
654 | 692 |
655 The following extra properties are recognized. | |
656 | |
657 @table @code | |
658 @item :text-format | |
659 The format string used when the push button cannot be displayed | |
660 graphically. There are two escapes, @code{%s}, which must be present | |
661 exactly once, will be substituted with the tag, and @code{%%} will be | |
662 substituted with a singe @samp{%}. | |
663 @end table | |
664 | |
665 By default the tag will be shown in brackets. | 693 By default the tag will be shown in brackets. |
694 | |
695 @defopt widget-push-button-prefix | |
696 String to prefix push buttons. | |
697 @end defopt | |
698 | |
699 @defopt widget-push-button-suffix | |
700 String to suffix push buttons. | |
701 @end defopt | |
666 | 702 |
667 @node editable-field, text, push-button, Basic Types | 703 @node editable-field, text, push-button, Basic Types |
668 @comment node-name, next, previous, up | 704 @comment node-name, next, previous, up |
669 @subsection The @code{editable-field} Widget | 705 @subsection The @code{editable-field} Widget |
670 | 706 |