unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Wrong value of background-mode on dark XTerm
@ 2009-06-01 22:32 Juliusz Chroboczek
  2009-08-11  5:03 ` Dan Nicolaescu
  0 siblings, 1 reply; 2+ messages in thread
From: Juliusz Chroboczek @ 2009-06-01 22:32 UTC (permalink / raw)
  To: emacs-devel

Running 23.0.94.1 on an ``xterm -rv'' (reverse-video), I get

    (frame-parameter nil 'background-mode)
    ==> light

which oviously reads to almost illegible text in certain modes.

With recent XTerm versions, the background colour can be retrieved with
the escape sequence ``Operating System Controls''

  ESC ] 1 1 ; ? ESC \ 

which returns an escape sequence in the same format, but with the ``?''
replaced with an RGB specification

  ESC ] 1 1 ; rgb:0000/0000/0000 ESC \

I have no idea what this escape sequence does to older XTerms, but the
XTerm version number can be retrieved with ``Send Device Attributes''

  ESC [ > c

which returns something like

  ESC [ > 0 ; 2 4 2 ; 0 c

where the 242 is the XTerm patchlevel.

                                        Juliusz




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

end of thread, other threads:[~2009-08-11  5:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-01 22:32 Wrong value of background-mode on dark XTerm Juliusz Chroboczek
2009-08-11  5:03 ` Dan Nicolaescu

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