"Per Abrahamsen" <[EMAIL PROTECTED]> wrote:

>     (setq tw-value-field
>           (widget-create 'editable-field
>                          :size 50
>                          :format "Value: %v\n"
>                          ""))

This works great. Here's a patch that adapts the documentation:

2007-02-03  Markus Triska  <[EMAIL PROTECTED]>

        * widget.texi (Programming Example): put stable text in :format

*** widget.texi 18 Jan 2007 03:32:09 +0100      1.40
--- widget.texi 03 Feb 2007 12:49:27 +0100      
***************
*** 349,358 ****
    (let ((inhibit-read-only t))
      (erase-buffer))
    (remove-overlays)
!   (widget-insert "Here is some documentation.\n\nName: ")
    (widget-create 'editable-field
                 :size 13
!                :format "%v " ; Text after the field!
                 "My Name")
    (widget-create 'menu-choice
                 :tag "Choose"
--- 349,358 ----
    (let ((inhibit-read-only t))
      (erase-buffer))
    (remove-overlays)
!   (widget-insert "Here is some documentation.\n\n")
    (widget-create 'editable-field
                 :size 13
!                :format "Name: %v " ; Text after the field!
                 "My Name")
    (widget-create 'menu-choice
                 :tag "Choose"
***************
*** 364,371 ****
                 '(item :tag "This option" :value "This")
                 '(choice-item "That option")
                 '(editable-field :menu-tag "No option" "Thus option"))
-   (widget-insert "Address: ")
    (widget-create 'editable-field
                 "Some Place\nIn some City\nSome country.")
    (widget-insert "\nSee also ")
    (widget-create 'link
--- 364,371 ----
                 '(item :tag "This option" :value "This")
                 '(choice-item "That option")
                 '(editable-field :menu-tag "No option" "Thus option"))
    (widget-create 'editable-field
+                :format "Address: %v"
                 "Some Place\nIn some City\nSome country.")
    (widget-insert "\nSee also ")
    (widget-create 'link


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Reply via email to