emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: patch for woman (woman-topic-at-point)


From: Richard M. Stallman
Subject: Re: patch for woman (woman-topic-at-point)
Date: Fri, 26 Aug 2005 08:03:18 -0400

    The problem is that "to suggest" for `woman' means to actually
    *insert* the suggested name in the minibuffer, a behavior described
    as deprecated in the documentation of `completing-read'.

That is an unnecessarily complex solution.  It would be better
just to change *how* that name is offered.  Instead of inserting
it in the minibuffer, make it the default, more or less as below.

This could be an unconditional change, so it would not require any
options.  However, it might also be desirable to check (perhaps as an
option) whether the name is valid before offering it as the default.

Your diff includes some other miscellanious fixes, such as breaking
a line in a doc string, which might be good to install independent
of this.

*** woman.el    07 Aug 2005 13:30:28 -0400      1.33
--- woman.el    26 Aug 2005 06:02:31 -0400      
***************
*** 1235,1245 ****
              (completing-read
               "Manual entry: "
               woman-topic-all-completions nil 1
               ;; Initial input suggestion (was nil), with
               ;; cursor at left ready to kill suggestion!:
               (and woman-topic-at-point
                    (cons (or (current-word) "") 0)) ; nearest word
!              'woman-topic-history)))
      ;; Note that completing-read always returns a string.
      (if (= (length topic) 0)
        nil                             ; no topic, so no file!
--- 1235,1247 ----
              (completing-read
               "Manual entry: "
               woman-topic-all-completions nil 1
+              nil
+              'woman-topic-history
               ;; Initial input suggestion (was nil), with
               ;; cursor at left ready to kill suggestion!:
               (and woman-topic-at-point
                    (cons (or (current-word) "") 0)) ; nearest word
! )))
      ;; Note that completing-read always returns a string.
      (if (= (length topic) 0)
        nil                             ; no topic, so no file!




reply via email to

[Prev in Thread] Current Thread [Next in Thread]