I've recently switched to emacsclient for most text editing. I am trying to migrate some of my settings to the new (and slightly different) environment.
In particular, in my .emacs file I have a function that sets the window size, and prepares some themes. However code in the .emacs file is not executed on each invocation of emacsclient, so the settings do not apply to these windows. Based on the question here, I added a hook to 'server-visit-hook
that called a function which executed my settings. However, the settings are not being applied when I restart the server and invoke emacsclient.
How can set the styling and positioning of new emacsclient windows? Relevant portions of my .emacs are included below:
(defun gui-mode()
(set-face-attribute 'default nil :font "Monospace-8")
(require 'theme-wombat)
(set-frame-size-according-to-resolution))
(add-hook 'server-visit-hook 'gui-mode)
(when window-system
(gui-mode))