From: Juanma Barranquero <lekktu@gmail.com>
To: Albert <ab.for.lists@gmail.com>
Cc: 10729@debbugs.gnu.org
Subject: bug#10729: 24.0.93; On MS-Windows: emacsclientw.exe -n -c does create a new frame, but does not always display the requested file or the requested directory (24.0.92 does)
Date: Mon, 6 Feb 2012 18:03:17 +0100 [thread overview]
Message-ID: <CAAeL0SQtM+VcpatPkk06N34rKixa3Ut6EVUWw3VfHfa9ajZYqA@mail.gmail.com> (raw)
In-Reply-To: <CAAeL0SQgkkqK8txJXS1=GSn5xFrUMzUoyGgH4_t64yJ8GbWpLg@mail.gmail.com>
On Sun, Feb 5, 2012 at 16:48, Juanma Barranquero <lekktu@gmail.com> wrote:
>> 1. command window started from emacs/bin
>> 2. start runemacs -Q
>> 3. M-x server-start
>> 4. start emacsclientw -n -c test.txt
>> ==> (small existing file) this works as expected (a new frame with test.txt)
>> 5. repeat 4.: does not work: the second frame now displays an extra instance
>> of *scratch*
>> 6. repeat 4.: does work: a new frame with test.txt
>> 7. repeat 4.: does not work: the last frame now shows *scratch* (and
>> all other frames also)
>> 8. ... this repeats itself; I tried until I had 4 frames showing
>> *scratch* and then the next repeat gives a new frame with test.txt
>> again.
Hmm. I'm not sure it is a bug, or at least, I'm not sure the bug is
that it sometimes does not create a new frame.
When you request a new frame with -c or -t, you're passing
instructions to server.el about how to display the buffer. But
server.el also obeys the setting of server-window. If you look at
server-switch-buffer, you'll see that, when the buffer is already
shown in a window, and server-window is nil, it simply does
(select-window win) ; win is the window displaying test.txt
(set-buffer next-buffer) ; next-buffer is the one containing test.txt
so no new frame is created. That's not a bug. For some reason I still
have to investigate, the buffer shown in win is then replaced by
*scratch* (this is puzzling).
Next time, as test.txt is not visible (*scratch* replaced it in win),
server-switch-buffer creates a new frame. Rinse and repeat.
As a workaround, while I investigate further, I think you can run emacs with
emacs -f server-start --eval "(setq server-window 'switch-to-buffer)"
which does what you want.
Juanma
next prev parent reply other threads:[~2012-02-06 17:03 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-04 23:41 bug#10729: 24.0.93; On MS-Windows: emacsclientw.exe -n -c does create a new frame, but does not always display the requested file or the requested directory (24.0.92 does) Albert
2012-02-05 15:48 ` Juanma Barranquero
2012-02-06 17:03 ` Juanma Barranquero [this message]
2012-02-06 17:47 ` Albert
2012-02-06 21:06 ` Juanma Barranquero
2012-02-06 17:57 ` martin rudalics
2012-02-06 21:11 ` Juanma Barranquero
2012-02-07 7:53 ` martin rudalics
2012-02-07 13:08 ` Juanma Barranquero
2012-02-07 13:31 ` Juanma Barranquero
2012-02-07 13:33 ` Juanma Barranquero
2012-02-07 14:32 ` martin rudalics
2012-02-07 14:35 ` Juanma Barranquero
2012-02-07 15:21 ` martin rudalics
2012-02-07 15:28 ` Juanma Barranquero
2012-02-07 17:05 ` martin rudalics
2012-02-07 17:27 ` Stefan Monnier
2012-02-08 12:24 ` Juanma Barranquero
2012-02-07 15:22 ` martin rudalics
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=CAAeL0SQtM+VcpatPkk06N34rKixa3Ut6EVUWw3VfHfa9ajZYqA@mail.gmail.com \
--to=lekktu@gmail.com \
--cc=10729@debbugs.gnu.org \
--cc=ab.for.lists@gmail.com \
/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.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
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).