all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Dynamic setting of custom vars?
@ 2003-03-25 15:59 Greg Fenton
  2003-03-25 17:04 ` Stefan Monnier
  2003-03-25 17:08 ` Per Abrahamsen
  0 siblings, 2 replies; 3+ messages in thread
From: Greg Fenton @ 2003-03-25 15:59 UTC (permalink / raw)


I am trying to set som custom vars based on conditions of the 
system we are running on.

In my .emacs, I have the following code:

;-----------------------------------------------------------
(cond
  ((string-match "my-laptop" (downcase (system-name)))
     (setq glf-height 60))
  ((string-match "my-linux-box" (downcase (system-name)))
     (setq glf-height 80)))

(custom-set-variables
  '(default-frame-alist
      (quote ((width . 81) (height . glf-height))))
  '(initial-frame-alist
      (quote ((width . 81) (height . glf-height))))
)
;-----------------------------------------------------------


However, it appears that the value of glf-height is being ignored 
during the creation of the intial frame (trying to create 
subsequent frames throws an error "(wrong-type-argument integerp 
glf-height)".

I assume I must reference the variable in some other way in the 
custom-set-variables or that the value of glf-height is not 
visible to the make-frame-command.

Is what I'm doing at all possible?  Is there a better way (should 
I simply avoid custom-set-variables)?

Thanks in advance,
greg.fenton

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-03-25 17:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-03-25 15:59 Dynamic setting of custom vars? Greg Fenton
2003-03-25 17:04 ` Stefan Monnier
2003-03-25 17:08 ` Per Abrahamsen

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.