HiTEX: Reflowable Output for TEX
Reflowable Output for
If you want to know what this is about, read the introductory paper
in TUGBoat issue 39:3, 2018: HINT: Reflowing TEX Output.
- This is a pre-release of the hitex program. It is still buggy but can be use to conduct experiments.
- There is currently no support for output templates.
- The support for tables is limmited and largely untested.
- You need a full installation of TEX to begin with.
Find out where your installation stores the binaries.
For example by running which latex.
It will answer somethink like /usr/share/texmf/bin/latex
Store the hinitex binary in the same directory.
This is important because part of the search path, which the kpathsearch
library uses to find input files, is relative to your home directory and the
other part is relative to the program location.
You probably need administrator rights to access the directory and
- depending on your download program and operating system -
you must make the file executable.
On linux use chmod 755 hinitex.
- If you do not have administrator rights, check below for instructions
how to install hitex locally.
- You have to add two (symbolic) links named hitex and hilatex
for example using the command ln -s hinitex hitex
and ln -s hinitex hilatex.
There is only one program hinitex but when you call it
under the name hitex it will load the
hitex.fmt format file.
And when you call it as hilatex,
it will load the hilatex.fmt format file.
- Find out where your installation stores the format files.
For example by running kpsewhich latex.fmt.
It will answer something like /usr/share/texmf-var/web2c/latex.fmt.
Another method is running kpsewhich --show-path fmt which
prints a lengthy search path.
Store the format files hitex.fmt and
hilatex.fmt in the same directory
(you might again need administrator rights for this).
You might need to run mktexlsr because the kpathsearch library
will first check the ls-r files, and if found will then not
check the directories. Again you probably need administrator rights.
These format files have hyphenation tables only for german and english.
If you need different languages, you need to configure
your language.dat file and generate your own format files.
Since hinitex is based on Don Knuths
distribution, it will run out of memory if you try to add all
the languages that a typical installation
of TEX offers today.
- If the precompiled binaries do not fit your needs here are the C
source and header files as well as a simple Makefile: hitex.tgz
You need the kpathsea library installed on your system to compile the program. Once you have the hinitex binary,
proceed with the installation instructions as above. Unless you change the sources, you can use the same format files.
- If you must install hitex localy, you can put the executable
files somewhere on your search path. Check your PATH variable
for a directory where you have write access. If there is none, you have
to change your path variable or explicitely specify the path each time
you run the executable. Then (see next paragraph) run kpsewhich
with debugging enabled and see if the search path includes some directory
relative to your home directory. On UNIX machines this is usually the case.
You can store the format files then into these local directories.
- If your new hitex program has problems finding its input
files, set the environment variable KPATHSEA_DEBUG to some small
value. Something like export KPATHSEA_DEBUG=3 or 12
should be enough.
Running hitex with this variable set will give you lots of
information about which files and directories are considered. You can
compare this to a run of regular tex or latex and
see where the differences are.
If all breaks down (well, this is a prototype and not a distribution) locate
the files and copy them into your working directory. The current directory
is usually the first item in the search path.
- It some kpathsearch library expert is reading this and has suggestions
for improving these instructions, please let me know!
Errata and Improvements
- Segmentation fault if commandline nonempty and file not found
Fixed: March 30, 2020
- time, day, month, and year are set to 4. July 1776
Fixed: March 30, 2020. They are set using GMT.
- If you want to know how to compile, run, and test the programs,
see the instructions above.
- If you have read the instructions and still have questions, send me an email to ruckert (at) cs.hm.edu
- If you want to help, send me immediately an email to ruckert (at) cs.hm.edu.
Back to the project home page