bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Revision to second bug report


From: Marc Levoy
Subject: Revision to second bug report
Date: 9 Sep 2002 02:29:50 -0700

Dear Emacs maintainers,

I would like to revise the second of my two bug reports - the one about having
trouble setting my initial screen height.  I am still having this trouble, but
the "meta-bug" I reported, that after-init-hook wasn't being invoked in Linux
Emacs, was wrong; it *is* being invoked.  I jumped to the wrong conclusion
because I was invoking Emacs as follows:

        % emacs -l myinit.el

This invokes myinit.el and .emacs.  The former contains my attempt to increase
screen height, as well as my attempt to (add-hook 'after-init-hook...); the
latter was written out by Emacs after I made some customizations using the
Emacs menus.

As I discovered after some additional experimentation, Emacs first evaluates
.emacs, then invokes after-init-hook, which at this point is not defined,
then evaluates myinit.el, which defines after-init-hook, but too late.

To prevent someone else from making this same mistake, it might help to clarify
in your documentation that after-init-hook is invoked after .emacs, but
*before* any lisp file specified on the invoking command line.

Unfortunately, this didn't solve my entire problem.  After discovering my
error, I then added my definition of after-init-hook to .emacs (rather than to
myinit.el):

        (add-hook 'after-init-hook 'mem-after-init-hook)
        (defun mem-after-init-hook ()
                (set-frame-height (selected-frame) 60)
        )

Some testing verified that this hook was now being invoked.  However, it does
not succeed in resetting the frame/screen height, which, after being reduced by
3 lines when I disable the toolbar, insists on staying at its reduced height.
I can enlarge it with my first keystroke after initialization, but I cannot for
the life of me enlarge it during initialization.  What is the problem?

-Marc Levoy
 Associate Professor
 Computer Science Department
 Stanford University





reply via email to

[Prev in Thread] Current Thread [Next in Thread]