[Top][All Lists]

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

Preferences support for Carbon Emacs

From: YAMAMOTO Mitsuharu
Subject: Preferences support for Carbon Emacs
Date: Wed, 16 Mar 2005 17:39:37 +0900
User-agent: Wanderlust/2.12.2 (99 Luftballons) SEMI/1.14.6 (Maruoka) FLIM/1.14.6 (Marutamachi) APEL/10.6 Emacs/22.0.50 (sparc-sun-solaris2.8) MULE/5.0 (SAKAKI)

Mac OS X has a customization mechanism called "preferences".


I've just installed some changes that enable Carbon Emacs to get
preferences through X Resources functions (like registry on W32).
Now users can use preferences in place of X Resources.

For example, adding a line

   Emacs.cursorType: bar

to ~/.Xresources in X11 corresponds to the execution of

   % defaults write org.gnu.Emacs Emacs.cursorType bar

in Carbon.  One can use boolean or numeric values as well as string

   % defaults write org.gnu.Emacs Emacs.toolBar -bool off
   % defaults write org.gnu.Emacs Emacs.lineSpacing -int 3

Of course, you can directly edit your own
~/Library/Preferences/org.gnu.Emacs.plist with Property List Editor or
your favorite text editor :-)

I also added a function that reads arbitrary application preference
value and converts it a Lisp object.  For example, evaluation of
(mac-get-preference "AppleLanguages") results in an array ["ja" "en"
"fr" "de" ...] of strings in my environment.  Maybe this can be used
for setting up the default language environment at startup time.

                                     YAMAMOTO Mitsuharu

reply via email to

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