/[emacs]/emacs/man/widget.texi
ViewVC logotype

Diff of /emacs/man/widget.texi

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.13.2.5 by miles, Thu Apr 29 10:59:12 2004 UTC revision 1.13.2.6 by miles, Sat Sep 4 09:21:45 2004 UTC
# Line 213  middle of another field is prohibited. Line 213  middle of another field is prohibited.
213    
214  Editable text fields are created by the @code{editable-field} widget.  Editable text fields are created by the @code{editable-field} widget.
215    
216  An editable field must be surrounded by static text on both sides, that  @strong{Warning:} In an @code{editable-field} widget, the editable
217  is, text that does not change in the lifetime of the widget.  If the  field must not be adjacent to another widget---that won't work.
218  field extends to the end of the line, the terminating line-feed character  You must put some text in between.  Either make this text part of
219  will count as the necessary static text on that end, but you will have  the @code{editable-field} widget itself, or insert it with
220  to provide the static text before the field yourself.  The  @code{widget-insert}.
221  @code{:format} keyword is useful for generating the static text; for  
222  instance, if you give it a value of @code{"Name: %v"}, the "Name: " part  The @code{:format} keyword is useful for generating the necessary
223  will count as the static text.  text; for instance, if you give it a value of @code{"Name: %v "},
224    the @samp{Name: } part will provide the necessary separating text
225    before the field and the trailing space will provide the
226    separating text after the field.  If you don't include the
227    @code{:size} keyword, the field will extend to the end of the
228    line, and the terminating newline will provide separation after.
229    
230  The editing text fields are highlighted with the  The editing text fields are highlighted with the
231  @code{widget-field-face} face, making them easy to find.  @code{widget-field-face} face, making them easy to find.
# Line 345  Interface}). Line 350  Interface}).
350    (widget-insert "Here is some documentation.\n\nName: ")    (widget-insert "Here is some documentation.\n\nName: ")
351    (widget-create 'editable-field    (widget-create 'editable-field
352                   :size 13                   :size 13
353                     :format "%v " ; Text after the field!
354                   "My Name")                   "My Name")
355    (widget-create 'menu-choice    (widget-create 'menu-choice
356                   :tag "Choose"                   :tag "Choose"

Legend:
Removed from v.1.13.2.5  
changed lines
  Added in v.1.13.2.6

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26