* dired-mode-hook
@ 2014-04-30 15:48 Doug Lewan
2014-04-30 16:50 ` dired-mode-hook Eli Zaretskii
2014-05-01 15:03 ` dired-mode-hook Doug Lewan
0 siblings, 2 replies; 5+ messages in thread
From: Doug Lewan @ 2014-04-30 15:48 UTC (permalink / raw)
To: help-gnu-emacs@gnu.org
There's a hook that I'd like to use with dired mode. It would position the cursor on a preferred file in that directory.
When dired-mode-hooks are called the buffer isn't yet "painted" with its contents. (For example, (point-max) returns 1.) So, all those great dired-mode functions (like dired-goto-file, which I want) don't do anything.
Am I doing something wrong? Is there some way to force the dired-mode buffer to have contents? Is it a bug in dired?
Thanks for any help.
,Douglas
Douglas Lewan
Shubert Ticketing
(201) 489-8600 ext 224
LISP: The most intelligent way to misuse a computer.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: dired-mode-hook
2014-04-30 15:48 dired-mode-hook Doug Lewan
@ 2014-04-30 16:50 ` Eli Zaretskii
2014-05-01 15:03 ` dired-mode-hook Doug Lewan
1 sibling, 0 replies; 5+ messages in thread
From: Eli Zaretskii @ 2014-04-30 16:50 UTC (permalink / raw)
To: help-gnu-emacs
> From: Doug Lewan <dougl@shubertticketing.com>
> Date: Wed, 30 Apr 2014 15:48:53 +0000
>
> There's a hook that I'd like to use with dired mode. It would position the cursor on a preferred file in that directory.
>
> When dired-mode-hooks are called the buffer isn't yet "painted" with its contents. (For example, (point-max) returns 1.) So, all those great dired-mode functions (like dired-goto-file, which I want) don't do anything.
>
> Am I doing something wrong? Is there some way to force the dired-mode buffer to have contents? Is it a bug in dired?
I think you want dired-initial-position-hook instead.
^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: dired-mode-hook
[not found] ` <<83sioulq1l.fsf@gnu.org>
@ 2014-04-30 17:02 ` Drew Adams
0 siblings, 0 replies; 5+ messages in thread
From: Drew Adams @ 2014-04-30 17:02 UTC (permalink / raw)
To: Eli Zaretskii, help-gnu-emacs
> I think you want dired-initial-position-hook instead.
FWIW -
For that, you need Emacs 24.4 (soon) or a recent development version.
^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: dired-mode-hook
2014-04-30 15:48 dired-mode-hook Doug Lewan
2014-04-30 16:50 ` dired-mode-hook Eli Zaretskii
@ 2014-05-01 15:03 ` Doug Lewan
2014-05-01 15:52 ` dired-mode-hook Eli Zaretskii
1 sibling, 1 reply; 5+ messages in thread
From: Doug Lewan @ 2014-05-01 15:03 UTC (permalink / raw)
To: help-gnu-emacs@gnu.org
Recently I asked
>
> There's a hook that I'd like to use with dired mode. It would position
> the cursor on a preferred file in that directory.
>
Eli Zaretskii wrote
> I think you want dired-initial-position-hook instead.
That's conceptually right, but I don't find it anywhere.
Drew Adams wrote
> FWIW -
> For that, you need Emacs 24.4 (soon) or a recent development version.
:-o I've spent the last day at ftp.gnu.org/future and gotten nothing. Darn!
Thanks for the responses and help.
,Douglas
Douglas Lewan
Shubert Ticketing
(201) 489-8600 ext 224
LISP: The most intelligent way to misuse a computer.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: dired-mode-hook
2014-05-01 15:03 ` dired-mode-hook Doug Lewan
@ 2014-05-01 15:52 ` Eli Zaretskii
0 siblings, 0 replies; 5+ messages in thread
From: Eli Zaretskii @ 2014-05-01 15:52 UTC (permalink / raw)
To: help-gnu-emacs
> From: Doug Lewan <dougl@shubertticketing.com>
> Date: Thu, 1 May 2014 15:03:04 +0000
>
> Eli Zaretskii wrote
> > I think you want dired-initial-position-hook instead.
>
> That's conceptually right, but I don't find it anywhere.
>
> Drew Adams wrote
> > FWIW -
> > For that, you need Emacs 24.4 (soon) or a recent development version.
>
> :-o I've spent the last day at ftp.gnu.org/future and gotten nothing. Darn!
Try here:
ftp://alpha.gnu.org/gnu/emacs/pretest/
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2014-05-01 15:52 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <<155DEC68569B714B86C2C7075F5EDA9892AB0A36@DAKIYA1.pegasus.local>
[not found] ` <<83sioulq1l.fsf@gnu.org>
2014-04-30 17:02 ` dired-mode-hook Drew Adams
2014-04-30 15:48 dired-mode-hook Doug Lewan
2014-04-30 16:50 ` dired-mode-hook Eli Zaretskii
2014-05-01 15:03 ` dired-mode-hook Doug Lewan
2014-05-01 15:52 ` dired-mode-hook Eli Zaretskii
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).