Jeremy C. Reed wrote:
Can anyone share examples for both printing line characters and reverse video characters? Or point to some docs about this?

Here is an example of line characters. But my xterm doesn't show it (probably wrong font), but maybe your console will.

                      ���������������������������������Ŀ
                      � Which would you like to do?     �
                      �                                 �
                      � a: Edit the MBR partition table �
                      �>b: Use the entire disk          �
                      �����������������������������������

Note that is special characters for vertical and horizontal lines and four different corners.

I'd like to do that in LaTeX or LyX instead of using screenshot.

I guess I could use some parbox, makebox or framebox instead but haven't tried that. (I realized that because I also want to use a box around entire area which would measure about 80 characters by 24 characters.)
You'd be hard pressed to actually use line-drawing characters.
They are not well supported, since latex is mainly made for
proportional fonts and variable interword spacing so
it is impossible to line up vertical lines anyway. Still, you can use monospaced fonts like courier,
and it is possible although difficult to load a line drawing font
into latex and use it.

Insert->box is much simpler, and you can set the width to
80 em (the width of an 'm' - which ought to be right for a
fixed-width font.) The width trick didn't quite work for
me, as the font was reset in the box.  Perhaps overriding the document
font will help, ot just experiment with lengths till the box size is just right.

As for reverse video, here is an example using ANSI codes:

        printf "\e[7m this is reverse \e[0m\n"

How to do that with LyX? (white on black)?
In the preamble: \usepackage{color}
In the document, in ERT:

\colorbox{black}{\color{white}White text on black background!}

I have several text console screenshots where I also captured the text. I think my book would look better if I let TeX format the text versus using PNG images.
Instead of PNG, consider vector drawing software. This always looks
better in print - book printers use extremely high resolution.


Helge Hafting

Reply via email to