From: Chuck Siska <chuck.siska@nb.conexant.com>
Subject: Re: terminal & X configuration
Date: Tue, 23 Apr 2002 11:36:35 -0700 [thread overview]
Message-ID: <3CC5A9B3.2D65748E@nb.conexant.com> (raw)
In-Reply-To: 15557.13662.166399.990763@localhost.localdomain
luis --
i run the same .emacs file on unix, mswind95/98 and
mswindnt. it's done in 2 parts (although it can be
done in one part). one part is to define a function
to describe the system characteristics:
(message "Set my cs-what-env...")
(defun cs-what-env ()
"Returns a string indicating what kind of environment emacs runs in.
'E.g., Windows_95', 'Windows_NT', 'X11_windows'."
(interactive)
(let ((doze32 (if (>= emacs-major-version 20) 'w32 'win32)))
(cond ((eq window-system doze32)
(or (getenv "OS") "Windows_95"))
((eq window-system 'x)
(concat "X" window-system-version "_windows"))
(t "Console"))))
the second part is to use the defined function to choose
what to do in a given circumstance:
(message "Set my fonts...")
(let ((sys-env (cs-what-env)))
(cond
;;---------------------------------------- Unix ----
((string= "X11_windows" sys-env)
(message "Set my X11_windows fonts...")
(setq cs-default-font "5x8")
(setq initial-frame-alist
(append '((width . 100)
(height . 50))
initial-frame-alist))
(setq cs-default-font "5x8")
)
;;---------------------------------------- MSwind ----
((or (string= "Windows_95" sys-env)
(string= "Windows_NT" sys-env))
(message "Set my MSwind fonts...")
; set font to terminal, regular, 6 point.
(setq cs-default-font "-*-Terminal-normal-r-*-*-8-60-*-*-c-*-*-oem-")
)
(t nil)))
good luck.
-- chuck
"Luis O. Silva" wrote:
>
> Dearest Emacs Community,
>
> Would you please help me to know how I can have different
> configurations of my Emacs for working in X and for
> working on a terminal (emacs -nw), without having to call
> different dot-files?
>
> Thank you very much in advance.
>
> Sincerely yours,
> luis
>
> --
> Luis Octavio Silva P.
> St. Petersburg State University.
> 66/3 Botanicheskaya St., Apt.119/2
> Stary Peterhof
> St. Petersburg, Russia.
>
> _______________________________________________
> Help-gnu-emacs mailing list
> Help-gnu-emacs@gnu.org
> http://mail.gnu.org/mailman/listinfo/help-gnu-emacs
--
|\_/\_.-'""``:-._
What is life without looking for . . `; -._ )-;-,_`)
the next cute little bug to play with? v_,- _ ),(,.\ ``-'
_.- _.,-_/ / ((.'
-- chuck.siska@conexant.com `<}:.. ((,.-' ((,/
next prev parent reply other threads:[~2002-04-23 18:36 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-04-23 10:20 terminal & X configuration Luis O. Silva
2002-04-23 18:36 ` Chuck Siska [this message]
2002-04-24 14:42 ` In reply to: " Luis O. Silva
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3CC5A9B3.2D65748E@nb.conexant.com \
--to=chuck.siska@nb.conexant.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).