From: Leo <sdl.web@gmail.com>
Subject: Re: A nice gnus thread tree in console
Date: Fri, 08 Dec 2006 21:06:50 +0000 [thread overview]
Message-ID: <m2slfqhzbp.fsf@sl392.st-edmunds.cam.ac.uk> (raw)
In-Reply-To: yoijslfqqjzv.fsf@gamma02.me.chalmers.se
[-- Attachment #1: Type: text/plain, Size: 1870 bytes --]
On FRI, 8 DEC 2006, Johan Bockgård wrote:
> Leo <sdl.web@gmail.com> writes:
>
>> I don't quite understand how people find the glyphs.
>>
>> (dolist (c '((?\207 . ?q) (?\216 . ?x) (?\212 . ?t) (?\203 . ?m)))
>> (aset standard-display-table (car c)
>> (vector (create-glyph (concat "\e(0" "\e[35m" ; magenta
>> (char-to-string (cdr c))
>> "\e[0m" "\e(B")))))
>
> "ESC ( C" switches character sets.
> "ESC [ N m" selects color.
>
> http://www.xfree86.org/current/ctlseqs.html
>
> "m" is a lower-left corner character etc.
>
> http://vt100.net/docs/tp83/appendixa.html (bottom)
>
> The \nnn numbers are somewhat arbitrary in this context.
Thank you.
Now I pick up some pieces of code from the emacswiki and put them in a
function as:
(defun my-gnus-summary-line-format-ascii-fancy ()
"Use fancy ASCII graphics to display thread tree."
(interactive)
(setq gnus-summary-line-format
(concat
"%0{%U%R%z%u&@;%}"
"%10{|%}"
"%1{%d%}"
"%10{|%}"
"%( %-15,15f %)"
"%10{|%}"
"%4k"
"%10{|%}"
"%2u&score;"
"%10{|%}"
"%u&thread;%s\n"))
(unless standard-display-table
(setq standard-display-table (make-display-table)))
(dolist (c '((?\207 . ?q) (?\216 . ?x) (?\212 . ?t) (?\203 . ?m)))
(aset standard-display-table (car c)
(vector (create-glyph (concat "\e(0" "\e[36m" ; magenta
(char-to-string (cdr c))
"\e[0m" "\e(B")))))
(setq gnus-sum-thread-tree-vertical "\216"
gnus-sum-thread-tree-root ""
gnus-sum-thread-tree-false-root ""
gnus-sum-thread-tree-indent " "
gnus-sum-thread-tree-single-indent ""
gnus-sum-thread-tree-leaf-with-other "\212\207>"
gnus-sum-thread-tree-single-leaf "\203\207>")
(gnus-message 5 "Using fancy ascii tree layout."))
The thread tree can be displayed in emacs starting in gnome-terminal
or xterm etc. but with strange background color. See the screen shot.
[-- Attachment #2: gnus-eyecandy.png --]
[-- Type: image/png, Size: 5698 bytes --]
[-- Attachment #3: Type: text/plain, Size: 136 bytes --]
However, if started in virtual console (Ctrl-Alt-F1), it is display as
"mq>" etc.
Any ideas?
Again thank you for your help.
--
Leo
[-- Attachment #4: Type: text/plain, Size: 152 bytes --]
_______________________________________________
help-gnu-emacs mailing list
help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs
next prev parent reply other threads:[~2006-12-08 21:06 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.1657.1165530732.2155.help-gnu-emacs@gnu.org>
2006-12-08 15:51 ` A nice gnus thread tree in console Johan Bockgård
2006-12-08 18:04 ` Leo
[not found] ` <mailman.1677.1165601084.2155.help-gnu-emacs@gnu.org>
2006-12-08 19:13 ` Johan Bockgård
2006-12-08 21:06 ` Leo [this message]
2006-12-07 22:31 Leo
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m2slfqhzbp.fsf@sl392.st-edmunds.cam.ac.uk \
--to=sdl.web@gmail.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.
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.