[PLUG] Editor in Console window
Stephen Liu
satimis at writeme.com
Tue Jul 23 00:32:13 UTC 2002
Thanks Rich
I will try later
Stephen
At 06:33 AM 7/22/2002 -0700, you wrote:
>On Mon, 22 Jul 2002, Stephen Liu wrote:
>
> > The problem is I can't read the content with deep red characters on dark
> > background. How to change the background colour
>
>Stephen,
>
> Below is a copy of ~/.emacs. They're always a work in progress and readily
>shared among users. I like the same appearance of emacs whether it's running
>on a console or in a virtual terminal during an X session. Take what works
>for you.
>
>Rich
>-----------------------------------------------------------
>(cond (window-system
> (setq default-frame-alist
> '((width . 350)
> (height . 400)
> (font . "-adobe-courier-medium-r-*--*-165-*-*-m-*-iso8859-1")
> (foreground-color . "white")
> (background-color . "black")
> (mouse-color . "Orchid")
> (cursor-color . "Orchid")
> (icon-type . t) ; gnu picture as Emacs icon
> (icon-name . nil) ; use frame title
> ))
> (setq frame-title-format "%b") ; set frame title to buffer name
> (setq icon-title-format "%b") ; set icon title to buffer name
>))
>
>(custom-set-variables)
>(custom-set-faces
> '(default ((t (:size "14"))) t))
>(setq default-major-mode 'text-mode)
>(add-hook 'text-mode-hook 'turn-on-auto-fill)
>(setq-default transient-mark-mode t)
>;(require 'tex-site)
>(require 'ps-print)
>(global-font-lock-mode
>t)
>(setq font-lock-maximum-decoration t)
>
>(cond (window-system
> (setq font-lock-face-attributes
>; face fg bg bf it ul
> '((font-lock-comment-face "GreenYellow" nil t t nil)
> (font-lock-string-face "wheat" nil nil t nil)
> (font-lock-keyword-face "purple" nil t nil nil)
> (font-lock-type-face "MediumVioletRed" nil t nil nil)
> (font-lock-function-name-face "DarkOliveGreen4" nil t nil nil)
> (font-lock-variable-name-face "DodgerBlue" nil t nil nil)
> (font-lock-reference-face "SeaGreen" nil nil t t ))
> font-lock-maximum-decoration t
> font-lock-support-mode 'lazy-lock-mode
> font-lock-verbose nil
> lazy-lock-stealth-verbose nil
> )
> (if (fboundp 'global-font-lock-mode)
> (global-font-lock-mode t)
> (add-hook 'find-file-hooks 'turn-on-font-lock))
>))
>
>;; kludge until colors work correctly:
>(make-face 'rbs-comment-face)
>(set-face-foreground 'rbs-comment-face "wheat")
>(set-face-background 'rbs-comment-face "black")
>
>(make-face 'rbs-string-face)
>(set-face-foreground 'rbs-string-face "LightPink1")
>(set-face-background 'rbs-comment-face "black")
>
>(make-face 'rbs-keyword-face)
>(set-face-foreground 'rbs-keyword-face "khaki1")
>(set-face-background 'rbs-keyword-face "black")
>
>(make-face 'rbs-type-face)
>(set-face-foreground 'rbs-type-face "Goldenrod1")
>(set-face-background 'rbs-type-face "black")
>
>(make-face 'rbs-function-name-face)
>(set-face-foreground 'rbs-function-name-face "PaleGreen1")
>(set-face-background 'rbs-function-name-face "black")
>
>(make-face 'rbs-variable-name-face)
>(set-face-foreground 'rbs-variable-name-face "turquoise2")
>(set-face-background 'rbs-variable-name-face "black")
>
>(make-face 'rbs-reference-face)
>(set-face-foreground 'rbs-reference-face "Magenta2")
>(set-face-background 'rbs-reference-face "black")
>
>(make-face 'rbs-constant-face)
>(set-face-foreground 'rbs-constant-face "black")
>(set-face-background 'rbs-constant-face "black")
>
>; let the new face be the font face
>(setq font-lock-comment-face 'rbs-comment-face)
>(setq font-lock-string-face 'rbs-string-face)
>(setq font-lock-keyword-face 'rbs-keyword-face)
>(setq font-lock-type-face 'rbs-type-face)
>(setq font-lock-function-name-face 'rbs-function-name-face)
>(setq font-lock-variable-name-face 'rbs-variable-name-face)
>(setq font-lock-reference-face 'rbs-reference-face)
>(setq font-lock-constant-face 'rbs-constant-face)
>
>;; for C code:
>(global-set-key "%" 'match-paren)
>
>(defun match-paren
>(arg)
>"Go to the matching parenthesis if on parenthesis otherwise insert
>%."
> (interactive
> "p")
> (cond ((looking-at "\\s\(") (forward-list 1) (backward-char 1))
> ((looking-at "\\s\)") (forward-char 1) (backward-list 1))
> ((looking-at "\\s\{") (forward-list 1) (backward-char 1))
> ((looking-at "\\s\}") (forward-char 1) (backward-list 1))
> ((looking-at "\\s\[") (forward-list 1) (backward-char 1))
> ((looking-at "\\s\]") (forward-char 1) (backward-list 1))
> (t (self-insert-command (or arg 1)))))
More information about the PLUG
mailing list