From: Mike Mattie <codermattie@gmail.com>
To: emacs-devel@gnu.org
Subject: (window-system) returns nil on after-make-frame-functions when creating an X frame
Date: Mon, 9 Mar 2009 10:02:12 -0700 [thread overview]
Message-ID: <20090309170208.GA6650@reforged> (raw)
[-- Attachment #1: Type: text/plain, Size: 871 bytes --]
Hi,
The behavior of (window-system) as it stands has a corner-case that
does not make sense.
I run a function on after-make-frame-functions that loads my GUI configuration
(previously discussed).
To make sure it runs only when a X frame is created, vs. a TTY I would check
that it is an X frame.
To do this I called (window-system) which normally returns "x". It is not
the best idea, but intuitively after the X frame is created it would sensibly
return "x".
Currently it returns nil. When (window-system) is evaluated in the scratch
buffer sometime after the frame is made, well after after-make-frame-functions
it does indeed return "x".
Though my use in this case is not advised, I think the current behavior in
this scenario does not make sense.
Cheers,
Mike Mattie
--
GnuPG Key: B9012279 is available from HKP server pgp.mit.edu
[-- Attachment #2: Type: application/pgp-signature, Size: 197 bytes --]
next reply other threads:[~2009-03-09 17:02 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-09 17:02 Mike Mattie [this message]
2009-03-09 17:36 ` (window-system) returns nil on after-make-frame-functions when creating an X frame Dan Nicolaescu
2009-03-09 18:06 ` Stefan Monnier
2009-03-09 17:54 ` Chong Yidong
2009-03-09 18:38 ` Mike Mattie
2009-03-09 20:10 ` Stefan Monnier
2009-03-09 19:51 ` Mike Mattie
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=20090309170208.GA6650@reforged \
--to=codermattie@gmail.com \
--cc=emacs-devel@gnu.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.
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).