unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Whitfield Diffie <the.whitfield.diffie@gmail.com>
To: Thien-Thi Nguyen <ttn@gnuvola.org>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Fwd: Setting mark in minibuffer prompt
Date: Sun, 8 Jul 2012 10:18:56 -0700	[thread overview]
Message-ID: <CAOgUEJLoBmqkKAb6vaOw3qOy1-KMwzgp1o6BUCPH8au5VAfb+A@mail.gmail.com> (raw)
In-Reply-To: <87mx3akysf.fsf@zigzag.favinet>

[-- Attachment #1: Type: text/plain, Size: 1056 bytes --]

> You can complete [the message] by asking a
> specific question or posting code that demonstrates your efforts
> to date (along with a specific question). ...
> Does that make sense?

    I makes sens but I thought that was what I had done.
Rather than writing

       I am trying to write an interactive function
       that prompts for a file name, placing point at
       the end of the prompt and mark somewhere
       earlier in the path.

I had written

       How do I write an interactive function
       that prompts for a file name, placing point at
       the end of the prompt and mark somewhere
       earlier in the path?

    I described what I could do; code that does that is now attached.

    Certainly, I do not want to be impolite and would like to
understand the list's sense of courtesy.

                                  Thanks,

                                                 Whit

P.S. I finished this note only because it was almost done when I got
Drew Adams message, which offers an answer; I will not have a look at
that.

[-- Attachment #2: visit-notes.el --]
[-- Type: application/octet-stream, Size: 502 bytes --]

(defun visit-notes nil

  "   Notes prompts for a filename of the form ``~/notes/<date>'', placing
   point in the prompt before the date, for example:

                              location of point  
                                       |
                                       V
                    Directory: ~/notes/2012.07.08/"

  (interactive)
  (read-filename "Directory: "
		 "~/notes/"
		 nil
		 nil
		 (filename-as-directory (format-time-string "%Y.%m.%d"
							    (current-time)))))



  reply	other threads:[~2012-07-08 17:18 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-17 15:25 Setting mark in minibuffer prompt Whitfield Diffie
2012-07-08 15:36 ` Fwd: " Whitfield Diffie
2012-07-08 16:15   ` Laurent Hoeltgen
2012-07-08 16:22   ` Thien-Thi Nguyen
2012-07-08 17:18     ` Whitfield Diffie [this message]
2012-07-08 20:21       ` Thien-Thi Nguyen
2012-07-08 17:06   ` Drew Adams
2012-07-08 17:54     ` Whitfield Diffie
2012-07-08 18:07       ` how to customize `read-passwd' [was: Setting mark in minibuffer prompt] Drew Adams
2012-07-11  4:44         ` Whitfield Diffie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAOgUEJLoBmqkKAb6vaOw3qOy1-KMwzgp1o6BUCPH8au5VAfb+A@mail.gmail.com \
    --to=the.whitfield.diffie@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    --cc=ttn@gnuvola.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).