Warning: this is an htmlized version!
The original is across this link,
and the conversion rules are here.
#######
#
# E-scripts for TeX-related things.
#
# Note 1: use the eev command (defined in eev.el) and the
# ee alias (in my .zshrc) to execute parts of this file.
# Executing this file as a whole makes no sense.
#
# Note 2: be VERY careful and make sure you understand what
# you're doing.
#
# Note 3: If you use a shell other than zsh things like |&
# and the for loops may not work.
#
# Note 4: I always run as root.
#
# Note 5: some parts are too old and don't work anymore. Some
# never worked.
#
# Note 6: the definitions for the find-xxxfile commands are on my
# .emacs.
#
# Note 7: if you see a strange command check my .zshrc -- it may
# be defined there as a function or an alias.
#
# Note 8: the sections without dates are always older than the
# sections with dates.
#
# This file is at <http://angg.twu.net/e/tex.e>
#           or at <http://angg.twu.net/e/tex.e.html>.
#        See also <http://angg.twu.net/emacs.html>,
#                 <http://angg.twu.net/.emacs[.html]>,
#                 <http://angg.twu.net/.zshrc[.html]>,
#                 <http://angg.twu.net/escripts.html>,
#             and <http://angg.twu.net/>.
#
#######



# «.index»
# «.docs»		(to "docs")
# «.minimal»		(to "minimal")
# «.source2e»		(to "source2e")
# «.source2e.dvi»	(to "source2e.dvi")
# «.classes.dtx-dvi»	(to "classes.dtx-dvi")
# «.equation-numbers»	(to "equation-numbers")
# «.texbook»		(to "texbook")
# «.mfbook»		(to "mfbook")
# «.ps-720dpi»		(to "ps-720dpi")
# «.latex2html»		(to "latex2html")
# «.pstoimg»		(to "pstoimg")
# «.dtx2dvi»		(to "dtx2dvi")
# «.kpathsea»		(to "kpathsea")
# «.stmaryrd»		(to "stmaryrd")
# «.testfont»		(to "testfont")
# «.testfontcmds»	(to "testfontcmds")
# «.testfont.tex»	(to "testfont.tex")
# «.mf_X»		(to "mf_X")
# «.mf_X.1»		(to "mf_X.1")
# «.mf_X.2»		(to "mf_X.2")
# «.metapost-old»	(to "metapost-old")
# «.metapost»		(to "metapost")
# «.tetex-bin»		(to "tetex-bin")
# «.weaving»		(to "weaving")
# «.leo_moura_eev»	(to "leo_moura_eev")
# «.babel»		(to "babel")
# «.portug-hyph»	(to "portug-hyph")
# «.texlive-lang»	(to "texlive-lang")
# «.showhyphens»	(to "showhyphens")
# «.gftype»		(to "gftype")
# «.gftodvi»		(to "gftodvi")
# «.bbold_and_rsfs»	(to "bbold_and_rsfs")
# «.arabtex»		(to "arabtex")
# «.pic_manual»		(to "pic_manual")
# «.xdvi-gz»		(to "xdvi-gz")
# «.xdvi-pid»		(to "xdvi-pid")
# «.xdvi»		(to "xdvi")
# «.rail»»		(to "rail")
# «.src2tex»		(to "src2tex")
# «.auctex»		(to "auctex")
# «.twocolumn»		(to "twocolumn")
# «.show_and_tracing»	(to "show_and_tracing")
# «.show_box_dims»	(to "show_box_dims")
# «.smash»		(to "smash")
# «.indices»		(to "indices")
# «.tatsutaproof»	(to "tatsutaproof")
# «.bussproofs»		(to "bussproofs")
# «.ptproof-old»	(to "ptproof-old")
# «.ptproof»		(to "ptproof")
# «.texcad»		(to "texcad")
# «.arrow.tex»		(to "arrow.tex")
# «.picture_mode»	(to "picture_mode")
# «.thin_supset»	(to "thin_supset")
# «.begin»		(to "begin")
# «.realcalc»		(to "realcalc")
# «.tex-br»		(to "tex-br")
# «.LaTeX-demo»		(to "LaTeX-demo")
# «.cmsy10_scaled»	(to "cmsy10_scaled")
# «.bibtex»		(to "bibtex")
# «.makebbl»		(to "makebbl")
# «.TOCs»		(to "TOCs")
# «.mytoc»		(to "mytoc")
# «.contentsline»	(to "contentsline")
# «.enlarge-pool_size»	(to "enlarge-pool_size")
# «.fraktur»		(to "fraktur")
# «.fontfamily»		(to "fontfamily")
# «.hyperref»		(to "hyperref")
# «.breakurl»		(to "breakurl")
# «.newbox»		(to "newbox")
# «.prime-bug»		(to "prime-bug")
# «.ignoring»		(to "ignoring")
# «.makeindex»		(to "makeindex")
# «.greek»		(to "greek")
# «.ThesisPUC»		(to "ThesisPUC")
# «.texdoc»		(to "texdoc")
# «.pdfpages»		(to "pdfpages")
# «.ite»		(to "ite")
# «.psfonts»		(to "psfonts")
# «.pstricks-old»	(to "pstricks-old")
# «.pstricks»		(to "pstricks")
# «.cartao-claudia»	(to "cartao-claudia")
# «.png_screenshots»	(to "png_screenshots")
# «.cv-packages»	(to "cv-packages")
# «.cv»			(to "cv")
# «.currvita»		(to "currvita")
# «.currvitaedrx»	(to "currvitaedrx")
# «.TEXINPUTS»		(to "TEXINPUTS")
# «.dvipng»		(to "dvipng")
# «.tetex-and-texlive»	(to "tetex-and-texlive")
# «.fontdimen»		(to "fontdimen")
# «.quote»		(to "quote")
# «.quotation»		(to "quotation")
# «.verse»		(to "verse")
# «.running-TeX-show»	(to "running-TeX-show")
# «.tesemestr»		(to "tesemestr")
# «.framebox»		(to "framebox")
# «.dags»		(to "dags")
# «.figure-and-caption»	(to "figure-and-caption")
# «.miniforth.bib»	(to "miniforth.bib")
# «.magnification-in-tex»	(to "magnification-in-tex")
# «.magnification-in-latex»	(to "magnification-in-latex")
# «.dvi2dvi»		(to "dvi2dvi")
# «.savebox»		(to "savebox")
# «.indentfirst»	(to "indentfirst")
# «.verbatim»		(to "verbatim")
# «.verbatim.dtx»	(to "verbatim.dtx")
# «.verbatimbox»	(to "verbatimbox")
# «.verbbox»		(to "verbbox")
# «.boxedminipage»	(to "boxedminipage")
% «.smini»		(to "smini")
# «.tools»		(to "tools")
# «.smallmatrix»	(to "smallmatrix")
# «.inputenc»		(to "inputenc")
# «.weaving-tex.web»	(to "weaving-tex.web")
# «.latex-general»	(to "latex-general")
# «.leavevmode»		(to "leavevmode")
# «.texbytopic»		(to "texbytopic")
# «.color»		(to "color")
# «.xcolor»		(to "xcolor")
# «.bicolorhbox»	(to "bicolorhbox")
# «.protect»		(to "protect")
# «.psnfss-avant-garde»	(to "psnfss-avant-garde")
# «.ovals»		(to "ovals")
# «.xfig»		(to "xfig")
# «.xfig-file-format»	(to "xfig-file-format")
# «.eepic»		(to "eepic")
# «.tac.cls»		(to "tac.cls")
# «.demobox»		(to "demobox")
# «.matrix»		(to "matrix")
# «.math-atoms»		(to "math-atoms")
# «.lshort»		(to "lshort")
# «.left-quote-double-hat»	(to "left-quote-double-hat")
# «.message»		(to "message")
# «.newlinechar»	(to "newlinechar")
# «.debugging-diagxy»	(to "debugging-diagxy")
# «.cmtt-and-cmttb»	(to "cmtt-and-cmttb")
# «.math-lists»		(to "math-lists")
# «.beamer»		(to "beamer")
# «.texlive-base-deb-src»	(to "texlive-base-deb-src")
# «.texlive-bin-deb-src»	(to "texlive-bin-deb-src")
# «.dvired-fonts»	(to "dvired-fonts")
# «.skencil»		(to "skencil")
# «.big-delimiters»	(to "big-delimiters")
# «.book.cls»		(to "book.cls")
# «.qtree»		(to "qtree")
# «.juridico»		(to "juridico")
# «.newcounter»		(to "newcounter")
# «.fitch»		(to "fitch")
# «.mdwtab»		(to "mdwtab")
# «.smashpicture»	(to "smashpicture")
# «.shortvrb»		(to "shortvrb")
# «.llangle-and-rrangle»	(to "llangle-and-rrangle")
# «.landscape»		(to "landscape")
# «.crossover»		(to "crossover")
# «.birkjour»		(to "birkjour")
# «.arxiv»		(to "arxiv")
# «.more-than-9-args»	(to "more-than-9-args")
# «.selinger-fitch»	(to "selinger-fitch")
# «.ipe»		(to "ipe")
# «.geometry»		(to "geometry")
# «.2-pages-per-sheet»	(to "2-pages-per-sheet")
# «.floats»		(to "floats")
# «.subfigure»		(to "subfigure")
# «.subfig»		(to "subfig")
# «.let»		(to "let")
# «.ata.cls»		(to "ata.cls")
# «.tlmgr»		(to "tlmgr")
# «.T1-fontenc»		(to "T1-fontenc")
# «.no-room-for-a-new-dimen»	(to "no-room-for-a-new-dimen")






#####
#
# some docs
# 2000oct02
#
#####

# «docs»  (to ".docs")
# (to "texbook")
# (to "xdvi-gz")
# (find-angg ".zshrc" "zxdvi")
# (find-vldifile "tetex-doc.list")
# (find-vldifile "tetex-src.list")
#
#   texbook:   p.427=438 font charts
#              p.434=445 symbol commands
#   essential: p.20      huge table of symbols commands (<- use this)
#   amsguide:  p.20=21   symbol commands
#
#   amsldoc:   many examples of ams math mode

# (find-angg "X")
# export DISPLAY=:0.0
xdvi +438 $SCTAN/systems/knuth/tex/texbook.dvi &
xdvi +445 $SCTAN/systems/knuth/tex/texbook.dvi &
zxdvi /usr/share/doc/texmf/latex/general/essential.dvi.gz +20 &
xdvi /usr/share/doc/texmf/amstex/amsguide.dvi.gz         +21 &
zxdvi /usr/share/doc/texmf/latex/amslatex/amsldoc.dvi.gz  +10 &

gv   /usr/share/doc/texmf/generic/xypic/xyrefer.ps.gz &
gv   /usr/share/doc/texmf/generic/xypic/xyguide.ps.gz &
xdvi /usr/share/texmf/source/generic/xypic/doc/xyrefer.dvi &
xdvi /usr/share/texmf/source/generic/xypic/doc/xyguide.dvi &

xdvi $SCTAN/systems/knuth/mf/mfbook.dvi &
gv /usr/share/doc/texmf/metapost/base/mpman.ps.gz &

zxdvi /usr/share/doc/texmf/latex/base/cfgguide.dvi.gz &
zxdvi /usr/share/doc/texmf/latex/base/clsguide.dvi.gz &
zxdvi /usr/share/doc/texmf/latex/base/fntguide.dvi.gz &
zxdvi /usr/share/doc/texmf/latex/base/usrguide.dvi.gz &
zxdvi /usr/share/doc/texmf/latex/general/guide.dvi.gz &


# The paths below this point are not yet potatoized, and I need to
# rewrite the e-scripts that generate testmath.dvi and source2e.dvi...

xdvi /usr/lib/texmf/source/latex/amslatex/math/testmath.dvi &

# (find-knuthfile "tex/texbook.tex" 25862)
# xdvi /usr/lib/texmf/texmf/doc/ams/amslatex/testmath.dvi &

# Source2e:
xdvi /usr/lib/texmf/source/latex/base/source2e.dvi &
# and its index...
# (find-lsrcfile "base/source2e.tex")
# (find-lsrcfile "base/source2e.ind")
cd /usr/lib/texmf/source/latex/base/
agrep '\{part\}...hspace' source2e.toc

xdvi $SCTAN/systems/knuth/tex/texbook.dvi &
#
# (find-fline "$SCTAN/systems/knuth/mf/mfbook.tex")
# (find-fline "$SCTAN/systems/knuth/tex/texbook.tex")
# (find-web2cfile "tex/tex.web")
# (find-web2cfile "mf/mf.web")
# (find-knuthfile "tex/index.tex")

# (find-fline "/usr/doc/texmf/latex/amslatex/testmath.tex.gz")
# (find-fline "/usr/lib/texmf/source/latex/amslatex/math/testmath.tex")
# (find-fline "/usr/share/texmf/source/latex/guide/essential.tex")
# (find-fline "/usr/share/texmf/source/latex/guide/essential2e.tex")

# xdvi /usr/lib/texmf/texmf/doc/latex/general/guide.dvi &
# xdvi /usr/lib/texmf/texmf/doc/latex/general/l2kurz.dvi &

# (find-node "(latex)Top")
xdvi /usr/lib/texmf/texmf/doc/latex/general/latex2e.dvi &
# (find-lshfile "lshort2e.tex")
xdvi /usr/lib/texmf/texmf/doc/latex/general/lshort2e.dvi &
xdvi /usr/lib/texmf/texmf/doc/latex/base/fntguide.dvi &

cd /usr/lib/texmf/texmf/doc/ams/amslatex/
latex testmath.tex
latex testmath.tex
latex testmath.tex

xdvi /snarf/ftp/ftp.dcs.qmw.ac.uk/pub/tex/contrib/pt/proofs/prooftree-doc.dvi &

# amsldoc has many examples of ams math mode.
#
xdvi /usr/lib/texmf/texmf/doc/ams/amslatex/amsldoc.dvi &
xdvi /usr/lib/texmf/texmf/doc/ams/amslatex/instr-l.dvi &
xdvi /usr/lib/texmf/texmf/doc/ams/amstex/amsguide.dvi &

# amsfndoc has font charts at the end.
xdvi /usr/lib/texmf/texmf/doc/ams/amsfonts/amsfndoc.dvi &
xdvi /usr/lib/texmf/texmf/doc/ams/amsfonts/amsfonts.dvi &
xdvi /usr/share/doc/texmf/fonts/amsfonts/eufrak.dvi.gz &
xdvi /usr/share/doc/texmf/fonts/amsfonts/euscript.dvi.gz &

# Install the LaTeX2e texinfo docs, to be accessed with, e.g.:
# (find-node "(latex)Top")
#
cd /usr/lib/texmf/source/info/
makeinfo latex2e.texi
mv -v latex latex-* /usr/info/

locate '/usr/*.dvi' | sort

# 2008jun07:
# amsldoc and instr-l are broken...
# (find-dvipage  "/usr/share/doc/tetex-doc/amstex/amsguide.dvi.gz")
# (find-xpdfpage "/usr/share/doc/tetex-doc/latex/amsmath/amsldoc.pdf.gz")
# (find-fline    "/usr/share/doc/tetex-doc/latex/amsmath/amsldoc.pdf.gz")
# (find-xpdfpage "/usr/share/doc/tetex-doc/latex/amscls/instr-l.pdf.gz")
# (find-fline    "/usr/share/doc/tetex-doc/latex/amscls/instr-l.pdf.gz")




#####
#
# A minimal LaTeX file
# 2000oct31
#
#####

# «minimal»  (to ".minimal")
#*
cd /tmp/
cat > ltest.tex <<'---'
\documentclass{book}
\begin{document}
Hello
\end{document}
---
latex ltest.tex
xdvi ltest.dvi &
#*




#####
#
# TeXing testmath (potato)
# 2000oct31
#
#####

# «testmath»  (to ".testmath")
#*
cd ~/tmp/
rm -v testmath.{aux,log,dvi}
zcat /usr/share/doc/texmf/latex/amslatex/testmath.tex.gz > testmath.tex
# cp /usr/share/texmf/source/latex/amslatex/math/testmath.tex .
latex testmath.tex
latex testmath.tex
latex testmath.tex
#*
xdvi ~/tmp/testmath.dvi &
xdvi +29 ~/tmp/testmath.dvi &

# (find-fline "~/tmp/testmath.tex")





#####
#
# source2e.tex (generating a dvi doc for the LaTeX base files)
# 00oct04
#
#####

# «source2e»  (to ".source2e")
# (find-lsrcfile "base/texpert.txt" "print the LaTeX source")
# (find-lsrcfile "base/texpert.txt" "To typeset a documented code file")
# (find-lsrcfile "base/source2e.tex" "to produce a fully indexed source code")
#*
# (find-fline "/tmp/texsrc/latex/base/source2e.ind")
# (find-fline "/tmp/texsrc/latex/base/source2e.ind" "\\put")

cd /tmp/texsrc/latex/base/
grep '{part}' source2e.toc \
  | sed 's/\\hspace {1em}/ /g' \
  | sed 's/\\contentsline {part}{\(.*\)}{\(.*\)}/\2	\1/g'

#*




####
#
# typesetting source2e.dvi
# 2004jan27 / 2009aug18
#
####

# «source2e.dvi»  (to ".source2e.dvi")
# (find-zsh "dmissing source2e")
# (find-status   "texlive-latex-base-doc")
# (find-vldifile "texlive-latex-base-doc.list")
# (find-udfile   "texlive-latex-base-doc/")
# http://www.ctan.org/pkg/source2e

# (find-angg ".emacs" "source2e")
# (find-angg ".emacs" "source2e-parts")
# (find-zsh "dmissing texpert.txt")
# (find-lsrcfile "base/manifest.txt")
# (find-lsrcfile "base/texpert.txt" "How to print the LaTeX source")
# (find-lsrcfile "base/texpert.txt" "source2e.tex")
# (find-lsrcfile "base/")

# (code-c-d "latexsrc" "~/usrc/latex/base/")
# (defun find-source2epage (n &rest r) (find-dvipage "~/usrc/latex/base/source2e.dvi" n))
# (find-source2epage (+ 9 487) "Index")
# (find-latexsrcfile "")
#*
# Old way:
rm -Rv   ~/usrc/latex/base/
mkdir -p ~/usrc/latex/base/
cd /usr/share/texmf-tetex/source/latex/base/
cp -v *  ~/usrc/latex/base/
cd       ~/usrc/latex/base/

#*
# New way:
# http://www.ctan.org/tex-archive/macros/latex/base/
# http://www.ctan.org/get/macros/latex/base.zip
rm -Rv   ~/usrc/latex/base/
mkdir -p ~/usrc/latex/base/
unzip -d ~/usrc/latex/ $S/http/www.ctan.org/get/macros/latex/base.zip
cd       ~/usrc/latex/base/

# (find-source2efile "source2e.tex" "latex source2e.tex")
latex source2e.tex
makeindex -s source2e.ist source2e.idx
makeindex -s gglo.ist -o source2e.gls source2e.glo
latex source2e.tex
latex source2e.tex	|& tee ols
pdflatex source2e.tex   |& tee opls

# «classes.dtx-dvi»  (to ".classes.dtx-dvi")
# (find-angg ".emacs" "classes.dtx")
# Is this the right way?
latex    classes.dtx
latex    classes.dtx    |& tee olc
pdflatex classes.dtx    |& tee oplc

#*

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
cd       ~/usrc/latex/base/
# (code-dvi       "lclasses" "~/usrc/latex/base/classes.dvi")
# (code-pdftotext "lclasses" "~/usrc/latex/base/classes.pdf")
# (find-lclassespage 1)


# (code-c-d "source2e" "~/usrc/latex/base/")
# (code-dvi       "source2e" "~/usrc/latex/base/source2e.dvi")
# (code-pdftotext "source2e" "~/usrc/latex/base/source2e.pdf")
# (find-source2efile "")
# (find-source2epage 1)
# (find-source2etext)

# (find-man "1 dvipdf")
# (find-node "(dvips)Option summary")
# dvipdf source2e.dvi source2e.pdf    |& tee odvipdf
#
# dvips: Font tcrm1000 not found, characters will be left blank.
# dvips: Font ecrm1000 at 8000 not found; scaling 600 instead.
# dvips: Such scaling will generate extremely poor output.
# dvips: Font tcbx1000 not found, characters will be left blank.

# (code-c-d "ulsrc" "~/usrc/latex/base/" :xdvi)
# (find-ulsrcxdvi "source2e.dvi")
# (find-ulsrcfile "ltlists.dtx")
# (find-ulsrcxdvi "source2e.dvi" (+ 9 245))

#*
# (find-latexsrcfile "source2e.tex" "\\DocInclude{ltdirchk}")
# (find-latexsrcfile "ltxdoc.dtx" "\\section{DocInclude}")
# (find-latexsrcfile "ltxdoc.dtx" "\\section{DocInclude}" "\\thepart=")

#*
# Jumping from index entries to source lines
# (find-latexsrcfile "source2e.ind")
# (find-source2epage (+ 9 487) "Index")
# (find-latexsrcfile "source2e.toc")

cd ~/usrc/latex/base/
grep '{part}' source2e.toc | grep hspace | tee .parts0

# (find-latexsrcfile ".parts0")
# \contentsline {part}{a\hspace {1em}ltdirchk.dtx}{1}

lua50e '
  for line in io.lines(".parts0") do
    _, __, c, fname, page = string.find(line, "{part}{(.).-{1em}(.-)}{(.-)}")
    if _ then
      print(string.format("\"%s\" %-14s %3s", c, "\""..fname.."\"", page))
    end
  end
' | tee .parts

#*
cd ~/usrc/latex/base/
latex doc.dtx
latex doc.dtx
latex doc.dtx
#*
;; (find-latexsrcfile ".parts")




#####
#
# Putting equation numbers in parts of a diagram
# 2004jan28
#
#####

# «equation-numbers»  (to ".equation-numbers")
# (source2e-ind "ttfamily equation")
# (find-source2e "")
# (find-source2e "ltmath.dtx")

\@definecounter{equation}
\def\equation{$$\refstepcounter{equation}}
\def\endequation{\eqno \hbox{\@eqnnum}$$\@ignoretrue}

%*
% (eelatex-bounded)
\makeatletter

\begin{equation} a \end{equation}
\begin{equation} b \end{equation}
%
\refstepcounter{equation}
%
\begin{equation} c \end{equation}
$$ d \eqno                 $$
$$ e \eqno \hbox{\@eqnnum} $$
$$ f       \hbox{\@eqnnum} $$
$$ g                       $$
\begin{equation} h \end{equation}

%*





#####
#
# more on jumping to source lines in .dtx files
# 2004jan27
#
#####

(find-source2e "doc.dtx")

(find-source2e "doc.dtx" 17)
(find-dvipage (ee-latexsrcfile "doc.dvi") 14)

(find-source2e "doc.dtx" 100)
(find-dvipage (ee-latexsrcfile "doc.dvi") 18)

(find-source2e "doc.dtx" 151)
(find-dvipage (ee-latexsrcfile "doc.dvi") 20)

;; Na linha 152 a gente já se ferra:
;; tem umas linhas "%" começando na margem...
(find-source2e "doc.dtx" 151 "\\begin{macrocode}\n%")
(find-source2e "doc.dtx" 152)
(find-dvipage (ee-latexsrcfile "doc.dvi") 20)

;; Depois ainda tem truques com catcodes:
(find-source2e "doc.dtx" 152 "^^A")
(find-source2e "doc.dtx" 152 "\\catcode`\\%=12")


(find-source2e "doc.dtx" 1 "four spaces between the |%|")
(progn
  (find-latexsrcfile "doc.dtx")
  (ee-isearch-re "%    \\\\\\(begin\\|end\\){macrocode\\*?}\n")
)

# (find-elnode "Selective Display")
# (find-elnode "Invisible Text")









(source2e-tofname "a")
(source2e-tofname "doc.dtx")

# (find-elnode "Regexp Search" "Command: re-search-forward")
# (find-elnode "Regexp Special" "matches only at the end of a line")


(progn
  (find-source2e "doc.dtx" 1)
  (re-search-forward "\n\\([^%]\\|$\\|%<\\)" nil nil 2))

  (find-source2e "doc.dtx" 1)


(= 1 (length "c"))

(defun source2e-file (c) (interactive "sPart: ")
  (let* ((fname (second (member c source2e-parts-list)))
	 (fullfname (ee-latexsrcfile fname)))
    (find-fline fullfname)))

(defun source2e-part (c) (interactive "sPart: ")
  (let* ((page (third (member c source2e-parts-list)))
	 (realpage (+ 9 page))
	 (dvifname (ee-latexsrcfile "source2e.dvi")))
    (find-dvipage dvifname realpage)))

;; (source2e-file "C")
;; (source2e-part "C")





# (find-latexsrcfile "source2e.ind")
# (find-latexsrcfile "")

# (find-latexsrcfile "source2e.aux")
# (find-latexsrcfile "source2e.log")
# (find-latexsrcfile "source2e.tex")





ols

# (find-latexsrcfile "manifest.txt")




# Index:
# (find-lsrcfile "base/source2e.ind")
cd /usr/lib/texmf/source/latex/base/
agrep '\{part\}...hspace' source2e.toc

# Compiling:
cd /usr/lib/texmf/source/latex/base/
latex source2e.tex
makeindex -s source2e.ist source2e.idx
makeindex -s gglo.ist -o source2e.gls source2e.glo
latex source2e.tex
latex source2e.tex	|& tee ols

xdvi /usr/lib/texmf/source/latex/base/source2e.dvi &

# Índice das seções:

# (find-lsrcfile "base/ols")
# (find-pl5pod "var" "undef $/;")
cd /usr/lib/texmf/source/latex/base/
grep -v '^\*' ols | perl -e '
  undef $/; $ols = <STDIN>;
  $i = 0;
  @letras = split(//, " abdefghiklmnopqrstuwyzABCDEFGHIJKLMNO  ");
  # @letras = split(//, " abcdefghijklmnopqrstuwxyzABCDEFGHIJKLMNO  ");
  while ($ols =~ m/\(([a-z0-9.]*)[ \n]\[([0-9]*)\]/g) {
    # print "$1 $2\n";
    printf "%1s %12s %3d\n", $letras[$i++], $1, $2;
  }
' | tee olss

grep 'part.*hspace' source2e.toc
grep 'part.*hspace' source2e.toc | cut -b 22,30,36- |
  perl -nle 'm/^(.*?)\}/ && print $1' | tee oletras






latex classes.dtx

export DISPLAY=:0.0
xdvi /usr/lib/texmf/source/latex/base/source2e.dvi &
xdvi /usr/lib/texmf/source/latex/base/classes.dvi &

# verbatim: p.212=221.
# (find-lsrcfile "base/ltmiscen.dtx" 564)

# (find-fline "/usr/lib/texmf/texmf/tex/plain/base/plain.tex" 42)
# (find-fline "/usr/lib/texmf/texmf/tex/plain/base/plain.tex" 1231)




#####
#
# .dtx -> .dvi in the general case
#
#####

# «dtx2dvi»  (to ".dtx2dvi")
# (find-w3 "/usr/doc/texmf/help/faq/uktug-faq/texfaq_3.html#QU32" ".dtx files")

# (find-lsrcfile "base/docstrip.dtx" 179)
# (find-lsrcfile "base/docstrip.dtx" 932)
# (find-lsrcfile "base/docstrip.ins")
# (find-lsrcfile "base/docstrip.ins" 166)
# (find-lsrcfile "base/doc.dtx" "abstract")
# (find-lsrcfile "base/ltxdoc.dtx" 82)

cd /usr/lib/texmf/source/latex/base/
latex docstrip.ins
makeindex -s docstrip.ist docstrip.aux

cat <<'EOF' | latex |& tee ol
\def\batchfile{keywords.ins}
\input docstrip.tex
\generateFile{keywords.ist}{f}{\from{keywords.dtx}{index}}
\endinput
EOF

# (find-fline "/usr/lib/texmf/source/latex/progkeys/keywords.dtx" 9)
# (find-fline "/usr/lib/texmf/source/latex/progkeys/keywords.dtx" 478)
# (find-fline "/usr/lib/texmf/source/latex/progkeys/Makefile.tetex")
# (find-fline "/usr/lib/texmf/source/latex/progkeys/keywords.ins" 43)
#
cd /usr/lib/texmf/source/latex/progkeys/
#
cat <<'EOF' | latex |& tee ol
\def\batchfile{keywords.ins}
\input docstrip.tex
\generateFile{keywords.drv}{f}{\from{keywords.dtx}{driver}}
\generateFile{keywords.sty}{f}{\from{keywords.dtx}{style}}
\generateFile{keywords.ist}{f}{\from{keywords.dtx}{index}}
\endinput
EOF
#
latex keywords.drv
latex keywords.drv
latex keywords.drv
makeindex -s keywords.ist keywords.idx
latex keywords.drv

# AFAIremember, the general case doesn't work.





#####
#
# Babel: using portuguese
# 2001feb05
#
#####

# «babel»  (to ".babel")
# (to "portug-hyph")

# (find-sh "locate babel")
# (find-dvipage "/usr/share/doc/tetex-doc/generic/babel/tb1202.dvi.gz")
# (find-dvipage "/usr/share/doc/tetex-doc/generic/babel/tb1401.dvi.gz")
# (find-dvipage "/usr/share/doc/tetex-doc/generic/babel/tb1604.dvi.gz")
# (find-dvipage "/usr/share/doc/tetex-doc/generic/babel/user.dvi.gz")

zxdvi /usr/doc/texmf/generic/babel/user.dvi.gz +20
zxdvi /usr/doc/texmf/generic/babel/tb1202.dvi.gz +5
zxdvi /usr/doc/texmf/generic/babel/tb1401.dvi.gz
zxdvi /usr/doc/texmf/generic/babel/tb1604.dvi.gz

# (find-fline "/etc/texmf/language.dat" "change the active language")
# (find-fline "/usr/share/texmf/tex/generic/babel/")
# (find-fline "/usr/share/doc/texmf/generic/babel/")
# (find-texmfsrcgenfile "babel/")
# (find-texmfsrcgenfile "babel/language.skeleton" "file is read as an option")
# (find-texmfsrcgenfile "babel/babel.dtx" "subsection{Multiple languages}")
# (find-texmfsrcgenfile "babel/portuges.dtx")
# (find-texmfsrcgenfile "babel/portuges.dtx" "Lopt{brazil}")
# (find-texmftexgenfile "babel/portuges.ldf")

# (find-fline "/usr/doc/texmf/generic/babel/")
# (find-fline "/usr/doc/texmf/generic/babel/announce.txt" "otherlanguage")
# (find-angg "LATEX/tese2.sty")

# Example of usage (syntax only, without text to hyphenate):
#*
cd /tmp/
cat > tmp.tex <<'---'
\documentclass{book}
\usepackage[cp850]{inputenc}
\usepackage[brazilian,english]{babel}
\begin{document}
...
% Redundant because brazilian is the first option to babel:
\selectlanguage{brazilian}
...
\begin{otherlanguage}{english}
...
\end{otherlanguage}
...
\end{document}
---
latex tmp.tex
#*

% 2008nov11
% (find-fline "/usr/share/texmf-texlive/tex/generic/babel/babel.sty")
% (find-fline "/usr/share/texmf-texlive/tex/generic/babel/portuges.ldf")
% (find-fline "/usr/share/texmf-texlive/tex/generic/babel/babel.def")
% (find-fline "/usr/share/texmf-texlive/tex/generic/babel/english.ldf")
% (find-sh "locate hyphen.cfg")
% (find-fline "/usr/share/texmf-texlive/tex/generic/babel/hyphen.cfg")
% (find-kopkadaly4page (+ 12 253) "language.dat")
% (find-kopkadaly4page (+ 12 256) "hyphen.cfg")




#####
#
# Portuguese hyphenation
# 2000oct04 / 2008nov10 / 2010jun16
#
#####

# «portug-hyph»  (to ".portug-hyph")
# Allowing portuguese hyphenation:
# (find-fline "/etc/texmf/language.dat" "portuges")
/usr/bin/texconfig init |& tee ~/o
# (find-fline "~/o")

# 2012apr02
# (find-zsh "availabledebs | sort | grep texlive-lang")
# (find-status   "texlive-lang-portuguese")
# (find-vldifile "texlive-lang-portuguese.list")
# (find-udfile   "texlive-lang-portuguese/")
# (find-fline "/etc/texmf/hyphen.d/10texlive-lang-portuguese.cnf")
# (find-fline "/var/lib/tex-common/hyphen-cnf/texlive-lang-portuguese.list")

# 2008nov10:
# (find-sh "locate language.dat")
# (find-fline "/var/lib/texmf/tex/generic/config/language.dat")
# (find-fline "/etc/texmf/language.d/")
# (find-fline "/etc/texmf/language.d/10tetex.cnf" "portuges")
# (find-man "1 update-language")

# (find-sh "locate pt8hyph.tex")
# (find-zsh "dmissing hyph | grep pt")

# Reference?

# 2010jun16:
# (find-zsh "dmissing babel | grep texlive")
# (find-zsh "dmissing babel | grep texlive | grep portug")
# (find-lsrcfile "babelbib/portuguese.bdf")
# (find-udfile "texlive-doc/generic/babel/")
# (find-udfile "texlive-latex-base-doc/generic/babel/")

(code-xpdf      "babel" "/usr/share/doc/texlive-latex-base-doc/generic/babel/babel.pdf")
(code-pdftotext "babel" "/usr/share/doc/texlive-latex-base-doc/generic/babel/babel.pdf")
;; (find-babelpage   1  "Contents")
;; (find-babelpage  59  "13 Local language configuration")
;; (find-babelpage 145  "35 The portuguese language")
;; (find-babelpage 362 "Index")
;; (find-babelpage 365 "Index" "\\noextrasportuges")
;; (find-babelpage 366 "Index" "\\selectlanguage")
;; (find-babeltext "")

;; (find-kopkadaly4page (+ 12 254) "Language switching commands")
;; (find-kopkadaly4text (+ 12 254) "Language switching commands")
;; (find-kopkadaly4page (+ 12 254) "\\selectlanguage{language}")
;; (find-kopkadaly4text (+ 12 254) "\\selectlanguage{language}")
;; (find-kopkadaly4page (+ 12 255) "\\noextraslang")
;; (find-kopkadaly4text            "\\noextraslang")
;; (find-kopkadaly4page (+ 12 553) "\\language{num}")
;; (find-kopkadaly4text            "\\language{num}")

# (find-fline "/etc/texmf/")
# (find-fline "/etc/texmf/language.d/09texlive-base.cnf")
# (find-fline "/etc/texmf/language.d/09texlive-base.cnf")
# (find-udfile "" "texlive")

# (find-vldifile "texlive-base.preinst")
# (find-vldish "grep /etc/texmf/ texlive*")
# (find-vldifile "texlive-base.conffiles" "/etc/texmf/language.d/09texlive-base.cnf")


# «texlive-lang»  (to ".texlive-lang")
# (find-man "texconfig")
# (find-sh "locate -i tex-on-debian")
# (find-fline "/usr/share/doc/tex-common/")
# (find-udfile "tex-common/TeX-on-Debian.txt.gz" "texlive-lang-*")
# (find-zsh "availabledebs | sort | grep texlive-lang")

apti texlive-lang-portuguese
# (find-status   "texlive-lang-portuguese")
# (find-vldifile "texlive-lang-portuguese.list")
# (find-udfile   "texlive-lang-portuguese/")
# (find-fline "/etc/texmf/language.d/10texlive-lang-portuguese.cnf")

# Fnaufel recommends this:
# (find-LATEXfile "2009-planodetrabalho.tex" "\\usepackage[brazil]{babel}")


# «showhyphens»  (to ".showhyphens")
# (find-texbooktext "\\def\\showhyphens")
# (find-texbooktext "\\showhyphens{ random text }")

# (find-texbookpage (+ 11 455) "several languages in the same paragraph")
# (find-texbooktext            "several languages in the same paragraph")

# (find-fline "/usr/share/texmf-texlive/tex/generic/babel/")
# (find-fline "/usr/share/texmf-texlive/tex/generic/babel/portuges.ldf")
# (find-fline "/usr/share/texmf-texlive/tex/generic/babel/portuges.sty")
# (find-fline "/usr/share/texmf-texlive/tex/generic/hyphen/pthyph.tex")
# (find-fline "/usr/share/texmf-texlive/tex/generic/babel/english.ldf")

* (eepitch-latex)
* (eepitch-kill)
* (eepitch-latex)
\tracingonline=1\scrollmode
\show\languagename
\makeatletter
\show\l@portuges
\showhyphens{eduardo}
\language=\l@portuges
\show\languagename
\showhyphens{eduardo}
\language=\l@english
\showhyphens{eduardo}




#####
#
# getting a CTAN subdirectory (pstricks)
#
#####

cd $CTAN/graphics/
wget ftp://ftp.rge.com/pub/tex/graphics/pstricks.tar.gz

cd $CTAN/graphics/
rm -Rv pstricks
tar -xvzf pstricks.tar.gz
gzip -dv $(find pstricks)

mkdir -p $CTAN/fonts/
cd       $CTAN/fonts/
wget ftp://ftp.rge.com/pub/tex/fonts/ascii.tar.gz
mkdir -p $CTAN/fonts/utilities/
cd       $CTAN/fonts/utilities/
wget 	ftp://ftp.rge.com/pub/tex/fonts/utilities/a2ac.tar.gz	\
	ftp://ftp.rge.com/pub/tex/fonts/utilities/ega2mf.tar.gz
mkdir -p $CTAN/help/Catalogue/
cd       $CTAN/help/Catalogue/
wget 	ftp://ftp.rge.com/pub/tex/help/Catalogue/catalogue.html.gz	\
	ftp://ftp.rge.com/pub/tex/help/Catalogue/ctfull.html.gz	\
	ftp://ftp.rge.com/pub/tex/help/Catalogue/ctindex.html

ps2mf
mff-29
MF-PS
metafont-for-beginners

moredefs
morehelp
phonet
picins
proofs
pslatex
pstotext
rail
rlepsf
rmpage
rsfs
saferef
schedule
semantic
showlabels
simpsons
smallcap
sobolev
startex
stmaryrd
subeqn
subeqnarray
subfigure
swift
syngen
syntonly
tensor
theorem
thumb
time
times
tipa
titleref
twg-list
typehtml
uniqleaf
varioref
verbatim
word2x
wsuipa
xr
xspace





#####
#
# Proofing a font (old)
#
#####

# (to "gftodvi")

cd /MP
mf cmr10
gftodvi cmr10.2602gf

export DISPLAY=:0.0
xdvi -p 300 cmr10.dvi

# The gray font is broken by default, so
# take a look at missfont.log (on the current directory) and

MakeTeXPK gray 600 600 1+0/600 ljfour

# It is trying to produce a gray font for an "imagen". What is it?

# (find-fline "/usr/lib/texmf/texmf/fonts/source/public/misc/gray.mf")
# (find-fline "/usr/lib/texmf/texmf/ls-R")
# (find-fline "/usr/lib/texmf/texmf/metafont/misc/")
# (find-fline "/usr/lib/texmf/texmf/metafont/misc/modes.mf" 869)
# (find-fline "/usr/bin/MakeTeXPK" 104)
# (find-fline "/usr/lib/texmf/texmf/metafont/misc/modes.mf" 1591)
# (find-fline "/usr/lib/texmf/texmf/metafont/misc/modes.mf" 2303)

(write-heredoc "~/MP/grayljfour.mf")
if mode<>ljfour: errmessage "This file is for ljfour only"; fi
rep=5; boolean large_pixels;
font_identifier "GRAYLJFOUR";
input grayf
EOF

cd ~/MP/
rm /var/lib/texmf/fonts/pk/ljfour/gnu/raleigh/grayljfour.600pk
MakeTeXPK grayljfour 600 600 1+0/600 ljfour

# Quem decide o diretório do pk? E o tfm novo, é sempre escrito? Como
# a fonte vai mudar muito eu quero apagar sempre o tfm velho. Onde ele
# está?




#####
#
# psfrag
#
#####

# (find-fline "/usr/lib/texmf/source/latex/psfrag/announce.txt" "overlay")
# (find-zsh "dmissing psfrag")
# (find-fline "/usr/share/texmf-tetex/source/latex/psfrag/announce.txt")
# (find-fline "/usr/share/texmf-tetex/source/latex/psfrag/pfgguide.tex")





#####
#
# Kpathsea search
# 2004jan21
#
#####

# «kpathsea»  (to ".kpathsea")
# (find-angg "LATEX/dout/")
# (find-angg "LATEX/dout/Makefile")

# (find-node "(kpathsea)Default expansion")
# (find-node "(kpathsea)Top")
# (find-node "(kpathsea)Slow path searching")
# (find-node "(kpathsea)Debugging")
# (find-node "(kpathsea)Debugging" "KPATHSEA_DEBUG")
# (find-node "(kpathsea)Filename database")

# (find-fline "/usr/share/texmf/web2c/" "texmf.cnf")
# (find-fline "/etc/texmf/texmf.cnf")

# How can I make emacs use kpathsea to get the full path for a filename?
# (find-sh  "kpsewhich --help")
# (find-sh0 "kpsewhich -n tex tex epsf.tex")
# (find-sh "KPATHSEA_DEBUG=-1 kpsewhich -n tex tex epsf.tex")
# (find-sh "KPATHSEA_DEBUG=63 kpsewhich -n tex tex epsf.tex")





#####
#
# kpathsea debugging
#
#####

# (find-node "(kpathsea)Debugging")
# TeX finds the lilypond .texs but LaTeX doesn't.
#
export KPATHSEA_DEBUG=63
tex '\input lilyponddefs'   |& tee ot
latex '\input lilyponddefs' |& tee ol
#
# I guess the .texs are being installed at the wrong place (in my system).
#
# kdebug:  before expansion = $KPSE_DOT:$TEXMFS/tex{/plain,/generic,}//
# kdebug:  before expansion = $KPSE_DOT:$TEXMFS/tex/{latex,latex209,generic}//
#
# (find-fline "/usr/lib/texmf/texmf.cnf" 62)

Eu copiei o diretório /usr/lib/texmf/texmf/..lily.. para um lugar
acessivel pelo latex e rehasheei.

(find-lilyfile "bin/make-website.pl")
(find-lilyfile "bin/out/make-website" 88)
(find-lilyfile "bin/out/make-website" 114)
(find-lilyfile "bin/out/make-website" 157)
(find-lilyfile "input/wtk1-fugue2.ly")
(find-lilyfile "input/wtk1-fugue2.ly")
(find-lilyfile "Documentation/out/wtk1-fugue2.ly.txt")





#########
#
# ega2mf
#
#########

cd /usr/src/
rm -Rv ega2mf
tar -xvzf $CTAN/fonts/utilities/ega2mf.tar.gz
cd ega2mf
gzip -dv *
gcc -o ega2mf ega2mf.c
gcc -o vga2mf vga2mf.c

# (find-fline "/c5/home/BUP/PROgLOJA/vga437t.mf")
# (find-fline "/c5/home/BUP/PROgLOJA/vga437t0.mf")
# (find-fline "/c5/home/BUP/PROgLOJA/vga850.mf")
# (find-fline "/c5/home/BUP/PROgLOJA/vgasqdot.mf")

# Name of the .gf file: <jobname>.<resolution>gf; MFbook p.324, MFprog
# block 1164.
#
# p.277 (find-knuthfile "mf/mfbook.tex" "|screenchars|.")
# (find-fline "/usr/lib/texmf/texmf/metafont/base/plain.mf" "z@#")

## Eu modifiquei o vga2mf à beça, ele não tem mais pickups, usa chars
## 8x8 e isso é o header novo:

% This is vga850.mf generated by vga8tomf from /home/replace/ega1.8.
if unknown cmbase: input cmbase fi
mode_setup;
def generate suffix t= enddef;
input cmtt10; font_setup;
if ligs>1: font_coding_scheme:="TeX text";
else: font_coding_scheme:=if ligs=0: "TeX typewriter text"
  else: "TeX text without f-ligatures" fi; fi

def corner(expr row,col) =
  ((col/8)[0, 9u],
   (row/8)[body_height, -desc_depth])
enddef;
def crt(expr row,col) =
  numeric x[],y[];
  z0=corner(row,col);
  z1=corner(row+1,col+1);
  fill (x0,y0)--(x0,y1)--(x1,y1)--(x1,y0)--cycle;
enddef;

## Todas as outras coisas importantes foram parar dentro de uma
## Makefile:

SRCDIR = /usr/lib/texmf/texmf/fonts/source/vga
PKDIR  = /var/lib/texmf/fonts/pk/ljfour/unknown/unknown
PK600  = $(PKDIR)/vga850.600pk

vga8tomf: vga8tomf.c
	gcc -o vga8tomf vga8tomf.c

vga850.mf: vga8tomf
	vga8tomf /home/replace/ega1.8 vga850.mf

font0:
	-rm -Rv  $(SRCDIR)
	-mkdir -p $(SRCDIR)
	cd       $(SRCDIR)/
	#
	-rm -v $(SRCDIR)/vga850.mf
	-ln -s ~/LATEX/vga850.mf $(SRCDIR)/vga850.mf
	texhash

fonttfm:
	-rm -Rv /usr/lib/texmf/texmf/fonts/tfm/public/vga
	-mkdir  /usr/lib/texmf/texmf/fonts/tfm/public/vga
	-rm -v  /var/lib/texmf/fonts/tfm/unknown/unknown/vga850.tfm
	MakeTeXTFM vga850

clearpks:
	-rm -v $(PKDIR)/vga850*pk

btype:
	mf '\mode:=ljfour; mag:=1; scrollmode; input vga850b'
	gftype -i vga850b.600gf

$(PK600): vga850.mf
	-rm -v $(PK600)
	MakeTeXPK vga850 600 600 1.0

font600: $(PK600)

##
##

# (find-fline "/usr/lib/texmf/texmf/fonts/source/vga/vga850.mf")
# (find-fline "~/LATEX/vga850.mf")
# (find-fline "$CTAN/systems/knuth/mf/mfbook.tex" "^@beginchar@")





######
#
# stmaryrd
# 2000oct01 / 2013aug20
#
######

#*
# «stmaryrd»  (to ".stmaryrd")
# (find-zsh "dmissing stmaryrd")
# (find-status   "texlive-math-extra")
# (find-vldifile "texlive-math-extra.list")
# (find-udfile   "texlive-math-extra/")

# (find-status "tetex-nonfree")
# (find-vldifile "tetex-nonfree.list")
# (find-vldifile "tetex-nonfree.list" "stmary")
# (find-fline "/usr/doc/tetex-nonfree/")
# (find-fline "/usr/share/texmf/tex/latex/misc/stmaryrd.sty")
# (find-fline "/usr/share/texmf/tex/latex/misc/stmaryrd.sty" "bindnasrepma")

cd /usr/share/doc/texmf/latex/styles/
zcat stmaryrd.dvi.gz > /tmp/stmaryrd.dvi
xdvi /tmp/stmaryrd.dvi &

#*
# 2006sep24:
# (find-zsh "dmissing stmaryrd")
# (find-dvipage "/usr/share/doc/tetex-doc/latex/stmaryrd/stmaryrd.dvi.gz")
# (find-dvipage "/usr/share/doc/texlive-doc/fonts/stmaryrd/stmaryrd.dvi.gz")
# (find-dvipage "/usr/share/doc/texlive-math-extra/fonts/stmaryrd/stmaryrd.dvi.gz")
# (find-status   "tetex-extra")
# (find-vldifile "tetex-extra.list")
# (find-udfile   "tetex-extra/")
# (find-fline "/usr/share/texmf-tetex/source/latex/stmaryrd/stmaryrd.sty")
# (find-fline "/usr/share/texmf-tetex/tex/latex/stmaryrd/stmaryrd.sty")
# (find-fline "/usr/share/texmf-texlive/tex/latex/stmaryrd/stmaryrd.sty")
# (find-fline "/usr/share/texmf-texlive/tex/latex/stmaryrd/stmaryrd.sty" "\\llbracket")
# (find-texbookpage (+ 11 469))
# (find-texbookpage (+ 11 292) "\\left<delim>")





#####
#
# testfont
# 2000oct01
#
#####

# «testfont»  (to ".testfont")
# First a quick way to get descriptions for many chars:
cd /usr/share/texmf/fonts/source/
agrep cmchar $(find * -name '*.mf') | tee ~/o
# (find-fline "~/o")
# (find-fline "~/o" "linear logic")

#*
# Now testfont itself.
# (find-knuthfile "mf/mfbook.tex" "The last line of |testfont| is")
# (find-fline "/usr/share/texmf/tex/plain/base/testfont.tex")

cat > $EEG <<'---'
\let\noinit! \input testfont.tex
\def\fontname{bbmbx10}\startfont\table
\def\fontname{stmary10}\startfont\table
\def\fontname{msam10}\startfont\table
\bye
---
cd /tmp/
eeg tex
xdvi testfont.dvi &
#*

cd /tmp/
tex '\let\noinit! \input testfont.tex'\
    '\def\fontname{bbmbx10}\startfont\table'\
    '\def\fontname{stmary10}\startfont\table'\
    '\def\fontname{msam10}\startfont\table'\
    '\bye'
xdvi testfont.dvi &
#*

cd /tmp/
tex '\let\noinit! \input testfont.tex'\
    '\def\Test#1{\def\fontname{#1}\startfont\table}'\
    '\Test{bbmbx10}'\
    '\Test{stmary10}'\
    '\Test{msam10}'\
    '\bye'
xdvi testfont.dvi &

#*
# «testfontcmds»  (to ".testfontcmds")
# (find-angg ".zshrc" "testfontcmds")

function testfontcmds () {
  echo -nE '\let\noinit! \input testfont.tex'
  for i in $*; do
    echo -nE '\def\fontname{'$i'}\startfont\table'
  done
  echo -E '\bye'
}
cd /tmp/
tex "$(testfontcmds bbmbx10 stmary10)"

#*
tex "$(testfontcmds wasy10 ccmi10)"; rexdvi /tmp/testfont.dvi
testfont wasy10 ccmi10

testfont xccam10 xccbm10 xccex10 xccmi10 xccsy10 cccsc10 ccmi10 \
  ccmic9 ccr10 ccsl10 ccslc9 ccti10




#####
#
# testfont.tex (another approach)
# 2008jun21
#
#####

# «testfont.tex»  (to ".testfont.tex")
# (find-angg ".emacs" "find-testfont")
# (find-mfbookpage (+ 13 336))
# (find-mfbookfile "mfbook.tex" "testfont.tex")
# (find-mfbooktext "testfont.tex ")
# (find-plainsrcfile "testfont.tex")

* (eepitch-tex)
* (eepitch-kill)
* (eepitch-tex)
\let\noinit!
\input testfont
\def\Test#1{\def\fontname{#1}\startfont\table}
\def\newpage{\vfill\break}
\Test{bbm10}
\newpage
\Test{bbold10}
\bye

# (find-dvipage "/tmp/texput.dvi")
# (find-efunction 'eev)



function dvifonts-l () { dvitype -output-level=1 $1 | grep fntdef }
function dvifonts () { dvifonts-l $* | cut -d' ' -f 4- }


  (eev eelatex-eevscript nil)
  (format "eelatex: wrote %s and %s" ee-file-tex ee-file))


  (ee-write-with-nl s e "" "" altfile)





#####
#
# gftype
# 2000oct01
#
#####

# «gftype»  (to ".gftype")
# (eeman "gftype")
# With "-i" gftype will show the bitmaps for the font (in ascii)!
#*

cd /tmp/
mf '\mode:=ljfour; mag:=1/2; nonstopmode; input stmary10'
gftype -i stmary10.300gf > o
# (find-fline "/tmp/o")
#*

# (find-fline "/etc/texmf/modes.mf" "one pixel one point")





#####
#
# gftodvi
# 2000oct01
#
#####

# «gftodvi»  (to ".gftodvi")
# (eeman "gftodvi")
# (find-knuthfile "mf/mfbook.tex" "beginchapter Appendix H. Hardcopy Proofs")
# But by doing like this we still don't get labels:
#*
cd /tmp/
mf '\mode:=ljfour; mag:=4; nonstopmode; input stmary10'
gftodvi stmary10.2400gf
xdvi    stmary10.dvi &

cd /tmp/
mf '\mode:=ljfour; mag:=4; nonstopmode; input cmr10'
gftodvi cmr10.2400gf
xdvi    cmr10.dvi &

#*
# (find-knuthfile "mf/mfbook.tex" "proofing:=2")
# Just setting "proofing" doesn't change much:
cd /tmp/
mf '\mode:=ljfour; mag:=4; proofing:=2; nonstopmode; input cmr10'
gftodvi cmr10.2400gf
xdvi    cmr10.dvi &

# By using "mode:=proof" we get everything: labels, equations and grids.
cd /tmp/
mf '\mode:=proof; nonstopmode; input stmary10'
gftodvi stmary10.2602gf
xdvi    stmary10.dvi &
#*


# How do I make mf (i.e., mfw) display every char?
# (find-knuthfile "mf/mfbook.tex" "if displaying>0:")





#####
#
# blackboard bold and rsfs
# 2000oct07 / 2008mar04
#
#####

# «bbold_and_rsfs»  (to ".bbold_and_rsfs")
# (find-dn4ex "edrx08.sty" "bbold")
# (find-symbolspage 46)
# (find-fline "/usr/share/texmf-tetex/tex/latex/amsfonts/amsfonts.sty")
# (find-fline "/usr/share/texmf-tetex/tex/latex/amsmath/amstex.sty")
# (find-fline "/usr/share/texmf-tetex/tex/latex/bbm/bbm.sty")
# (find-fline "/usr/share/texmf-tetex/tex/latex/bbold/bbold.sty")
# (find-angg ".zshrc" "testfontcmds")
# (find-zsh0 "cd /tmp/; tex \"$(testfontcmds bbm10 bbold10)\"")
# (find-dvipage "/tmp/testfont.dvi")

cd /usr/lib/texmf/fonts
find | grep bb

#*
cd /tmp/
tex '\let\noinit! \input testfont.tex'\
    '\def\Test#1{\def\fontname{#1}\startfont\table}'\
    '\Test{bbm10}'\
    '\Test{bbold10}'\
    '\Test{bbmbx10}'\
    '\Test{rsfs10}'\
    '\bye'
xdvi testfont.dvi
#*

# (find-fline "/usr/share/texmf/doc/latex/jknappen/")
# (find-fline "/usr/share/texmf/doc/latex/jknappen/mathbbol.rme")
# (find-fline "/usr/share/texmf/doc/latex/jknappen/mathrsfs.rme")
# (find-fline "/usr/share/texmf/fonts/source/jknappen/sauter/")
# (find-fline "/usr/share/texmf/tex/latex/jknappen/")
# (find-fline "/usr/share/texmf/fonts/source/public/bbold/")
# (find-fline "/usr/share/texmf/tex/latex/misc/bbold.sty")
# (find-fline "/usr/share/texmf/source/latex/bbm/")
# (find-fline "/usr/share/texmf/source/latex/bbm/bbm.dtx")
# (find-fline "/usr/share/texmf/tex/latex/bbm/")

cd /usr/lib/texmf/
find * -type f | sort > .files
agrep -i 'blackboard bold' $(grep dtx .files)

# (find-fline "/usr/share/texmf/source/latex/amsfonts/amsfonts.dtx")
# (find-fline "/usr/share/texmf/source/latex/amsfonts/euscript.dtx")
# (find-fline "/usr/share/texmf/source/latex/psnfss/mathtime.dtx")

# (find-fline "$SCTAN/systems/knuth/tex/texbook.tex" 25862)

#*
cd /tmp/
cat > bb.tex <<'---'
\nonstopmode\tracingonline1\makeatletter
\documentclass{book}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{mathrsfs}
\begin{document}
$\mathbb{RIC}\mathscr{ABCDEFGHIJKLMNOPQRSTUVWXYZ}$
\show\mathbb
\end{document}
---
latex bb.tex
dvifonts bb.dvi
#*
xdvi /tmp/testfont.dvi
#*





######
#
# 720dpi fonts
#
######

# (find-fline "/var/spool/texmf/")
# (find-fline "/var/spool/texmf/ls-R")

# (find-fline "/var/spool/texmf/pk/cx/")
# (find-fline "/var/spool/texmf/pk/cx/public/cm/")
# (find-fline "/var/spool/texmf/pk/ljfour/public/cm/")

rm /var/spool/texmf/pk/cx/public/cm/cmr10.300pk
rm /var/spool/texmf/pk/ljfour/public/cm/cmr10.600pk

rm /var/spool/texmf/pk/ljfour/public/cm/cmr10.600pk
cd ~/LATEX/
strace-to ~/s xdvi -geometry +240+0  99feb11.dvi |& tee ~/o

cut -b 7- ~/s | sort | uniq
cut -b 7- ~/s | sort | uniq | getstrings | sort | uniq |& tee ~/o2
find $(grep '^/' ~/o2) -type f -maxdepth 0 > ~/o3
agrep -l ljfour $(<~/o3)

# (find-fline "/usr/bin/mktexpk" "ljfour")
# (find-fline "/usr/lib/texmf/web2c/mf.base")

/etc/texmf/modes.mf
/usr/lib/texmf/metafont/misc/modes.mf

# (find-node "(kpathsea)Top")
# (find-node "(kpathsea)mktex configuration")

# (find-fline "/var/spool/texmf/pk/cx/")
/usr/lib/texmf/web2c/texmf.cnf


agrep ljfour $(locate mktex)

# (find-fline "/etc/texmf/mktex.cnf")
# (find-fline "/usr/bin/mktexlsr")
# (find-fline "/usr/bin/mktexmf")
# (find-fline "/usr/bin/mktexpk")
# (find-fline "/usr/bin/mktextfm")
# (find-fline "/usr/lib/texmf/web2c/mktex.cnf")
# (find-fline "/usr/lib/texmf/web2c/mktex.opt" "ljfour")
# (find-fline "/usr/lib/texmf/web2c/mktexdir")
# (find-fline "/usr/lib/texmf/web2c/mktexdir.opt")
# (find-fline "/usr/lib/texmf/web2c/mktexnam")
# (find-fline "/usr/lib/texmf/web2c/mktexnam.opt")
# (find-fline "/usr/lib/texmf/web2c/mktexupd")


# (find-node "(bash)Bourne Shell Builtins" "`:'")
# (find-node "(bash)Shell Parameter Expansion")




kpathsea: Running mktexpk --mfmode ljfour --bdpi 600 --mag 1+0/600 --dpi 600 cmr10
mktexpk: Running mf \mode:=ljfour; mag:=1+0/600; nonstopmode; input cmr10


kpathsea: Running mktexpk --mfmode / --bdpi 720 --mag 1+0/720 --dpi 720 cmr10
mktexpk: Mismatched mode ljfour and resolution 720; ignoring mode.
mktexpk: Can't guess mode for 720 dpi devices.
mktexpk: Use a config file, or update me.
kpathsea: Appending font creation commands to missfont.log.
dvips: Font cmr10 at 720 not found; scaling 600 instead.
dvips: Such scaling will generate extremely poor output.




#####
#
# ctan mirrors
#
#####

# (find-fline "/usr/doc/texmf/help/ctan/CTAN.sites.gz")

mynetselect $(
  gzip -cd /usr/doc/texmf/help/ctan/CTAN.sites.gz |
    grep '^  [a-z]' |
    awk '{print tolower($1)}'
)

# (find-fline "~/o2")


# Para FCTAN=ftp://ctan.tug.org/tex-archive :
psne $FCTAN/ls-lR.gz
#
cd $SCTAN
gzip -dv ls-lR.gz
~/ICON/lslR2find -1 < ls-lR | cut -b0-8,21- > ls-lR.i

# (find-fline "$SCTAN/ls-lR.i")

psne $FCTAN/macros/tip.tgz
cd $SCTAN/macros/
tar -xvzf tip.tgz




#####
#
# TeX in practice
# 99nov01
#
#####

# «tip»
# (code-c-d "tip" "$SCTAN/macros/tip/")
# (find-tipfile "" "boxing")
#
# (find-tipfile "boxing7.tip")
# (find-tipfile "boxing6.tip")
# (find-tipfile "box-zero.tip")
# (find-tipfile "boxing5.tip")
# (find-tipfile "box-bul.tip")
# (find-tipfile "box-bb.tip")
# (find-tipfile "box-thck.tip")
# (find-tipfile "vcentx.tip")

# (find-tipfile "inputd.tip")

#*
cd $SCTAN/macros/tip/
cp -v boxing7.tip boxing6.tip box-zero.tip boxing5.tip box-bul.tip \
  box-bb.tip box-thck.tip vcentx.tip ~/LATEX/

cd $SCTAN/macros/tip/
zip /tmp/tip.zip boxing7.tip boxing6.tip box-zero.tip boxing5.tip \
  box-bul.tip box-bb.tip box-thck.tip vcentx.tip
laf /tmp/tip.zip

#*
cd ~/LATEX/
cat > tmp.tex <<'---'
\def\wlog#1{}
\def\InputD#1{\input #1}
\input boxing7.tip

a\HboxR{bcd}e
\bye
---
tex tmp.tex
xdvi -s 2 tmp.dvi
#*





#####
#
# ethiop
#
#####

# (find-available "ethiop")
# (find-vldifile "ethiop.list")
# (find-fline "/usr/doc/ethiop/")

cd /usr/doc/ethiop/
gzip -dv *
latex ethiodoc.tex
latex ethiodoc.tex
latex ethiodoc.tex
xdvi ethiodoc.dvi



#####
#
# arabtex
# 2001oct23
#
#####

# «arabtex»  (to ".arabtex")
# (find-available "perspic-texts")
# (find-available "arabtex")

# (find-status "arabtex")
# (find-vldifile "arabtex.list")
# (find-fline "/usr/doc/arabtex/")

# (code-c-d "arabtexdoc" "/usr/share/doc/texmf/arabtex/")
# (code-c-d "arabtexdoc" "/tmp/arabtex-doc/")
# (find-arabtexdocfile "")

#*
rm -Rv /tmp/arabtex-doc/
mkdir  /tmp/arabtex-doc/
cp -iv /usr/share/doc/texmf/arabtex/* /tmp/arabtex-doc/
cd     /tmp/arabtex-doc/
gzip -dv *.gz
latex arabdoc.tex	|& tee ol

#*
# (find-dvipage "/tmp/arabtex-doc/arabdoc.dvi" (+ 2 36))
# (find-arabtexdocfile "")
# (find-arabtexdocfile "arabdocd.tex")
# (find-arabtexdocfile "arabdoce.tex")

cd /tmp/arabtex-doc/
xdvi +38 arabdoc.dvi &
#*





#####
#
# The pic manual
#
#####

# «pic_manual»  (to ".pic_manual")

gv $S/http/cm.bell-labs.com/cm/cs/cstr/116.ps
# But gv is not happy...
# (find-es "ps" "gv_psheaders")

# (find-fline "$S/http/cm.bell-labs.com/cm/cs/cstr/116.ps")
# (find-node "(gawk)If Statement")

(
echo "116.ps:\n"
awk '{if ($0 ~ /^%/) {print $0; c=0} else {if (c==0) {print ""; c=1}}}' \
  < $S/http/cm.bell-labs.com/cm/cs/cstr/116.ps
# echo "\n\n\ntmp.ps:\n"
# awk '{if ($0 ~ /^%/) {print $0; c=0} else {if (c==0) {print ""; c=1}}}' \
#   < ~/LATEX/tmp.ps
) > ~/o

# (find-fline "~/o")

# (find-fline "$S/http/cm.bell-labs.com/cm/cs/cstr/116.ps" "%%Page: 14 16")



pstotext $S/http/cm.bell-labs.com/cm/cs/cstr/116.ps \
  | tr ˇ - | tee ~/o

# (find-es "ps" "pstotext")
# (find-es "ps" "pstotext")

# Incomplete output.
# (find-es "ps" "pstotext")





#####
#
# Gothic fonts
# 99oct24
#
#####

# (find-fline "/usr/lib/texmf/tex/latex/amsfonts/eufrak.sty")





#####
#
# Tese do Max
#
#####

# «tese_do_max»

rm -Rv /tmp/thesis*
cd /tmp/
tar -xvzf ~/tese-max.tgz

cd /tmp/thesis/
latex thesis.tex	|& tee olt
# latex thesis.tex
# latex thesis.tex

(cd /tmp/thesis/; xdvi /tmp/thesis/thesis.dvi &)

# (find-fline "/tmp/thesis/")
# (find-fline "/tmp/thesis/")




#####
#
# TeX ruler (to estimate dims with xdvi)
#
#####

# (find-zsh "dmissing tex-ruler")
# (find-zsh "dmissing /ruler")
# (find-zsh "dmissing /ruler | grep tex")
# http://www.ntg.nl/doc/eijkhout/ruler.pdf
# http://ftp.sayclub.com/pub/CTAN/macros/generic/misc/ruler.tex
xdvi $S/http/www.loria.fr/services/tex/divers/tex-ruler.dvi &





######
#
# tex -> png
# 99nov06
#
######

# «tex2png»

# (find-fline "~/LATEX/Makefile")
# (find-es "music" "ps_to_png")





#####
#
# Hunting ps fonts (for certain calligraphic chars)
# 99nov16
#
#####

# «hunting_ps_fonts»
# «rsfs»

# (find-es "tex" "testfont")
# (find-fline "~/.zshrc" "dvifonts")
# (find-lsrcfile "psnfss/")
# (find-lsrcfile "psnfss/mathtime.dtx")
# (find-lsrcfile "psnfss/mathtest.tex")

cd /usr/lib/texmf/source/latex/psnfss/
latex mathtest
xdvi mathtest.dvi &

cd /usr/lib/texmf/source/latex/psnfss/
dvifonts mathtest.dvi

cd /tmp/
tex '\let\noinit! \input testfont.tex'\
    '\def\Test#1{\def\fontname{#1}\startfont\table}'\
    '\Test{ectt1000}'\
    '\Test{ptmb7t}'\
    '\Test{ptmb8t}'\
    '\Test{ptmr8t}'\
    '\Test{ptmri8t}'\
    '\Test{zptmcm7m}'\
    '\Test{zptmcm7t}'\
    '\Test{zptmcm7v}'\
    '\Test{zptmcm7y}'\
    '\bye'
dvips -o testfont.ps testfont.dvi
regv testfont.ps

# xdvi testfont.dvi &

dtxagrep ptm
locate zptmcm

# (find-fline "/usr/lib/texmf/fonts/vf/adobe/mathptmx/zptmcm7y.vf")
# (eeman "vftovp")

cp /usr/lib/texmf/fonts/vf/adobe/mathptmx/zptmcm7y.vf /tmp/
cp /usr/lib/texmf/fonts/tfm/adobe/mathptmx/zptmcm7y.tfm /tmp/
cd /tmp/
vftovp zptmcm7y > o

# (find-fline "/tmp/o")
# There's a mention to the "rsfs" encoding, and rsfs sounds familiar...
# So,

dtxagrep rsfs
# (find-fline "/usr/lib/texmf/source/latex/jknappen/mathrsfs.rme")
# (find-fline "/usr/lib/texmf/source/latex/jknappen/mathrsfs.sty")
# (find-fline "/usr/lib/texmf/source/latex/jknappen/ursfs.fd")

# The trick is to put a \usepackage{mathrsfs} in the preamble and use
# things like \mathscr{ABCDE} in the body of the text.





#####
#
# Patrick Lincoln's linear logic "par" macro
# 99sep??
#
#####

# «upside_down_ampersand»

# (find-fline "$S/ftp/ftp.csl.sri.com/pub/linear/mailing-list-traffic/18.summary" "\\draw package")





#####
#
# \edrxnotes
# 00jan19
#
#####

# «edrxnotes»

# 00jan19: moved the script below to my .zshrc. Now I can use
# "savetmptex" insted of "/tmp/save". See:
# (find-angg ".zshrc" "savetmptex")
# (find-angg ".emacs" "eelatex")

# (find-node "(zsh)Conditional Expressions")
# (find-fline "~/LATEX/tese2.sty" "\\def\\edrxnotes#1")
# (find-angg "eev.el" "eelatex")

cat > /tmp/save <<'---'
i=$(perl -nle 'm/^\\edrxnotes{([!-~]+)}/ && print $1' < tmp.tex)
if [[ -n $i ]]; then
  echo $i.tex
  sed -e "s/^\\\\input tmp.dnt/\\\\input $i.auto.dnt/" < tmp.tex > $i.tex
fi
---

# First, run the block above to create the script /tmp/save; then,
# instead of doing just "ee" to run LaTeX on a block saved with f3,
# do:
#
#   ee; . /tmp/save
#
# if the LaTeXable block had a line like "\edrxnotes{xxx}" then
# tmp.tex will be copied to xxx.tex; if it had a "\input tmp.dnt" then
# it will be changed to "\input xxx.auto.dnt".



# (find-es "emacs" "saving_emacs_macros")
# (load-library "edmacro")
# (insert-kbd-macro (make-symbol ""))

(setq last-kbd-macro
  (read-kbd-macro "<<search-forward>> edrxnotes RET <f3>"))

# Only use the macro below if you have two windows and the other one
# is a shell buffer...

(setq last-kbd-macro
  (read-kbd-macro "<<search-forward>> edrxnotes RET <f3>
      C-x o ee; SPC . SPC /tmp/save RET C-x o"))


# «edrxnotes-makefile»
# (find-angg "LATEX/Makefile" "edrxnotes")
#*
cd ~/LATEX/
export A=""
echo -n .INTERMEDIATE: > ~/o2
echo -n edrxnotes: > ~/o3
# for i in [0-9]*.tex tp-*.tex tesemestr.tex slidesmestr.tex; do
# for i in [0-9]*.tex; do
for i in *.tex; do
  j=$(basename $i .tex)
  echo -n " $j.dvi" >> ~/o3
  if grep "input $j.auto.dnt" $i > /dev/null; then
    echo $j.dvi: $j.tex $j.auto.dnt
    echo -n " $j.auto.dnt" >> ~/o2
  else
    echo $j.dvi: $j.tex
  fi
done |& tee ~/o
(echo 'ifeq ($(KEEPAUX),)'
 cat ~/o2; echo
 echo 'endif'
 echo; cat ~/o; echo; cat ~/o3) | tee ~/o4

# (find-fline "~/o4")

echo '# (find-es "tex" "edrxnotes-makefile")' > ~/LATEX/Makefile.auto
cat ~/o4 >> ~/LATEX/Makefile.auto
# (find-fline "~/LATEX/Makefile.auto")
#*




#####
#
# Leo Moura's PIC examples
# 00jan24
#
#####

# «leo_moura_pic»

# (find-fline "~/99oct26.pucmail" "eevP")

cd /tmp/
rm -fv 7 instrs examples.tar.gz
expect -c '
  spawn mail -f ~/99oct26.pucmail
  send "s7 7\rx\r"
  interact
  spawn metamail -r -w -q 7
  send "instrs\r\r"
  interact
'
rm -fv mm.a00*

rm -Rv /tmp/pic
mkdir /tmp/pic
cd /tmp/pic/
tar -xvzf /tmp/examples.tar.gz

tr -d \\r < eev.el > eev0.el
mv eev0.el eev.el

# (find-fline "/tmp/pic/")
# (find-fline "/tmp/pic/eev.el")

rm -v Makefile~
rm -v abs_tree_fatorial.tex
rm -v comp_tree_range_1.tex
rm -v eev.el
rm -v eev.el~
rm -v gravelSFC.tex
rm -v test.tex~

tar -cvzf /tmp/examples0.tar.gz *
laf	  /tmp/examples*gz

cd /tmp/pic/
make	|& tee om

# (find-fline "/tmp/instrs")
# (find-fline "/tmp/pic/")
# (find-fline "/tmp/pic/Makefile")
# (find-fline "/tmp/pic/test.tex")
# (find-fline "/tmp/pic/gravelSFC.pic")
# (find-fline "/tmp/pic/abs_tree_fatorial.pic")
# (find-fline "/tmp/pic/comp_tree_range_1.pic")
# (find-fline "/tmp/pic/sfc.pic")




#####
#
# Leo Moura's extensions to eev.el
# 00jan24
#
#####

# «leo_moura_eev»  (to ".leo_moura_eev")

# (find-fline "~/99oct26.pucmail" "eevP")
# (find-etag "file-name-sans-extension")

(defun se-to-string-without-comments (s e char)
  (let ((currpos) (content))
	(save-excursion
	  (setq currpos s)
	  (setq content "")
	  (while (< currpos e)
		(goto-char currpos)
		(beginning-of-line)
		(while (eq (char-after (point)) (string-to-char char))
		  (forward-char))
		(setq currpos (point))
		(end-of-line)
		(setq content (concat content (buffer-substring
					       currpos (point)) "\n"))
		(next-line 1)
		(setq currpos (point)))
	  content)))

(defun tst-se-to-string-without-comments (s e)
  (interactive "r")
  (insert (se-to-string-without-comments s e ";")))

(defun write-ee-without-comments
  (s e comment-char pre post &optional other-ee-file fmode)
  (write-ee-string (concat pre (se-to-string-without-comments
				s e comment-char)
			   post)

;;

(defun eevP (s e &optional other-ee-file) (interactive "r")
  (write-ee-without-comments s e "%" "set -v\n" "\nset +v" other-ee-file)
  (shell-command ". ~/bin/emacs.ee &")
  )             ; zsh/bash

(defun eevB (s e &optional other-ee-file) (interactive "r")
  (write-ee-without-comments s e "/" "set -v\n" "\nset +v" other-ee-file)
  (shell-command ". ~/bin/emacs.ee &")
  )             ; zsh/bash

(defun eevC (s e &optional other-ee-file) (interactive "r")
  (write-ee-without-comments s e ";" "set -v\n" "\nset +v" other-ee-file)
  (shell-command ". ~/bin/emacs.ee &")
  )             ; zsh/bash

;;;;;
;;;;; «lm-eepic»
;;;;; things to run PIC on a block of text
;;;;;
;
(defun eepic (s e) (interactive "r")
  (write-ee s e "cat > ~/LATEX/tmp.pic <<'--%%--'
		 .PS\n"                 
	        "\n.PE\n--%%--\n
                 cd ~/LATEX
                 pic -t tmp.pic > tmp_pic.tex
                 cat > ~/LATEX/tmp.tex <<'--%%--'
                 \\input{tese_defs}
                 \\begin{document}
                 \\begin{figure}
                   \\scriptsize
                   \\input{tmp_pic} 
                   \\centerline{\\box\\graph}
                 \\end{figure}
                 \\end{document}\n--%%--\n
                 rm tmp.dvi
                 latex tmp.tex\n
                 xdvi tmp.dvi")
  (shell-command ". ~/bin/emacs.ee &"))

;;;;;
;;;;; «lm-eespic»
;;;;; things to run PIC on buffer
;;;;;
;
(defun eespic () (interactive)
  (write-ee (point-min) (point-max) "cat > tmp.pic <<'--%%--'\n"
	    "\n--%%--\n
             pic -t tmp.pic > ~/LATEX/tmp_pic.tex
             rm tmp.pic
             cd ~/LATEX
             cat > ~/LATEX/tmp.tex <<'--%%--'
             \\input{tese_defs}
             \\begin{document}
             \\begin{figure}
               \\scriptsize
               \\input{tmp_pic} 
               \\centerline{\\box\\graph}
             \\end{figure}
             \\end{document}\n--%%--\n
             rm tmp.dvi
             latex tmp.tex\n
             xdvi tmp.dvi")
  (shell-command ". ~/bin/emacs.ee &"))

;;;;;
;;;;; «lm-eespic»
;;;;; things to run PIC on buffer
;;;;;
;
;
(defun pic2tex () 
  (interactive)
  (shell-command (concat "pic -t " (buffer-name) " > " (file-name-sans-extension (buffer-name)) ".tex")))






#####
#
# TeXing the TeXbook
# 2000feb29 / 2005jan01
#
#####

# «texbook»  (to ".texbook")
# (find-angg ".emacs.papers" "texbook")
# http://www.ctan.org/tex-archive/systems/knuth/tex/texbook.tex
# http://mirrors.dotsrc.org/ctan/systems/knuth/dist/tex/texbook.tex
#*
rm -Rv ~/usrc/texbook/
mkdir  ~/usrc/texbook/
cd     ~/usrc/texbook/
cp -v     $S/http/www.ctan.org/tex-archive/systems/knuth/tex/texbook.tex .
cp -v $S/http/mirrors.dotsrc.org/ctan/systems/knuth/dist/tex/texbook.tex .

patch texbook.tex <<'%%%'
7,10c7,10
< \loop\iftrue
<   \errmessage{This manual is copyrighted and should not be TeXed}\repeat
< \pausing1 \input manmac
< \ifproofmode\message{Proof mode is on!}\pausing1\fi
---
> %\loop\iftrue
> %  \errmessage{This manual is copyrighted and should not be TeXed}\repeat
> \input manmac %\pausing1 \input manmac
> %\ifproofmode\message{Proof mode is on!}\pausing1\fi
%%%

tex texbook
#*
cd     ~/usrc/texbook/
# dvipdf texbook.dvi
pdftex texbook.tex

#*
# (find-texbookpage 400)
# (find-texbooktext)



#####
#
# mfbook
# 2008jun21
#
#####

# «mfbook»  (to ".mfbook")
# http://www.ctan.org/get/systems/knuth/dist/mf/mfbook.tex
#*
rm -Rv ~/usrc/mfbook/
mkdir  ~/usrc/mfbook/
cd     ~/usrc/mfbook/
cp -v $S/http/www.ctan.org/get/systems/knuth/dist/mf/mfbook.tex .

# (find-fline "~/usrc/mfbook/mfbook.tex")
# 7,10c7,10

patch mfbook.tex <<'%%%'
8,11c8,11
< \loop\iftrue
<   \errmessage{This manual is copyrighted and should not be TeXed}\repeat
< \pausing1 \input manmac
< \ifproofmode\message{Proof mode is on!}\pausing1\fi
---
> %\loop\iftrue
> %  \errmessage{This manual is copyrighted and should not be TeXed}\repeat
> \input manmac %\pausing1 \input manmac
> %\ifproofmode\message{Proof mode is on!}\pausing1\fi
%%%

tex mfbook
# dvipdf mfbook.dvi
pdftex mfbook.tex

#*
# (find-mfbookpage 200)
# (find-mfbooktext)




#####
#
# portuguese hyphenation in potato's tetex
#
#####

# (find-fline "~/LATEX/tese2.sty")

% (find-es "tex" "edrxnotes")
% (find-lsrcfile "../generic/babel/portuges.dtx" "dateportuges")

cd /var/lib/dpkg/info/
for i in tetex*.list; do basename $i .list; done

cd /var/lib/dpkg/info/
agrep -h babel tetex*list | sort


# (find-fline "/usr/doc/tetex-base/")
# (find-fline "/usr/doc/tetex-bin/")
# (find-fline "/usr/doc/tetex-doc/")
# (find-fline "/usr/doc/tetex-extra/")
# (find-fline "/usr/doc/tetex-lib/")
# (find-fline "/usr/doc/tetex-src/")

# (find-vldifile "tetex-base.list")
# (find-vldifile "tetex-bin.list")
# (find-vldifile "tetex-doc.list")
# (find-vldifile "tetex-extra.list")
# (find-vldifile "tetex-lib.list")
# (find-vldifile "tetex-src.list")

# (find-fline "/usr/share/doc/texmf/generic/babel/")

cd /usr/share/doc/texmf/generic/babel/
rm -Rv /tmp/babel/
mkdir /tmp/babel/
cp -iv *.dvi* /tmp/babel/
cd /tmp/babel/
gzip -dv *gz

cd /tmp/babel/
xdvi user.dvi



# (find-vldifile "tetex-src.list")
# (find-fline "/usr/doc/tetex-src/")
# (find-fline "/usr/share/texmf/source/generic/babel/portuges.dtx")

# (find-fline "/usr/doc/" "tetex")
# (find-fline "/usr/doc/tetex-base/")
# (find-fline "/usr/doc/tetex-base/README.Debian")

cd /usr/share/texmf/source/generic/babel/
# (find-fline "/usr/share/texmf/source/generic/babel/bbcompat.dtx")
# (find-fline "/usr/share/texmf/source/generic/babel/bbcompat.dtx" "old interface")





#####
#
# Metafont with X display (potato)
# 2000sep20
#
#####

# «mf_X»  (to ".mf_X")
# «mf_X.1»  (to ".mf_X.1")
# «mf_X.2»  (to ".mf_X.2")
# (find-angg ".Xdefaults" "metafont")
# (find-mfbookfile "mfbook.tex" "Chapter 23. Online\\\\Displays")
# (find-mfbookpage (+ 13 191)   "Chapter 23: Online Displays")
# (find-mfbooktext              "Chapter 23: Online Displays")
# (find-mfbookfile "mfbook.tex" "Appendix E. Examples")
# (find-mfbookpage (+ 13 301)   "Appendix E: Examples")
# (find-mfbooktext              "Appendix E: Examples")
# (find-mfbookpage (+ 13 356)   "Appendix I: Index")
# (find-mfbooktext              "Appendix I: Index")
# (find-man "1 mf" "ONLINE GRAPHICS OUTPUT")
# http://www.tug.org/teTeX/texmf/doc/tetex/teTeX-FAQ
# (find-fline "/usr/share/doc/texmf/tetex/teTeX-FAQ.gz" "\n29) Metafont does not support the X display")
# (find-fline "/usr/doc/tetex-base/README.Debian" "use mf with X")
# (find-status "tetex-bin")
# (find-vldifile "tetex-bin.list" "mfw")
# (find-fline "/usr/doc/tetex-bin/")
# (find-man "1 mf")
#*
cd /usr/bin/
ldd mf
ldd mft
ldd mfw

#*
cd /tmp/
cat > $EEG <<'---'
beginchar(incr code,10pt#,10pt#,0);
pickup pencircle scaled .3pt; draw unitsquare scaled w;
pickup pencircle scaled 1pt;
for k=1 upto 10:
  drawdot(uniformdeviate w, uniformdeviate w);
endfor;
showit;
endchar;
bye;
---
eeg mfw '\screen_width:=100; screen_depth:=200; screenstrokes;'
# (find-fline "/etc/texmf/modes.mf" "screen_rows :=")
# (find-fline "/usr/share/texmf-texlive/metafont/misc/modes.mf" "screen_rows :=")
#*

* (eepitch-mf)
* (eepitch-kill)
* (eepitch-mf)
\screen_width:=100; screen_depth:=200; screenstrokes;
beginchar(incr code,10pt#,10pt#,0);
pickup pencircle scaled .3pt; draw unitsquare scaled w;
pickup pencircle scaled 1pt;
for k=1 upto 10:
  drawdot(uniformdeviate w, uniformdeviate w);
endfor;
showit;
endchar;
bye;






#####
#
# metapost
#
#####

# «metapost-old»  (to ".metapost-old")
# (find-fline "~/MP/arrow.mp")
cd ~/MP/
mp arrow.mp
gv -watch arrow.1

# (find-fline "/cdbup1/home981121/root/MP/arrow.mp")
#*
rm -Rv /tmp/mp/
mkdir  /tmp/mp/
cd     /tmp/mp/
cat > 1.mp <<'%%%'
beginfig(1);
u=2cm;
w=2mm;
z1=(4u,1u);	z1d=up;
z2=z1+(0u,3u);	z2d=up;
z3=z2+(2u,2u);	z3d=right;
z4=z3+(1u,0u);	z4d=right;
for n=1,2,3,4:
  z[n]l=z[n] + (z[n]d rotated 90) scaled w;
  z[n]r=z[n] - (z[n]d rotated 90) scaled w;
endfor;
%fill z1--z2--z3--z4--cycle;
fill z1l---z2l..z3l---z4l--z4r---z3r..z2r---z1r--cycle;
endfig;
end
%%%

mpost 1.mp
gv 1.1
#*

# (find-fline "/usr/share/doc/texmf/metapost/base/")
gv /usr/share/doc/texmf/metapost/base/mpgraph.ps.gz &
gv /usr/share/doc/texmf/metapost/base/mpintro.ps.gz &
gv /usr/share/doc/texmf/metapost/base/mpman.ps.gz &
# About arrows: mpman, p.37

# (find-node "(dvips)EPSF Macros")
# (find-fline "/usr/lib/texmf/texmf/tex/latex/graphics/epsfig.sty")
# (find-fline "/usr/lib/texmf/source/latex/graphics/epsfig.dtx")
# (find-fline "/usr/lib/texmf/source/latex/graphics/epsfig.dtx" "epsf.tex")

# Boxes:
kpsewhich mp boxes.mp
# (find-fline "/usr/lib/texmf/texmf/metapost/base/boxes.mp")

kpsewhich tex epsf.sty
kpsepath latex

# (find-fline "/usr/lib/texmf/texmf/metapost/base/plain.mp" 421)

# Roubar o código de setas de alguma fonte do TeX (ams, talvez)
# Escrever o script que usa o testfont.

# (find-fline "/usr/share/texmf/tex/plain/base/testfont.tex")
# (find-fline "/usr/share/texmf/tex/plain/misc/mproof.tex")




#####
#
# metapost
# 2008jun21
#
#####

# «metapost»  (to ".metapost")
# (find-es "metapost")
# (find-angg ".emacs" "metapost")
# (find-angg ".emacs.papers" "metapost")
# (find-eeshell "apti texlive-metapost texlive-metapost-doc")
# (find-status   "texlive-metapost")
# (find-vldifile "texlive-metapost.list")
# (find-udfile   "texlive-metapost/")
# (find-status   "texlive-metapost-doc")
# (find-vldifile "texlive-metapost-doc.list")
# (find-udfile   "texlive-metapost-doc/")

# (code-c-d "metapostdoc" "/usr/share/doc/texlive-metapost-doc/metapost/")
# (code-c-d "featpostdoc" "/usr/share/doc/texlive-metapost-doc/metapost/featpost/")
# (find-metapostdocfile "")
# (find-metapostdocfile "base/")
# (find-featpostdocfile "")

# (find-man "1 dmp")
# (find-man "1 dvitomp")
# (find-man "1 makempx")
# (find-man "1 mpost")
# (find-man "1 mpto")
# (find-man "1 newer")
# (find-fline "/usr/share/texmf-tetex/metapost/misc/x.mp")
# (find-fline "/usr/share/texmf-tetex/metapost/misc/null.mp")
# (find-efunction 'eepitch-latex)

(defun eepitch-mpost () (interactive) (ee-eepitch-comint "/tmp/" "mpost" "mpost"))
(defun eepitch-mf    () (interactive) (ee-eepitch-comint "/tmp/" "mf"    "mf"))

* (eepitch-mpost)
* (eepitch-kill)
* (eepitch-mpost)
null
beginfig(1);
u=2cm;
w=2mm;
z1=(4u,1u);	z1d=up;
z2=z1+(0u,3u);	z2d=up;
z3=z2+(2u,2u);	z3d=right;
z4=z3+(1u,0u);	z4d=right;
for n=1,2,3,4:
  z[n]l=z[n] + (z[n]d rotated 90) scaled w;
  z[n]r=z[n] - (z[n]d rotated 90) scaled w;
endfor;
% fill z1--z2--z3--z4--cycle;
fill z1l---z2l..z3l---z4l--z4r---z3r..z2r---z1r--cycle;
endfig;
end

% (find-pspage "/tmp/mpout.1")




#####
#
# Generating ".ps"s with other resolutions (potato)
# 2000sep19
#
#####

# «ps-720dpi»  (to ".ps-720dpi")
# (find-fline "/etc/texmf/")
# (find-fline "/etc/texmf/mktex.cnf")
# (find-fline "/usr/bin/mktexpk")
# (find-fline "/usr/bin/mktexpk" "MODE=ljfour")
# (find-fline "/etc/texmf/modes.mf")
# (find-fline "/etc/texmf/modes.mf" "epscszz")

# (find-status "tetex-bin")
# (find-vldifile "tetex-bin.list")
# (find-fline "/usr/doc/tetex-bin/")

# (find-fline "/usr/sbin/texconfig" "default mode (xdvi/dvips/mf)")
# (find-fline "/usr/sbin/texconfig" "FAQ=")
# (find-fline "/usr/doc/texmf/tetex/teTeX-FAQ.gz" "\n9)")
# (find-node "(dvips)config.ps installation")
# (find-node "(dvips)Option details" "`-mode MODE'")
# (find-node "(dvips)Configuration file searching" "`-mode'")

# (find-fline "~/LATEX/Makefile" "%.ps720 : %.dvi")

#*
rm -v /var/spool/texmf/pk/epscszz/public/cm/cmr10.720pk
cd ~/LATEX/
rm tmp.ps
MODE=epscszz make tmp.ps720
#*


# (find-fline "/etc/texmf/modes.mf" "ljlo")
# Now we add versions of ljlo with other "blacker" factors, and...
#*
/usr/bin/texconfig init |& tee ~/o
#*
rm -v /tmp/tmp.*
cd ~/LATEX/
make tmp.dvi
dvips -D 150 -mode edrxlozerofive -o /tmp/tmp.05.ps tmp.dvi
dvips -D 150 -mode edrxloone -o /tmp/tmp.1.ps tmp.dvi
dvips -D 150 -mode edrxlotwo -o /tmp/tmp.2.ps tmp.dvi
#*




#####
#
# latex2html
# 2000sep27
#
#####

# «latex2html»  (to ".latex2html")
# (find-status "latex2html")
# (find-vldifile "latex2html.list")
# (find-fline "/usr/doc/latex2html/")

# (find-fline "/usr/share/latex2html/")
# (find-fline "/usr/share/texmf/tex/latex/latex2html/")
# (find-fline "/usr/bin/latex2html")
# (find-fline "/usr/bin/pstoimg")
# (find-fline "/usr/bin/texexpand")
# (find-fline "/etc/latex2html.config")
# (eeman "latex2html")
# (eeman "pstoimg")

# (find-w3 "/usr/doc/latex2html/html/index.html")
# (find-fline "~/LATEX/Makefile")

# Can latex2html convert my texts?

#*
rm -Rv /tmp/LATEX/
cd
cp -diPpvR LATEX /tmp/
cd /tmp/LATEX/
# (find-fline "/tmp/LATEX/Makefile" "\n.INTERMEDIATE")
sed 's/.INTERMEDIATE/#.INTERMEDIATE/g' < Makefile > Makefile2
mv Makefile2 Makefile

cd /tmp/LATEX/
make 00jan09.auto.dnt
latex2html 00jan09 |& tee o

#*
cd /tmp/LATEX/00jan09/
edrxnetscape ./index.html &

#*

# No.

# (find-fline "/tmp/LATEX/00jan09/")




#####
#
# pstoimg
# 2001mar06
#
#####

# «pstoimg»  (to ".pstoimg")
#*
# (eev-bounded)
# (find-angg "LATEX/Makefile" "making_pngs")
# (find-es "music" "ps_to_png")
# (find-fline "/usr/bin/pstoimg")
# (find-man "1 pstoimg")
cd ~/LATEX/
rm /tmp/tmp*
make /tmp/tmp.ps300
pstoimg -multi -type png -crop a -antialias -aaliastext \
  -density 150 \
  -out /tmp/tmp.png /tmp/tmp.ps300
make /tmp/tmp.ps
pstoimg -multi -type png -crop a -antialias -aaliastext \
  -density 150 \
  -out /tmp/tmp600..png /tmp/tmp.ps

# Why the "..":
#   pstoimg: Written /tmp/tmp600.1.png
#   pstoimg: Written /tmp/tmp600.2.png

# make /tmp/tmp.300.05.p01.png
# make /tmp/tmp.300.05.png
# make /tmp/tmp.150.png

#*
cd ~/dednat/
make example.dvi
rm -fv example.ps example.png
make -f ~/LATEX/Makefile DPI=150 example.ps
# make -f ~/LATEX/Makefile DPI=150 /tmp/example.150.png
pstoimg -type png -crop a -antialias -aaliastext \
  -density 150 \
  -out /tmp/a.png example.ps
# Bad news: "display" doesn't like the result (though zgv and netscape do)

#*




#####
#
# tetex-bin source (potato)
# 2000oct01
#
#####

# «tetex-bin»  (to ".tetex-bin")

# (find-status "tetex-bin")
# (find-vldifile "tetex-bin.list")
# (find-fline "/usr/doc/tetex-bin/")

# The tetex-bin source package generates tetex-bin, tetex-dev and
# tetex-lib, but the last two are not very interesting because they
# contain only kpathsea stuff.

#*
pdsc $SDEBIAN/dists/potato/main/source/tex/tetex-bin_1.0.6-7.dsc
cd /usr/src/tetex-bin-1.0.6/
find * | sort > .files
debian/rules binary	|& tee odrb

#*
cd /usr/src/tetex-bin-1.0.6/
agrep '\./tangle' odrb

#*
# «weaving»  (to ".weaving")
cd /usr/src/tetex-bin-1.0.6/texk/web2c/
rm -Rv /tmp/weave/
mkdir  /tmp/weave/
cp -v {tex,mf,gftodvi}.{web,ch} /tmp/weave/
cd     /tmp/weave/

weave gftodvi.web
tex   gftodvi.tex
weave gftodvi.web gftodvi.ch
mv    gftodvi.tex gftodvi-ch.tex
tex           gftodvi-ch.tex

weave tex.web
tex   tex.tex
weave tex.web tex.ch
mv    tex.tex tex-ch.tex
tex           tex-ch.tex

weave mf.web
tex   mf.tex
weave mf.web mf.ch
mv    mf.tex mf-ch.tex
tex          mf-ch.tex

xdvi  gftodvi.dvi &
xdvi  gftodvi-ch.dvi &

xdvi  tex.dvi &
xdvi  tex-ch.dvi &

xdvi  mf.dvi &
xdvi  mf-ch.dvi &

#*

# (find-texbinfile "odrb" "./tangle ")

# (code-c-d "texbin" "/usr/src/tetex-bin-1.0.6/")
# (find-texbinfile "")
# (find-texbinfile "odrb")
# (find-texbinfile ".files")
# (find-texbinfile "texk/web2c/")
# (find-texbinfile "texk/web2c/window/")
# (find-texbinfile "texk/web2c/mf.web")
# (find-texbinfile "texk/web2c/mf.web" "Online graphic output.")
# (find-texbinfile "texk/web2c/window/")
# (find-node "(web2c)Metafont")
# (find-node "(web2c)Online Metafont graphics" "`Metafont'")

# (find-fline "/tmp/weave/")
# (find-fline "/tmp/weave/mf.tex")
# (find-fline "/tmp/weave/mf.tex" "\\:\\X")
# (find-fline "/tmp/weave/mf-ch.tex")
# (find-fline "/tmp/weave/mf-ch.tex" "\\:\\X")
# (find-fline "/tmp/weave/mf-ch.tex" "16 ``window'' areas")




#####
#
# xdvi'ing compressed files
# 2000oct01
#
#####

# «xdvi-gz»  (to ".xdvi-gz")
# (to "docs")
# (find-fline "/usr/doc/tetex-base/README.Debian" "view the compressed .dvi")
# (find-fline "/usr/doc/tetex-bin/changelog.Debian.gz" "zipped files")
# (find-status "tetex-bin")
# (find-vldifile "tetex-bin.list")
# (find-texbinfile "texk/xdvik/")
# (find-texbinfile "texk/xdvik/xdvi-sh")
# (find-fline "/usr/bin/X11/xdvi" "*.gz")

#*
# Prepare to hand-patch
cd /usr/bin/X11/
if [[ ! -e xdvi.orig ]]; then cp -av xdvi xdvi.orig; fi
# (find-fline "/usr/bin/X11/xdvi" "*.gz")
#*
# Bring the original back
cd /usr/bin/X11/
mv -v xdvi.orig xdvi
#*

# ...then I gave up. Instead of fixing the xdvi wrapper or writing one
# of my own I decided to use a simple shell function instead. Here it
# is: (find-angg ".zshrc" "zxdvi")

# I'm not calling it in scripts or mime descriptions, just in
# e-scripts, like in this one: (to "docs")


# A test:
#*
rm -Rv /tmp/a
mkdir /tmp/a
cd ~/LATEX
gzip -c6 feb98.dvi > /tmp/a/feb98.dvi.gz
zxdvi /tmp/a/feb98.dvi.gz
#*




#####
#
# xdvi and sigusr1
# 2000oct29
#
#####

# «xdvi-pid»  (to ".xdvi-pid")
# (find-angg ".zshrc" "rexdvi")
# (find-man "1 xdvi" "SIGUSR1")
# (find-zshnode "Parameters Set By The Shell")
# (find-zshnode "Parameters Set By The Shell" "! <S>")

cd ~/LATEX/
xdvi tmp.dvi &
echo $! > /tmp/xdvi.pid

kill -USR1 $(</tmp/xdvi.pid)




#####
#
# xdvi
# 2012sep07
#
#####

# «xdvi»  (to ".xdvi")
# (find-man "1 xdvi" "  +page")
# (find-man "1 xdvi" "srcltx.sty")
# (find-man "1 xpdf")





#####
#
# rail
# 2000oct22
#
#####

# «rail»  (to ".rail")
# (find-fline "$SCTAN/support/")

#*
rm -Rv /usr/src/rail/
cd /usr/src/
tar -xvzf $SCTAN/support/rail.tar.gz
cd /usr/src/rail/
make |& tee om
#*
cd /usr/src/rail/
make clean
make rail.dvi	|& tee omrd
#*

gv /usr/src/rail/rail.ps &
man2t /usr/src/rail/rail.man |& l -S
#*

# (find-fline "/usr/src/rail/")
# (find-fline "/usr/src/rail/rail.tex")
# (find-fline "/usr/src/rail/rail.rai")
# (find-fline "/usr/src/rail/rail.rao")




#####
#
# twocolumn
# 2000oct31
#
#####

# «twocolumn»  (to ".twocolumn")
# (find-angg "LATEX/tese2.sty" "twocolumn")

cd /usr/share/texmf/source/latex/base/
agrep -l twocolumn *

zxdvi /usr/doc/texmf/latex/tools/multicol.dvi.gz &

# (find-fline "/usr/share/texmf/source/latex/tools/multicol.dtx")
# (find-fline "/usr/share/texmf/tex/latex/tools/multicol.sty")

# (find-fline "/usr/doc/texmf/index.html" "fix2col")
# (find-w3 "/usr/doc/texmf/index.html" "fix2col")

# (find-lsrcfile "base/changes.txt")
# (find-lsrcfile "base/classes.dtx")
# (find-lsrcfile "base/clsguide.tex")
# (find-lsrcfile "base/doc.dtx")
# (find-lsrcfile "base/idx.tex")
# (find-lsrcfile "base/letter.dtx")
# (find-lsrcfile "base/ltclass.dtx")
# (find-lsrcfile "base/ltfiles.dtx")
# (find-lsrcfile "base/ltfloat.dtx")
# (find-lsrcfile "base/ltnews.cls")
# (find-lsrcfile "base/ltoutput.dtx")
# (find-lsrcfile "base/makeindx.dtx")
# (find-lsrcfile "base/manual.err")
# (find-lsrcfile "base/proc.dtx")
# (find-lsrcfile "base/slides.dtx")
# (find-lsrcfile "base/usrguide.tex")

# (find-node "(latex)Layout")




#####
#
# \show, \tracingall, etc
# 2000oct31
#
#####

# «show_and_tracing»  (to ".show_and_tracing")
# (find-texbookpage (+ 11 476))
# (find-knuthfile "tex/")
# (find-knuthfile "tex/texbook.tex" "beginchapter Appendix I. Index" "show")
# (find-knuthfile "tex/texbook.tex" "|\\tracingall|")
# (find-fline "/usr/share/texmf/tex/plain/base/plain.tex")
# (find-fline "/usr/share/texmf/tex/plain/base/plain.tex" "% \\tracingonline=")
# (find-fline "/usr/share/texmf/tex/plain/base/plain.tex" "\\def\\tracingall")

# (find-texbookpage (+ 11 32))
# (find-knuthfile "tex/texbook.tex" "nonstopmode")
#*
cd /tmp/
tex '\relax\tracingonline=1\nonstopmode
  \show\smash
  \setbox1\hbox{bp}
  \showbox1
  \bye
'
#*

# 2008may09:
# (find-texbookfile "texbook.tex")
# (find-texbookfile "texbook.tex" "\\tracingall")
# (find-texbookfile "texbook.tex" "Appendix I. Index")
# (find-texbookfile "texbook.tex" "Appendix I. Index" "show")
# (find-texbookfile "texbook.tex" "Appendix I. Index" "tracing")
% (find-texbooktext "")
% (find-texbooktext "\\errorstopmode | \\scrollmode")
% (find-texbooktext "\\tracingonline (positive")
% (find-texbooktext "\\showthe\\dimen2")
% (find-texbooktext "`\\showthe'")
% (find-texbooktext "Box contents" "\\tracingonline=1")
% (find-texbooktext "! Undefined control sequence.")
% (find-texbooktext "`?'")
% (find-texbooktext "`S', `R', or `Q'")
% (find-texbooktext "\\scrollmode, \\nonstopmode, and \\batchmode")
% (find-texbooktext "Type `S'. TEX will proceed without pausing")
% (find-texbooktext "Type `R'. This is like `S' but even stronger")
% (find-texbooktext "Type `Q'. This is like `R' but even more so")

* (eepitch-tex)
* (eepitch-kill)
* (eepitch-tex)
\tracingonline=1
\newlinechar=`\^^J
\catcode` =12\def\spac{ }\catcode` =10
\setbox1\hbox{bp}
\message{^^J \the\wd1\spac \the\ht1\spac \the\dp1}
\showbox1
I\show\smash
I\showthe\wd1
\interact
\showthe\wd1
I\bye
%\interact



#####
#
# Showing the dimensions of a box
# 99nov06
#
#####

# «show_box_dims»  (to ".show_box_dims")
# (find-angg "LATEX/edrx.sty" "showboxdims")
# (find-texbookfile "texbook.tex" "The \\<token list> of a |\\write|")
# (find-texbookfile "texbook.tex" "\\newlinechar=`\\^^J")
# (find-texbookfile "texbook.tex" "10&Space")
# (find-texbookfile "texbook.tex" "12&Other character")
# (find-texbookfile "texbook.tex" "13&Active character")
# (find-texbookfile "texbook.tex" "^|\\message||{...}|")
# (find-texbookpage (+ 11 37) "Category" "Meaning")
# (find-texbookpage (+ 11 481))
# (find-texbookpage (+ 11 227))

%*
% (eelatex-bounded)
\setbox1\hbox{bp}
\newlinechar=`\^^J
\catcode` =12\def\spac{ }\catcode` =10
\message{^^J \the\wd1\spac \the\ht1\spac \the\dp1}
\dp1=12pt
\message{^^J \the\wd1\spac \the\ht1\spac \the\dp1}
\message{^^J \the\wd1\spac \the\ht1\spac \the\dp1}
%*
% (eelatex-bounded)
\catcode` =12\gdef\spac{ }\catcode` =10
\gdef\showboxdims#1{\immediate\write16{
  wd=\the\wd#1\spac ht=\the\ht#1\spac dp=\the\dp#1
}}
\setbox1\hbox{bp}
\showboxdims{1}
\dp1=12pt
\showboxdims{1}
%*


# Converting dimensions:
# (find-knuthfile "tex/texbook.tex" "newdimen")
# (find-fline "/usr/lib/texmf/tex/plain/base/plain.tex" "newdimen")
# (find-knuthfile "tex/texbook.tex" "in=72.27")
# (/ 1 72.27)

%*
\newlinechar=`\^^J
\newdimen\tmpdimen
%\def\rmpt#1pt{#1}
\def\rmpt#1{#1}

\tmpdimen=72.27pt
\message{^^J \the\tmpdimen}
\tmpdimen=0.013837\tmpdimen
\message{^^J \rmpt\the\tmpdimen in}
%*


# Other notes:
#*
tex '\tracingonline=1\scrollmode
  \message{hello}
  \setbox1\hbox{bp}
  \showthe\wd1
  \showthe\ht1
  \showthe\dp1
  \bye'
#*
tex '\tracingonline=1\scrollmode
\newlinechar=`\^^J
\def\sp{ }
\setbox1\hbox{bp}
\catcode` =12\def\spac{ }\catcode` =10
\message{    \the\wd1   \the\ht1\ \the\dp1}
\message{^^J \the\wd1^^ \the\ht1{} \the\dp1}
\message{^^J \the\wd1\sp \the\ht1^^20 \the\dp1}
\message{^^J \the\wd1\string\ \the\ht1\char` \the\dp1}
\message{^^J \the\wd1\spac \the\ht1\spac \the\dp1}
\message{^^J \the\wd1\spac \the\ht1\spac \the\dp1}
\bye'
#*

# (find-knuthfile "tex/texbook.tex")
# (find-texbooktext "256 box registers")
# (find-texbooktext "\\expandafter token")
# (find-texbooktext "futurelet")
# (find-texbooktext "batchmode")
# (find-texbooktext "showthe\n")
# (find-texbooktext "\\csname")
# (find-texbooktext "2\\wd3")

# (find-fline "/usr/lib/texmf/tex/plain/base/manmac.tex" "index")

# (find-fline "~/LATEX/")
# (find-fline "~/LATEX/boxing7.tip")
# (find-fline "~/LATEX/Makefile")




#####
#
# \smash
# 2001oct23
#
#####

# «smash»  (to ".smash")
% (find-texbookpage (+ 11 178) "\\smash")
% (find-texbookpage (+ 11 360) "\\def\\smash")
% (find-texbooktext            "\\def\\smash")
% (find-amsldocpage (+ 6 11) "\\smash options")
% (find-lsrcfile "base/ltmath.dtx" "\\def\\smash")
% (find-lsrcfile "amslatex/math/amsmath.dtx" "\\renewcommand{\\smash}")
% (find-lsrcfile "base/ltdefns.dtx" "\\def\\@protected@testopt")
% (find-plainsrcfile "plain.tex" "\\def\\smash")
% Why doesn't the standard LaTeX \smash work?
%*
\def\mysmash#1{{\setbox0\hbox{#1}%
  \wd0=0pt\ht0=0pt\dp0=0pt%
  \box0}}

aa\smash{BBB}cccc

aa\mysmash{BBB}cccc

%*
% (eedn4a-bounded)
\def\mysmash#1{{%
  \setbox0\hbox{#1}%
  \wd0=0pt\ht0=0pt\dp0=0pt%
  \box0
  }}
\def\red#1{{\color{red}#1}}

Foo: \mysmash{right}wrong

Foo: \mysmash{\red{right}}wrong

\leavevmode \mysmash{right}wrong

%*





#####
#
# tetex-bin source (potato)
# 2000oct01
#
#####

# «tetex-bin»  (to ".tetex-bin")

# (find-status "tetex-bin")
# (find-vldifile "tetex-bin.list")
# (find-fline "/usr/doc/tetex-bin/")

# The tetex-bin source package generates tetex-bin, tetex-dev and
# tetex-lib, but the last two are not very interesting because they
# contain only kpathsea stuff.

#*
pdsc $SDEBIAN/dists/potato/main/source/tex/tetex-bin_1.0.6-7.dsc
cd /usr/src/tetex-bin-1.0.6/
find * | sort > .files
debian/rules binary	|& tee odrb

#*
cd /usr/src/tetex-bin-1.0.6/
agrep '\./tangle' odrb

#*
# «weaving»  (to ".weaving")
cd /usr/src/tetex-bin-1.0.6/texk/web2c/
rm -Rv /tmp/weave/
mkdir  /tmp/weave/
cp -v {tex,mf,gftodvi}.{web,ch} /tmp/weave/
cd     /tmp/weave/

weave gftodvi.web
tex   gftodvi.tex
weave gftodvi.web gftodvi.ch
mv    gftodvi.tex gftodvi-ch.tex
tex           gftodvi-ch.tex

weave tex.web
tex   tex.tex
weave tex.web tex.ch
mv    tex.tex tex-ch.tex
tex           tex-ch.tex

weave mf.web
tex   mf.tex
weave mf.web mf.ch
mv    mf.tex mf-ch.tex
tex          mf-ch.tex

xdvi  gftodvi.dvi &
xdvi  gftodvi-ch.dvi &

xdvi  tex.dvi &
xdvi  tex-ch.dvi &

xdvi  mf.dvi &
xdvi  mf-ch.dvi &

#*

# (find-texbinfile "odrb" "./tangle ")

# (code-c-d "texbin" "/usr/src/tetex-bin-1.0.6/")
# (find-texbinfile "")
# (find-texbinfile "odrb")
# (find-texbinfile ".files")
# (find-texbinfile "texk/web2c/")
# (find-texbinfile "texk/web2c/window/")
# (find-texbinfile "texk/web2c/mf.web")
# (find-texbinfile "texk/web2c/mf.web" "Online graphic output.")
# (find-texbinfile "texk/web2c/window/")
# (find-node "(web2c)Metafont")
# (find-node "(web2c)Online Metafont graphics" "`Metafont'")

# (find-fline "/tmp/weave/")
# (find-fline "/tmp/weave/mf.tex")
# (find-fline "/tmp/weave/mf.tex" "\\:\\X")
# (find-fline "/tmp/weave/mf-ch.tex")
# (find-fline "/tmp/weave/mf-ch.tex" "\\:\\X")
# (find-fline "/tmp/weave/mf-ch.tex" "16 ``window'' areas")




#####
#
# xdvi'ing compressed files
# 2000oct01
#
#####

# «xdvi-gz»  (to ".xdvi-gz")
# (to "docs")
# (find-fline "/usr/doc/tetex-base/README.Debian" "view the compressed .dvi")
# (find-fline "/usr/doc/tetex-bin/changelog.Debian.gz" "zipped files")
# (find-status "tetex-bin")
# (find-vldifile "tetex-bin.list")
# (find-texbinfile "texk/xdvik/")
# (find-texbinfile "texk/xdvik/xdvi-sh")
# (find-fline "/usr/bin/X11/xdvi" "*.gz")

#*
# Prepare to hand-patch
cd /usr/bin/X11/
if [[ ! -e xdvi.orig ]]; then cp -av xdvi xdvi.orig; fi
# (find-fline "/usr/bin/X11/xdvi" "*.gz")
#*
# Bring the original back
cd /usr/bin/X11/
mv -v xdvi.orig xdvi
#*

# ...then I gave up. Instead of fixing the xdvi wrapper or writing one
# of my own I decided to use a simple shell function instead. Here it
# is: (find-angg ".zshrc" "zxdvi")

# I'm not calling it in scripts or mime descriptions, just in
# e-scripts, like in this one: (to "docs")


# A test:
#*
rm -Rv /tmp/a
mkdir /tmp/a
cd ~/LATEX
gzip -c6 feb98.dvi > /tmp/a/feb98.dvi.gz
zxdvi /tmp/a/feb98.dvi.gz
#*




#####
#
# src2tex
# 2000oct25
#
#####

# «src2tex»  (to ".src2tex")
# (find-status "src2tex")
# (find-vldifile "src2tex.list")
# (find-fline "/usr/doc/src2tex/")

#*
rm -Rv /tmp/st-e/
mkdir  /tmp/st-e/
cd     /tmp/st-e/
cp -v /usr/share/doc/src2tex/examples/contrib/* .
cp -v /usr/share/doc/src2tex/examples/*         .
gzip -dv *
#*
cd     /tmp/st-e/
for i in *.dvi; do xdvi -s 8 $i; done
for i in *.ps; do  gv -antialias $i; done





#####
#
# auctex
# 2000oct31 / 2008nov12
#
#####

# «auctex»  (to ".auctex")
# (find-status   "auctex")
# (find-vldifile "auctex.list")
# (find-udfile   "auctex/")
# (find-node "(auctex)Top")
# (find-node "(auctex)Itemize-like")
# (find-node "(preview-latex)Top")
# (find-firefox "/usr/share/doc/auctex/HTML/auctex/index.html")
# (find-firefox "/usr/share/doc/auctex/HTML/preview-latex/index.html")
# (find-node "(auctex)Top")
# (find-node "(auctex)Commands" "% Local Variables:")
# (find-node "(auctex)Commands" "write the current region into the region file")

# (find-fline "/etc/emacs-snapshot/site-start.d/50auctex.el")
# (find-sitelispfile "auctex/")
# (find-fline "/var/lib/auctex/emacs21/")




# Just as a curiosity: auctex uses local variables a lot.
zcatinfo /usr/share/info/auctex > /tmp/auctex.info
# (find-fline "/tmp/auctex.info")





#####
#
# making indices
# 2001jan25
#
#####

# «indices»  (to ".indices")
# (find-lsrcfile "amslatex/math/amsldoc.tex")
#*
rm -Rv /tmp/latex/
mkdir  /tmp/latex/
cd     /tmp/latex/
cp -v /usr/share/texmf/source/latex/amslatex/math/amsldoc.tex .
latex amsldoc.tex
latex amsldoc.tex
xdvi /tmp/latex/amsldoc.dvi

# (find-fline "/tmp/latex/")
# (find-fline "/tmp/latex/amsldoc.tex" "tableofcontents")
# (find-fline "/tmp/latex/amsldoc.toc")
#*
lsrcagrep tableofcontents
lsrcagrep -l tableofcontents |& tee ~/o
l +/tableofcontents $(<~/o)
#*

# (find-node "(latex)Table of Contents")
# (find-node "(latex)Sectioning")





#####
#
# Makoto Tatsuta's proof.sty
# 2001oct23
#
#####

# «tatsutaproof»  (to ".tatsutaproof")
# (find-angg "LATEX/proof.orig.sty")
# (find-angg "LATEX/proof.edrx.sty")
# (find-fline "$SCTAN/macros/latex/contrib/other/proof/proof.sty")
# (find-fline "$SCTAN/macros/latex/contrib/other/proof/proofeg.tex")

tkdiff ~/LATEX/proof.edrx.sty $SCTAN/macros/latex/contrib/other/proof/proof.sty

# (find-angg "dednat/dednat.lua" "tatsuta_donode")
# (find-angg "dednat/dednat2.lua" "tatsuta_do_node")

# 2007aug20:
# http://tug.ctan.org/macros/latex/contrib/lkproof/proof.sty
# http://tug.ctan.org/macros/latex/contrib/lkproof/proofeg.tex
# (find-sh0 "cp -v $S/http/tug.ctan.org/macros/latex/contrib/lkproof/proof* ~/LATEX/")
# (find-dvipage "~/LATEX/proofeg.dvi" 1)
#*
cd ~/LATEX/
latex proofeg.tex
rexdvi proofeg.dvi

#*




#####
#
# Samuel Buss' package for typesetting proof trees
# 2001feb25
#
#####

# «bussproofs»  (to ".bussproofs")
# (find-shttpw3 "www.math.ucla.edu/~asl/bussproofs.sty")
#*
cd /tmp/
cp $S/http/www.math.ucla.edu/~asl/bussproofs.sty .
cat > proof.tex <<'---'
\documentclass{book}
\usepackage{bussproofs}
\begin{document}

% (find-fline "/tmp/bussproofs.sty" "For example, to generate")
% (find-fline "/tmp/bussproofs.sty" "\\def\\BinaryInfC")
% (find-fline "/tmp/bussproofs.sty" "Usages:")
$$
\AxiomC{D}
\AxiomC{A}
\AxiomC{B}
\BinaryInfC{C}
%\BinaryInf{E}
\BinaryInfC{E}
\DisplayProof
$$

\scriptsize
\def\ScoreOverhang{0pt}

$$
\AxiomC{A}
\AxiomC{\(B\)}
\RightLabel{X}
\BinaryInfC{C}
\DisplayProof
$$

\end{document}
---

latex proof.tex && rexdvi proof.dvi
#*



#####
#
# Paul Taylor's proof tree package
# 2001apr03
#
#####

# «ptproof-old»  (to ".ptproof-old")
# (find-angg "dednat/dednat3.lua" "paul.taylor")
# (find-sftpfile "ftp.dcs.qmw.ac.uk/pub/tex/contrib/pt/proofs/")

# (code-c-d "ptproof" "$S/ftp/ftp.dcs.qmw.ac.uk/pub/tex/contrib/pt/proofs/")
# (find-ptprooffile "prooftree-doc.tex" "primitive")
# (find-ptprooffile "prooftree.tex")
#*
rm -Rv /tmp/pt/
mkdir  /tmp/pt/
cd     /tmp/pt/
# cp -iv $S/ftp/ftp.dcs.qmw.ac.uk/pub/tex/contrib/pt/proofs/* .
cp    -v $S/http/www.monad.me.uk/proofs/prooftree.sty .
cp    -v $S/http/www.monad.me.uk/proofs/prooftree-doc.tex .

cd     /tmp/pt/
cat > pttest.tex <<'%%%'
\documentclass{book}
\usepackage{prooftree}
\begin{document}
\begin{prooftree}
  \[ A \quad
     B \using \land I \justifies
  A \land B \]
  A \land B \to C
  \[ \[ \justifies
     ?? \] \justifies
  ? \] \justifies
C
\end{prooftree}
\end{document}
%%%
latex pttest.tex  &&  rexdvi pttest.dvi

#*


# «ptproof»  (to ".ptproof")
# http://www.monad.me.uk/proofs/
# http://www.monad.me.uk/proofs/prooftree.sty
# http://www.monad.me.uk/proofs/prooftree-doc.tex
#*
rm -Rv ~/usrc/ptproof/
mkdir  ~/usrc/ptproof/
cd     ~/usrc/ptproof/
cp -v $S/http/www.monad.me.uk/proofs/prooftree.sty .
cp -v $S/http/www.monad.me.uk/proofs/prooftree-doc.tex .
cp -v prooftree.sty prooftree.tex
latex prooftree-doc.tex  \
  && rexdvi prooftree-doc.dvi \
  && dvipdf prooftree-doc.dvi

#*
# (code-c-d "ptproof" "~/usrc/ptproof/")
# (find-ptprooffile "")
# (find-ptprooffile "prooftree-doc.tex")
# (find-fline "~/LATEX/" "prooftree")
# (find-sh0 "rm -v ~/LATEX/prooftree.sty")
# (find-sh0 "cp -v $S/http/www.monad.me.uk/proofs/prooftree.sty ~/LATEX/")

# (code-dvi       "ptproof" "~/usrc/ptproof/prooftree-doc.dvi")
# (code-pdftotext "ptproof" "~/usrc/ptproof/prooftree-doc.pdf")
# (find-ptproofpage 1)
# (find-ptprooftext)
# (find-ptprooftext "\\kern-26em")









#####
#
# TeXCad
# 2001may26
#
#####

# «texcad»  (to ".texcad")
#*
rm -Rv /usr/src/xtexcad-2.4.1/
cd /usr/src/
tar -xvzf $S/ftp/ftp.tex.ac.uk/tex-archive/graphics/xtexcad/xtexcad-2.4.1.tar.gz
cd /usr/src/xtexcad-2.4.1/

xmkmf		|& tee ox
make		|& tee om

#*
debtartvzf /var/cache/apt/archives/xlib6g-dev_3.3.6-9_i386.deb	|& tee ~/o
# (find-fline "~/o" "xmkmf")
#*
cd /
debtarxvzf /var/cache/apt/archives/xlib6g-dev_3.3.6-9_i386.deb \
  ./usr/X11R6/bin/xmkmf	\
  ./usr/X11R6/bin/imake
#*

# (code-c-d "texcad" "/usr/src/xtexcad-2.4.1/")
# (find-texcadfile "")
# (find-texcadfile "README")




#####
#
# arrow.tex
# 2001nov01
#
#####

# «arrow.tex»  (to ".arrow.tex")
# (find-fline "/usr/share/texmf/tex/plain/misc/arrow.tex" "% Some examples")
#*
cd /tmp/
cat > arrowtest.tex <<'---'
\input arrow.tex
\parskip=20pt

The first example:
$$\commdiag{A&\mapright^f&B&\mapleft^g&C\cr
\mapdown\lft\psi&\arrow(3,-2)\rt s&\mapup\rt\phi&
\arrow(-3,2)\lft l&\mapdown\rt\theta\cr
D&\mapright_h&E&\mapleft_{\int_0^t{\bf A}\,d\sigma}&F\cr}$$

Covering homotopy property (Bott and Tu, {\it Differential Forms in
Algebraic Topology}):
$$\commdiag{Y&\mapright^f&E\cr \mapdown&\arrow(3,2)\lft{f_t}&\mapdown\cr
Y\times I&\mapright^{\bar f_t}&X}$$

Universal mapping property (Warner, {\it Foundations of Differentiable
Manifolds and Lie Groups}): $$\varrowlength=20pt
\commdiag{V\otimes W\cr \mapup\lft\phi&\arrow(3,-1)\rt{\tilde l}\cr
V\times W&\mapright^l&U\cr}$$

A cube (Francis Borceux):
$$\harrowlength=48pt \varrowlength=48pt \sarrowlength=20pt
\def\cross#1#2{\setbox0=\hbox{$#1$}%
  \hbox to\wd0{\hss\hbox{$#2$}\hss}\llap{\unhbox0}}
\gridcommdiag{&&B&&\mapright^b&&D\cr
&\arrow(1,1)\lft a&&&&\arrow(1,1)\lft d\cr
A&&\cross{\hmorphposn=12pt\mapright^c}{\vmorphposn=-12pt\mapdown\lft f}
&&C&&\mapdown\rt h\cr\cr
\mapdown\lft e&&F&&\cross{\hmorphposn=-12pt\mapright_j}
{\vmorphposn=12pt\mapdown\rt g}&&H\cr
&\arrow(1,1)\lft i&&&&\arrow(1,1)\rt l\cr
E&&\mapright_k&&G\cr}$$

Zassenhaus's Butterfly Lemma (Lang, {\it Algebra}):
$$\hgrid=16pt \vgrid=8pt \sarrowlength=32pt
\def\cross#1#2{\setbox0=\hbox{$#1$}%
  \hbox to\wd0{\hss\hbox{$#2$}\hss}\llap{\unhbox0}}
\def\l#1{\llap{$#1$\hskip.5em}}
\def\r#1{\rlap{\hskip.5em$#1$}}
\gridcommdiag{&&U&&&&V\cr &&\bullet&&&&\bullet\cr
&&\sarrowlength=16pt\sline(0,1)&&&&\sarrowlength=16pt\sline(0,1)\cr
&&\l{u(U\cap V)}\bullet&&&&\bullet\r{(U\cap V)v}\cr
&&&\sline(2,-1)&&\sline(2,1)\cr
&&\cross{=}{\sline(0,1)}&&\bullet&&\cross{=}{\sline(0,1)}\cr\cr
&&\l{^{\textstyle u(U\cap v)}}\bullet&&\cross{=}{\sline(0,1)}&&
 \bullet\r{^{\textstyle(u\cap V)v}}\cr
&\sline(2,1)&&\sline(2,-1)&&\sline(2,1)&&\sline(2,-1)\cr
\l{u}\bullet&&&&\bullet&&&&\bullet\r{v}\cr
&\sline(2,-1)&&\sline(2,1)&&\sline(2,-1)&&\sline(2,1)\cr
&&\bullet&&&&\bullet\cr &&u\cap V&&&&U\cap v\cr}$$

\bye
---
tex arrowtest.tex && rexdvi arrowtest.tex
#*




#####
#
# The "picture" mode
# 2001nov02
#
#####

# «picture_mode»  (to ".picture_mode")
# (find-fline "/usr/share/texmf/fonts/source/public/latex/")
# (find-fline "/usr/share/texmf/fonts/source/public/latex/circle.mf")
# (find-fline "/usr/share/texmf/fonts/source/public/latex/lcircle.mf")
# (find-texbookpage (+ 11 389) "\\def\\point")
# (find-texbooktext            "\\def\\point")
# (find-texbooktext)
# (find-angg "LATEX/edrx.sty" "showboxdims")
#*
# «thin_supset»  (to ".thin_supset")
# (find-angg "LATEX/edrx.sty" "limp")

cd ~/LATEX/
cat > tmp.tex <<'---'
\documentclass{book}
\begin{document}
aa%
\setlength{\unitlength}{1pt}%
\begin{picture}(10,10)
  \put(0,2){\oval(20,4)[r]}
\end{picture}%
%
zz
\end{document}
---
latex tmp.tex
rexdvi tmp.dvi
# dvifonts tmp.dvi

#*
# 2005oct19
# A thin "\supset" char, used as a logical "implies" symbol
# (find-xpdfpage  "/usr/share/doc/texlive-doc/latex/amsmath/amsopn.pdf")
# (find-pdftotext "/usr/share/doc/texlive-doc/latex/amsmath/amsopn.pdf")
# (find-xpdfpage  "/usr/share/doc/texlive-doc/latex/amsmath/amsldoc.pdf")
# (find-pdftotext "/usr/share/doc/texlive-doc/latex/amsmath/amsldoc.pdf")
# (find-lsrcfile "amsmath/amsopn.sty")
# (find-lsrcfile "amsmath/amsopn.dtx")
# (find-man "texdoc")
# (find-sh "texdoc -l amsldoc")
# (eev "texdoc amsldoc")
# (find-texbookpage (+ 11 389))
# (find-angg "LATEX/edrx.sty" "showboxdims")

%*
% (eedn4a-bounded)
% (find-dn4ex "edrx08.sty" "limp")
% (find-texbookpage (+ 11 155) "\\mathrel")
% (find-texbooktext            "\\mathrel")
% (find-texbookpage (+ 11 155) "$1\\mathord,234$")
% (find-texbooktext            "$1\\mathord,234$")

\par \def\limp{\mathrel{\limpchar}} $P⊃Q${}$|||$
\par \def\limp{\mathbin{\limpchar}} $P⊃Q${}$|||$
\par \def\limp{\mathrel{\limpchar}} $P⊃${}$|||$
\par \def\limp{\mathbin{\limpchar}} $P⊃${}$|||$

%*







#####
#
# understanding \begin
# 2002apr09
#
#####

# «begin»  (to ".begin")
# (find-node "(latex)Command Index")
# (find-node "(latex)\newenvironment")
# (find-angg "LATEX/2002d.tex" "newenvironment")

# (find-lsrcfile "base/")
# (find-lsrcfile "base/ltmiscen.dtx" "\\def\\begin")
# (find-lsrcfile "base/ltmiscen.dtx" "\\def\\end")
# (find-lsrcfile "base/ltdefns.dtx" "\\def\\newenvironment")

# (find-vldifile "tetex-src.list")

# (find-texbytopictext "\\begin{...} ... \\end{...}")
# (find-texbytopicpage (+ 1 131))




#####
#
# realcalc
# 2002apr15
#
#####

# «realcalc»  (to ".realcalc")
lynx /debian/usr/share/doc/texmf/help/Catalogue/entries/calc.html
lynx /debian/usr/share/doc/texmf/help/Catalogue/entries/realcalc.html

# (find-fline "/usr/share/texmf/tex/latex/tools/calc.sty")
# (find-dvipage "/usr/share/texmf/doc/latex/tools/calc.dvi" 1)
# (find-fline "/debian/usr/share/texmf/source/latex/calc/calc.dtx")
# (find-fline "/debian/usr/share/texmf/source/latex/tools/calc.dtx")

#*
rm -Rv $usr_src/realcalc/
cd $usr_src/
tar -xvzf $S/ftp/ftp.dante.de/tex-archive/macros/generic/realcalc.tar.gz
cd $usr_src/realcalc/
grep '%%' realcalc.tex > realcalc.doc
latex realdemo.tex

cp -v realcalc.tex ~/LATEX/

# (code-c-d "realcalc" "$usr_src/realcalc/")
# (find-realcalcfile "readme")
# (find-realcalcfile "realcalc.doc")
# (find-realcalcfile "realcalc.tex")
# (find-realcalcfile "realtest.tex")

#*



####
#
# LaTeX-demo (in Portuguese)
# 2002jul08
#
####

# «tex-br»  (to ".tex-br")
# (find-shttpw3 "biquinho.furg.br/tex-br/")

# «LaTeX-demo»  (to ".LaTeX-demo")
#*
rm -Rv $usr_src/LaTeX-demo-1.13/
cd     $usr_src/
tar -xvzf $S/http/biquinho.furg.br/tex-br/doc/LaTeX-demo/LaTeX-demo-1.13.tar.gz
cd     $usr_src/LaTeX-demo-1.13/
make demo.dvi

#*
# (code-c-d "ltxdemo" "$usr_src/LaTeX-demo-1.13/")
# (find-ltxdemofile "")




#####
#
# cmsy10 scaled
# 2002nov21
#
#####

# «cmsy10_scaled»  (to ".cmsy10_scaled")
# Producing an \otimes in cmsy10 scaled 1000, for Dynkin diagrams.
# See Kopka/Daly pp.62-63.
# (find-lsrcfile "base/fontdef.dtx" "\\otimes}{\\mathbin}{symbols}{\"0A}")
# (find-fline "~/dynkin/")
# (eev "testfont cmsy10")
# (eev "dvifonts ~/LATEX/2002h.dvi | sort")
%*
\newfont{\mycmsyten}{cmsy10 scaled 5000}
\def\myox{{\mycmsyten\symbol{"0A}}}
ab{\myox}cd
%*




#####
#
# the pullback symbol
# 2003mar29
#
#####

# (find-man "1 xdvi")
# (find-texbookpage 9)
# (find-texbookpage (+ 11 221) "Chapter 21: Making Boxes")
# (find-knuthfile "tex/texbook.tex")
# (find-fline "/usr/share/texmf/tex/plain/base/manmac.tex")
# (find-fline "/usr/share/texmf/tex/plain/base/manmac.tex" "samplebox")
# (find-fline "/usr/share/texmf/tex/plain/base/manmac.tex" "\\def\\setcornerrules")
rexdvi $SCTAN/systems/knuth/tex/texbook.dvi -s 7 -topmargin .9in
%*

%\def\setcornerrules{\hbox to \pagewidth{\vrule width 1pc height\ruleht
%    \hfil \vrule width 1pc}
%  \hbox to \pagewidth{\llap{\sevenrm(page \folio)\kern1pc}%
%    \vrule height1pc width\ruleht depth\z@
%    \hfil \vrule width\ruleht depth\z@}}

\par abc\hbox to 1pc{\vrule \vbox to 10pt{\hrule height 2pt width 3pt}}def
\par abc\hbox to 1pc{\vrule \vbox{\hrule \hbox to 10pt{}}}def
\par abc\hbox{\vrule p\vrule}def
\par abc\hbox{\vrule b\vrule}def
\par abc\hbox{\vrule \vbox{\hrule o}\vrule}def
\par abc\hbox{\vrule \vbox{o \hrule}\vrule}def
\par abc\hbox{\vrule \vbox{o}\vrule}def
\par abc\hbox{\vrule\hbox to 10pt{\vbox{o}\vrule}}def
\par abc\hbox{\vrule\hbox to 10pt{\vbox{\hrule \noindent o}\vrule}}def
\par abc\hbox to 1cm{\vrule width 1pc height .5pt \hfil \vrule width 1pc}def

%*


#####
#
# bibtex
# 2002dec09
#
#####

# «bibtex»  (to ".bibtex")
# (find-angg "LATEX/catsem.bib")
# (find-angg "LATEX/filters.bib")
# (find-sh "locate bibtex")
# (find-zsh "dmissing bibtex")
# (find-fline "/hdd6/snarf/ftp/ftp.cs.cmu.edu/user/jcr/ReynoldsJC.bib")
# (find-fline "/hdd6/snarf/ftp/ftp.math.mcgill.ca/pub/rags/SeelyRAG.bib")
# (find-fline "/hdd6/snarf/http/hypatia.dcs.qmw.ac.uk/author/FreydPJ/bilbio.bib.html")
# (find-fline "$S/ftp/ftp.imf.au.dk/pub/kock/KockA.bib")
# (find-fline "/usr/share/doc/texmf/bibtex/base/")
# (find-fline "/usr/share/doc/texmf/bibtex/base/btxdoc.tex.gz")
# (find-fline "/usr/share/doc/texmf/bibtex/base/btxdoc.bib")
# (code-dvi "btxdoc" "/usr/share/doc/tetex-doc/bibtex/base/btxdoc.dvi.gz")
# (code-dvi "btxdoc" "/tmp/bib/btxdoc.dvi")
# (find-btxdocpage 11 "Helpful Hints")
# (find-lsrcfile "natbib/")
# (find-lsrcfile "natbib/README.1st")
# (find-lsrcfile "lshort/src/spec.tex" "\\section{Bibliography}")
# (find-dvipage "/usr/share/doc/texmf/latex/general/lshort.dvi.gz" (+ 14 57))
#*
# (find-sh "locate btxdoc")
# (find-fline "/usr/share/doc/texlive-base/bibtex/base/")
# (find-fline "/usr/share/doc/texlive-doc/bibtex/base/")

rm -Rv /tmp/bib/
mkdir  /tmp/bib/
cd     /tmp/bib/
cp -v /usr/share/doc/texlive-base/bibtex/base/* .
gunzip -v *.gz
# (find-fline "/usr/share/doc/texmf/bibtex/base/btxdoc.tex.gz" "running")
# (find-man "1 bibtex")
latex  btxdoc.tex
bibtex btxdoc
latex  btxdoc.tex
latex  btxdoc.tex

#*
rm -Rv /tmp/bib2/
mkdir  /tmp/bib2/
cd     /tmp/bib2/
cat > ragsmini.bib <<'%%%'
@article{SeelyRAG:cshoplc,
 author		= {R. A. G. Seely},
 title		= {Categorical Semantics for Higher Order Polymorphic
                   Lambda Calculus},
 journal	= {Journal of Symbolic Logic},
 volume		= {52},
 number		= {4},
 pages		= {969--988},
 checked	= {Yes},
 month		= {dec},
 year		= 1987}
%%%
cat > bibtest.tex <<'%%%'
\documentclass{article}
\begin{document}
% \cite{SeelyRAG:cshoplc}
\nocite{*}
\bibliography{ragsmini}
% \bibliographystyle{plain}
\bibliographystyle{alpha}
\end{document}
%%%

latex  bibtest.tex
bibtex bibtest
latex  bibtest.tex
latex  bibtest.tex

rexdvi bibtest.dvi
#*
# (find-fline "/tmp/bib2/")
# (find-lsrcfile "base/")
# (find-lsrcfile "base/ltbibl.dtx")
# (find-fline "/usr/share/texmf/bibtex/")

# (find-fline "/usr/share/texmf/bibtex/bst/ams/amsalpha.bst")
# (find-fline "/usr/share/texmf/bibtex/bst/base/alpha.bst")
# (find-fline "/usr/share/texmf/bibtex/bst/plbib/plalpha.bst")
# (find-fline "/usr/share/texmf/source/latex/amscls/amsalpha.bst")




#####
#
# makebbl
# 2003jul04
#
#####

# «makebbl»  (to ".makebbl")
# (find-angg ".zshrc" "makebbl")
# (find-LATEX "catsem.bib" "test")
# (find-angg ".emacs.papers" "kopkadaly")
# (find-kopkadaly4page (+ 12 309) "\\bibliography{database1,")
# (find-kopkadaly4text (+ 12 309) "\\bibliography{database1,")
# (find-kopkadaly4page (+ 12 310) "With \\nocite{*}, every entry")
# (find-kopkadaly4text (+ 12 310) "With \\nocite{*}, every entry")
# (find-kopkadaly4page (+ 12 310) "\\bibliographystyle{style}")
# (find-kopkadaly4text (+ 12 310) "\\bibliographystyle{style}")
# (find-kopkadaly4page (+ 12 316) "14.2.3 Cross-referencing")
# (find-kopkadaly4text (+ 12 316) "14.2.3 Cross-referencing")
#*
rm -Rv /tmp/tmpbib/
mkdir  /tmp/tmpbib/
cd     /tmp/tmpbib/
cp ~/LATEX/catsem.bib .
cp ~/LATEX/filters.bib .
cat > tmpbib.tex <<'%%%'
\documentclass{book}
\begin{document}
\nocite{*}
% \bibliography{catsem}
\bibliography{catsem,filters}
% \bibliography{filters}
\bibliographystyle{alpha}
\end{document}
%%%
latex tmpbib.tex
bibtex tmpbib
# latex tmpbib.tex
# latex tmpbib.tex

#*
rm -Rv /tmp/tmpbib/
mkdir  /tmp/tmpbib/
cd     /tmp/tmpbib/
cp ~/LATEX/catsem.bib .
function makebbl () {
  echo -E '\documentclass{book}'	>  tmpbib.tex
  echo -E '\begin{document}'		>> tmpbib.tex
  echo -E '\nocite{*}'			>> tmpbib.tex
  for i in $*[2,-1]; do
    echo -E '\bibliography{'$i'}'	>> tmpbib.tex
  done
  echo -E '\bibliographystyle{alpha}'	>> tmpbib.tex
  echo -E '\end{document}'		>> tmpbib.tex
  latex  tmpbib.tex
  bibtex tmpbib
  cp -v tmpbib.bbl $1
}

makebbl mybib.bbl catsem

cat > test.tex <<'%%%'
\documentclass[oneside]{book}
\begin{document}
See \cite{GeuversPhD}.
\input mybib.bbl
\end{document}
%%%
latex test.tex
latex test.tex
rexdvi test.dvi

#*




#####
#
# generating tables of contents automatically
# 2002dec24
#
#####

# «TOCs»  (to ".TOCs")
#*
rm -Rv /tmp/latextoc/
mkdir  /tmp/latextoc/
cd     /tmp/latextoc/
cat > test.tex <<'%%%'
\documentclass{book}
\begin{document}
\par Title page
\tableofcontents
\chapter{chapter the 1st}
\section{section the 1st.1st}
\section{section the 1st.2st}
\chapter{chapter the 2st}
\chapter{chapter the 3st}
\end{document}
%%%
latex test.tex
latex test.tex
#
# (find-fline "/tmp/latextoc/")
# (find-fline "/tmp/latextoc/test.toc")

#*



#####
#
# generating a "mytoc" and producing an eev-ish "to" index from it
# 2002dec24 / 2005jul08
#
#####

# «mytoc»  (to ".mytoc")
# (find-angg ".emacs.papers" "kopkadaly")
# (find-angg ".zshrc" "mytoctoeevlinks")
# (find-texbookfile "")
# (find-texbookpage (+ 11 226))
# (find-texbookfile "texbook.tex")
# (find-texbookfile "texbook.tex" "^|\\newwrite| command")
# (find-texbookfile "texbook.tex" "^|\\newwrite||{\\alloc@7\\write")
#*
rm -Rv /tmp/latextoc/
mkdir  /tmp/latextoc/
cd     /tmp/latextoc/
cat > test.tex <<'%%%'
\documentclass{book}
\begin{document}
  % \makeatletter\@starttoc{mytoc}\makeatother
  % (find-lsrcfile "base/ltsect.dtx" "|\\@starttoc|")
  % (find-lsrcfile "base/ltsect.dtx" "\\def\\@starttoc")
  % (find-lsrcfile "base/ltplain.dtx" "\\def\\newwrite")
  % (find-lsrcgrep "grep -nH -e addtocontents base/*.dtx")
  % (find-lsrcgrep "grep -nH -e tf@ base/*.dtx")
  % (find-lsrcfile "base/ltsect.dtx" "\\def\\addtocontents#1#2")
  % (find-lsrcfile "base/ltsect.dtx" "\\def\\@starttoc#1")
  % (find-lsrcfile "base/ltsect.dtx" "open \\jobname.EXT as file \\tf@EXT")
  % (find-source2epage 'ltplain +3)
  % (find-knuthfile "tex/texbook.tex" "csname")
  \makeatletter
    \newwrite\tf@mytoc
     \openout\tf@mytoc=\jobname.mytoc
  \makeatother
  \def\mychapter#1#2{\chapter{#1}\label{#2}\addtocontents{mytoc}{: #2}}
  \def\mysection#1#2{\section{#1}\label{#2}\addtocontents{mytoc}{:: #2}}
\par Title page
\tableofcontents
\mychapter{chapter the 1st}{ch1}
\mysection{section the 1st.1st}{sec1.1}
\mysection{section the 1st.2st}{sec1.2}
\mychapter{chapter the 2st}{ch2}
\mychapter{chapter the 3st}{ch3}
\end{document}
%%%
latex test.tex \
  && latex test.tex
cat test.mytoc | mytoctoeevlinks
#
# (find-fline "/tmp/latextoc/")
# (find-fline "/tmp/latextoc/test.toc")
# (find-fline "/tmp/latextoc/test.mytoc")

#*
# (find-lsrcfile "base/classes.dtx" "tableofcontents")
# (find-lsrcfile "base/ltsect.dtx" "\\def\\addtocontents")
# (find-lsrcfile "base/ltsect.dtx" "\\def\\addcontentsline")
# (find-lsrcfile "base/ltsect.dtx" "\\begin{macro}{\\@starttoc}")
# (find-lsrcfile "base/ltsect.dtx" "\\def\\@starttoc")
# (find-lsrcfile "base/ltplain.dtx" "\\def\\newwrite")
# (find-knuthfile "tex/texbook.tex" "writes\none line to a file")
# (find-knuthfile "tex/texbook.tex" "|\\openout|\\<number>|=|\\<file name>")




#####
#
# Using \tableofcontents but changing \contentsline
# 2012dec27
#
#####

# «contentsline» (to ".contentsline")
# (find-anggfile "quadradinho/quadradinho-a5.aux")
# (find-anggfile "quadradinho/quadradinho-a5.toc")





#####
#
# Some math commands fail inside \chapter, \section, etc
# 2002dec25
#
#####

#*
rm -Rv /tmp/latexbug/
mkdir  /tmp/latexbug/
cd     /tmp/latexbug/
cat > test.tex <<'%%%'
\documentclass{book}
\usepackage{amsmath}
\begin{document}
\tableofcontents
$a \overset{\bullet}{\to} b$
\chapter{$a \overset{\bullet}{\to} b$}
\end{document}
%%%
latex test.tex \
  && latex test.tex

#*



#####
#
# Enlarging TeX (for SGA1)
# 2003jan17
#
#####

# «enlarge-pool_size»  (to ".enlarge-pool_size")
# (find-es "math" "SGA1")
# (find-fline "/usr/share/doc/texmf/tetex/teTeX-FAQ.gz" "enlarge")

# (find-fline "/etc/texmf/texmf.cnf" "\npool_size = ")
pool_size = 325000
%pool_size = 125000 - enlarged by Edrx! (find-es "tex" "enlarge-pool_size")
#*
texconfig init
#*



#####
#
# fraktur / mathfrak
# 2003mar08
#
#####

# «fraktur»  (to ".fraktur")
xdvi /usr/share/doc/texmf/fonts/amsfonts/amsfndoc.dvi.gz &
xdvi /usr/share/doc/texmf/fonts/amsfonts/amsfonts.dvi.gz &
xdvi /usr/share/doc/texmf/fonts/amsfonts/eufrak.dvi.gz &
xdvi /usr/share/doc/texmf/fonts/amsfonts/euscript.dvi.gz &
# (find-fline "/usr/share/texmf/source/latex/amsfonts/eufrak.dtx" "mathfrak")

cd /usr/share/doc/texmf/fonts/amsfonts/
for i in eufrak.dvi euscript.dvi; do zcat $i.gz > /tmp/$i; done
dvifonts /tmp/eufrak.dvi
dvifonts /tmp/euscript.dvi
testfont eufm10 eusm10
testfont eufm5 eufm6 eufm7 eufm8 eufm9

#*
cd ~/LATEX/
cat > tmp.tex <<'%%%'
\documentclass{book}
\usepackage{amsfonts}
\usepackage{bbm}
\usepackage{mathrsfs}
% (find-lsrcfile "amsfonts/euscript.dtx" "\\DeclareMathAlphabet\\EuScript")
\DeclareMathAlphabet\EuScript{U}{eus}{m}{n}
\SetMathAlphabet\EuScript{bold}{U}{eus}{b}{n}
\begin{document}
\par Gothic:
\par mathfrak: $\mathfrak{ABCDEFGHIJKLMNOPQRSTUVWXYZ-abc-012345}$
\par Calligraphic (``script''):
\par mathcal:  $\mathcal{ABCDEFGHIJKLMNOPQRSTUVWXYZ}$
\par mathscr:  $\mathscr{ABCDEFGHIJKLMNOPQRSTUVWXYZ}$
\par EuScript: $\EuScript{ABCDEFGHIJKLMNOPQRSTUVWXYZ}$
\par Blackboard bold:
\par mathbb:   $\mathbb{ABCDEFGHIJKLMNOPQRSTUVWXYZ}$
\par mathbbm:  $\mathbbm{ABCDEFGHIJKLMNOPQRSTUVWXYZ-abc-012345}$
\end{document}
%%%
latex tmp.tex
rexdvi tmp.dvi
dvifonts tmp.dvi
#*
testfont eufm10 cmsy10 rsfs10 eusm10 msbm10 bbm10
#*

% (find-fline "/usr/share/texmf/tex/latex/jknappen/mathrsfs.sty")
% (find-fline "/usr/share/doc/texmf/latex/jknappen/mathrsfs.rme")
% (find-fline "/usr/share/texmf/tex/latex/bbm/bbm.sty" "\\mathbbm")
% (find-es "tex" "rsfs")

# (find-lsrcfile "amsfonts/amsfonts.dtx" "\\DeclareMathAlphabet\\mathfrak")
# (find-lsrcfile "amsfonts/eufrak.dtx" "\\DeclareMathAlphabet\\EuFrak")
# (find-lsrcfile "amsfonts/eufrak.dtx" "mathfrak")
# (find-lsrcfile "amsfonts/amsfonts.fdd" "eufm10")
# (find-lsrcfile "base/cmfonts.fdd")
# (find-lsrcfile "jknappen/ubbold.fd")
# (find-lsrcfile "jknappen/ursfs.fd")
# (find-lsrcfile "jknappen/ustmary.fd")
# (find-progoutput "locate .fd")
# (find-progoutput "locate .fd | grep texmf | sort")
grep ptmr $(locate .fd | grep texmf)

/usr/share/texmf/source/latex/amsfonts/amsfonts.fdd
/usr/share/texmf/source/latex/base/cmfonts.fdd

# «fontfamily»  (to ".fontfamily")
# (code-dvi "fntguide" "/usr/share/doc/texmf/latex/base/fntguide.dvi.gz")
# (find-lsrcfile "base/fntguide.tex" "|ptm|  & Adobe Times")
# (find-fntguidepage 5)
#*
cd ~/LATEX/
cat > tmp.tex <<'%%%'
\documentclass{book}
\begin{document}
\par Computer Modern
\par \fontfamily{ptm}\selectfont
     Adobe Times, a.k.a.\ Times Roman
\end{document}
%%%
latex tmp.tex
rexdvi tmp.dvi
dvifonts tmp.dvi
#*
# (find-fline "/usr/share/texmf/tex/latex/psnfss/ot1ptm.fd")
# (find-lsrcfile "base/fntguide.tex" "\\begin{decl}\n|\\DeclareFontShape|")
# (find-lsrcfile "base/fntguide.tex" "\\label{sec:loadinfo}")
# (find-lsrcfile "base/fntguide.tex" "|\\fontfamily|")

# (find-lsrcfile "guide/guide.tex" "\\fontexample{ptm}{Times}")
# (find-fline "/usr/share/texmf/tex/latex/psnfss/times.sty")
# (find-fline "/usr/share/texmf/tex/latex/psnfss/")
# (find-lsrcfile "psnfss/psfonts.dtx")
# (find-lsrcfile "psnfss/psnfss2e.tex")
gv /usr/share/texmf/source/latex/psnfss/psnfss2e.pdf &

# (find-lsrcfile "psnfss/" "test")






#####
#
# hyperlinks in dvi files
# 2003jan17 / 2005jun17 / 2008nov14
#
#####

# «hyperref»  (to ".hyperref")
# (find-zsh "dmissing hyperref")
# (find-zsh "dmissing hyperref | grep texlive")
# (find-fline "/usr/share/texmf-texlive/tex/latex/hyperref/")
# (find-fline "/usr/share/doc/texlive-latex-base-doc/latex/hyperref/")
# (find-hyperrefdocfile "")
# (find-hyperreffile "")
# (find-hyperrefdocw3m "manual.html")
# file:///usr/share/doc/texlive-latex-base-doc/latex/hyperref/manual.html

(progn
  (code-c-d "hyperrefdoc" "/usr/share/doc/texlive-latex-base-doc/latex/hyperref/")
  (code-c-d "hyperref"    "/usr/share/doc/texlive-latex-base/latex/hyperref/")
  (code-c-d "hyperref"    "/usr/share/texmf-texlive/tex/latex/hyperref/")
  (code-xpdf      "hyperrefreadme"   (ee-hyperrefdocfile "README.pdf"))
  (code-pdftotext "hyperrefreadme"   (ee-hyperrefdocfile "README.pdf"))
  (code-xpdf      "hyperrefhyperref" (ee-hyperrefdocfile "hyperref.pdf"))
  (code-pdftotext "hyperrefhyperref" (ee-hyperrefdocfile "hyperref.pdf"))
  (code-xpdf      "hyperrefmanual"   (ee-hyperrefdocfile "manual.pdf"))
  (code-pdftotext "hyperrefmanual"   (ee-hyperrefdocfile "manual.pdf"))
  (code-xpdf      "hyperrefoptions"  (ee-hyperrefdocfile "options.pdf"))
  (code-pdftotext "hyperrefoptions"  (ee-hyperrefdocfile "options.pdf"))
  (code-xpdf      "hyperrefpaper"    (ee-hyperrefdocfile "paper.pdf"))
  (code-pdftotext "hyperrefpaper"    (ee-hyperrefdocfile "paper.pdf"))
  (code-xpdf      "hyperrefslides"   (ee-hyperrefdocfile "slides.pdf"))
  (code-pdftotext "hyperrefslides"   (ee-hyperrefdocfile "slides.pdf"))
  )

;; (find-hyperrefreadmepage     1  "Contents")
;; (find-hyperrefreadmepage     7  "Customizing index style file")
;; (find-hyperrefreadmetext "")
;; (find-hyperrefhyperrefpage   1 "Contents")
;; (find-hyperrefhyperrefpage 234 "Index")
;; (find-hyperrefhyperreftext "")
;; (find-hyperrefmanualpage )
;; (find-hyperrefmanualtext "")
;; (find-hyperrefmanualpage 12 "\\href{URL}{text}")
;; (find-hyperrefmanualtext    "\\href{URL}{text}")
;; (find-hyperrefmanualpage 13 "\\hypertarget")
;; (find-hyperrefmanualtext    "\\hypertarget")
;; (find-hyperrefmanualtext "\\phantomsection")
;; (find-hyperrefoptionspage  1)
;; (find-hyperrefoptionstext "")
;; (find-hyperrefpaperpage 1)
;; (find-hyperrefpapertext "")
;; (find-hyperrefslidespage      1  "Contents")
;; (find-hyperrefslidestext "")

# (find-fline "/usr/share/doc/texlive-doc/latex/hyperref/")
# (find-fline "/usr/share/texmf-texlive/tex/latex/hyperref/")

# (find-kopkadaly4page 7 "Contents")
# (find-kopkadaly4page (+ 12 3))
# (find-kopkadaly4page (+ 12 607) "Index")
# (find-kopkadaly4page (+ 12 241) "Options for hyperref")
# (find-kopkadaly4text            "Options for hyperref")
# (find-kopkadaly4page (+ 12 247) "\\href{url}{text}")
# (find-kopkadaly4text            "\\href{url}{text}")

# (find-man "1 xdvi" "small arrow")
# (find-man "1 xdvi" "\nHYPERLINKS\n")
# (find-man "1 xdvi" "htex-back()")

# (find-lsrcfile "hyperref/hyperref.sty" "Implicit mode ON; LaTeX internals redefined")

# (find-LATEXgrep "grep -nH -e hyperref *.tex")
# (find-LATEXfile "2009unilog-dnc.aux")

#*
# (eev-bounded)
cd /tmp/
cat > hyperreftest.tex <<'---'
\documentclass{article}
\usepackage[colorlinks]{hyperref} % (find-es "tex" "hyperref")
\begin{document}
\par This is page 1
\par \hypertarget{anchor-One}{This is anchor-One}
\par \href      {#anchor-Two}{This is a link to anchor-Two}
\newpage
\par This is page 2
\par \hypertarget{anchor-Two}{This is anchor-Two}
\par \href      {#anchor-One}{This is a link to anchor-One}
\end{document}
---
latex hyperreftest.tex && rexdvi hyperreftest.dvi

#*




#####
#
# breakurl
# 2012aug07
#
#####

# «breakurl»  (to ".breakurl")
# (find-sh "locate breakurl")
# (find-fline "/usr/share/doc/texlive-doc/latex/breakurl")
# (find-fline "/usr/share/doc/texlive-doc/latex/breakurl/README")
(code-xpdf      "breakurl" "/usr/share/doc/texlive-doc/latex/breakurl/breakurl.pdf")
(code-pdftotext "breakurl" "/usr/share/doc/texlive-doc/latex/breakurl/breakurl.pdf")
;; (find-breakurlpage      1  "Contents")
;; (find-breakurlpage (+ 1 1) "Index")
;; (find-breakurltext "")



#####
#
# newbox and saving diagrams
# 2003mar21
#
#####

# «newbox»  (to ".newbox")
# Inspired by a (bigger) hint given by Michael Barr
#*
cd /tmp/
cat > test.tex <<'%%%'
\documentclass{book}
\usepackage{xypic}
\begin{document}

\newbox\dnar
\setbox\dnar=\hbox{\raise 5pt\hbox{$ \xy\ar (0,-100) \endxy $}}
\def\downarrow{\mathrel{\copy\dnar}}
\def\downarrow{{\mathrel{\copy\dnar}}}

$$ \pmatrix{a \\ \downarrow \\ c} $$

\end{document}
%%%
latex test.tex && rexdvi test.dvi
#*
cd ~/LATEX/
cat > test.tex <<'%%%'
\documentclass{book}
\input diagxy.tex
\begin{document}

\makeatletter
\newbox\@dnmto
\setbox\@dnmto=\hbox{\raise 5pt\hbox{$\xy \ar(0,-100)\dir{|} \endxy$}}
\def\dnmto{\mathrel{\copy\@dnmto}}
\newbox\@mot
\setbox\@mot=\hbox{$\xy \ar(-100,0)\dir{|} \endxy$}
\def\mot{\mathrel{\copy\@mot}}
\makeatother

$$ \begin{array}{ccc} a & \mot & b \\ \dnmto \\ c \end{array} $$

\end{document}
%%%
latex test.tex && rexdvi test.dvi
#*




####
#
# the '->^\prime bug on old TeTeXes
# 2003may25
#
####

# «prime-bug»  (to ".prime-bug")
%*
\tracingonline=1\nonstopmode
\tracingall
$f'''$
%*
#*
# (find-knuthfile "tex/texbook.tex" "\\hex{8000}")
# (find-knuthfile "tex/texbook.tex" "\\mathcode`\\'=\"8000")
# (find-knuthfile "tex/texbook.tex" "convert |f'''| into")
# (find-knuthfile "tex/texbook.tex" "\\gdef'{^\\bgroup\\prim@s}")
# (find-knuthfile "tex/texbook.tex" "\\let\\bgroup={")
# (find-lsrcfile "base/ltmath.dtx" "\\global\\let'\\active@math@prime")
# (find-lsrcfile "base/fontdef.dtx" "\\mathcode`\\'=\"8000 % ^\\prime")

# It is \active@math@prime that does not exist on the old TeTeX

#*
eev-cd lsrc base
grep 'prim[@e]' *
#*

# (find-lsrcfile "tools/trace.dtx")
# (find-fline "/usr/share/texmf/tex/latex/tools/trace.sty")




####
#
# ignoring parts of a document
# 2003jun14
#
####

# «ignoring»  (to ".ignoring")
# (find-angg "LATEX/2003a.hdr.tex" "ignoring")

\def\ENDIGNORE{}
\long\def\BEGINIGNORE#1\ENDIGNORE{}		% means ignore
\long\def\BEGINIGNORE{}				% means do not ignore

\def\ENDIGNOREAE{}	% for when we want to ignore almost everything
\long\def\BEGINIGNOREAE#1\ENDIGNOREAE{}  	% means ignore
\long\def\BEGINIGNOREAE{}			% means do not ignore

\def\doignore#1#2{\long\def#1##1#2{}}
\def\donotignore#1#2{\def#1{}\def#2{}}
\def\defIFs#1#2#3#4#5{
  \def#1{\donotignore#3#5 \doignore#4#5}
  \def#2{\doignore#3#5 \donotignore#4#5}
}

\defIFs \MINIMALYES      \MINIMALNO
      \IFMINIMAL    \IFNOTMINIMAL      \ENDIFMINIMAL
\defIFs \ALLOWTRASHYES   \ALLOWTRASHNO
      \IFALLOWTRASH \IFNOTALLOWTRASH   \ENDIFALLOWTRASH

\MINIMALYES
\ALLOWTRASHNO




#####
#
# makeindex
# 2003jul04
#
#####

# «makeindex»  (to ".makeindex")
# (find-man "1 makeindex" "SPECIAL EFFECTS")
# (find-lsrcfile "guide/" "Makefile")
# (find-lsrcfile "guide/guide.tex")
# (find-lsrcfile "guide/")
# (find-lsrcfile "lshort/src/spec.tex" "\\section{Indexing}")
# (find-dvipage "/usr/share/doc/texmf/latex/general/lshort.dvi.gz" (+ 14 58))
# (find-lsrcfile "misc/")
# (find-lsrcfile "showlabels/")
#*
rm -Rv /tmp/guide/
mkdir  /tmp/guide/
cd /usr/share/texmf/source/latex/guide/
cp -iv * /tmp/guide/
cd     /tmp/guide/
latex guide
latex guide
makeindex guide
latex guide
# (find-fline "/tmp/guide/" "guide.aux")

#*
# (find-angg ".emacs.papers" "kopkadaly")
# (find-kopkadaly4page 7 "Contents")
# (find-kopkadaly4page (+ 12 228) "9.4.3      Running MakeIndex")
# (find-kopkadaly4text            "9.4.3      Running MakeIndex")
# (find-kopkadaly4page (+ 12 607) "Index")
# (find-kopkadaly4text)


rm -Rv /tmp/mitest/
mkdir  /tmp/mitest/
cd     /tmp/mitest/
cat > mitest.tex <<'----'
\documentclass{article}
\usepackage{makeidx}
\usepackage{showidx}
\usepackage{showlabels}
\makeindex
\begin{document}

\section{sigma}\label{sigma}
aa \index{alpha}
bb \index{alpha!beta}
cc \index{alpha!beta!gamma}

\section{tau}\label{tau}

\printindex
\end{document}
----
latex mitest.tex
latex mitest.tex
makeindex mitest
latex mitest.tex

rexdvi mitest.dvi

#*



#####
#
# \parbox, \makebox, minipage
# 2003jun19
#
#####

# Not yielding results as nice as I would like, but it's ok for now
# (find-node "(latex)\\parbox")
# (find-node "(latex)\\framebox")
%*
% (eelatex-bounded 'once)
\def\blas{bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla
          bla bla bla bla bla bla bla bla}

\par \blas
\par
\framebox{
\begin{minipage}{4in}
  \par \blas
  \par \blas
\end{minipage}
}
\par
\framebox{
\parbox{4in}{
  \par \blas
  \par \blas
  }
}
\par \blas
%*



#####
#
# greek
# 2003aug10
#
#####

# «greek»  (to ".greek")
# (code-c-d "babel" "/usr/share/texmf/source/generic/babel/")
# (find-babelfile "greek.dtx" "Typing conventions")
# (find-efunction 'eelatex)
# (find-angg "LATEX/echotropia.tex")
#*
cd /tmp/
cat > tmp-greek.tex <<'%%%'
\documentclass{book}
\usepackage[brazilian,english,greek]{babel}
\begin{document}

\par\greektext polutoniko
\par\latintext polutoniko

\end{document}
%%%
latex tmp-greek.tex
rexdvi tmp-greek.dvi

#*




#####
#
# ThesisPUC (by Thomas Lewiner)
# 2003dec29
#
#####

# «ThesisPUC»  (to ".ThesisPUC")
# (code-c-d "tpuc" "~/usrc/ThesisPUC/")
# (find-tpucfile "")
#*
rm -Rv ~/usrc/ThesisPUC/
cd ~/usrc/
unzip ~/LATEX/ThesisPUC.zip
cd ~/usrc/ThesisPUC/

rm -v ThesisPUC.pdf

# tomlew's titlesec.sty is 2.5, but woody's is 2.4...
# If we don't remove this then "latex Exple.tex" will complain
rm -v titlesec.sty
#
# How I got the list of files:
#  cd /usr/share/texmf/tex/latex/titlesec/
#  for i in *; do (cd ~/usrc/ThesisPUC; laf $i); done
#
# (find-vldifile "tetex-extra.list" "titlesec")
# (find-fline "/usr/share/texmf/tex/latex/titlesec/")
rm -v block.tss drop.tss frame.tss leftmargin.tss margin.tss rightmargin.tss
rm -v titletoc.sty wrap.tss
#
# But if I remove those I get errors, oops
# (find-vldifile "tetex-src.list" "titlesec")
# rm -v ttlkeys.def ttlps.def

# Tomlew uses the same extramarks.sty as woody but a newer fancyhdr.sty...
# (find-vldifile "tetex-extra.list" "fancyhdr")
# (find-fline "/usr/share/texmf/tex/latex/fancyhdr/")
rm -v extramarks.sty
# rm -v fancyhdr.sty

# These are even in tetex-base, so bye tomlew's
# (find-vldifile "tetex-base.list" "indentfirst.sty")
# (find-vldifile "tetex-base.list" "inputenc.sty")
# (find-vldifile "tetex-base.list" "setspace.sty")
rm -v indentfirst.sty
rm -v inputenc.sty
rm -v setspace.sty

# Tomlew uses a newer subfigure
# (find-tpucfile "")
# (find-tpucfile "subfigure.cfg")
# (find-tpucfile "ltxdoc.cfg")
# (find-fline "/usr/share/texmf/tex/latex/config/ltxdoc.cfg")
# (find-fline "/usr/share/texmf/tex/latex/misc/subfigure.sty")

#*
# Exemplo
# (find-fline "~/usrc/ThesisPUC/")
cd ~/usrc/ThesisPUC/
rm -fv Exple.{aux,dvi,lof,log,lot,toc}
latex Exple.tex
latex Exple.tex
latex Exple.tex
rexdvi Exple.dvi &

#*
# Manual
cd ~/usrc/ThesisPUC/
latex ThesisPUC.tex
latex ThesisPUC.tex
latex ThesisPUC.tex
rexdvi ThesisPUC.dvi &

#*




#####
#
# texdoc
# 2004jan27
#
#####

# «texdoc»  (to ".texdoc")
# (find-man "1 texdoc")
# (find-fline "/usr/bin/texdoc")
# (find-fline "/usr/bin/texdoctk")
# (find-fline "/etc/texdoctk/texdoctk.dat")
#*
texdoc multicol
texdoc lshort
texdoc amssymbols
#*

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
texdoc -l lshort
TEXDOCVIEW_dvi=echo texdoc lshort

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
texdoc showkeys
texdoc
texdoc -l showkeys
texdoc -v -l showkeys

# (find-sh "texdoc showkeys")
# (find-fline "/usr/bin/texdoc")
# How do I run texdoc->xdvi in background?
# This doesn't work...
#   (find-bgprocess "texdoc showkeys")







#####
#
# pdfpages
# 2004feb26
#
#####

# «pdfpages»  (to ".pdfpages")
# (find-es "ps" "pdfpages")
# http://www.mostlymaths.net/2008/09/latex-booklets.html
# http://www.mostlymaths.net/2009/04/easy-paperback-book-binding-how-to.html

;; (find-zsh "dmissing pdfpages")
(code-c-d  "pdfpages" "/usr/share/doc/texlive-latex-recommended-doc/latex/pdfpages/")
(code-xpdf      "pdfpages" (ee-pdfpagesfile "pdfpages.pdf"))
(code-pdftotext "pdfpages" (ee-pdfpagesfile "pdfpages.pdf"))
;; (find-pdfpagesfile "")
;; (find-pdfpagespage  1  "Contents")
;; (find-pdfpagestext "")

#*
cd /tmp/
cat > p.tex <<'%%%'
\documentclass[oneside]{book}
\usepackage{pdfpages}
\begin{document}
\includepdf[pages={1,3}]{ThesisPUC.pdf}
\end{document}
%%%
pdflatex p.tex

#*
function pdfpages () {
  echo -E '\documentclass[oneside]{book}
    \usepackage{pdfpages}
    \begin{document}
    \includepdf[pages={'$2'}]{'$1'}
    \end{document}
  ' > $3.tex
  pdflatex $3.tex
}

#*
rm -Rv /tmp/pdfpages/
mkdir  /tmp/pdfpages/
cd     /tmp/pdfpages/
cp ~/LATEX/dout/ThesisPUC/ThesisPUC.pdf .
pdfpages ThesisPUC.pdf 1,3-4 selection1
gv selection1.pdf

#*
rm -Rv /tmp/puc-parts/
mkdir  /tmp/puc-parts/
cd     /tmp/puc-parts/
cp ~/LATEX/puc.pdf .

function pdfpages () {
  echo -E '\documentclass[oneside]{book}
    \usepackage{pdfpages}
    \begin{document}
    \includepdf[pages={'$2'}]{'$1'}
    \end{document}
  ' > $3.tex
  pdflatex $3.tex
}

pdfpages puc.pdf  1-11 9916982_2003_pretextual
pdfpages puc.pdf 12-15 9916982_2003_cap_0
pdfpages puc.pdf 16-33 9916982_2003_cap_1
pdfpages puc.pdf 34-51 9916982_2003_cap_2
pdfpages puc.pdf 52-67 9916982_2003_cap_3
pdfpages puc.pdf 68-69 9916982_2003_postextual

#*
cd /tmp/puc-parts/
for i in 9916982*pdf; do gv $i; done

#*




####
#
# ite
# 2004mar15
#
####

# «ite»  (to ".ite")
# (code-c-d "ite" "~/usrc/ite_3/")
# (code-c-d "ite" "$HOME/usrc/ite_3/")
# (find-itefile "")
# (find-itefile "lisp/")

# Needs shell=bash
#*
rm -Rv ~/usrc/ite_3/
tar -xvzf $S/http/www.ctan.org/tex-archive/support/ite/ite_3.tar.Z -C ~/usrc/
cd ~/usrc/ite_3/
cp -v ite.conf ite.conf.orig
# (find-itefile "ite.conf")

find * -type f | sort > .files

patch -p0 ite.conf <<'%%%'
17c17,18
< home-path "~/iTe/development"
---
> #home-path "~/iTe/development"
> home-path "~/usrc/ite_3"
40,41c41,42
< #gs-options "-sDEVICE=x11"
< gs-options ""
---
> gs-options "-sDEVICE=x11"
> #gs-options ""
%%%

cd ~/usrc/ite_3/test/
# export TEXINPUTS=~/usrc/ite_3/tex:
. compile |& tee oc

#*
# (find-itew3m "doc/index.html")
# (find-itew3m "doc/manual.html")
# (find-itew3m "doc/installation.html")
# (find-itew3m "doc/bindings.html")
# (find-itefile "test/")

(progn
  (require 'tex-site)
  (code-c-d "ite" "$HOME/usrc/ite_3/")
  (add-to-list 'load-path (ee-itefile "lisp"))
  (setq ite-config-files (list (ee-itefile "ite.conf")))
  (load-library "~/usrc/ite_3/lisp/ite.el")
  )

(find-itefile "test/basic.tex")
(find-itefile "test/")

#*
  ;; (autoload 'ite "ite" "...interactive TeX editor..." t)
  ;; (debug-on-entry 'ite-start-process)
#*

cd ~/usrc/ite_3/
grep 'Processing block' $(<.files)
grep 'iTe_PerlFinished' $(<.files)
grep 'Starting ' $(<.files)
grep 'iTe_GhostScriptStarted' $(<.files)
grep 'not found' $(<.files)
grep 'iTe log' $(<.files)

#*
# (find-itefile "rsc/ite.pl")
# (find-itefile "rsc/ite.pl" "Processing block")
# (find-itefile "rsc/ite.pl" "iTe_PerlFinished")
# (find-itefile "lisp/ite.el")
# (find-itefile "lisp/ite.el" "iTe_PerlFinished")
# (find-itefile "lisp/ite.el" "Starting %s with %s")

# (find-itefile "lisp/ite.el" "iTe_GhostScriptStarted")
# (find-itefile "lisp/ite.el" "-c /iTe_GhostScriptStarted == flush")

# (find-itefile "lisp/ite.el")

# (find-status "auctex")
# (find-vldifile "auctex.list")
# (find-fline "/usr/doc/auctex/")





####
#
# PS fonts
# 2004mar29
#
####

# «psfonts»  (to ".psfonts")
# (find-lsrcfile "psnfss.extra/OT1pzc.fd")
# (find-lsrcfile "psnfss.extra/T1pzc.fd")
# (find-fline  "/usr/share/doc/texmf/fontinst/base/")
# (find-dvipage "/usr/share/doc/texmf/fontinst/base/fontinst.dvi.gz" 1)
# (find-fline  "/usr/share/texmf/tex/fontinst/base/")
# (find-man "1 fontinst")

# (find-fline "/usr/share/texmf/source/latex/psnfss.extra/OT1pzc.fd")
# (find-fline "/usr/share/texmf/source/latex/psnfss.extra/T1pzc.fd")

# (find-w3m "/usr/share/doc/texmf/help/Catalogue/entries/psfonts.html")

# (find-fline "/etc/texmf/dvips/psfonts.map")
# (find-fline "/etc/texmf/dvipsj/psfonts.map")
# (find-fline "/usr/share/texmf/dvi2ps/fontsk/")
# (find-fline "/usr/share/texmf/dvips/base/psfonts.map")
# (find-fline "/usr/share/texmf/dvips/bluesky/")
# (find-fline "/usr/share/texmf/dvipsj/base/psfonts.map")
# (find-fline "/usr/share/texmf/source/latex/psnfss/psfonts.dtx")
# (find-fline "/usr/share/texmf/source/latex/psnfss/psfonts.ins")
# (find-fline "/usr/share/ttf2pt1/app/netscape/psfonts.cf")

# (find-fline "/usr/share/texmf/fontname/")

cd /usr/share/texmf/
du -c tex fontname source

cd /usr/share/texmf/
find tex fontname source -type f | l -S

cd /usr/share/texmf/
find tex fontname source -type f \
  | xargs -s 64000 \
    grep installfonts

cd /usr/share/texmf/; find tex source -type f | sort | xargs -s 64000 \
  grep DeclareFontFamily
cd /usr/share/texmf/; find tex source -type f | sort | xargs -s 64000 \
  grep DeclareFontShape

# (find-lsrcfile "base/ltfssbas.dtx" "\\def\\DeclareFontFamily#1#2#3")
# (find-lsrcfile "base/ltfsscmp.dtx" "DeclareFontFamily")
# (find-fline "/usr/share/texmf/tex/latex/base/latex.ltx" "DeclareFontFamily")

# (find-lsrcfile "base/ltfssbas.dtx" "\\def\\DeclareFontShape{")
# (find-lsrcfile "base/ltfssbas.dtx" "\\def\\DeclareFontShape@#1#2#3#4#5#6")
# (find-fline "/usr/share/texmf/tex/latex/base/latex.ltx" "DeclareFontShape")
# (find-fline "/usr/share/texmf/tex/latex/base/latex.ltx" "DeclareFontShape@")

# (find-fline "/usr/share/texmf/tex/fontinst/base/xfntinst.sty" "\\def\\latinfamily")
# (find-fline "/usr/share/texmf/tex/fontinst/base/fontinst.sty" "\\def\\latinfamily")

/usr/share/texmf/tex/
/usr/share/texmf/source/




#####
#
# pstricks
# 2001oct23
#
#####

# «pstricks-old»  (to ".pstricks-old")
# (find-status "tetex-extra")
# (find-vldifile "tetex-extra.list")
# (find-fline "/usr/doc/tetex-extra/")
# (find-fline "/usr/share/texmf/tex/generic/pstricks/")

# (find-status "tetex-src")
# (find-vldifile "tetex-src.list")
# (find-fline "/usr/doc/tetex-src/")
# (find-fline "/usr/share/texmf/source/generic/pstricks/")

# (find-status "tetex-doc")
# (find-vldifile "tetex-doc.list")
# (find-fline "/usr/doc/tetex-doc/")
# (find-fline "/usr/doc/texmf/generic/pstricks/")
# (find-fline "/usr/doc/texmf/generic/pstricks/obsolete/")

# (code-c-d "pstdoc" "/usr/doc/texmf/generic/pstricks/")
# (find-pstdocfile "")
# 
# VI: Text Tricks (find-pspage (ee-pstdocfile "obsolete/pst-usr3.ps.gz") 52)
#*
cd /usr/doc/texmf/generic/pstricks/
for i in *dvi*; do xdvi $i; done
#*
cd /usr/doc/texmf/generic/pstricks/obsolete/
for i in *.ps*; do gv $i; done
#*


gv /usr/share/doc/texmf/generic/pstricks/doc-fill.ps.gz &
gv /usr/share/doc/texmf/generic/pstricks/obsolete/betadoc1.ps.gz &
gv /usr/share/doc/texmf/generic/pstricks/obsolete/betadoc2.ps.gz &
gv /usr/share/doc/texmf/generic/pstricks/obsolete/pst-quik.ps.gz &
gv /usr/share/doc/texmf/generic/pstricks/obsolete/pst-usr1.ps.gz &
gv /usr/share/doc/texmf/generic/pstricks/obsolete/pst-usr2.ps.gz &
gv /usr/share/doc/texmf/generic/pstricks/obsolete/pst-usr3.ps.gz &
gv /usr/share/doc/texmf/generic/pstricks/obsolete/pst-usr4.ps.gz &

# (code-c-d "pst" "/usr/src/pstricks/")

rm -Rv /usr/src/pstricks
cd /usr/src/
cp -dipvR $SCTAN/graphics/pstricks.tar.gz

cd /usr/src/pstricks

cd /usr/src/pstricks/src.old/
# (find-pstfile "src.old/pst-user.tex")
# (find-pstfile "src.old/pst-user.sty")
cp -iv /usr/lib/texmf/texmf/tex/latex/base/article.sty art12.sty

# (find-pstfile "src.old/pst-user.sty")
# (find-pstfile "src.old/art12.sty")
# (find-pstfile "src.old/npsfont.sty")
# (find-pstfile "src.old/pst-user.sty" 93)
# (find-pstfile "src.old/pst-user.log")

cd /usr/src/pstricks/origdoc/
# Logotipos do Denis Girou; só dá pra ver com o gv.
tex denis1.tex
dvips -o denis1.ps denis1.dvi
gv denis1.ps

tex denis2.tex
dvips -o denis2.ps denis2.dvi
gv denis2.ps

latex samples.tex
dvips -o samples.ps samples.dvi
gv samples.ps

rm -Rv $CTAN/graphics/pstricks/
cd $CTAN/graphics/
tar -xvzf pstricks.tar.gz
gzip -dv $(find pstricks -name '*.gz')

cd $CTAN/graphics/pstricks/origdoc/

# (find-pstfile "src.old/pst-user.tex")
# (find-pstfile "src.old/pst-user.sty" 199)
# (find-pstfile "src.old/pstricks.doc")
# (find-pstfile "src.old/pst-make.tex")
# (find-pstfile "src.old/pst-code.tex")

# (find-fline "~/PS/pst1.tex")

# (find-lsrcfile "base/doc.dtx" "abstract")
# (find-lsrcfile "base/doc.dtx" "produce the documentation")
# (find-lsrcfile "base/ltxdoc.dtx" 82)
# (find-fline "/usr/lib/texmf/texmf/tex/latex/base/doc.sty")




####
#
# pstricks
# 2004mar26
#
####

% «pstricks»  (to ".pstricks")
% (find-eevnewfile "tmp-pst.tex")
% (setq eelatex-eevscript "cd ~/eev-0.94/; latex tmp-pst.tex && dvips -o tmp-pst.ps tmp-pst.dvi && regv tmp-pst.ps &")

#*
# (eev-bounded)
cat > ~/eev-0.94/tmp-pst.tex
\documentclass{book}
\usepackage {pstcol,pst-text}
\usepackage {lscape}
\begin{document}
\input ee.tex
\end{document}
%%%

#*

%*
% (eelatex-bounded)
%
% \usepackage {pstcol,pst-text}
\definecolor{pink}{rgb}{1, .75, .8}

\begin{pspicture}(-3,-2.2)(3,2.2)
  \psset{linestyle=none}
  % \newcommand{\curly}[1]{{\fontfamily{pzc}%
  %   \fontsize{17}{17}\itshape#1}}
  \def\curly#1{{\fontfamily{pzc}\fontsize{17}{17}#1}}
  \def\curly#1{{\fontfamily{pzc}\fontsize{17}{17}\itshape#1}}
  \pstextpath[c]{\psarcn(0,0){2}{180}{0}}
  {\curly{The Unseen University}}
\end{pspicture}

%*
% (eelatex-bounded)

\begingroup
\fontfamily{pzc}\fontsize{60}{60}\itshape

Hello

Bye

\endgroup

%*
% (eelatex-bounded)

\begin{landscape}
\begingroup
\fontfamily{pzc}\fontsize{60}{60}\itshape

\centerline{Hello}

\centerline{Bye}

\endgroup
\end{landscape}

%*




#####
#
# cartão pra Cláudia
# 2004jul07
#
#####

# «cartao-claudia»  (to ".cartao-claudia")
%*
% (eelatex-bounded)

\def\newpage{\vfill\break}

\def\HWID{65mm}        % largura do cartão
\def\VMRG{12mm}        % \vspace's acima e abaixo do texto num cartão 
\def\HSEP{-3.8pt}      % usado num \hspace pra fazer os cartões grudarem
\def\VSEP{-1.5pt}      % usado num \vspace pra fazer os cartões grudarem

\def\cartao{
  \framebox{\parbox{\HWID}{
    \vspace{\VMRG}
    \centerline{\bf Aulas de Italiano}
    \centerline{   Cláudia O'Connor    }
    \centerline{ 8118-2034 / 2508-5184 }
    \vspace{\VMRG}
}}}
\def\cartaocartao{\centerline{\cartao\hspace{\HSEP}\cartao}}
\def\novalinha{\par\vspace{\VSEP}}

\cartaocartao\novalinha
\cartaocartao\novalinha
\cartaocartao\novalinha
\cartaocartao\novalinha
\cartaocartao

%*
#*
# (eev-bounded)
cd /tmp/
dvips -D 600 -o cartao-claudia.ps ~/eev-0.94/tmp.dvi
dvipdf ~/eev-0.94/tmp.dvi cartao-claudia.pdf

#*
cd /tmp/
Scp cartao-claudia.ps cartao-claudia.pdf edrx@${SUCURI}:public_html/tmp/
Scp cartao-claudia.ps cartao-claudia.pdf edrx@${SUCURI}:slow_html/tmp/
#
# http://www.mat.puc-rio.br/~edrx/tmp/cartao-claudia.ps
# http://www.mat.puc-rio.br/~edrx/tmp/cartao-claudia.pdf

#*




#####
#
# including png screenshots
# 2005apr14
#
#####

# «png_screenshots»  (to ".png_screenshots")
% What's the right scale to use?
%
% A png of, say, 590x400 pngpx ("png pixels") is by default converted
% to an image of size 590x400 pt (points, those that are 1/72 in), but
% I want to convert that a size in which each pngpx takes an integer
% number or pdots ("printer dots"), considering a 600dpi printer...
%
% The base case is making each pngpx take exactly one pdot: that is
% done by
%
%   \includegraphics[scale=0.12]{convertedpng.eps}
%
% (really - nice number, heh? (/ 72 600.0) = 0.12
#*
mkdir /tmp/pngtex/
cd    /tmp/pngtex/
cp /tmp/ss-lua-2.png foo.png

#*
# (find-sh "cd /tmp/pngtex/; file foo.png")
# 590 x 400
# (find-fline "$EEVTMPDIR/tmp.tex")
# (find-eevtmpfile "tmp.tex")

%*
% (eelatex-bounded)

   $\backslash$includegraphics[scale=0.60]\{/tmp/ss-lua-2.eps\}:
\par\noindent \includegraphics[scale=0.12]{/tmp/ss-lua-2.eps}
\par          \includegraphics[scale=0.60]{/tmp/ss-lua-2.eps}
\vfill

%*
! LaTeX Error: Cannot determine size of graphic in /tmp/ss-lua-2.png (no BoundingBox).

# (find-sh "pngcrush -h")
# (find-sh "pngcrush -h" "convert color to grayscale")
# (find-sh "pngcrush -h" "delete an unwanted alpha channel")
# (find-sh "pngcrush -h" "0 means try all of 1-10")
# (find-man "convert")
# (find-man "ImageMagick")
# (find-man "ImageMagick" "-density <width>x<height>")




#####
#
# Typesetting CVs using LaTeX
# 2005feb19
#
#####

# «cv-packages»  (to ".cv-packages")

#         http://www.ctan.org/tex-archive/macros/latex/contrib/cv/
#          ftp://ftp.dante.de/tex-archive/macros/latex/contrib/cv.tar.gz

# http://www.ctan.org/tex-archive/macros/latex/contrib/cv/
#  ftp://ftp.dante.de/tex-archive/macros/latex/contrib/cv.tar.gz
# http://www.ctan.org/tex-archive/macros/latex/contrib/curve/
#  ftp://ftp.dante.de/tex-archive/macros/latex/contrib/curve.tar.gz
# http://www.ctan.org/tex-archive/macros/latex/contrib/currvita/
#  ftp://ftp.dante.de/tex-archive/macros/latex/contrib/currvita.tar.gz

mkdir -p $S/http/www.ctan.org/tex-archive/macros/latex/contrib/
tar   -C $S/http/www.ctan.org/tex-archive/macros/latex/contrib/ \
   -xvzf  $S/ftp/ftp.dante.de/tex-archive/macros/latex/contrib/cv.tar.gz
cd       $S/http/www.ctan.org/tex-archive/macros/latex/contrib/cv/

mkdir -p $S/http/www.ctan.org/tex-archive/macros/latex/contrib/
tar   -C $S/http/www.ctan.org/tex-archive/macros/latex/contrib/ \
   -xvzf  $S/ftp/ftp.dante.de/tex-archive/macros/latex/contrib/curve.tar.gz
cd       $S/http/www.ctan.org/tex-archive/macros/latex/contrib/curve/

mkdir -p $S/http/www.ctan.org/tex-archive/macros/latex/contrib/
tar   -C $S/http/www.ctan.org/tex-archive/macros/latex/contrib/ \
   -xvzf  $S/ftp/ftp.dante.de/tex-archive/macros/latex/contrib/currvita.tar.gz
cd       $S/http/www.ctan.org/tex-archive/macros/latex/contrib/currvita/

ftp://ftp.dante.de/tex-archive/macros/latex/contrib/cv.tar.gz
http://www.ctan.org/tex-archive/macros/latex/contrib/cv/

#*
# «cv»  (to ".cv")
# (code-c-d "cv" "/tmp/cv/" :xdvi)
rm -Rv /tmp/cv/
cd /tmp/
tar -xvzf $S/ftp/ftp.dante.de/tex-archive/macros/latex/contrib/cv.tar.gz
cd /tmp/cv/
latex CVCTAN.tex
xdvi  CVCTAN.dvi &

#*
# «currvita»  (to ".currvita")
# (code-c-d "currvita" "/tmp/currvita/" :xdvi)
# (find-currvitaxdvi "cvtest.dvi")
# (find-currvitaxdvi "currvita.dvi")
rm -Rv /tmp/currvita/
cd     /tmp/
tar -xvzf $S/ftp/ftp.dante.de/tex-archive/macros/latex/contrib/currvita.tar.gz
cd /tmp/currvita/
latex currvita.ins
latex currvita.dtx
latex currvita.dtx
latex currvita.dtx
latex cvtest.tex

# (find-currvitafile "")
# (find-currvitafile "cvtest.tex")

#*
# (find-fline "/tmp/currvita/")
# (find-fline "/tmp/cv/")

# (eebg-xdvi "/tmp/currvita/cvtest.dvi")
# (eebg-xdvi "/tmp/currvita/currvita.dvi")
# (eebg-xdvi "/tmp/cv/CVCTAN.dvi")

#*
# «currvitaedrx»  (to ".currvitaedrx")
# (code-c-d "currvitaedrx" "~/CURRICULO/currvita/")
# (find-currvitaedrxfile "")
# (find-currvitaedrxfile "cvtest.tex")

cd ~/CURRICULO/currvita/
tar -xvzf $S/ftp/ftp.dante.de/tex-archive/macros/latex/contrib/currvita.tar.gz
mv -v currvita/* .
rmdir currvita/

# (find-anggfile "CURRICULO/curric-edrx-jan2005.txt")

#*




#####
#
# TEXINPUTS
# 2006jul19
#
#####

# «TEXINPUTS»  (to ".TEXINPUTS")
# (find-node "(kpathsea)Variable expansion")
# (find-node "(kpathsea)Path sources")
# (find-node "(kpathsea)Default expansion")
# (find-node "(kpathsea)Supported file formats" "`tex'")
# (find-fline "/etc/texmf/texmf.cnf" "% TEXINPUTS ")
# (find-fline "/etc/texmf/texmf.d/")
# (find-fline "/etc/texmf/texmf.d/45TeXinputs.cnf")
# (find-fline "/etc/texmf/texmf.d/45TeXinputs.cnf")

# (find-fline "/etc/texmf/texmf.cnf")
# (find-fline "/usr/share/tetex-bin/texmf.cnf")
# (find-fline "/usr/share/texmf/web2c/texmf.cnf")
# (find-sh "locate texmf.cnf")
# (find-zsh "dmissing texmf.cnf")




#####
#
# dvipng
# 2006oct11
#
#####

# «dvipng»  (to ".dvipng")
# http://trac.lunatic-bumblebee.com/trac/browser/emacs-blog/trunk/emacs-blog-latex.el
# (find-status   "dvipng")
# (find-vldifile "dvipng.list")
# (find-udfile   "dvipng/")
# (find-node "(dvipng)")
# (find-node "(dvipng)Basic usage")
# (find-node "(dvipng)Option details")
# (find-node "(dvipng)Index")
# (find-sh "dvipng --help")




#####
#
# TeTeX and TeXLive
# 2007nov19
#
#####

# «tetex-and-texlive»  (to ".tetex-and-texlive")
# "TeTeX has been abandoned upstream, TeX Live..."
# http://lists.debian.org/debian-devel-announce/2007/04/msg00006.html

# http://www.tug.org/texlive/doc.html
# http://www.tug.org/texlive/doc/texlive-en/live.html#x1-6500010




#####
#
# fontdimen parameters for the typewriter fonts
# 2007nov24
#
#####

# «fontdimen»  (to ".fontdimen")
# (find-texbookpage 400)
# (find-texbooktext)
# (find-texbooktext "special \\fontdimen parameters")
# (find-texbooktext "\\fontdimen16\\tensy=2.7pt")
# (find-texbooktext " 22 \\fontdimen param")
# (find-texbooktext "5    x height")
# (find-texbooktext "1   slant per pt")

# (find-angg ".emacs.papers" "hatcher")
# http://www.math.cornell.edu/~hatcher/AT/typography.html
#   \fontdimen16\textfont2=2.5pt

# (find-sh "locate plain.tex")
# (code-c-d "plaintex" "/usr/share/texmf-tetex/tex/plain/")
# (find-plaintexfile "")
# (find-plaintexfile "base/plain.tex" "\\font\\tentt=cmtt10 % typewriter")

# (find-es "tex" "kpathsea")
# (find-sh  "kpsewhich --help")
# (find-sh0 "kpsewhich cmr10.mf")




#####
#
# quote, quotation, verse
# 2008feb10
#
#####

# «quote»  (to ".quote")
# «quotation»  (to ".quotation")
# «verse»  (to ".verse")

%*
% (eedn4-51-bounded)
% (find-kopkadaly4page (+ 12 67) "4.2.3   Two-sided indentation")
% (find-kopkadaly4text           "4.2.3   Two-sided indentation")
% (find-lsrcfile "base/article.cls" "\\newenvironment{quotation}")
% (find-kopkadaly4text "\\list \\do {cmds}")
% (find-kopkadaly4text "\\listparindent")

\noindent
A section of text may be displayed by indenting it by an equal amount
on both sides, with the environments

\begin{quote}
\begin{verbatim}
\begin{quote}      text  \end{quote}
\begin{quotation}  text  \end{quotation}
\end{verbatim}

  Additional vertical spacing is inserted above and below the
  displayed text to separate it visually from the normal text.

  The text to be displayed may be of any length; it can be part of a
  sentence, a whole paragraph, or several paragraphs.

  Paragraphs are separated as usual with an empty line, although no
  empty lines are needed at the beginning and end of the displayed
  text since additional vertical spacing is inserted here anyway.

\end{quote}

The difference between the above two forms is thus:

\begin{quotation}

    In the \verb|quotation| environment, paragraphs are marked by
  extra indentation of the first line, whereas in the \verb|quote|
  environment, they are indicated with more vertical spacing between
  them.

    The present text is produced within the \verb|quotation|
  environment, while the sample above was done with the \verb|quote|
  environment.

    The \verb|quotation| environment is only really meaningful when
  the regular text makes use of first-line indentation to show off new
  paragraphs.

\end{quotation}

\noindent
For indenting rhymes, poetry, verses, etc.\ on both sides, the
environment

\begin{verbatim}
\begin{verse}   text  \end{verse}
\end{verbatim}

\noindent
is more appropriate.

\begin{verse}
  Stanzas as separated by blank lines \\
  while the individual lines of the stanza are divided by \verb|\\|.

  If a line is too long for the reduced text width, it will be left
    and right justified and continued on the next line, which is
    indented even further.
\end{verse}

%*




#####
#
# Running TeX and showing defs
# 2008feb10
#
#####

# «running-TeX-show»  (to ".running-TeX-show")
# (find-texbookpage (+ 11 23) "Running TeX")
# (find-texbookpage (+ 11 31) "the machine will soon stop")
# (find-texbookfile "texbook.tex" "the machine will soon stop")
# (find-texbooktext               "the machine will soon stop")

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
cd /tmp/
latex
\makeatletter
\blop
?
H
I\show\smash
I\show\begin
I\show\on@line
I\show\newenvironment
I\show\new@environment
I\show\verse

% (find-source2efile "")
% (find-source2egrep "grep -nH -e quotation *")
% (find-source2egrep "grep -nH -e verse *")
% (find-source2efile "classes.dtx" "\\begin{environment}{verse}")
% (find-source2efile "classes.dtx" "\\begin{environment}{quotation}")
% (find-source2efile "classes.dtx" "\\begin{environment}{quote}")

% (find-source2efile "")
% (find-source2egrep "grep -nH -e newenvironment *")
% (find-source2efile "ltdefns.dtx" "\\begin{macro}{\\newenvironment}")




#####
#
# tesemestr
# 2008mar04
#
#####

# «tesemestr»  (to ".tesemestr")
# (find-angg ".emacs.papers" "tesemestr")
# http://angg.twu.net/math/tesemestr-texsrc.tar.gz
# http://angg.twu.net/math/tesemestr-dvi.tar.gz
# http://angg.twu.net/math/tesemestr.ps.gz
# http://angg.twu.net/math/tesemestr.pdf
# http://angg.twu.net/math/slidesmestr-texsrc.tar.gz
# http://angg.twu.net/math/2000uff-texsrc.tar.gz
# http://angg.twu.net/math/
#*
rm -Rv ~/usrc/tesemestr/
mkdir  ~/usrc/tesemestr/
cd     ~/usrc/tesemestr/
tar -C ~/usrc/tesemestr/ -xvzf \
  $S/http/angg.twu.net/math/tesemestr-texsrc.tar.gz

mkdir  ~/usrc/tesemestr/slides/
cd     ~/usrc/tesemestr/slides/
tar -C ~/usrc/tesemestr/slides/ -xvzf \
  $S/http/angg.twu.net/math/slidesmestr-texsrc.tar.gz

mkdir  ~/usrc/tesemestr/uff/
cd     ~/usrc/tesemestr/uff/
tar -C ~/usrc/tesemestr/uff/ -xvzf \
  $S/http/angg.twu.net/math/2000uff-texsrc.tar.gz

#*
# (code-c-d "tesemestr" "~/usrc/tesemestr/")
# (find-tesemestrfile "")
# (find-tesemestrfile "tesemestr.tex" "\\cpoQuatro cbad")
# (find-tesemestrfile "edrx.sty" "\\def\\cpoQuatro")
# (find-tesemestrpage 83)
# (code-c-d "slidesmestr" "~/usrc/tesemestr/slides/")
# (find-slidesmestrfile "")




#####
#
# framebox
# 2008mar04
#
#####

# «framebox»  (to ".framebox")
# «dags»  (to ".dags")
# (find-dn4ex "edrx08.sty" "dags")
# (find-node "(latex)\\framebox")
# (find-source2egrep "grep -nH -e framebox *")
# (find-source2efile "ltboxes.dtx" "\\DescribeMacro\\framebox")
# (find-kopkadaly4page (+ 12 635) "Index" "picture")
# (find-kopkadaly4page (+ 12 288))
# (find-kopkadaly4page (+ 12 301))
%*
% (eedn4a-bounded)

Bla \framebox{foo} bar

\def\dagThree#1#2#3{{\unitlength=.1ex
  \begin{picture}(13,24)
    \put(0,12){\scriptsize #1}    % top left
    \put(12,12){\scriptsize #2}   % top right
    \put(6,0){\scriptsize #3}     % bottom
  \end{picture}
  }}
\def\dagFive#1#2#3#4#5{{\unitlength=.1ex
  \begin{picture}(13,48)
    \put(6,36){\scriptsize $#1$}    % top
    \put(0,24){\scriptsize $#2$}    % second line, left
    \put(12,24){\scriptsize #3}   % second line, right
    \put(6,12){\scriptsize #4}    % third line
    \put(6,0){\scriptsize #5}     % bottom
  \end{picture}
  }}
\def\lowerDagFiveBy{1.2ex}
\def\dagFive#1#2#3#4#5{\lower\lowerDagFiveBy\hbox{\unitlength=.1ex
  \begin{picture}(13,48)
    \put(6,36){\scriptsize #1}    % top
    \put(0,24){\scriptsize #2}    % second line, left
    \put(12,24){\scriptsize #3}   % second line, right
    \put(6,12){\scriptsize #4}    % third line
    \put(6,0){\scriptsize #5}     % bottom
  \end{picture}
  }}

% Foo:\framebox{\dagThree 123}:bar:\dagThree 123:plic
% 
% Foo:\framebox{\dagFive 12345}:bar:\dagFive 12345:plic
% 
% Foo:\framebox{\dagFive 12345}:bar:\dagFive 12345:plic

\edrxcolors
\def\bhbox{\bicolorhbox}
\def\Bhbox{}

Foo: a\bhbox{\dagThree 234}b\bhbox{\dagFive 23456}c

Foo: a\bhbox{\dagThree 234}b\bhbox{\dagFive 23456}c

Foo: a\Bhbox{\dagThree 234}b\Bhbox{\dagFive 23456}c

Foo: a\Bhbox{\dagThree 234}b\Bhbox{\dagFive 23456}c

Foo: a\Bhbox{\dagThree 234}b\bhbox{\dagFive {\,$·$}3456}c


Foo: \bhbox{\scriptsize 9} \bhbox{\scriptsize $9{·}8$} \bhbox{\scriptsize $·$}bar

{
\def·{{\,$\cdot$}}
\def·{0}
$\{a, \dagFive23456, b\}$

$\left\{a, \dagFive23456, b\right\}$

\def\lowerFiveBy{1.6ex}
$\left\{\dagFive23456, \dagFive01011\right\}$

$\{\dagFive23456, \dagFive01011\}$
}


%*



#####
#
# figures, listings, captions
# 2008mar12
#
#####

# «figure-and-caption»  (to ".figure-and-caption")
# (find-source2egrep "grep -nH -e caption *")
# (find-source2egrep "grep -nH -e listing *")
# (find-source2efile "classes.dtx" "\\begin{macro}{\\@makecaption}")
# (find-source2efile "ltfloat.dtx" "\\begin{macro}{\\caption}")
# (find-source2efile "ltfloat.dtx" "\\fnum@TYPE")
# (find-tesemestrfile "edrx.sty" "\\def\\epsscale")




#####
#
# miniforth.bib
# 2008mar12
#
#####

# «miniforth.bib»  (to ".miniforth.bib")
# (find-miniforthfile "")
# (find-miniforthfile "miniforth.bib")
# (find-miniforthfile "citing.tex")
# http://bibdesk.sourceforge.net/
#*
rm -Rv /tmp/bib/
mkdir  /tmp/bib/
cd     /tmp/bib/
cp -v ~/miniforth/miniforth.bib .
cp -v ~/miniforth/citing.tex .

latex citing ; bibtex citing ; latex citing ; latex citing

#*
# (find-fline   "/tmp/bib/")
# (find-dvipage "/tmp/bib/citing.dvi")




#####
#
# Magnification in TeX and LaTeX
# 2008apr03
#
#####

# «magnification-in-tex»  (to ".magnification-in-tex")
# (find-2000ufffile "2000uff.tex")
# (find-2000ufffile "2000uff.tex" "\\large")
# (find-texbookpage (+ 11 403) "\\magnification")
# (find-texbookpage (+ 11 349) "\\magstep")
# (find-texbookpage (+ 11 59) "\\magnification")
# (find-texbookfile "")
# (find-texbookfile "texbook.tex" "^|\\magnification||=\\magstep2|")

# «magnification-in-latex»  (to ".magnification-in-latex")
# http://www.elec.ucl.ac.be/logistique/informatique/Digests/TeX/1992/texhax.21




#####
#
# dvi2dvi
# 2008apr03
#
#####

# «dvi2dvi»  (to ".dvi2dvi")
# «savebox»  (to ".savebox")
# (find-kopkadaly4page (+ 12  87) "\\newsavebox{\\boxname}")
# (find-kopkadaly4text            "\\newsavebox{\\boxname}")
# (find-man "dvi2dvi")
# (find-sh "dvi2dvi")
# (find-sh "cd ~/LATEX/ && dvi2dvi -m 5 < tmp.dvi > /tmp/tmp2.dvi")
# (find-zsh "cd ~/LATEX/ && strace-to ~/s dvi2dvi -m 5 < tmp.dvi > /tmp/tmp2.dvi")
# (find-fline "~/s")
# (find-sh "dvi2dvi -h")
# (find-dvipage "/tmp/tmp2.dvi")
# (find-sh "xdvi /tmp/tmp2.dvi")
# (find-dvipage "~/tmp/tmp2.dvi")

%*
% (eedn4-51-bounded)
% (find-node "(latex)Spaces & Boxes")
% (find-angg "LATEX/tmp.dnt")

\thispagestyle{empty}

%D diagram demo
%D 2Dx    100      +25
%D 2D 100 a0 <==== a1
%D 2D	   -        -
%D 2D	   |  <-->  |
%D 2D	   v	    v
%D 2D +25 a2 ====> a3
%D 2D
%D (( a0 .tex= a,b a1 .tex= a
%D    a2 .tex=  c  a3 .tex= b|->c
%D    @ 0 @ 1 <= @ 0 @ 2 |-> @ 1 @ 3 |-> @ 2 @ 3 =>
%D    @ 0 @ 3 harrownodes nil 20 nil <->
%D ))
%D enddiagram

$\diag{demo}$

\newsavebox{\diagabc}
\savebox{\diagabc}{\bf Foo}

ab \usebox{\diagabc} cd \usebox{\diagabc} ef

\savebox{\diagabc}{$\diag{demo}$}

ab \usebox{\diagabc} cd \usebox{\diagabc} ef

%*

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
cd /tmp/
dvifonts tmp2.dvi
dvifonts ~/LATEX/tmp.dvi



#####
#
# indentfirst
# 2008apr07
#
#####

# «indentfirst»  (to ".indentfirst")
# (find-sh "locate indentfirst")
# (find-w3m "/usr/share/doc/tetex-doc/help/Catalogue/entries/indentfirst.html")
# (find-dvipage "/usr/share/doc/tetex-doc/latex/tools/indentfirst.dvi")
# (find-fline "/usr/share/texmf-tetex/source/latex/tools/indentfirst.dtx")
# (find-fline "/usr/share/texmf-tetex/tex/latex/tools/indentfirst.sty")




#####
#
# understanding \begin{verbatim}
# 2008apr15
#
#####

# «verbatim»  (to ".verbatim")
# (find-source2efile "")
# (find-source2efile "ltmiscen.dtx" "\\subsection{Verbatim}")
# (find-source2efile "ltmiscen.dtx" "\\subsection{Verbatim}" "missing item")
# (find-source2efile "ltmiscen.dtx" "\\gdef\\@vobeyspaces")
# (find-source2egrep "grep -nH -e obeyspaces *")
# (find-source2egrep "grep -nH -e makeother *")

# (find-texbookfile "")
# (find-texbookgrep "grep -nH -e obeyspaces *")
# (find-texbookgrep "grep -nH -e obeylines *")

# (find-fline "/usr/share/texmf-tetex/tex/plain/verbatim/verbatim.tex")
# (find-plainsrcfile "")
# (find-plainsrcfile "plain.tex" "\\def\\obeyspaces")
# (find-plainsrcfile "plain.tex" "\\gdef\\obeylines")
# (find-plainsrcfile "plain.tex" "\\let\\endgraf=\\par \\let\\endline=\\cr\n")

\def\par{\leavevmode\endgraf}

* (eepitch-latex)
* (eepitch-kill)
* (eepitch-latex)
\tracingonline=1
\makeatletter
\show\verbatim
i\show\endverbatim
i\show\endtrivlist
i\show\@verbatim
i\show\frenchspacing
i\show\sfcode
i\show\@vobeyspaces
i\show\@xverbatim
i\show\verb
i\show\dospecials
i\show\@makeother
i\show\obeylines
i\show\obeyspaces
i\show\space

%*
% (eedn4a-bounded)

plic {\tt bar} ploc

plic \begingroup bar \tt poo \endgroup foo

plic \begingroup\def*{\endgroup} foo \tt poo * bar


\makeatletter
\def\makespecialsother{\let\do\@makeother\dospecials}
\makeatother
\let\softpar=\par
\def\hardpar{\softpar\leavevmode}
\def\myobeylines{\let\par=\hardpar\obeylines}
\def\mysetverbatim{\makespecialsother\myobeylines\obeyspaces}
\def\mystarverbatim{\begingroup\def*{\endgroup}\tt\mysetverbatim}

a\mystarverbatim
foo bar
  plic  ploc
 tt tt plic
%@~\\{}*bar

\setbox0=\vtop{
a\mystarverbatim
foo bar
  plic  ploc
 tt tt plic
%@~\\{}*bar}

\leavevmode\copy0\copy0

\fbox{\copy0}

\bhbox{\copy0}

\fbox{\vbox{a b c}}

\fbox{\hbox{a b c}}

%*




#####
#
# verbatim.dtx
# 2009aug18
#
#####

# «verbatim.dtx»  (to ".verbatim.dtx")
# (find-zsh "dmissing verbatim")
# (find-zsh "dmissing verbatim | grep tex ")
# (find-zsh "dmissing verbatim.pdf")
# (find-fline "/usr/share/texmf-texlive/tex/generic/genmisc/verbatim.tex")
# (find-fline "/usr/share/texmf-texlive/tex/latex/tools/verbatim.sty")
# (code-xpdf      "verbatim" "/usr/share/doc/texlive-latex-base-doc/latex/tools/verbatim.pdf")
# (code-pdftotext "verbatim" "/usr/share/doc/texlive-latex-base-doc/latex/tools/verbatim.pdf")
# (find-verbatimpage 4 "boxed text")
# (find-verbatimtext   "boxed text")

# The .dtx is in the "tools" bundle: (to "tools")




#####
#
# verbatimbox
# 2009aug18
#
#####

# «verbatimbox»  (to ".verbatimbox")
# «verbbox»  (to ".verbbox")
# (find-dn4exfile "edrx08.sty" "verbatimbox")
# http://tug.ctan.org/pkg/verbatimbox
# http://tug.ctan.org/get/macros/latex/contrib/verbatimbox.zip
# (find-sh0 "cp -v ~/usrc/verbatimbox/verbatimbox.sty ~/LATEX/")
# (find-sh0 "rm -v                                    ~/LATEX/verbatimbox.sty")
#*
rm -Rv   ~/usrc/verbatimbox/
unzip -d ~/usrc/ \
  $S/http/tug.ctan.org/get/macros/latex/contrib/verbatimbox.zip
cd       ~/usrc/verbatimbox/

#*
# (code-c-d "verbatimbox" "~/usrc/verbatimbox/")
# (find-verbatimboxfile "")
# (find-verbatimboxfile "verbatimbox_example.tex")
# (find-verbatimboxfile "verbatimbox.sty")
# (find-fline "~/usrc/verbatimbox/")

%*
% (eedn4a-bounded)
% (find-sh0 "cd ~/LATEX/ && dvips  -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-sh0 "cd ~/LATEX/ && dvired -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-pspage "~/LATEX/tmp.ps")

\begin{verbbox}
      Program test
      implicit none
      integer a, x
      a = 0
      x = 1
   10 a = a + x
      if (a .eq. 100) stop
      goto 10
      end
\end{verbbox}

\begin{tabular}{| c | c | c |}
\hline
First box of table &
\begin{tabular}{@{} c @{}} \theverbbox[t]\end{tabular} &
last box of table \\
\hline
\end{tabular}

%*
;; (find-kopkadaly4page (+ 12 86) "fbox")
;; (find-kopkadaly4page (+ 12 94) "\\ovalbox")
;; (find-kopkadaly4page (+ 12 607) "Index")
;; (find-kopkadaly4page (+ 12 620) "fbox")
;; (find-kopkadaly4text)




#####
#
# boxedminipage
# 2009aug18
#
#####

# «boxedminipage»  (to ".boxedminipage")
# http://ctan.org/pkg/boxedminipage

% (find-angg ".emacs.papers" "kopkadaly")
% (find-kopkadaly4page         7  "Contents")
% (find-kopkadaly4page (+ 12  88) "4.7.3   Parboxes and minipages")
% (find-kopkadaly4text            "4.7.3   Parboxes and minipages")
% (find-kopkadaly4page (+ 12  90) "4.7.5   Paragraph boxes of speci" "c height")
% (find-kopkadaly4text            "4.7.5   Paragraph boxes of speci" "c height")
% (find-kopkadaly4text            "Finally, vertical boxes such as")
% (find-kopkadaly4page (+ 12 607) "Index")
% (find-kopkadaly4text)

# How to mix the boxy verbatims with my ttchars?
# (find-dn4ex "edrx08.sty" "ttchars")

* (eepitch-latex)
* (eepitch-kill)
* (eepitch-latex)
\tracingonline=1\scrollmode
\show\setbox
\show\begin


%*
% (eedn4a-bounded)
% (find-sh0 "cd ~/LATEX/ && dvips  -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-sh0 "cd ~/LATEX/ && dvired -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-pspage "~/LATEX/tmp.ps")

A b c d:
\begin{minipage}[c]{2cm}
a b c d e f g
\par a b c d e f g

\noindent a b c d e f

a a a a a a a a a a a a a a a a a a a a a a
\end{minipage}
bar.

\savebox{\myboxa}{%
\begin{minipage}[c]{2cm}
a b c d e f g
\par a b c d e f g

\noindent a b c d e f

a a a a a a a a a a a a a a a a a a a a a a
\end{minipage}%
}

Boo: \usebox{\myboxa} woo: \usebox{\myboxa} plink.


%*
% (eedn4a-bounded)
% (find-sh0 "cd ~/LATEX/ && dvips  -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-sh0 "cd ~/LATEX/ && dvired -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-pspage "~/LATEX/tmp.ps")

\setbox0=\hbox{%
\begin{minipage}[c]{2cm}
\par \verb|a = 123|
\par \verb|b = 234|
\par a b c d e f g

\noindent a b c d e f

a a a a a a a a a a a a a a a a a a a a a a
\end{minipage}%
}
\savebox{\myboxa}{\copy0}

Boo: \fbox{\usebox{\myboxa}} woo: \usebox{\myboxa} plink.

%*

% «smini»  (to ".smini")
% (defun smini () (interactive) (insert "\\setbox0=\\hbox{%\n\\begin{minipage}[c]{2cm}\n\\end{minipage}%\n}\n\\savebox{\\myboxa}{\\copy0}\n"))










#####
#
# The source for the "tools" package
# 2009aug18
#
#####

# «tools»  (to ".tools")
# http://www.ctan.org/tex-archive/help/Catalogue/entries/tools.html
# http://tug.ctan.org/get/macros/latex/required/tools.zip
#*
rm -Rv   ~/usrc/tools/
unzip -d ~/usrc/ \
  $S/http/tug.ctan.org/get/macros/latex/required/tools.zip
cd       ~/usrc/tools/

#*
# (code-c-d "latextools" "~/usrc/tools/")
# (find-latextoolsfile "")
# (find-latextoolsfile "verbatim.dtx")
#
# (code-xpdf      "verbatim" "~/usrc/tools/verbatim.pdf")
# (code-pdftotext "verbatim" "~/usrc/tools/verbatim.pdf")
# (find-verbatimpage      5  "\\def\\verbatimboxed")
# (find-verbatimtext         "\\def\\verbatimboxed")
# (find-verbatimpage      5  "\\def\\verbatimwrite")
# (find-verbatimtext         "\\def\\verbatimwrite")
# (find-verbatimpage      1  "Contents")
# (find-verbatimpage (+ 1 1) "Index")
# (find-verbatimtext "")




#####
#
# smallmatrix
# 2008apr26
#
#####

# «smallmatrix»  (to ".smallmatrix")
# (find-dn4exfile "edrx08.sty")
# (find-amslmathgrep "grep -nH -e smallmatrix *")
# (find-amslmathfile "")
# (find-amsldocpage 1)
# (find-amsldoctext)
# (find-amsldocpage (+ 4 11) "smallmatrix")
# (find-amsldoctext          "smallmatrix")
# (find-amslmathfile "amsmath.dtx" "\\begin{environment}{smallmatrix}")




#####
#
# inputenc
# 2008may06
#
#####

# «inputenc»  (to ".inputenc")
# (find-dn4exfile "edrx08.sty")
# (find-dn4exfile "edrxmain41.tex" "\\usepackage[latin1]{inputenc}")
# (find-sh "locate inputenc")
# (find-sh "locate latin1.def")
# (find-dvipage "/usr/share/doc/tetex-doc/latex/base/inputenc.dvi.gz")
# (find-fline   "/usr/share/texmf-tetex/source/latex/base/inputenc.dtx")
# (find-fline   "/usr/share/texmf-tetex/tex/latex/base/latin1.def")




#####
#
# weaving tex.web
# 2008may09
#
#####

# «weaving-tex.web»  (to ".weaving-tex.web")
# http://www.ctan.org/get/systems/knuth/dist/tex/tex.web
# (find-es "tex" "weaving")
#*
rm -Rv ~/usrc/tex/
mkdir  ~/usrc/tex/
cd     ~/usrc/tex/
cp -v $S/http/www.ctan.org/get/systems/knuth/dist/tex/tex.web .
weave tex.web
tex   tex.tex
dvipdf tex.dvi

#*
(code-c-d "texwebsrc" "~/usrc/tex/")
(code-dvi       "texwebsrc" (ee-texwebsrcfile "tex.dvi"))
(code-pdftotext "texwebsrc" (ee-texwebsrcfile "tex.pdf"))
;; (find-texwebsrcfile "")
;; (find-texwebsrcpage 1)
;; (find-texwebsrcpage (+ -2 482))
;; (find-texwebsrctext)
;; (find-texwebsrctext "define show box")
;; (find-texwebsrcpage (+ -2 453))




#####
#
# tetex-doc/latex/general
# 2008may09
#
#####

# «latex-general»  (to ".latex-general")
# (find-status   "tetex-doc")
# (find-vldifile "tetex-doc.list")
# (find-udfile   "tetex-doc/")
# (find-fline "/usr/share/doc/tetex-doc/latex/general/")
#*
rm -Rv /tmp/general/
mkdir  /tmp/general/
cd     /tmp/general/
cp -v /usr/share/doc/tetex-doc/latex/general/* .
cp -v /usr/share/doc/tetex-doc/plain/impatient/impatient.dvi.gz .
gunzip -v *.gz

#*
# (find-sh "ls /tmp/general/*")
# (find-pspage  "/tmp/general/a.ps")
# (find-dvipage "/tmp/general/guide.dvi")
# (find-pspage  "/tmp/general/guide.ps")
# (find-pspage  "/tmp/general/l2kurz.pdf")
# (find-pspage  "/tmp/general/l2tabu.pdf")
# (find-pspage  "/tmp/general/l2tabuen.pdf")
# (find-dvipage "/tmp/general/latex2e.dvi")
# (find-pspage  "/tmp/general/lshort.pdf")
# (find-dvipage "/tmp/general/symbols.dvi")
# (find-dvipage "/tmp/general/symbols.dvi")
# (find-dvipage "/tmp/general/impatient.dvi")
# (find-dvipage "/usr/share/doc/tetex-doc/plain/impatient/impatient.dvi.gz")

(code-ps        "lshort" "/tmp/general/lshort.pdf")
(code-pdftotext "lshort" "/tmp/general/lshort.pdf")
;; (find-lshortpage 1)
;; (find-lshorttext)




#####
#
# \leavevmode
# 2008may17
#
#####

# «leavevmode»  (to ".leavevmode")
# (find-texbytopictext "\nHorizontal and Vertical Mode")
# (find-texbytopictext "The horizontal commands are the following:")
# (find-texbytopictext "\\def\\leavevmode{\\unhbox\\voidb@x}")
# (find-lsrcgrep "grep -nH -e leavevmode base/*")
# (find-lsrcfile "base/ltplain.dtx" "\\def\\leavevmode")
# (find-texbookpage (+ 11 313) "\\leavevmode is an abbreviation for")
# (find-texbooktext            "\\leavevmode is an abbreviation for")





#####
#
# texbytopic.dvi
# 2008may20
#
#####

# «texbytopic»  (to ".texbytopic")
# (find-angg ".emacs.papers" "texbytopic")
# ftp://tug.ctan.org/pub/tex-archive/info/texbytopic/
# (eev "psner-ftp ftp://tug.ctan.org/pub/tex-archive/info/texbytopic/")
#*
rm -Rv ~/usrc/texbytopic/
mkdir  ~/usrc/texbytopic/
cd     ~/usrc/texbytopic/

cd $S/ftp/tug.ctan.org/pub/tex-archive/info/texbytopic/
cp -v README TeXbyTopic.tex figflow.tex glossary.tex tables.tex tex.bib \
       ~/usrc/texbytopic/
cd     ~/usrc/texbytopic/

# "ol" will contain 18000 lines of warnings like this:
#   Package hyperref Warning: Token not allowed in a PDFDocEncoded string,
#   (hyperref)                removing `\\' on input line 786.
latex TeXbyTopic.tex > ol
latex TeXbyTopic.tex > ol2
latex TeXbyTopic.tex > ol3

#*
# (code-c-d "texbytopic" "~/usrc/texbytopic/")
# (code-dvi "texbytopicdvi" (ee-texbytopicfile "TeXbyTopic.dvi"))
# (find-texbytopicfile "")
# (find-texbytopicfile "ol")
# The dvi version seem to be identical to the pdf...
# (find-texbytopicdvipage 1)
# (find-texbytopicpage  1)




#####
#
# color
# 2008may21
#
#####

# «color»  (to ".color")
# (find-lsrcfile "graphics/color.dtx")
# (find-lsrcfile "graphics/color.sty")

# (find-fline "/usr/share/texmf-tetex/tex/latex/graphics/color.sty")
# (find-zsh "dmissing grfguide")
# (find-zsh "dmissing color.sty")
# (code-xpdf      "grfguide" "/usr/share/doc/texlive-latex-base-doc/latex/graphics/grfguide.pdf")
# (code-pdftotext "grfguide" "/usr/share/doc/texlive-latex-base-doc/latex/graphics/grfguide.pdf")
# (find-grfguidepage      1  "Contents")
# (find-grfguidetext "")

# (find-grfguidepage 4)

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
cd /tmp/

cat > test.tex <<'%%%'
\documentclass[oneside]{book}
\usepackage{color}
\begin{document}
Hello {\color{red}world}.
\end{document}
%%%

latex test.tex
rexdvi test.dvi

# «xcolor»  (to ".xcolor")
# (find-status   "latex-xcolor")
# (find-vldifile "latex-xcolor.list")
# (find-udfile   "latex-xcolor/")
# (find-sh0 "zcat /usr/share/doc/texmf/latex-xcolor/xcolor.pdf.gz > /tmp/xcolor.pdf")
(code-xpdf      "latexxcolor" "/tmp/xcolor.pdf")
(code-pdftotext "latexxcolor" "/tmp/xcolor.pdf")
# (find-latexxcolorpage 1)
# (find-latexxcolorpage 31)
# (find-latexxcolorpage 39 "x11names")
# (find-latexxcolortext)
# (find-latexxcolortext "4.4   Colors via x11names option")






#####
#
# bicolorhbox
# 2008jun09
#
#####

# «bicolorhbox»  (to ".bicolorhbox")
# (find-dn4ex "edrx08.sty" "colors")
%*
% (eedn4a-bounded)
% (find-es "color")
\definecolor{orange}{rgb}{1,.64,0}
\def\red   #1{{\color{red}#1}}
\def\orange#1{{\color{orange}#1}}
\def\yellow#1{{\color{yellow}#1}}
\def\smashedvrule#1#2#3{\vrule width#1 height#2 depth#3 \kern-#1}
\def\bicolorhbox#1{%
  \setbox0\hbox{#1}%
  \yellow{\smashedvrule{\wd0}{\ht0}{0pt}}%
  \orange{\smashedvrule{\wd0}{0pt}{\dp0}}%
  \box0%
  }

Foobar\bicolorhbox{plic}ploc

Foobarplicploc

%*
% (eedn4a-bounded)
\edrxcolors
\def\bhbox{\bicolorhbox}

Foobar\bhbox{plic}ploc

Foobarplicploc

%*

% (find-dn4ex "edrx08.sty" "colors")
% (find-lsrcfile "graphics/color.dtx")

* (eepitch-latex)
* (eepitch-kill)
* (eepitch-latex)
\tracingonline=1\scrollmode
\documentclass{article}
\usepackage{color}
\begin{document}
\def\red#1{{\color{red}#1}}
a\red{b}c
\end{document}

# (find-sh "dvitype -output-level=1 /tmp/texput.dvi")
# (find-man "dvitype")
# (find-node "(web2c)dvitype invocation")







#####
#
# \protect
# 2008may24
#
#####

# «protect»  (to ".protect")
# (find-angg ".emacs" "source2e")
# (find-lsrcgrep "grep -nH -e \\protect base/*.dtx")
# (find-lsrcgrep "grep -nH -e \\\\protect base/*.dtx")
# (find-lsrcfile "base/makeindx.dtx" "\\def\\protect")

* (eepitch-latex)
* (eepitch-kill)
* (eepitch-latex)
\interact
I\show\protect

# (find-source2epage (+ 9 528))
# (find-source2epage (+ 9 35))
# (find-source2efile "ltdefns.dtx" "Fragile and robust commands")





#####
#
# psnfss (for Avant Garde and Utopia)
# 2008may26
#
#####

# «psnfss-avant-garde»  (to ".psnfss-avant-garde")
# (find-sh "locate times.sty")
# (find-fline "/usr/share/texmf-tetex/tex/cslatex/ntimes.sty")
# (find-fline "/usr/share/texmf-tetex/tex/latex/dvilj/cgtimes.sty")
# (find-fline "/usr/share/texmf-tetex/tex/latex/psnfss/times.sty")
# (find-fline "/usr/share/texmf-tetex/tex/latex/qfonts/qtimes.sty")

# (find-sh "locate psfonts.dtx")
# (find-fline "/usr/share/texmf-tetex/source/latex/psnfss/psfonts.dtx")
# (find-sh "locate /psfonts")
# (find-fline "/usr/share/texmf-tetex/source/latex/psnfss/")

# (find-sh "locate /psnfss")
# (code-c-d "psnfssdoc" "/usr/share/doc/texlive-latex-base-doc/latex/psnfss/")

;; (find-psnfssdocfile "")
;; (find-psnfssdocfile "psnfss/")
;; (find-psnfssdocfile "test/test0.tex.gz")
;; (find-psnfssdocfile "test/test1.tex")
;; (find-psnfssdocfile "test/test2.tex")
(code-xpdf      "psnfss" (ee-psnfssdocfile "psnfss2e.pdf"))
(code-pdftotext "psnfss" (ee-psnfssdocfile "psnfss2e.pdf"))
;; (find-psnfsspage 1)
;; (find-psnfsspage 10 "Typeface examples")
;; (find-psnfsstext)
;; (find-psnfsstext "9.4 The package utopia\n")

# (find-sh "locate utopia")
# (find-fline "/usr/share/texmf-tetex/source/latex/psnfss/utopia.map")
# (find-fline "/usr/share/texmf-tetex/source/latex/psnfss/utopia.sty")
# (find-fline "/usr/share/texmf-tetex/tex/latex/psnfss/utopia.sty")
# (find-sh "locate /avant")

%*
% (eedn4a-bounded)

\large

{\rm Rmoo}

% Broken:
% (find-lsrcfile "psnfss/utopia.sty")
% \renewcommand{\rmdefault}{put}
% {\rm Rmutopia}

{\bf Bfoo}

{\sl Sloo}

{\sf Sfoo}

% (find-fline "/usr/share/texmf-tetex/tex/latex/psnfss/avant.sty")
\renewcommand{\sfdefault}{pag}

{\sf Sfoo}

{\sf RRJ 4}

{\sf Rimbaud 0}

%*
% (find-zsh "cd ~/LATEX/; dvifonts tmp.dvi")
# (find-fline "locate pagk")




#####
#
# ovals
# 2008may26
#
#####

# «ovals»  (to ".ovals")
# (find-kopkadaly4page (+ 12 288) "13.1   The picture environment")
# (find-kopkadaly4text            "13.1   The picture environment")
# (find-kopkadaly4page (+ 12 296) "\\oval(x dimen,y dimen)[part]")
# (find-kopkadaly4text            "\\oval(x dimen,y dimen)[part]")
# (find-kopkadaly4page (+ 12 301) "13.1.6 Shifting a picture environment")
# (find-kopkadaly4text            "13.1.6 Shifting a picture environment")
%*
% (eedn4a-bounded)

\begingroup

\def\n #1 #2 #3 {\put(#1,#2){\makebox(0,0){$\bullet$}}}
\def\n #1 #2 #3 {\put(#1,#2){\makebox(0,0){#3}}}
\def\o #1 #2 #3 #4 {\put(#1,#2){\oval(#3,#4)}}
\def\d #1 #2 #3 {\put(#1,#2){\vector(0,-1){#3}}}

\setlength{\unitlength}{0.9pt}

\begin{picture}(100,100)
  \n 10 10 1
  \n 20 10 2
  \n 20 20 3
  \o 30 30 15 10
\end{picture}

\begin{picture}(100,100)
  \n 20 80 10
  \n 22 65 11
  \n 21 50 12
  \o 21 65 32 55
  %
  \n 60 62 20
  \o 60 62 20 20
  %
  \n 95 70 31
  \n 95 54 32
  \o 95 62 28 42
  %
  \n 21 12 1
  \n 60 12 2
  \n 95 12 3
  \o 58 12 105 28
  %
  \d 21 36 8
  \d 60 50 22
  \d 95 39 11
\end{picture}

\endgroup

%*




#####
#
# xfig
# 2008may26
#
#####

# «xfig»  (to ".xfig")
# (find-status   "xfig-doc")
# (find-vldifile "xfig-doc.list")
# (find-udfile   "xfig-doc/")
# (find-status   "xfig-libs")
# (find-vldifile "xfig-libs.list")
# (find-udfile   "xfig-libs/")
# (find-status   "xfig")
# (find-vldifile "xfig.list")
# (find-udfile   "xfig/")
# (find-status   "transfig")
# (find-vldifile "transfig.list")
# (find-udfile   "transfig/")
# (find-man "1 fig2dev")
# (find-man "1 fig2dev" "EPIC is an enhancement to LaTeX picture")
# (find-man "1 transfig")

# (find-man "1 xfig")
# (find-xfigdocw3m "contents.html")




#####
#
# Xfig file format (for ".fig"s)
# 2008aug08
#
#####

# «xfig-file-format»  (to ".xfig-file-format")
# (find-xfigdocw3m "contents.html")
# (find-xfigdocw3m "fig-format.html")
# (find-xfigdocw3m "fig-format.html" "The character #")
# (find-xfigdocw3m "fig-format.html" "(3.7) TEXT")
# (find-xfigrefpage 29 "comments")
# (find-xfigreftext    "comments")
# (find-xfigrefpage 43 "edit Fig comments")
# (find-xfigreftext    "edit Fig comments")
# (find-xfigrefw3m "editing.html#edit")
# (find-fline "/tmp/foo.fig")
# (find-bgprocess "xfig /tmp/foo.fig")

#*
cat > /tmp/foo.fig <<'%%%'
#FIG 3.2  Produced by xfig version 3.2.5-alpha5
Landscape
Center
Metric
A4      
100.00
Single
-2
1200 2

# (find-xfigdocw3m "fig-format.html" "(3.5) POLYLINE")
2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 2
	 1080 1710 2160 2115

# (find-xfigdocw3m "fig-format.html" "(3.7) TEXT")
4 0 0 50 -1 0 12 0.0000 4 150 960 900 1260 a b "c" \\foo\001
4 0 0 50 -1 0 12 0.0000 4 150 285 900 1515 bar\001
%%%

#*




#####
#
# eepic
# 2008aug08
#
#####

# «eepic»  (to ".eepic")
# (find-es "tex" "picture_mode")
# (find-zsh "dmissing eepic")
# (find-dvipage "/usr/share/doc/tetex-doc/latex/eepic/eepic.dvi.gz")
# (find-fline "/usr/share/doc/tetex-doc/latex/eepic/epic-eg3.fig")
# (find-fline "/usr/share/doc/tetex-doc/latex/eepic/epic-eg3.tex")
# (find-fline "/usr/share/doc/tetex-doc/latex/eepic/epic-eg4.fig")
# (find-fline "/usr/share/doc/tetex-doc/latex/eepic/epic-eg4.tex")
# (find-fline "/usr/share/doc/tetex-doc/latex/eepic/readme.gz")




#####
#
# tac.cls
# 2008may26
#
#####

# «tac.cls»  (to ".tac.cls")
# http://tac.mta.ca/tac/style/
# http://tac.mta.ca/tac/style/sample.dvi
# http://tac.mta.ca/tac/style/sample.tex
# http://tac.mta.ca/tac/style/styhint.txt
# http://tac.mta.ca/tac/style/tac.cls
#*
rm -Rv ~/usrc/tac-cls/
mkdir  ~/usrc/tac-cls/
cd     ~/usrc/tac-cls/

cp -v $S/http/tac.mta.ca/tac/style/sample.tex .
cp -v $S/http/tac.mta.ca/tac/style/tac.cls .
cp -v ~/LATEX/diagxy.tex .

latex sample.tex

#*
# (find-dvipage "~/usrc/tac-cls/sample.dvi")
# (find-sh0 "rm -v ~/LATEX/tac.cls")
# (find-sh0 "cp -v $S/http/tac.mta.ca/tac/style/tac.cls ~/LATEX/")




#####
#
# demobox
# 2008jun09
#
#####

# «demobox»  (to ".demobox")
%*
% (eedn4a-bounded)
% (find-texbookpage (+ 11 65))
% (find-texbookfile "texbook.tex")
% (find-texbookfile "texbook.tex" "\\demobox{A line of type.}")
% (find-texbookfile "texbook.tex" "exercise Construct a |\\demobox| macro")
% (find-texbookfile "texbook.tex" "\\demobox{Two lines}")

\def\dolist{\afterassignment\dodolist\let\next= }
\def\dodolist{\ifx\next\endlist \let\next\relax
  \else \\\let\next\dolist \fi
  \next}
\def\endlist{\endlist}
\def\hidehrule#1#2{\kern-#1%
  \hrule height#1 depth#2 \kern-#2 }
\def\hidevrule#1#2{\kern-#1{\dimen0=#1
    \advance\dimen0 by#2\vrule width\dimen0}\kern-#2 }
\def\makeblankbox#1#2{\hbox{\lower\dp0\vbox{\hidehrule{#1}{#2}%
    \kern-#1 % overlap the rules at the corners
    \hbox to \wd0{\hidevrule{#1}{#2}%
      \raise\ht0\vbox to #1{}% set the vrule height
      \lower\dp0\vtop to #1{}% set the vrule depth
      \hfil\hidevrule{#2}{#1}}%
    \kern-#1\hidehrule{#2}{#1}}}}
\def\maketypebox{\makeblankbox{0pt}{1pt}}
\def\makelightbox{\makeblankbox{.2pt}{.2pt}}
\def\\{\if\space\next\ % assume that \next is unexpandable
 \else \setbox0=\hbox{\next}\maketypebox\fi}
\def\demobox#1{\setbox0=\hbox{\dolist#1\endlist}%
  \leavevmode\copy0\kern-\wd0\makelightbox}

\setbox0=\vbox{\hbox{\demobox{Two lines}}\hbox{\demobox{of type.}}}
$\vcenter{\hbox{\makelightbox\kern-\wd0\box0}}$\qquad
  i.e.,\qquad$\vcenter{\vbox{\hbox{Two lines}\hbox{of type.}}}$

\hbox{\setbox0=\vbox{\hbox{\demobox{Two lines}}\hbox{\demobox{of type.}}}
      \makelightbox\kern-\wd0\box0}

%*




#####
#
# \matrix
# 2008jun18
#
#####

# «matrix»  (to ".matrix")
# (find-texbookpage (+ 11 177))
# (find-texbookfile "texbook.tex" "\\bordermatrix")
# (find-plainsrcfile "plain.tex" "\\def\\bordermatrix")
# (find-plainsrcfile "plain.tex" "\\def\\matrix")
# (find-plainsrcfile "plain.tex" "\\def\\ialign")




#####
#
# math atoms and math lists
# 2008jun20
#
#####

# «math-atoms»  (to ".math-atoms")

# (find-texbooktext)
# (find-texbookfile "")
# (find-texbookfile "texbook.tex")

# (find-texbookpage (+ 11 158) "thirteen kinds of atoms")
# (find-texbookpage (+ 11 170) "spacing between pairs of adjacent atoms")
# (find-texbooktext "thirteen kinds of atoms")
# (find-texbooktext "spacing" "between pairs of adjacent atoms")
# (find-texbookfile "texbook.tex" "thirteen kinds of atoms")
# (find-texbookfile "texbook.tex" "spacing between pairs of adjacent atoms")





#####
#
# lshort
# 2008jun24
#
#####

# «lshort»  (to ".lshort")
# (find-angg ".emacs.papers" "lshort")
# http://www.ctan.org/get/info/lshort/english/lshort-4.24.src.tar.gz
#*
rm -Rv ~/usrc/lshort-4.24/
tar -C ~/usrc/ -xvzf \
  $S/http/www.ctan.org/get/info/lshort/english/lshort-4.24.src.tar.gz
cd     ~/usrc/lshort-4.24/

make |& tee om

#*
rm -Rv ~/usrc/lshort/
mkdir  ~/usrc/lshort/
cd /usr/share/texmf-tetex/source/latex/lshort-4.14/ &&
  cp -Rv * ~/usrc/lshort/
mkdir ~/usrc/lshort/src/
cd    ~/usrc/lshort/src/
cp -v $S/http/www.ctan.org/tex-archive/fonts/euro/latex/eurosans/eurosans.sty .
cd ~/usrc/lshort/
cp -v $S/http/www.ctan.org/tex-archive/fonts/euro/latex/eurosans/eurosans.sty .
make |& tee om

#*
# (code-c-d "lshort" "~/usrc/lshort/")
# (find-lshortfile "")
# (find-lshortfile "om")
# /usr/share/doc/tetex-doc/help/Catalogue/entries/eurosans.html
# http://www.ctan.org/tex-archive/fonts/euro/latex/eurosans/
# http://www.ctan.org/tex-archive/fonts/euro/latex/eurosans/eurosans.sty
# http://www.ctan.org/tex-archive/fonts/euro/latex/eurosans/README.eurosans
# (code-c-d "lshort" "~/usrc/lshort-4.24/")
# (find-lshortfile "")




#####
#
# left quote and double hat
# 2008jun27
#
#####

# «left-quote-double-hat»  (to ".left-quote-double-hat")
# (find-texbookfile "texbook.tex" "^{left quote}")
# (find-texbookpage (+ 11 44)       "left quote")
# (find-texbooktext                "(left quote),")
# (find-texbookfile "texbook.tex" "double hat")
# (find-texbookpage (+ 11 45)     "double hat")
# (find-texbooktext               "double hat")
# Confusing... some things here don't work. 8-|
# What are the contexts in which "`^^J" becomes "10"?

# (find-texbookfile "texbook.tex" "control sequences that are expanded")
# (find-texbookpage (+ 11 212)    "control sequences that are expanded")
# (find-texbooktext               "control sequences that are expanded")
# (find-texbookfile "texbook.tex" "The powerful |\\the| operation")
# (find-texbookpage (+ 11 214)    "The powerful |\\the| operation")
# (find-texbooktext               "The powerful \\the operation")
# (find-texbookfile "texbook.tex" "^\\<integer parameter> is one of")
# (find-texbookpage (+ 11 272)    "integer parameter is one of")
# (find-texbooktext               "integer parameter is one of")

* (eepitch-tex)
* (eepitch-kill)
* (eepitch-tex)
\tracingonline=1\scrollmode
\message{`^^J}
\message{`a}
\newlinechar=32
\message{\the\newlinechar}
\newlinechar=`^^J
\message{\the\newlinechar}
\message{\newlinechar}




#####
#
# \message and \newlinechar
# 2008jun27
#
#####

# «message»  (to ".message")
# «newlinechar»  (to ".newlinechar")
# (find-texbookfile "texbook.tex" "to the ^{terminal}")
# (find-texbookfile "texbook.tex" "The \\<token list> of a |\\write|")
# TeX breaks messages at 79 chars; it resets the counter when
# a \newlinechar is found. \newlinechar is -1 by default.
# Trick:
#   \myspace := (char 32)_(catcode 12)
#   \mynl    := (char 10)_(catcode 12)
#   \newlinechar := 10
# and \msg{...} is like \message{...}, but
# inside msg's argument we define \s:=\myspace and \n:=\mynl.

* (eepitch-tex)
* (eepitch-kill)
* (eepitch-tex)
\tracingonline=1\scrollmode
%
{\catcode` =12\gdef\myspace{ }}
{\catcode`^^J=12\gdef\mynl{^^J}}
\def\msg#1{{\def\s{\myspace}\def\n{\mynl}\message{#1}}}
\newlinechar=`^^J
%
\def\digs{1234567890}
\def\twenty{\digs\digs}
\def\sixty{\digs\digs\digs\digs\digs\digs}
%
\message{\twenty\sixty}
\message{\twenty\mynl\sixty\twenty}
\msg{\twenty\n\sixty\twenty}
\msg{\twenty\s \s \s\sixty}
\msg{\digs\digs\n\sixty\s \s \s \sixty}
%
\newlinechar=-1
\message{\twenty\mynl\sixty\twenty}
\newlinechar=`^^J
\message{\twenty\mynl\sixty\twenty}





#####
#
# debugging diagxy
# 2008jun27
#
#####

# «debugging-diagxy»  (to ".debugging-diagxy")
# Objective: make "\morphism" print the diagxy command
# instead of running it.
# (find-LATEXfile "diagxy.tex")
# (find-LATEXsh "grep POS diagxy.tex")

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
cat ~/LATEX/diagxy.tex |
  lua51 -e 'io.write((io.read("*a"):gsub("\\POS","\\NEWPOS")))' > \
  /tmp/newdiagxy.tex

# (find-tkdiff "~/LATEX/diagxy.tex" "/tmp/newdiagxy.tex")

* (eepitch-latex)
* (eepitch-kill)
* (eepitch-latex)
\tracingonline=1\scrollmode
\input /home/edrx/LATEX/diagxy.tex
\documentclass{article}
\begin{document}
$\bfig
  \morphism(225,0)/->/<-225,-300>[{a}`{b};{}]
  \morphism(225,0)/->/<225,-300>[{a}`{c};{}]
  \morphism(0,-300)/->/<0,-300>[{b}`{d};{}]
 \efig
$
\end{document}

% (find-dvipage "/tmp/texput.dvi")


* (eepitch-latex)
* (eepitch-kill)
* (eepitch-latex)
\tracingonline=1\scrollmode
%\input /home/edrx/LATEX/diagxy.tex
\input /tmp/newdiagxy.tex
\def\NEWPOS{\POS}
\documentclass{article}
\begin{document}
$\bfig
  \morphism(225,0)/->/<-225,-300>[{a}`{b};{}]
  \morphism(225,0)/->/<225,-300>[{a}`{c};{}]
  \morphism(0,-300)/->/<0,-300>[{b}`{d};{}]
 \efig
$
\end{document}

% (find-xdvi "/tmp/texput.dvi")


% (find-LATEXfile "diagxy.tex")
%  \POS(#1,#2)*+!!<0ex,\axis>{#7}\ar#4^-{#9} (\xend,\yend)*+!!<0ex,\axis>{#8}%
   \POS(.1,.2)*+!!<0ex,.axis>{.7}.ar.4^-{.9} (.xend,.yend)*+!!<0ex,.axis>{.8}%
\def\MSGPOS#1<#2>#3<#4>#5{%
  \message{#1<#2>#3<#4>#5}%
  }



* (eepitch-latex)
* (eepitch-kill)
* (eepitch-latex)
\tracingonline=1\scrollmode
\input /home/edrx/LATEX/diagxy.tex
\documentclass{article}
\begin{document}
$\bfig
  \let\ORIGPOS=\POS
  % \def\POS{\message{POS}\ORIGPOS}
  \def\POS#1{\message{POS#1}\ORIGPOS#1}
  \morphism(0,-300)/->/<0,-300>[{b}`{d};{}]
 \efig
$

% (find-sh "locate xypic")

% (code-c-d "xy" "/usr/share/texmf-tetex/tex/generic/xypic")
% (find-xyfile "")





  \def\POS{\MSGPOS}
  \message{\POS}
  \message{\POS^/_$/}
  \setbox0=\hbox{aa}\message{\the\wd0}
  \message{\setbox0=\hbox{a}\the\wd0}
  % \message{\morphism(225,0)/->/<-225,-300>[{a}`{b};{}]}
  % \morphism(225,0)/->/<225,-300>[{a}`{c};{}]

\def\MSGPOS#1<#2>#3<#4>#5{%
  \message{POS#1<#2>#3<#4>#5}%
  }
{ \def\POS{\MSGPOS}
  \POS(.1,.2)*+!!<0ex,.axis>{.7}.ar.4^-{.9} (.xend,.yend)*+!!<0ex,.axis>{.8}%
}




#####
#
# cmtt and cmttb
# 2008jun28
#
#####

# «cmtt-and-cmttb»  (to ".cmtt-and-cmttb")
# (find-sh "locate cmtt")
# (find-fline "/usr/share/texmf-tetex/fonts/source/public/cm-bold/cmttb10.mf")
# (find-fline "/usr/share/texmf-tetex/fonts/source/public/cm/cmtt10.mf")

(find-tkdiff "/usr/share/texmf-tetex/fonts/source/public/cm-bold/cmttb10.mf"
             "/usr/share/texmf-tetex/fonts/source/public/cm/cmtt10.mf")




#####
#
# math lists
# 2008jul08
#
#####

# «math-lists»  (to ".math-lists")
# (find-texbookpage 1)
# (find-texbooktext)
# (find-texbookpage (+ 11 88) "### display math mode entered")
# (find-texbooktext           "### display math mode entered")
# (find-texbookpage (+ 11 158) "Vcent   is")
# (find-texbooktext            "Vcent   is")

* (eepitch-tex)
* (eepitch-kill)
* (eepitch-tex)
\tracingonline=1\scrollmode
$a + b
 \showlists




#####
#
# beamer
# 2008aug15 / 2013apr01
#
#####

# «beamer»  (to ".beamer")
# (find-es "beamer")
# (find-angg ".zshrc" "regv-beamer")
# (find-status   "latex-beamer")
# (find-vldifile "latex-beamer.list")
# (find-udfile   "latex-beamer/")

# (find-vldish "grep pdf latex-beamer.list")

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
# (find-fline "/tmp/latex-beamer/")
rm -Rv /tmp/latex-beamer/
cp -Rv /usr/share/doc/latex-beamer /tmp/
cd     /tmp/latex-beamer/
gunzip -rv *

cd /tmp/latex-beamer/solutions/conference-talks/
# pdflatex conference-ornate-20min.en.tex
  lualatex conference-ornate-20min.en.tex

# (find-fline "/tmp/latex-beamer/solutions/conference-talks/")
# (find-fline "/tmp/latex-beamer/solutions/conference-talks/conference-ornate-20min.en.tex")



* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
rm -Rv /tmp/beamerdocs/
mkdir  /tmp/beamerdocs/
cd     /tmp/beamerdocs/
cp -v $(grep pdf /var/lib/dpkg/info/latex-beamer.list) .
gunzip -v *.gz

# (find-fline "/tmp/beamerdocs/")
cd     

# (code-c-d "beamerthemes" "/usr/share/texmf/tex/latex/beamer/themes/")
# (code-c-d "beamerthemes" "/usr/share/texmf/tex/latex/beamer/base/themes")
# (find-beamerthemesfile "")
# (find-beamerthemesfile "theme/")
# (find-beamerthemesfile "theme/beamerthemeHannover.sty")
# \usetheme{Hannover}   % Renata

(code-ps        "beameruserguide" "/tmp/beamerdocs/beameruserguide.pdf")
(code-pdftotext "beameruserguide" "/tmp/beamerdocs/beameruserguide.pdf")
;; (find-beameruserguidepage 1)
;; (find-beameruserguidetext)
;; (find-beameruserguidetext "\\usetheme{Warsaw}")


\begin{frame}
  \frametitle{There Is No Largest Prime Number}
  \framesubtitle{The proof uses \textit{reductio ad absurdum}.}
  \begin{theorem}
    There is no largest prime number.
  \end{theorem}
  \begin{proof}
    \begin{enumerate}
    \item<1-| alert@1> Suppose $p$ were the largest prime number.
    \item<2-> Let $q$ be the product of the first $p$ numbers.
    \item<3-> Then $q+1$ is not divisible by any of them.
    \item<1-> Thus $q+1$ is also prime and greater than $p$.\qedhere
    \end{enumerate}
  \end{proof}
\end{frame}





#####
#
# texlive-base (from the debian sources)
# 2008aug17
#
#####

# «texlive-base-deb-src»  (to ".texlive-base-deb-src")
# http://ftp.debian.org/debian/pool/main/t/texlive-base/
# http://ftp.debian.org/debian/pool/main/t/texlive-base/texlive-base_2007.dfsg.1-3.dsc
# http://ftp.debian.org/debian/pool/main/t/texlive-base/texlive-base_2007.dfsg.1-3.diff.gz
# http://ftp.debian.org/debian/pool/main/t/texlive-base/texlive-base_2007.dfsg.1.orig.tar.gz
#*
rm -Rv ~/bigsrc/texlive-base/
mkdir  ~/bigsrc/texlive-base/
cd $S/http/ftp.debian.org/debian/pool/main/t/texlive-base/
cp -v texlive-base_2007.dfsg.1* ~/bigsrc/texlive-base/
cd     ~/bigsrc/texlive-base/
dpkg-source -sn -x texlive-base_2007.dfsg.1-3.dsc
cd     ~/bigsrc/texlive-base/texlive-base-2007.dfsg.1/
find * -type f | sort > .files
# dpkg-buildpackage -us -uc -b -rfakeroot     |& tee odb

#*
# (find-fline "~/bigsrc/texlive-base/")
* (eepitch-shell)
cd ~/bigsrc/texlive-base/
sudo dpkg -i *.deb

#*
# (code-c-d "texlivebase" "~/bigsrc/texlive-base/texlive-base-2007.dfsg.1/")
# (find-texlivebasefile "")
# (find-texlivebasefile ".files")
# (find-texlivebasesh "grep bluesky .files")
# (find-texlivebasesh "grep bluesky .files | grep cmr10")
# (find-texlivebasefile "texmf-dist/fonts/afm/bluesky/cm/cmr10.afm")
# (find-texlivebasefile "texmf-dist/fonts/type1/bluesky/cm/cmr10.pfb")




#####
#
# texlive-bin (from the debian sources)
# 2008aug16
#
#####

# «texlive-bin-deb-src»  (to ".texlive-bin-deb-src")
# http://ftp.debian.org/debian/pool/main/t/texlive-bin/
# http://ftp.debian.org/debian/pool/main/t/texlive-bin/texlive-bin_2007.dfsg.2-3.dsc
# http://ftp.debian.org/debian/pool/main/t/texlive-bin/texlive-bin_2007.dfsg.2-3.diff.gz
# http://ftp.debian.org/debian/pool/main/t/texlive-bin/texlive-bin_2007.dfsg.2.orig.tar.gz
#*
rm -Rv ~/bigsrc/texlive-bin/
mkdir  ~/bigsrc/texlive-bin/
cd $S/http/ftp.debian.org/debian/pool/main/t/texlive-bin/
cp -v texlive-bin_2007.dfsg.2* ~/bigsrc/texlive-bin/
cd     ~/bigsrc/texlive-bin/
dpkg-source -sn -x texlive-bin_2007.dfsg.2-3.dsc
cd     ~/bigsrc/texlive-bin/texlive-bin-2007.dfsg.2/
# dpkg-buildpackage -us -uc -b -rfakeroot     |& tee odb

#*
* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
cd     ~/bigsrc/texlive-bin/texlive-bin-2007.dfsg.2/
find * -type f | sort > .files

#*
# (find-fline "~/bigsrc/texlive-bin/")
* (eepitch-shell)
cd ~/bigsrc/texlive-bin/
sudo dpkg -i *.deb

#*
# (code-c-d "texlivebin" "~/bigsrc/texlive-bin/texlive-bin-2007.dfsg.2/")
# (find-texlivebinfile "")
# (find-texlivebinfile ".files")
# (find-texlivebinsh "grep dvired .files")
# (find-texlivebinfile "build/source/texk/tetex/dvired")
# (find-texlivebinfile "build/source/texk/tetex/dvired.man")
# (find-texlivebinfile "texmf/doc/man/man1/dvired.1")
# (find-texlivebinfile "texmf/dvips/config/config.dvired")
# (find-texlivebinfile "texmf/dvips/config/dvired.cfg")

# (find-texlivebinfile "build/source/texk/web2c/tex.web")
# (find-texlivebinfile "build/source/texk/dvipsk/")




#####
#
# dvired fonts
# 2008aug17
#
#####

# «dvired-fonts»  (to ".dvired-fonts")
# At first I thought that I would have to pass an argument "-D 300" to
# dvired to make it generate fonts that looked good on my HP
# DeskJet... But then I discovered that dvips uses the T1 (or T3?)
# versions of the Computer Modern fonts created by BlueSky...

# Karl Berry's hints, 2008sep23:
# (find-sh "locate updmap.cfg")
# (find-sh "locate config.pk")
# (find-man "5 updmap.cfg")
# (find-fline "/etc/texmf/updmap.d/00updmap.cfg")
# (find-fline "/usr/share/tex-common/00updmap.cfg")
# (find-fline "/usr/share/tex-common/00updmap.cfg.md5sum")
# (find-fline "/var/lib/texmf/web2c/updmap.cfg")
# (find-tkdiff "/var/lib/texmf/web2c/updmap.cfg" "/etc/texmf/updmap.d/00updmap.cfg")
# (find-fline "/usr/share/texmf-texlive/dvips/tetex/config.pk" "prefer bitmap")

# (find-sh "locate dvired")

# (find-fline "/etc/texmf/texlive/dvips/config.dvired")
# (find-fline "/etc/texmf/texlive/dvips/dvired.cfg")
# (find-fline "/usr/bin/dvired")
# (find-man "1 dvired")
# (find-fline "/usr/share/texmf-texlive/dvips/config/config.dvired")
# (find-fline "/usr/share/texmf-texlive/dvips/config/dvired.cfg")

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
function mkechobody () { echo '#!/bin/sh'; echo 'echo $0 $*'; }
function mkecho () { mkechobody > $1; chmod -v 755 $1; }
cd /tmp/
mkecho lpr
mkecho dvips
mkecho pstops
cd ~/LATEX/
# Why doesn't this trick work???
PATH=/tmp:$PATH dvired -o /tmp/tmp.ps 2008graphs.dvi
PATH=/tmp:$PATH /usr/bin/dvired -o /tmp/tmp.ps 2008graphs.dvi
PATH=/tmp:$PATH dvips foo bar
PATH=/tmp:$PATH sh -x /usr/bin/dvired -o /tmp/tmp.ps 2008graphs.dvi
rm -v /tmp/lpr /tmp/dvips /tmp/pstops

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
cd /tmp/
echo -E "Hello t \\bye" > hello.tex
cat hello.tex
tex hello.tex
sh -x  /usr/bin/dvired -o hello.2.ps    hello.dvi
sh -x           dvired -o hello.2.ps    hello.dvi |& tee o
PRINTER=deskjet dvired -o hello.2.dj.ps hello.dvi
PRINTER=deskjet dvired -o hello.2.dj.ps hello.dvi
PRINTER=deskjet sh -x dvired -o hello.2.dj.ps hello.dvi

dvips            -o hello.ps      hello.dvi
dvips -P pk      -o hello.pk.ps   hello.dvi
dvips -P deskjet -o hello.dj.ps   hello.dvi
dvips -D 300     -o hello.300.ps  hello.dvi
dvips -D 150     -o hello.150.ps  hello.dvi
# (find-dvipage "/tmp/hello.dvi")
# (find-pspage  "/tmp/hello.pk.ps")
# (find-pspage  "/tmp/hello.300.ps")
# (find-pspage  "/tmp/hello.150.ps")

# (find-fline   "/tmp/hello.pk.ps")

dvips -d 4            -o hello.ps      hello.dvi
dvips -d 4 -P deskjet -o hello.dj.ps   hello.dvi
dvips -d 4 -D 300     -o hello.300.ps  hello.dvi

# (find-sh "cd /tmp/ && dvips -d 68 -P deskjet -o hello.dj.ps hello.dvi")
# (find-sh "cd /tmp/ && dvips -d 68 -P deskjet -o hello.dj.ps hello.dvi |& tee o")
# (find-sh "cd /tmp/; tr '(),' \\\\n\\\\n\\\\n < o | sort | uniq | grep /")
# (find-fline "/usr/share/texmf/web2c/texmf.cnf" "fonts/type1")
# (find-fline "/var/lib/texmf/fonts/map/dvips/updmap/psfonts.map" "CMR10")

# (find-fline "/usr/share/texmf-texlive/fonts/type1/bluesky/")
# (find-zsh "dvifonts ~/LATEX/2008graphs.dvi | sort")
# (find-zsh "dvifonts ~/LATEX/2008sheaves.dvi | sort")

# (find-node "(dvips)Debug options")

# (find-man "xdvi")

# (find-fline "/tmp/o")
# (find-fline "/tmp/hello.2.ps")
# (find-fline "/tmp/hello.2.dj.ps")
# (find-pspage "/tmp/hello.2.ps")
# (find-pspage "/tmp/hello.2.dj.ps")
# (find-tkdiff "/tmp/hello.2.ps" "/tmp/hello.2.dj.ps")
# (find-tkdiff "/tmp/hello.ps" "/tmp/hello.dj.ps")
# (find-tkdiff "/tmp/hello.ps" "/tmp/hello.300.ps")
# (find-node "(dvips)Option details" "`-x NUM'" "magnification")
# (find-node "(dvips)Option details" "`-D NUM'" "resolution")
# (find-node "(dvips)Option details" "`-P PRINTER'")
# (find-node "(dvips)config.ps installation")
# (find-node "(dvips)config.ps installation" "p +cmfonts.map")
# (find-node "(dvips)Environment variables")

# (find-LATEXgrep "grep -nH -e dvips *.tex")

# (find-sh "locate dvips | grep config")
# (find-fline "/etc/texmf/texlive/dvips/config.ps")
# (find-fline "/etc/texmf/texlive/dvips/config.deskjet")
# (find-fline "/etc/texmf/texlive/dvips/deskjet.cfg")

# (find-node "(dvips)Configuration file commands" "`p [+]NAME'")
# (find-node "(dvips)PostScript fonts")
# (find-node "(dvips)psfonts.map")

# (find-fline "/etc/texmf/texlive/dvips/config.ps")
# (find-fline "/usr/share/texmf-texlive/dvips/config/config.ps")

# (find-sh "locate bluesky")

http://www.tex.ac.uk/cgi-bin/texfaq2html?label=getbitmap
http://www.tex.ac.uk/cgi-bin/texfaq2html?label=useMF
http://www.mail-archive.com/debian-tetex-maint@lists.debian.org/msg00548.html
http://www.tex.ac.uk/cgi-bin/texfaq2html?label=PSpreview





#####
#
# skencil
# 2008aug17
#
#####

# «skencil»  (to ".skencil")
# (find-status   "skencil")
# (find-vldifile "skencil.list")
# (find-udfile   "skencil/")




#####
#
# big delimiters
# 2008sep25
#
#####

# «big-delimiters»  (to ".big-delimiters")
%*
% (eedn4a-bounded)

\def\lcurlybar#1{\left\{\mskip#1mu\middle|}
\def\rcurlybar#1{\middle|\mskip#1mu\right\}}
\def\scof#1#2{\lcurlybar{#1}#2\rcurlybar{#1}}

\def\pmtwo#1#2{\begin{pmatrix}#1 \\ #2\end{pmatrix}}
\def\pmthree#1#2#3{\begin{pmatrix}#1 \\ #2 \\ #3\end{pmatrix}}

$\scof{-4}{abc}
 \scof{-5.5}{\pmtwo a b}
 \scof{-6}{\pmthree a b c}
$

%*
% (find-dvifonts "~/LATEX/tmp.dvi")

% (find-testfont "\\T{cmr10}\\T{cmmi10}\\T{cmsy10}")
% (find-testfont "\\T{cmex10}\\T{cmsy10}\\T{cmbx10}\\T{cmmi10}\\T{cmr10}\\T{cmsl10}")

% (find-symbolspage 53 "\\middle")
% (find-symbolstext    "\\middle")
% (find-sh "locate braket")
% (find-sh "locate ltxmisc")
% (code-c-d "ltxmisc" "/usr/share/texmf-texlive/tex/latex/ltxmisc/")
# (find-ltxmiscfile "braket.sty" "\\def\\mid@vertical")
% (find-ltxmiscfile "braket.sty" "e-TeX with its \\middle primitive")
% http://www.tex.ac.uk/cgi-bin/texfaq2html?label=etex
% http://www.tex.ac.uk/cgi-bin/texfaq2html?label=omegaleph

# (find-texbookpage (+ 11 471) "mu (math unit)")
# (find-texbookpage (+ 11 168) "mu")
# (find-texbookpage (+ 11 270) "mu")
# (find-texbookpage (+ 11 473) "openings")
# (find-texbookpage (+ 11 437) "openings")
# (find-texbookpage (+ 11 156) "\\delimiter")
# (find-texbookpage (+ 11 147) "\\big delimiters")
# (find-texbookpage (+ 11 150) "\\lmoustache")
# (find-plainsrcfile "plain.tex" "\\def\\lmoustache")
# (find-plainsrcfile "plain.tex" "\\def\\langle")
# (find-source2egrep "grep -nH -e moustache *")
# (find-source2egrep "grep -nH -e DeclareMathDelimiter *")
# (find-source2efile "ltfssdcl.dtx" "\\def\\@DeclareMathDelimiter")




#####
#
# book.cls
# 2008oct09
#
#####

# «book.cls»  (to ".book.cls")
# (find-dn4exfile "edrxheadfoot.tex")

# (find-source2efile "install.txt" "classes.dtx" "documented sources")
# (find-source2efile "install.txt" "running iniTeX on" "unpack.ins")
# (find-source2efile "unpack.ins"  "\\batchinput{classes.ins}")
# (find-source2efile "classes.ins" "\\generate" "\\file{book.cls}")
# (find-lsrcfile "base/book.cls" "\\if@twoside" "\\def\\ps@headings")

# Source:
# (find-source2efile "classes.dtx" "%<*article|report|book>")
# (find-source2efile "classes.dtx" "\\if@twoside" "\\def\\ps@headings")

# (find-source2efile "doc.dtx" "`documentation part'")




#####
#
# qtree
# 2008nov04
#
#####

# «qtree»  (to ".qtree")
# (find-angg "elisp/eeqtree.el")
# http://www.ling.upenn.edu/advice/latex/qtree/
# http://www.ling.upenn.edu/advice/latex/qtree/qtree.sty
# http://www.ling.upenn.edu/advice/latex/qtree/qtreenotes.tex
# http://www.ling.upenn.edu/advice/latex/qtree/qarrows.tex
# http://www.ling.upenn.edu/advice/latex/qtree/qtreenotes.pdf
# http://www.ling.upenn.edu/advice/latex/qtree/qarrows.pdf
#*
cd $S/http/www.ling.upenn.edu/advice/latex/qtree/
cp -v qtree.sty qtreenotes.tex qarrows.tex qtreenotes.pdf qarrows.pdf ~/.eev/

#*
* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)

cd ~/.eev/
cat > eeqtree.tex <<'%%%'
\documentclass[12pt]{article}
\usepackage{fullpage}
\usepackage{qtree}
\begin{document}
\Tree [.Root [.Left a b ] [.Right c ddd ] ]
\end{document}
%%%
cd ~/.eev/ && latex eeqtree.tex && dvipdf eeqtree.dvi && ls -l eeqtree*



#*

%*
% (eeqtree-bounded)
% (eeqtreenow-bounded)
% (defun c () (interactive) (find-sh eeqtree-command))
% (find-man "1 xpdf" "Reload the current PDF file.")
% (find-xpdfpage "~/.eev/eeqtree.pdf")
\Tree [.Root [.Left a b ] [.Right c d e ] ]

%*
# (find-man "xpdf")
% (find-node \"(gv)Notation\" \"<SC-X>\")
% (find-node \"(gv)Miscellaneous keys\" \"<SC-.>\" \"Reopen the current file\")
%*
% (eeqtree-bounded)
% (defun c () (interactive) (find-sh "cd ~/.eev/ && latex eeqtree.tex && dvipdf eeqtree.dvi && ls -l eeqtree*"))
% (find-xpdfpage "~/.eev/eeqtree.pdf")
% (find-node "(gv)Notation" "<SC-X>")
% (find-node "(gv)Miscellaneous keys" "<SC-.>" "Reopen the current file")
\Tree [.Root [.Left a b ] [.Right c dd ] ]

%*




#####
#
# juridico (by fnaufel)
# 2008nov17
#
#####

# «juridico»  (to ".juridico")
# http://www.ic.uff.br/~fnaufel/
# (find-fline "~/tmp/juridico.zip")
#*
rm -Rv   ~/usrc/juridico/
mkdir    ~/usrc/juridico/
unzip -d ~/usrc/juridico/ ~/tmp/juridico.zip
cd       ~/usrc/juridico/

latex exemplojuridico.tex 2>&1 > /dev/null
latex exemplojuridico.tex 2>&1 > /dev/null
latex exemplojuridico.tex

#*
# (code-c-d "juridico" "~/usrc/juridico/")
# (find-juridicofile "")
# (find-pspage (ee-juridicofile "exemplojuridico.pdf"))




#####
#
# \newcounter
# 2009apr29
#
#####

# «newcounter»  (to ".newcounter")
# (find-LATEX "2009apr29-C1.tex")
# (find-LATEX "2009apr29-MD.tex")
%*
% (eedn4a-bounded)
% (find-kopkadaly4page (+ 12 631) "Index" "newcounter")
% (find-kopkadaly4page (+ 12 182) "8.1.3   Changing counter values")
% (find-kopkadaly4text            "8.1.3   Changing counter values")
% (find-kopkadaly4page (+ 12 213) "9.2.1   Cross-references")
% (find-kopkadaly4text            "9.2.1   Cross-references")

\newcounter{myex}

(\arabic{myex})

\refstepcounter{myex}
(\arabic{myex})
\label{myex1}
($\Leftarrow$ this one)

\refstepcounter{myex}
(\arabic{myex})

\refstepcounter{myex}
(\arabic{myex})

\ref{myex1} ($\Leftarrow$ that one)

%*





#####
#
# Fitch-style natural deductions
# 2009may08
#
#####

# «fitch»  (to ".fitch")
# http://www.phil.cam.ac.uk/teaching_staff/Smith/LaTeX/fitch.html
# http://angasm.org/papers/fitch/
# http://folk.uio.no/johanw/FitchSty.html
# http://folk.uio.no/johanw/nd.pdf
# http://folk.uio.no/johanw/fitch.sty
#*
# (eev-bounded)

rm -v /tmp/fitch/
mkdir /tmp/fitch/
cd    /tmp/fitch/
cp -v $S/http/folk.uio.no/johanw/fitch.sty .

cat > test.tex <<'---'
\documentclass{article}
\usepackage{fitch}
\begin{document}
\begin{equation*}
  \begin{fitch}
    \fh \forall y\lnot P(y)                             \\
    \fa\fh \exists xP(x)                                \\
    \fa\fa\fitchmodalh{u}  P(u)                         \\
    \fa\fa\fa \forall y\lnot P(y) & R, 1                \\
    \fa\fa\fa \lnot P(u)          & $\forall$E, 4       \\
    \fa\fa\fa \bot                & $\lnot$E, 3,5       \\
    \fa\fa \bot                   & $\exists$E, 2, 3--6 \\
    \fa \lnot\exists xP(x)        & $\lnot$I, 2--7
  \end{fitch}
\end{equation*}
\end{document}
---

latex test.tex
rexdvi test.dvi

#*
# (eev-bounded)
# Provas que a Aline LaTeXou em 2009may18:

rm -v /tmp/fitch/
mkdir /tmp/fitch/
cd    /tmp/fitch/
cp -v $S/http/folk.uio.no/johanw/fitch.sty .

cat > test.tex <<'---'
\documentclass{article}
\usepackage[latin1]{inputenc}
\usepackage{fitch}
\begin{document}

Exemplo 1.11 (p.11)
\begin{equation*}
  \begin{fitch}
    \fh                                          & sem premissa           \\
    \fa \fh q \to r                              & hipótese               \\
    \fa \fa \fh \lnot q \to \lnot p              & hipótese               \\
    \fa \fa \fa \fh p                            & hipótese               \\
    \fa \fa \fa \fa \lnot \lnot p                & $\lnot \lnot i \ 3$    \\
    \fa \fa \fa \fa \lnot \lnot q                & MT 2,4                 \\
    \fa \fa \fa \fa    q                         & $\lnot \lnot e \ 5$    \\
    \fa \fa \fa \fa r                            & $\to e \ 1,6$          \\
    \fa \fa \fa p \to r                          & $\to i \ 3-7$          \\
    \fa \fa (\lnot q \to \lnot p) \to (p \to r)  & $\to i \ 2-8$          \\
    \fa (q \to r) \to ((\lnot q \to \lnot p) \to (p \to r))  & $\to i \ 1-9$ \\
  \end{fitch}
\end{equation*}

Exemplo 1.13 (p.12)
\begin{equation*}
  \begin{fitch}
    \fh p \land q \to r        & premissa         \\
    \fa \fh p                  & hipótese         \\
    \fa \fa \fh q              & hipótese         \\
    \fa \fa \fa p \land q      & $\land i \ 2,3$  \\
    \fa \fa \fa r              & $\to e \ 1,4$    \\
    \fa \fa q \to r            & $\to i \ 3-5$    \\
    \fa p \to (q \to r)        & $\to i \ 2-6$    \\
  \end{fitch}
\end{equation*}

Página 14
\begin{equation*}
  \begin{fitch}
    \fh p \lor q               & premissa          \\
    \fa \fh p                  & hipótese          \\
    \fa \fa q \lor p           & $\lor i_{2} \ 2$  \\
    \fa \fh q                  & hipótese          \\
    \fa \fa q \lor p           & $\lor i_{1} \ 4$  \\
    \fa q \lor p               & $\lor e \ 1, \; 2-3, \; 4-5$ \\
  \end{fitch}
\end{equation*}

Segunda derivação da p.36:
\begin{equation*}
  \begin{fitch}
    \fb p \land q    \to r     & premissa         \\
    \fj p                      & premissa         \\
    \fa \fh q                  & hipótese         \\
    \fa \fa p \land q          & $\land i \ 2,3$  \\
    \fa \fa r                  & $\to e \ 1,4$    \\
    \fa q \to r                & $\to i \ 3-5$    \\
  \end{fitch}
\end{equation*}

\end{document}
---

latex test.tex
rexdvi test.dvi

#*


% (find-sh "cp -v $S/http/folk.uio.no/johanw/fitch.sty ~/LATEX/")
% (find-LATEXfile "tmp.tex")



#####
#
# mdwtab
# 2009may19
#
#####

# «mdwtab»  (to ".mdwtab")
# http://www.ctan.org/tex-archive/macros/latex/contrib/mdwtools/mdwtab.pdf
# (code-xpdf      "mdwtab" "$S/http/www.ctan.org/tex-archive/macros/latex/contrib/mdwtools/mdwtab.pdf")
# (code-pdftotext "mdwtab" "$S/http/www.ctan.org/tex-archive/macros/latex/contrib/mdwtools/mdwtab.pdf")
# (find-mdwtabpage 1)
# (find-mdwtabtext 1)




#####
#
# \smashpicture
# 2009aug18
#
#####

# «smashpicture»  (to ".smashpicture")
# (find-kopkadaly4page (+ 12 635) "Index" "picture")
# (find-kopkadaly4page (+ 12 288) "picture")
# (find-kopkadaly4text            "13.1.4 Picture element commands")
# (find-kopkadaly4page (+ 12 301) "13.1.6 Shifting a picture environment")
# (find-kopkadaly4text            "13.1.6 Shifting a picture environment")
# (find-kopkadaly4page (+ 12 296) "Ovals and rounded corners")
# (find-kopkadaly4text            "Ovals and rounded corners")
%*
% (eedn4a-bounded)
% (find-sh0 "cd ~/LATEX/ && dvips  -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-sh0 "cd ~/LATEX/ && dvired -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-pspage "~/LATEX/tmp.ps")

\def\smashpicture#1{\begin{picture}(0,0)#1\end{picture}}
\def\vdashq{\smashpicture{\put(5,4.5){\tiny?}}\vdash}
\def\smashoval#1{\smashpicture{\put(0,0){\oval(#1)}}}

$a \vdashq b$

$a \smashoval{30,20} b$

%*




#####
#
# shortvrb (for DNC in Coq)
# 2009sep19
#
#####

# «shortvrb»  (to ".shortvrb")
# (find-angg ".emacs.papers" "kopkadaly")
# (find-kopkadaly4page 7 "Contents")
# (find-kopkadaly4page (+ 12 607) "Index")
# (find-kopkadaly4page (+ 12 639) "\f Index" "shortvrb")
# (find-kopkadaly4text            "\f Index" "shortvrb")
# (find-kopkadaly4page (+ 12 111) "shortvrb")
# (find-kopkadaly4page (+ 12 393) "shortvrb")
# (find-kopkadaly4page (+ 12 468) "shortvrb")
# (find-kopkadaly4page (+ 12 558) "shortvrb")
# (find-kopkadaly4text            "shortvrb")
# (find-lsrcfile "base/shortvrb.sty")
# (find-source2efile "doc.dtx")
# (find-source2efile "doc.dtx" "%<*package|shortvrb>")
# (find-dn4ex "edrx08.sty" "ttchars")
# (find-LATEX "2009dnc-in-coq.tex")

%*
% (eedn4a-bounded)
% (find-sh0 "cd ~/LATEX/ && dvips  -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-sh0 "cd ~/LATEX/ && dvired -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-pspage "~/LATEX/tmp.ps")

Foo:

\par \verb.012345678.
\par \verb.  23  678.

{\MakeShortVerb{}
 \ttchars
 \par Foo bar0123456789ABCDplic ploc
 \par Foo bar  23  678«»*  plic ploc
 \DeleteShortVerb{}
}

% $\substack{\delta \\ I \\ e}  f(\delta, e)$

\widemtos

\bsk

This:

\ssk

{\MakeShortVerb{}
 \ttchars
 \para := proj1 «a,b»
 \parb := proj2 «a,b»
 \parc := «b|->c» b
 \par«a,c» := (a, c)
 \DeleteShortVerb{}
}

\ssk

Becomes:

{\MakeShortVerb{}
 \ttchars
 \para := proj1 «$a,b$»
 \parb := proj2 «$a,b$»
 \parc := «$b \mto c$» b
 \par«$a,c$» := (a, c)
 \DeleteShortVerb{}
}

\ssk

And:

{\MakeShortVerb{}
 \ttchars
 \para := proj1 dnc0
 \parb := proj2 dnc0
 \parc := dnc1 b
 \pardnc2 := (a, c)
 \DeleteShortVerb{}
}

%*




#####
#
# llangle and rrangle
# 2009nov09
#
#####

# «llangle-and-rrangle»  (to ".llangle-and-rrangle")
# (find-LATEXfile "2009dnc-in-coq.tex" "\\def\\llangle")

% (find-es "tex" "llangle-and-rrangle")
% (find-dn4ex "edrx08.sty" "ttchars")
% (find-symbolspage 54 "\\llangle")
% (find-symbolstext    "\\llangle")
% http://ubuntuforums.org/archive/index.php/t-722871.html
\def\llangle{\langle\!\langle}
\def\rrangle{\rangle\!\rangle}
\def\angg#1{\llangle#1\rrangle}
\def\myotherttchars{
  \def«{\ttchar{$\llangle$}}
  \def»{\ttchar{$\rrangle$}}
  }
\def\myttchars{\basicttchars\myotherttchars}



#####
#
# landscape
# 2010apr20
#
#####

# «landscape»  (to ".landscape")
# (find-xpdfpage "/usr/share/doc/texlive-doc/latex/preprint/fullpage.pdf")
# (find-xpdfpage "/usr/share/doc/texlive-latex-extra-doc/latex/preprint/fullpage.pdf")
# (find-fline "/usr/share/texmf-texlive/tex/latex/preprint/fullpage.sty")
# (find-man "1 xdvi" "\\usepackage[dvips]{geometry}")
# (find-man "1 xdvi" "\nPAPERSIZE SPECIALS")

% (find-angg ".emacs.papers" "kopkadaly")
% (find-kopkadaly4page 7 "Contents")
% (find-kopkadaly4page (+ 12 607) "Index")
% (find-kopkadaly4page (+ 12 626) "landscape")
% (find-kopkadaly4page (+ 12 633) "page format")
% (find-kopkadaly4page (+ 12 452) "fullpage.sty")
% (find-kopkadaly4page (+ 12  47) "3.2.5    Page format")
% (find-kopkadaly4text            "3.2.5    Page format")
% (find-kopkadaly4page (+ 12 159) "lscape")
% (find-kopkadaly4page (+ 12 232) "10.1.1 The dvips driver")
% (find-kopkadaly4text            "10.1.1 The dvips driver")
% (find-kopkadaly4page (+ 12  38) "Specifying paper size")
% (find-kopkadaly4text)
% (find-kopkadaly4text "\\ProvidesPackage{fullpage}")
% (find-lsrcfile "preprint/fullpage.sty")

% \special{landscape}
% \special{xdvi:papersize=27cm,21cm}
% \usepackage[dvips]{a5}
% \usepackage[a4paper,landscape]{anysize}
%\usepackage[a4paper]{anysize}
%\marginsize{1cm}{1cm}{1cm}{1cm}  % left, right, top, bottom
% (find-zsh "dmissing anysize")
% (find-fline   "/usr/share/doc/texlive-doc/latex/anysize/")
% (find-dvipage "/usr/share/doc/texlive-doc/latex/anysize/anysize.dvi")
% (find-lsrcfile "anysize/anysize.sty")




#####
#
# crossover
# 2010jun06
#
#####

# «crossover»  (to ".crossover")
# (find-dn4ex "edrx08.sty" "crossover")
%*
% (eedn4a-bounded)
% (find-sh0 "cd ~/LATEX/ && dvips  -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-sh0 "cd ~/LATEX/ && dvired -D 300 -P pk -o tmp.ps tmp.dvi")
% (find-pspage "~/LATEX/tmp.ps")

% (find-texbookpage (+ 11 221) "\\vrule height4pt width3pt depth2pt")
% (find-texbooktext            "\\vrule height4pt width3pt depth2pt")
% (find-texbookpage (+ 11 285) "\\raise dimen box")
% (find-texbooktext            "\\raise dimen box")
\def\crossover#1#2#3{%
  \setbox0\hbox{#1}%
  \copy0%
  \hskip -\wd0%
  \setbox1\hbox{\vrule height #2 width\wd0 depth0pt}%
  \raise #3\copy1\relax}

Foo: \crossover{bleh bar}{0.25pt}{1.75pt} blop

Foo: \mycrossover{bleh bar} blop

%*



#####
#
# birkjour (for submitting a paper to a Birkauser journal)
# 2010nov01
#
#####

# «birkjour»  (to ".birkjour")
# http://article.gmane.org/gmane.science.mathematics.categories/5991
# http://www.springer.com/birkhauser/mathematics/journal/11787
# http://www.springer.com/cda/content/document/cda_downloaddocument/birkjour.zip

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
rm -Rv   ~/usrc/birkjour/
mkdir    ~/usrc/birkjour/
unzip -d ~/usrc/birkjour/ \
  $S/http/www.springer.com/cda/content/document/cda_downloaddocument/birkjour.zip
cd       ~/usrc/birkjour/

# (code-c-d       "birkjour" "~/usrc/birkjour/")
# (code-xpdf      "birkjour" "~/usrc/birkjour/bjourdoc.pdf")
# (code-pdftotext "birkjour" "~/usrc/birkjour/bjourdoc.pdf")
# (find-birkjourfile "")
# (find-birkjourpage 1)
# (find-birkjourtext 1)



#####
#
# Submitting to Arxiv
# 2010nov01
#
#####

# «arxiv»  (to ".arxiv")
# http://arxiv.org/help/primer
# http://arxiv.org/help/endorsement
# http://arxiv.org/help/faq/index
# http://arxiv.org/help/license

# http://en.wikipedia.org/wiki/Self_archiving
# http://en.wikipedia.org/wiki/Open_access_mandate
# http://www.eprints.org/openaccess/self-faq/



#####
#
# Macros with more than 9 arguments
# 2011jan04
#
#####

# «more-than-9-args»  (to ".more-than-9-args")
# (find-angg "LUA/defwithmanyargs.lua")
%*
% (eedn4a-bounded)
% My solution, using \sa, \ga, \begingroup and \endgroup.
% (find-angg "LUA/defwithmanyargs.lua")
% (find-dn4ex "edrxdnt.tex" "defded")

\def\sa#1#2{\expandafter\def\csname myarg#1\endcsname{#2}}
\def\ga#1{\csname myarg#1\endcsname}

\makeatletter
\def\foo#1#2#3#4#5{\begingroup%
  \sa{1}{#1}\sa{2}{#2}\sa{3}{#3}\sa{4}{#4}\sa{5}{#5}\foo@}
\def\foo@#1#2#3#4#5{%
  \sa{6}{#1}\sa{7}{#2}\sa{8}{#3}\sa{9}{#4}\sa{10}{#5}\foo@@}
\def\foo@@#1#2#3#4#5{%
  \sa{11}{#1}\sa{12}{#2}\sa{13}{#3}\sa{14}{#4}\sa{15}{#5}\foo@@@}
\def\foo@@@#1{%
  \sa{16}{#1}
  \begin{pmatrix}
    \ga{1} & \ga{2} & \ga{3} & \ga{4} \\
    \ga{5} & \ga{6} & \ga{7} & \ga{8} \\
    \ga{9} & \ga{10} & \ga{11} & \ga{12} \\
    \ga{13} & \ga{14} & \ga{15} & \ga{16} \\
  \end{pmatrix}
  \endgroup}
\makeatother

$$bar \foo 0123 4567 89AB CDEF bar$$
$$bar \foo 0123
           45{\foo 0123 4567 89ab cdef}7
           89AB
           CDEF bar$$

%*
% (eedn4a-bounded)
% The original solution, from:
% http://www.tex.ac.uk/cgi-bin/texfaq2html?label=moren9

\def\setargsitov#1#2#3#4#5{%
  \def\argi{#1}\def\argii{#2}\def\argiii{#3}\def\argiv{#4}\def\argv{#5}}
\def\setargsvitox#1#2#3#4#5{%
  \def\argvi{#1}\def\argvii{#2}\def\argviii{#3}\def\argix{#4}\def\argx{#5}}

% \def\argii{2}

\def\showargs{%
  1:{\argi}
  2:{\argii}
  3:{\argiii}
  4:{\argiv}
  5:{\argv}
  6:{\argvi}
  7:{\argvii}
  8:{\argviii}
  9:{\argix}
  10:{\argx}}

\makeatletter
\def\foo #1#2#3#4#5{\setargsitov{#1}{#2}{#3}{#4}{#5}\@foo}
\def\@foo#1#2#3#4#5{\setargsvitox{#1}{#2}{#3}{#4}{#5}\showargs}
\makeatother

\par \foo abcdefghij
\par \foo ABCDEFGHIJ
% \par 2:\argii

%*




#####
#
# fitch-0.5
# 2011nov24
#
#####

# «selinger-fitch»  (to ".selinger-fitch")
# http://www.mscs.dal.ca/~selinger/fitch/fitch-0.5.tgz
#*
rm -Rv ~/usrc/fitch-0.5/
tar -C ~/usrc/ -xvzf \
  $S/http/www.mscs.dal.ca/~selinger/fitch/fitch-0.5.tgz
cd     ~/usrc/fitch-0.5/

#*
# (code-c-d "fitch" "~/usrc/fitch-0.5/")
# (find-fitchfile "")

* (eepitch-lua51)
* (eepitch-kill)
* (eepitch-lua51)
ee_dofile "~/dednat5/eoo.lua"
FitchLine = Class {
  type    = "FitchLine",
  __index = {
    totex = function (fl, cmd)
        local n    = format(" {%s}", fl.n)
        local body = format(" {%s}", fl.body)
        local by   = fl.by and format(" \\by{%s}", fl.by) or ""
        return cmd..n..body..by
      end,
  },
}
FitchSubproof = Class {
  type    = "FitchSubproof",
  __index = {
    totex = function (fs, prefix)
        local T = {}
	local cmd = "\\hypo"
	for n,fl in ipairs(fs) do
	  PP(fl)
          if fl == "-" then cmd = "\\have"
	  else table.insert(T, prefix..fl:totex(cmd).."\n")
	  end
        end
        return table.concat(T)
      end,
  },
}

L1 = FitchLine {n=1, body="A", by="algebra"}
L2 = FitchLine {n=2, body="B"}
L3 = FitchLine {n=3, body="C", by="cee"}
L4 = FitchLine {n=4, body="D", by="dee"}
S1 = FitchSubproof {L1, L2, "-", L3, L4}

= S1:totex("  ")

= L1:totex "\\hypo"
= L2:totex "\\have"






#####
#
# showhyphens
# 2010jun08
#
#####




#####
#
# ipe
# 2012jun04
#
#####

# «ipe»  (to ".ipe")
# http://ipe7.sourceforge.net/
# http://lamut.informatik.uni-wuerzburg.de/mediawiki/ipe7/index.php/Main_Page
# (find-status   "ipe")
# (find-vldifile "ipe.list")
# (find-udfile   "ipe/")

# (find-fline "/usr/lib/ipe/7.0.10/ipelets/")
# (find-fline "/usr/share/ipe/7.0.10/")
# (find-fline "/usr/share/ipe/7.0.10/lua/")
#       file:///usr/share/ipe/7.0.10/doc/manual.html




#####
#
# geometry
# 2012aug09
#
#####

# «geometry»  (to ".geometry")
# (find-angg ".emacs.papers" "latexgeom")




#####
#
# 2 pages per sheet (Hugo Nóbrega)
# 2012dec01
#
#####

# «2-pages-per-sheet» (to ".2-pages-per-sheet")
# http://www.facebook.com/hugo.nobrega.372/posts/10151305375155777

LaTeX protip: to produce a pdf which looks pretty damn good printed in
"2 pages per sheet" mode, put the following in your preamble:

\usepackage{calc}
\usepackage[paperwidth=\textwidth+1cm,left=0.5cm,right=0.5cm,
            paperheight=\textheight+\footskip+1cm,top=0.5cm,bottom=0.5cm,
            includefoot]{geometry}

(this does change the paper proportions *ever so slightly*, though)

Hugo de Holanda This "version" will keep the paper size proportional
to A4, if that's what floats your boat:

\usepackage{calc}
\newlength{\newpaperheight}
\setlength{\newpaperheight}{\textheight+\footskip+1cm}
\newlength{\newpaperwidth}
\setlength{\newpaperwidth}{.707\newpaperheight}
\newlength{\newsidemargin}
\setlength{\newsidemargin}{.5\newpaperwidth - .5\textwidth}
\newlength{\newverticalmargin}
\setlength{\newverticalmargin}{.5cm}
\usepackage[paperwidth=\newpaperwidth,
            left=\newsidemargin,right=\newsidemargin,
            paperheight=\newpaperheight,
            top=\newverticalmargin,bottom=\newverticalmargin,
            includefoot]{geometry}

There was a problem if you used a documentclass with nonempty headers
(say, amsart). I think this fixes it:

\usepackage{calc}

\newlength{\newverticalmargin}
\setlength{\newverticalmargin}{.5cm}
\newlength{\newpaperheight}
\setlength{\newpaperheight}{\textheight+\headheight+\headsep+\footskip+2\newverticalmargin}
\newlength{\tempone}
\setlength{\tempone}{.707\newpaperheight - \textwidth}
\newlength{\newsidemargin}
\setlength{\newsidemargin}{.5\tempone}
\newlength{\newpaperwidth}
\setlength{\newpaperwidth}{\textwidth+2\newsidemargin}

\usepackage[paperwidth=\newpaperwidth,
            left=\newsidemargin,right=\newsidemargin,
            paperheight=\newpaperheight,
            top=\newverticalmargin,bottom=\newverticalmargin,
            includehead,includefoot]{geometry}




#####
#
# Floats
# 2013jan09
#
#####

# «floats» (to ".floats")
# (find-angg "quadradinho/quadradinho-texto.tex" "queremos")
# http://tex.stackexchange.com/questions/24796/how-to-handle-old-source-needing-floatflt-sty

% (find-angg ".emacs.papers" "kopkadaly")
% (find-kopkadaly4page 8 "Floating tables and figures")
% (find-kopkadaly4text 8 "Floating tables and figures")
% (find-kopkadaly4page (+ 12 170) "Floating tables and figures")
% (find-kopkadaly4text (+ 12 170) "Floating tables and figures")
% (find-kopkadaly4page (+ 12 173) "7.4   Float captions")
% (find-kopkadaly4text (+ 12 173) "7.4   Float captions")
% (find-kopkadaly4page (+ 12 178) "floatflt")
% (find-kopkadaly4text (+ 12 178) "floatflt")
% (find-sh "locate floatflt")
% (find-zsh "dmissing floatflt")
% (find-zsh "dmissing texlive | grep float")
% (find-zsh "dmissing texlive | grep float | grep README")

% (find-lsrcfile "float/float.sty")
% (find-fline "/usr/share/doc/texlive-doc/latex/float/")
% (find-fline "/usr/share/doc/texlive-doc/latex/float/README")
% (find-fline "/usr/share/doc/texlive-doc/latex/float/README" "[H]")
% (find-fline "/usr/share/doc/texlive-doc/latex/float/")
(code-xpdf     "float" "/usr/share/doc/texlive-doc/latex/float/float.pdf")
(code-pdf-text "float" "/usr/share/doc/texlive-doc/latex/float/float.pdf")
% (find-floatpage)
% (find-floattext)
% (find-floatpage 11 "boxed float style")
% (find-floattext 11 "boxed float style")
% (find-floatpage 2 "\\newfloat{ type }{ placement }{ ext }[ within ]")
% (find-floattext 2 "\\newfloat{ type }{ placement }{ ext }[ within ]")
% (find-floatpage 3 "\\newfloat{Program}{tbp}{lop}[section]")
% (find-floattext 3 "\\newfloat{Program}{tbp}{lop}[section]")

% Doesn't work:
\begin{floatingfigure}[hl]{1in}
$$\includegraphics[scale=0.15]{queremos4.pdf}$$
\end{floatingfigure}

;; (find-fline "/usr/share/doc/texlive-doc/latex/subfloat/")
(code-xpdf     "subfloat" "/usr/share/doc/texlive-doc/latex/subfloat/subfloat.pdf")
(code-pdf-text "subfloat" "/usr/share/doc/texlive-doc/latex/subfloat/subfloat.pdf")
;; (find-subfloatpage)
;; (find-subfloattext)

% (find-fline "/usr/share/doc/texlive-doc/latex/dpfloat/README.dpfloat")
% (find-fline "/usr/share/doc/texlive-doc/latex/floatrow/README")
% (find-fline "/usr/share/doc/texlive-doc/latex/subfloat/README")
% (find-fline "/usr/share/doc/texlive-doc/latex/trivfloat/README")




#####
#
# subfigure
# 2013apr13
#
#####

# «subfigure» (to ".subfigure")
# (find-sh "locate subfigure")
# (find-fline "/usr/share/doc/texlive-doc/latex/subfigure/")
/usr/share/doc/texlive-doc/latex/subfigure/

# (find-sh "locate subfig")
# (find-sh "locate subfig | grep -v subfigure")
# (find-sh "locate subfigure")
# (find-fline "/usr/share/doc/texlive-doc/latex/subfig/")
# (find-fline "/usr/share/doc/texlive-latex-recommended-doc/latex/subfig/")
# (code-xpdf     "subfig" "/usr/share/doc/texlive-latex-recommended-doc/latex/subfig/subfig.pdf")
# (code-pdf-text "subfig" "/usr/share/doc/texlive-latex-recommended-doc/latex/subfig/subfig.pdf" 8)
# (find-subfigpage)
# (find-subfigtext)
# (find-subfigpage (+ 8 41))
# (find-subfigtext (+ 8 41))
# (find-subfigpage (+ 8 42) "5.1        A Simple Example")
# (find-subfigtext (+ 8 42) "5.1        A Simple Example")
# (find-subfigpage (+ 8 54) "\\newcounter{sub#2}")
# (find-subfigtext (+ 8 54) "\\newcounter{sub#2}")

;; "subfig" supersedes "subfigure"...
;; (find-fline "/usr/share/doc/texlive-doc/latex/subfigure/")
(code-xpdf     "subfigure" "/usr/share/doc/texlive-doc/latex/subfigure/subfigure.pdf")
(code-pdf-text "subfigure" "/usr/share/doc/texlive-doc/latex/subfigure/subfigure.pdf")
;; (find-subfigurepage)
;; (find-subfiguretext)




#####
#
# The "subfig" package
# 2013apr26
#
#####

# «subfig» (to ".subfig")
http://tex.stackexchange.com/questions/9256/using-one-counter-for-different-floats
http://stackoverflow.com/questions/3865036/using-a-single-count-for-figures-and-tables-in-latex

% http://tex.stackexchange.com/questions/9256/using-one-counter-for-different-floats
% http://stackoverflow.com/questions/3865036/using-a-single-count-for-figures-and-tables-in-latex
% The "\let" below is a dirty trick to makefigures and boxedfigures
% use the same counter.




#####
#
# \let
# 2013apr18
#
#####

# «let» (to ".let")
# (find-texbookpage (+ 11 206) "\\let\\a=\\def")
# (find-texbooktext (+ 11 206) "\\let\\a=\\def")





#####
#
# Classe para atas de reunião
# 2013jan29
#
#####

# «ata.cls» (to ".ata.cls")
# [puro-uff-rfm: 1958] Uma classe LaTeX para atas de reunião
# (find-zsh "dmissing lineno.sty")
# (find-zsh "dmissing eorm")
# (find-status   "texlive-humanities")
# (find-vldifile "texlive-humanities.list")
# (find-udfile   "texlive-humanities/")
# (find-status   "texlive-humanities-doc")
# (find-vldifile "texlive-humanities-doc.list")
# (find-udfile   "texlive-humanities-doc/")
# (find-status   "texlive-fonts-extra")
# (find-vldifile "texlive-fonts-extra.list")
# (find-udfile   "texlive-fonts-extra/")
# (find-status   "texlive-fonts-extra-doc")
# (find-vldifile "texlive-fonts-extra-doc.list")
# (find-udfile   "texlive-fonts-extra-doc/")

# (find-angg "LATEX/2012-ata-rfm-dez.tex")




#####
#
# tlmgr
# 2013apr30
#
#####

# «tlmgr» (to ".tlmgr")
# Mentioned by:
# (find-es "luatex" "luacode")

# (find-man "tlmgr")
# http://www.tug.org/texlive/tlmgr.html
# http://www.tug.org/texlive/doc/tlmgr.html
# (find-zsh "dmissing tlmgr")




#####
#
# \usepackage[T1]{fontenc}
# 2013jul17
#
#####

# «T1-fontenc» (to ".T1-fontenc")
# (find-kopkadaly4page (+ 12 378) "\\usepackage[OT2,T1]{fontenc}")
# (find-kopkadaly4text (+ 12 378) "\\usepackage[OT2,T1]{fontenc}")
# (find-kopkadaly4page (+ 12 501) "\\usepackage[T1]{fontenc}")
# (find-kopkadaly4text (+ 12 501) "\\usepackage[T1]{fontenc}")
# (find-fline "/usr/share/texlive/texmf-dist/tex/latex/base/t1enc.def")




#####
#
# no room for a new dimen
# 2014apr03
#
#####

# «no-room-for-a-new-dimen» (to ".no-room-for-a-new-dimen")
# http://tex.stackexchange.com/questions/38607/no-room-for-a-new-dimen
# http://www.tex.ac.uk/cgi-bin/texfaq2html?label=noroom
# http://www.tex.ac.uk/cgi-bin/texfaq2html?label=etex

# (find-sh "locate etex")
# (find-sh "locate etex | grep texlive")


# (find-node "(reftex)Top")










\newlinechar=`^^J
\showthe\newlinechar
\newlinechar=-1
\showthe\newlinechar
%
\message{\the\newlinechar}


\message{Hello bar}
\message{Hello \the\wd0 bar}
\message{Hello \the\wd0{} bar}
\message{Hello \the\wd0\space bar}
\message{Hello \the\wd0\space bar foo}
\message{Hello \the\wd0\spac\spac bar foo}
\message{Hello \the\wd0\spac\spac bar f\nl oo}


# (find-texbookfile "texbook.tex" "&plain \\input story")
# (find-texbookfile "texbook.tex" "nonstopmode")

# (find-es "tex" "show_and_tracing")
# (find-plainsrcfile "plain.tex" "\\def\\space{ }")


{\catcode`\^^M=\active % these lines must end with %
  \gdef\obeylines{\catcode`\^^M\active \let^^M\par}%


% (find-texbookfile "texbook.tex" "^\\<integer parameter>" "^|\\newlinechar|")

http://edition.cnn.com/2009/WORLD/meast/05/08/kentucky.iraq.soldier.rape/index.html?iref=mpstoryview






# (find-lsrcgrep "grep -nH -e scriptsize base/*")
# (find-lsrcfile "base/classes.dtx" "\\begin{macro}{\\scriptsize}")



# (find-fline "/usr/share/texmf-tetex/source/latex/amslatex/math/")
/usr/share/texmf-tetex/source/latex/amslatex/math/amsmath.dtx
/usr/share/texmf-tetex/source/latex/amslatex/math/amsmath.sty
/usr/share/texmf-tetex/source/latex/amsmath/
/usr/share/texmf-tetex/source/latex/amsmath/00readme.txt
/usr/share/texmf-tetex/source/latex/amsmath/amsbsy.dtx










lucida
charter

#*
# (eev-bounded)
cd /usr/share/texmf/source/latex/
# grep -i lucida $(find * -type f)
# grep -i charter $(find * -type f)
grep -i declarefixedfont $(find * -type f)

#*
# (find-lsrcfile "psnfss/00readme.txt" "Charter")
# (find-lsrcfile "psnfss/psnfss2e.tex")
# (find-lsrcfile "psnfss/psnfss2e.tex" "\\caption{Font shapes supported")
# (find-pspage (ee-lsrcfile "psnfss/psnfss2e.pdf") 9)


http://www.accesspdf.com/pdftk/


# (find-fline "/usr/share/doc/texmf/tetex/")
# (find-fline "/usr/share/doc/texmf/tetex/TETEXDOC.tex.gz")
zxdvi /usr/share/doc/texmf/tetex/TETEXDOC.dvi.gz

# (find-fline "/usr/doc/texmf/")

# (find-fline "/usr/doc/texmf/help/faq/uktug-faq/")
# (find-w3 "/usr/doc/texmf/help/faq/uktug-faq/index.html")
# (find-w3 "/usr/doc/texmf/index.html")

# (find-fline "/usr/bin/MakeTeXPK")
# (find-fline "/usr/bin/mktexmf")
# (find-fline "/usr/bin/mktexpk")

# (find-status "mime-support")
# (find-vldifile "mime-support.list")
# (find-fline "/usr/doc/mime-support/")
# (find-fline "/usr/doc/mime-support/mailcap.txt.gz")

http://truben.no/latex/table/
http://www.youtube.com/watch?v=yplX3pYWlPo Steve Jobs
http://www.anovaordemmundial.com/2009/09/filme-o-mundo-segundo-monsanto.html







#  Local Variables:
#  coding:               raw-text-unix
#  ee-delimiter-hash:    "\n#*\n"
#  ee-delimiter-percent: "\n%*\n"
#  ee-anchor-format:     "«%s»"
#  End: