Subject: Re: bug#8112: 23.2; wish: emacsclient -c -g GEOMETRY

From: Arne Babenhauserheide <[email-masked]>
Date: Fri, 25 Feb 2011 01:51:04 +0100

On Friday 25 February 2011 01:13:18 Lennart Borgman wrote:
> Can't the --eval argument be used for this?

It only gets evaluated after the frame is created. 

This is possible, though: 

emacsclient -e "(add-to-list 'default-frame-alist '(height . 40))" \
-e "(add-to-list 'default-frame-alist '(width . 120))" ; emacsclient -c

It litters the alist with new definitions, but it works. 

Alternately put it in .bashrc: 

emacsclient -e "(add-to-list 'default-frame-alist '(height . 30))" \
-e "(add-to-list 'default-frame-alist '(width . 55))"

Then the setting only affects the given computer and I can use the .emacs.d 
unchanged.

But different from -g GEOMETRY it affects later frames, too :(

I then can’t call emacsclient with default settings without setting these 
default settings. 

To pseudo-only set it once: 

emacsclient -e "(add-to-list 'default-frame-alist '(height . 40))" \
-e "(add-to-list 'default-frame-alist '(width . 120))" ; emacsclient -c \
-e "(add-to-list 'default-frame-alist '(height . 40))" \
-e "(add-to-list 'default-frame-alist '(width . 80))"

But that is kinda clumsy compared to emacsclient -g 120x40… 

Best wishes, 
Arne