[Top][All Lists]

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

Re: a dark theme?

From: Emanuel Berg
Subject: Re: a dark theme?
Date: Wed, 16 Jul 2014 22:32:47 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Sharon Kimble <address@hidden> writes:

> I'm hoping that someone can advise me, I'm looking
> for a theme to use with emacs and gnus which has a
> dark background, but also allows me to read all the
> text in a gmail which currently appears as
> nearly-white on a slightly-grey background.

"All the text in a gmail"?

To get a default bright-on-dark "theme" (which I highly
recommend to reduce eye strain) simply evaluate this:

(set-face-attribute 'default nil
                    :foreground "cyan"
                    :background "black"
                    :bold nil)

Change "cyan" to whatever fits you the best. I use a
Linux VT/tty/"the console" and you probably use X. That
means I can't help you with the colors, but try
"green", "blue", etc. See if you can find something you
like; if not, dig deeper. Probably you don't won't bold
for ordinary text, save that option for faces that
highlight stuff (headers, keywords, and so on).

If you run into some text that you don't like the color
of, use this defun to identify the face:

(defun what-face (pos)
  (interactive "d")
  (let ((face (or (get-char-property (point) 'read-face-name)
                  (get-char-property (point) 'face))))
    (if face (message " Face: %s" face)
      (message " No face at %d." pos) )))

Put it in an init file, for example ~/.emacs. Then
invoke it with `M-x what-face' with point at the face
you don't like the color of. This will show you what
face it is. Then do as above again, only substitute
'default for the face you found. Note that several
modes/modules of Emacs uses the same faces. So if it
looks great with brown somewhere, it might not look as
great somewhere else, and of course, if you change it
again, the first place may look less good! In practice,
this is seldom or never a problem. If it is, it is
solvable but I never got to that. Just go for what
sticks out in a pleasant way, it should work
everywhere. Where applicable, put some thought into it:
with programming, the `font-lock-comment-face'
shouldn't be as bright and emphasized as
`font-lock-function-name-face' (because people
comment-out stuff, and read comments only as a
secondary measure, when they don't immediately
understand the code), what's more, perhaps red is a
natural color for `font-lock-warning-face', and so
on. But don't overthink it. Most important thing is it
should look clear, relaxed, and fun. Check out this
screenshot of a modest major-mode a once did. That's
how I like it. Obviously I didn't intellectualize every
singly color I put to use. It is still very pleasant to
work in such a mode - like a night club :) [1]

> I've recently been using aalto-dark, aalto-light,
> adwaita, alect-black-alt, tsdh-dark and all have
> failed the gmail test. I'm currently using tango,
> which is the complete reverse of what I'm looking
> for.

The problem with themes, which I didn't know existed
until this discussion by the way, is that you find one
mode, you like it to 80%, but not quite, so you look
for another, maybe you like that to 90%, and so
on. Instead of jumping between Emacs themes, Linux
distros, and so on, just put that time setting it up
the way you want it. Plain and simple. Time-consuming,
yes, but educational. Fun. And ultimately, much more
capable of getting not to 90% but (almost) all the way
(and those last percent missing not because some
perfect theme is eluding you, but because of your
current understanding and skills. Remember,
"Don't chase the dragon - become the dragon!"


underground experts united

reply via email to

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