all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Jan Even Nilsen <evenREMOVE@THISgfi.uib.no>
Subject: Re: frames and reading of .emacs?
Date: Thu, 08 Jan 2004 10:01:18 +0100	[thread overview]
Message-ID: <btj81n$1ub9$1@toralf.uib.no> (raw)
In-Reply-To: <m3r7ybv5z1.fsf@ID-177771.users.individual.de>

Martin Stemplinger wrote:
> AFAIK the settings are controlled by the variable
> initial-frame-alist. Its documentation says
> 
> You can specify geometry-related options for just the initial frame
> by setting this variable in your `.emacs' file; however, they won't
> take effect until Emacs reads `.emacs', which happens after first creating
> the frame.  If you want the frame to have the proper geometry as soon
> as it appears, you need to use this three-step process:
> * Specify X resources to give the geometry you want.
> * Set `default-frame-alist' to override these options so that they
>   don't affect subsequent frames.
> * Set `initial-frame-alist' in a way that matches the X resources,
>   to override what you put in `default-frame-alist'.

I tried this, and it works like before in some respects, the frame 
appears in position (given by X or whatever) and then pops into its 
assigned place, but not the right size.

My .emacs now looks like this after some stripping:
------------------------------------------------------------------
(setq default-frame-alist  '((top . -00) (left . 300) (width . 89) 
(height . 51) (cursor-color . "red")))
(setq initial-frame-alist  '((top . -00) (left . 300) (width . 89) 
(height . 51)))

(custom-set-faces
  '(default ((t (:stipple nil :background "khaki" :foreground "black" 
:inverse-video nil :box nil :strike-through nil :overline nil :underline 
nil :slant normal :weight normal :height 125 :width semi-condensed 
:family "misc-fixed"))))
  '(region ((t (:background "lightgoldenrod3"))))
)
-----------------------------------------------------------------

On startup the following happen:
1) The frame is moved to the right position, i.e. top and left is read 
from the first line, but the width and height is wrong, its 80x25 
(wherever that came from). M-x new-frame gets right size.

Questions: Is width and height not read? But initial-frame-alist's value 
is ((top . 0) (left . 300) (width . 89) (height . 51)) when i check, so 
it must be read. Why does not emacs use these last two sizes on startup, 
while it uses the first two? Are they overridden by some other mechanism 
(afterwards? No visible size change though)?

2) The first line of custom-set-faces, the '(default ... is set OK, but 
the '(region ... is not right. Regions gets marked with white on blue. 
There is nothing wrong with the syntax here because when using
(load-file "~/.emacs") it is read and used OK.

Question: Again, is there some other mechanism overriding this setting 
upon startup?
BTW: The region is not set righ by M-x new-frame, I need to (load-file 
"~/.emacs") in every new frame :-(

I have now stripped down the .emacs, and I am still puzzled, so I hope 
someone can give me a hint as to what my new emacs is doing.
I know that an existing default.el would be read last, but there is no 
such file on my system, as far as I can see.

Sincerely, Even
on
GNU Emacs 21.3.1 (i386-mandrake-linux-gnu, X toolkit, Xaw3d scroll bars) 
of 2003-08-27 on ke.mandrakesoft.com, modified by Mandrake

  reply	other threads:[~2004-01-08  9:01 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-07 15:00 frames and reading of .emacs? Jan Even Nilsen
2004-01-07 20:50 ` Martin Stemplinger
2004-01-08  9:01   ` Jan Even Nilsen [this message]
2004-01-08 16:36     ` Greg Fenton
2004-01-09  8:41       ` Jan Even Nilsen
2004-01-09  9:41         ` Martin Rydstr|m
2004-01-13  8:56           ` Jan Even Nilsen

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

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

  git send-email \
    --in-reply-to='btj81n$1ub9$1@toralf.uib.no' \
    --to=evenremove@thisgfi.uib.no \
    /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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.