unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Preferences support for Carbon Emacs
@ 2005-03-16  8:39 YAMAMOTO Mitsuharu
  2005-03-16  8:59 ` YAMAMOTO Mitsuharu
  2005-04-14  9:55 ` YAMAMOTO Mitsuharu
  0 siblings, 2 replies; 3+ messages in thread
From: YAMAMOTO Mitsuharu @ 2005-03-16  8:39 UTC (permalink / raw)


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

  http://developer.apple.com/documentation/MacOSX/Conceptual/BPRuntimeConfig/Concepts/UserPreferences.html

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
values.

   % 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
				mituharu@math.s.chiba-u.ac.jp

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

end of thread, other threads:[~2005-04-14  9:55 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-03-16  8:39 Preferences support for Carbon Emacs YAMAMOTO Mitsuharu
2005-03-16  8:59 ` YAMAMOTO Mitsuharu
2005-04-14  9:55 ` YAMAMOTO Mitsuharu

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).