all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Locating the default colors used by emacs
@ 2007-07-04  6:31 tigerleopard
  2007-07-04  7:24 ` Seweryn Kokot
  2007-07-04  8:44 ` Peter Dyballa
  0 siblings, 2 replies; 4+ messages in thread
From: tigerleopard @ 2007-07-04  6:31 UTC (permalink / raw)
  To: Help-gnu-emacs


I am trying to find out where the color information from emacs is located. I
looked into the .emacs
file from my user and the root, but both are empty. Someone told me to look
into the Xdefault, but my distribution doesn't have it. I know that I can
put the colors settings in the .emacs file, but the thing is that I don't
know the color that I want. What I want to do, is to copy the foreground and
background colors being used by root to my user.  
So, I want to know if there is a specific file that store some standard
colors in the case of the .emacs files being empty, or if this is
distribution dependent.
Or, if there is a command that shows the colors being used. 
And one thing that I have curiosity about, is why when I give a su to obtain
administrative privileges, emacs starts with the same colors than my user,
unlike when I login from the beginning as root.
Thanks in advance for all the help.

-- 
View this message in context: http://www.nabble.com/Locating-the-default-colors-used-by-emacs-tf4022666.html#a11425562
Sent from the Emacs - Help mailing list archive at Nabble.com.

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

* Re: Locating the default colors used by emacs
  2007-07-04  6:31 Locating the default colors used by emacs tigerleopard
@ 2007-07-04  7:24 ` Seweryn Kokot
  2007-07-06  5:46   ` tigerleopard
  2007-07-04  8:44 ` Peter Dyballa
  1 sibling, 1 reply; 4+ messages in thread
From: Seweryn Kokot @ 2007-07-04  7:24 UTC (permalink / raw)
  To: help-gnu-emacs

tigerleopard <tigerleopard1@lycos.com> writes:

> I am trying to find out where the color information from emacs is located. I
> looked into the .emacs
> file from my user and the root, but both are empty. Someone told me to look
> into the Xdefault, but my distribution doesn't have it. I know that I can
> put the colors settings in the .emacs file, but the thing is that I don't
> know the color that I want. What I want to do, is to copy the foreground and
> background colors being used by root to my user.  
> So, I want to know if there is a specific file that store some standard
> colors in the case of the .emacs files being empty, or if this is
> distribution dependent.
> Or, if there is a command that shows the colors being used. 
> And one thing that I have curiosity about, is why when I give a su to obtain
> administrative privileges, emacs starts with the same colors than my user,
> unlike when I login from the beginning as root.
> Thanks in advance for all the help.

just create .emacs file and put something like this

	  (set-background-color "DarkSlateGray")
	  (set-foreground-color "Wheat")
	  (set-face-background 'modeline "lightgoldenrod2")
	  (set-face-foreground 'modeline "DarkSlateGray")
	  (set-cursor-color "Orchid")
	  (set-face-foreground 'font-lock-comment-face "Gray")
	  (set-face-foreground 'font-lock-string-face "Gold3")
	  (set-face-foreground 'font-lock-function-name-face "LightBlue")
	  (set-face-foreground 'font-lock-keyword-face "cyan1")
	  (set-face-foreground 'font-lock-type-face "Violet")
	  (set-face-foreground 'font-lock-builtin-face "Cyan")
	  (set-face-foreground 'font-lock-variable-name-face "Gold")
	  (set-face-foreground 'font-lock-constant-face "Magenta")
	  (set-face-foreground 'scroll-bar "Wheat")
	  (set-face-background 'scroll-bar "lightgoldenrod2")
	  (set-face-foreground 'tool-bar "Wheat")
	  (set-face-background 'tool-bar "lightgoldenrod2")
	  (set-face-foreground 'font-lock-builtin-face "Cyan")

the list of predefined colors is shown typing M-x list-colors-display

and you can also check and change the colors of things by 
M-x customize-face 

regards,
Seweryn

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

* Re: Locating the default colors used by emacs
  2007-07-04  6:31 Locating the default colors used by emacs tigerleopard
  2007-07-04  7:24 ` Seweryn Kokot
@ 2007-07-04  8:44 ` Peter Dyballa
  1 sibling, 0 replies; 4+ messages in thread
From: Peter Dyballa @ 2007-07-04  8:44 UTC (permalink / raw)
  To: tigerleopard; +Cc: Help-gnu-emacs


Am 04.07.2007 um 08:31 schrieb tigerleopard:

> I am trying to find out where the color information from emacs is  
> located.

There are two sections in ~/.emacs: a free-form section and the one  
starting with "(custom-set-variables" and having as comment a warning  
not to edit this section. Usually this section is "maintained" by the  
customise interface in GNU Emacs. Look at menu entries "Options ->  
Customize Emacs!" Another way is to determine the characteristics of  
some character (C-u C-x = in GNU Emacs 22) and then choose (RET or  
[long-]click on the underlined hyperlink) the "face value" to enter  
the customisation interface. In GNU Emacs 21 you would need to invoke  
describe-text-properties.

In the free-form or Lisp section you can use for example:

         (setq initial-frame-alist '(
           (mouse-color           . "midnightblue")
           (foreground-color      . "grey20")
           (background-color      . "alice blue")
           (internal-border-width . 2)
           (line-spacing          . 1)
           (active-alpha          . 0.875)
           (inactive-alpha        . 0.75)
           (font . "-*-*-medium-r-normal--10-*-*-*-*-*-fontset- 
hiraginomin")
           (top . 25) (left . 650) (width . 91) (height . 50)))
         (setq default-frame-alist '(
           (border-color          . "#4e3831")
           (foreground-color      . "grey10")
           (background-color      . "ghost white")
           (vertical-scroll-bars  . left)
           (cursor-color          . "purple")
           (cursor-type           . box)
           (active-alpha          . 0.75)
           (inactive-alpha        . 0.875)
           (font . "-*-*-medium-r-normal--9-*-*-*-*-*-fontset- 
hiraginokaku")
           (top . 50) (left . 150) (width . 89) (height . 56)))


X11 users can use X Ressources (look into the GNU Emacs manual, i.e.  
C-h i m Emacs and then search for the "Command Line Options and  
Arguments" node), which are organised in files like ~/.Xdefaults or  
~/.Xressources (depends on the actual code in ~/.xinit or similiar  
files which set up the X11 environment).  ~/.Xdefaults or  
~/.Xressources can #include other files with set X application  
defaults. A lot "templates" exist in directories like /usr/X11R6/lib/ 
X11/app-defaults or /usr/X11R7/share/X11/app-defaults.

--
Greetings

   Pete

We are usually convinced more easily by reasons we have found  
ourselves than by those which have occurred to others.
                                           (Blaise Pascal)

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

* Re: Locating the default colors used by emacs
  2007-07-04  7:24 ` Seweryn Kokot
@ 2007-07-06  5:46   ` tigerleopard
  0 siblings, 0 replies; 4+ messages in thread
From: tigerleopard @ 2007-07-06  5:46 UTC (permalink / raw)
  To: Help-gnu-emacs


 
Seweryn Kokot-2 wrote:
> 
> 	  (set-background-color "DarkSlateGray")
> 	  (set-foreground-color "Wheat")
>              (set-cursor-color "Orchid")
> 


Thanks for help. These are the default colors used by Root here. And I will
play with some of the other settings in the future.





Peter Dyballa wrote:
> 
> X11 users can use X Ressources, which are organised in files like
> ~/.Xdefaults or  
> ~/.Xressources (depends on the actual code in ~/.xinit or similiar  
> files which set up the X11 environment).  ~/.Xdefaults or  
> ~/.Xressources can #include other files with set X application  
> defaults. A lot "templates" exist in directories like /usr/X11R6/lib/ 
> X11/app-defaults or /usr/X11R7/share/X11/app-defaults.
> 

Thanks for the input. The color settings were located in ~/.Xresources.


Peter Dyballa wrote:
> 
> (look into the GNU Emacs manual, i.e.   
> C-h i m Emacs and then search for the "Command Line Options and   
> Arguments" node)
> 

And this command and its combinations are going to be incredibly useful in
the future.


-- 
View this message in context: http://www.nabble.com/Locating-the-default-colors-used-by-emacs-tf4022666.html#a11459127
Sent from the Emacs - Help mailing list archive at Nabble.com.

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

end of thread, other threads:[~2007-07-06  5:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-04  6:31 Locating the default colors used by emacs tigerleopard
2007-07-04  7:24 ` Seweryn Kokot
2007-07-06  5:46   ` tigerleopard
2007-07-04  8:44 ` Peter Dyballa

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.