home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 22 gnu / 22-gnu.zip / dvi2pm.zip / DVI2PM.DOC next >
Text File  |  1990-09-09  |  14KB  |  370 lines

  1.  
  2.                                  DVI2PM
  3.  
  4.  
  5.  
  6.      A public domain DVI Previewer for the OS/2 Presentation Manager
  7.  
  8.  
  9.                     written by Christian Monte
  10.              email:<zimmermann@iskp.physik.tu-berlin.dbp.de>
  11.  
  12.  
  13.  DVI2PM is derived from Doug McDonald's DVIVGA for the IBM PC
  14.  (see file changes.os2) and provides the same keyboard interface.
  15.  
  16.  
  17.  Mouse and Scrollbar interface will be made available in the near future. 
  18.  For now DVI2PM is just a keyboard driven TeX-Previewer. I'm sorry but i 
  19.  need it now and not tomorrow. So there is many room for improvements. 
  20.  Someday it should work with fonts rather then bitmaps. Maybe anybody has 
  21.  an idea who to turn a PK-font in a PM-screen font. 
  22.  
  23.  
  24.  DVI2PM is a TeX screen previewer for OS/2 PM. It expects the name of
  25.  the .DVI file on the command line, and the extension .dvi can always
  26.  be omitted. If no command line arguments are given, the filename can
  27.  be set from the open menu.
  28.  
  29.  
  30.            This driver is based on a driver family written by
  31.            Nelson Beebe of the University of Utah and others.
  32.  
  33.  
  34.  EQUIPMENT REQUIREMENTS
  35.  
  36.  A Computer running OS/2 Presentation Manager. The program is developed
  37.  an tested with IBM OS/2 SE 1.2 and MSC 6.0. It does not support long
  38.  filenames and extended attributes.
  39.  
  40.  
  41.  COMMAND LINE OPTIONS
  42.  
  43.  The order of command options and .DVI file name is not significant; all
  44.  switch values are accepted by this driver, but not all are really
  45.  meaningful.
  46.  
  47.  Letter case is ignored in option switches:  -A and -a are equivalent.
  48.  
  49.                 -a Implement virtual font caching. This option is
  50.                    essentially useless for this driver.
  51.  
  52.                 -d Produce debugging output on stderr if a non-zero
  53.                    value is given.  These are:
  54.  
  55.                      2 --- Display coordinates, metrics, and bitmap
  56.                            of each character.
  57.                      8 --- Display each successful file opening.
  58.                     16 --- Display each unsuccessful file opening.
  59.                     32 --- Show discarded off-page text.
  60.                     64 --- Trace virtual font caching.
  61.                    128 --- Trace character setting.
  62.  
  63.                    It is possible to combine these options by adding
  64.                    their values.
  65.  
  66.            IMPORTANT:
  67.            It is at this time not possible to view debug output
  68.            in a PM window. To inspect debug results stderr can be
  69.              redirected to a file. For example:
  70.                DVI2PM -d24 test.dvi 2> debug.out
  71.  
  72.        -eVAR=value Define environment variables on command line. This
  73.                    is an alternative to placing them in the DOS
  74.                    environment.
  75.  
  76.  
  77.      -ffontsubfile Define an alternate font substitution file which is
  78.                    to be used instead of the default ones (see below).
  79.  
  80.                 -l Inhibit logging.
  81.  
  82.                 -m Reset magnification. The default for the screen
  83.                                                                   (k/2)
  84.                    driver is -m502. Useful values are int(1500*1.2     )
  85.                    from 279 to 1500. Other values will be reset to the
  86.                    nearest value in this set. Magnification values less
  87.                    than 25 are taken to be a TeX magstep parameter
  88.                    which is applied to the standard magnification for
  89.                    that device. Thus -m-0.5 will reduce the output size
  90.                    by the square root of 1.2, -m2 will increase it by 
  91.                    a factor of 1.44.
  92.  
  93.                    You may well need to use this parameter frequently;
  94.                    good values to try are 603, 502, 459, 419, 382,
  95.                    349, 318, and 289. These are equivalent to -m0.5,
  96.                    -m-0.5, -m-1, ... -m-3.5. -m382 or -m-2 gives actual
  97.                    size output using VGA on an IBM8513 monitor.
  98.                    
  99.                    Sizes smaller than 459 use substitute fonts, so that
  100.                    they may not come out looking quite perfect.
  101.  
  102.                    Read about "Batch Files" to find an easy way of
  103.                    changing sizes.
  104.  
  105.  
  106.           -x#units The -x options specify the left margin of the TeX
  107.                    page on the output page in any of several units.
  108.                    Letter case is not significant in the units field,
  109.                    which must not be separated from the number by any
  110.                    space.  The number may be fractional.  For example,
  111.                    -x1.0in, -x2.54cm, -x72.27pt, and -x6.0225pc all
  112.                    specify a one-inch left margin. Negative values are
  113.                    permissible, and may be used to shift the output
  114.                    page left (possibly truncating it on the left) in
  115.                    order to display a wide TeX page.
  116.  
  117.                    The units field is mandatory, and may be one of
  118.  
  119.                            big point (1in = 72bp)
  120.                            cicero (1cc = 12dd)
  121.                            centimeter (1in = 2.54cm)
  122.                            didot point (1157dd = 1238pt)
  123.                            inch
  124.                            millimeter (10mm = 1cm)
  125.                            pica (1pc = 12pt)
  126.                            point (72.27pt = 1in)
  127.                            scaled point (65536sp = 1pt)
  128.  
  129.           -y#units This is just like -x except that it is for the top
  130.                    margin.
  131.  
  132.                    Because the normal defaults waste screen space, the
  133.                    defaults for the screen driver have both been set to
  134.                    zero. If you wish to get the correct margins and
  135.                    size, try -x1.in -y1.in -m382 for DVIVGA.
  136.  
  137.  
  138.  
  139.  FONT SUBSTITUTION
  140.  
  141.  If no -ffontsubfile option is given, and font substitution is required,
  142.  if the current .DVI file is  foo.dvi, then the files  foo.sub,
  143.  texfonts.sub, and TEXINPUTS\texfonts.sub will be tried in order.  The
  144.  first two will be found on the current directory, and the last is the
  145.  default given in the environment string TEXINPUTS.  The -f option
  146.  allows all of these to be overridden. It is essentially necessary to
  147.  have this file if you use a magnification smaller than the default for
  148.  DVI2PM. A copy of a suitable one is supplied.
  149.  
  150.  Font substitution lines have the form:
  151.  
  152.  
  153.              oldname.oldmag      subname.submag   % comment
  154.              oldname oldmag      subname submag   % comment
  155.              oldname             subname          % comment
  156.  
  157.  Examples are:
  158.  
  159. ----------
  160.  
  161.  % These provide replacements for some LaTeX invisible fonts:
  162.  icmr10 1500     ->      cmr10 1500      % comment
  163.  icmr10.1500     ->      cmr10.1500      % comment
  164.  icmssb8         ->      cmssb8          % comment
  165.  
  166. ----------
  167.  
  168.  
  169.  The first two forms request substitution of a particular font and
  170.  magnification. The third form substitutes an entire font family; the
  171.  closest available magnification to the required one will be used.  Any
  172.  dots in the non-comment portion will be converted to spaces, and
  173.  therefore, cannot be part of a name field.
  174.  
  175.  The first matching substitution will be selected, so
  176.  magnification-specific substitutions should be given first, before
  177.  family substitutions.
  178.  
  179.  Comments are introduced by percent and continue to end-of-line, just as
  180.  for TeX. One whitespace character is equivalent to any amount of
  181.  whitespace. Whitespace and comments are optional.
  182.  
  183.  
  184.  
  185.  SCREEN CONTROL
  186.  
  187.  DVI2PM supports interactive viewing of the TeX output. Here is the
  188.  current command list. Input is immediate; no terminating carriage
  189.  return is necessary, except for the number command to go to a
  190.  particular page.
  191.  
  192.  home              Displays first page.
  193.  
  194.  end               Displays last page.
  195.  
  196.  pageup            Displays previous page.
  197.  
  198.  pagedown          Displays next page.
  199.  
  200.  number keys       Goto page. For example: "66 <ENTER>" diplays page 66.
  201.  
  202.  uparrow downarrow Move the view of the current page up or down. These
  203.                    commands do not require recalculating the screen
  204.                    image and are very fast.
  205.  
  206.                  D Move the page origin one inch down.
  207.  
  208.                  d Move the page origin one-quarter inch down.
  209.  
  210.                  U Move the page origin one inch up.
  211.  
  212.                  u Move the page origin one-quarter inch up.
  213.  
  214.                  L Move the page origin one inch left.
  215.  
  216.     leftarrow or l Move the page origin one-quarter inch right.
  217.  
  218.                  R Move the page origin one inch right.
  219.  
  220.    rightarrow or r Move the page origin one-quarter inch right.
  221.                    "Inches" refers to the "printed" page, and is only
  222.                    approximate on the screen.
  223.  
  224.  
  225.                  Q (or q or X or x or Ctrl Break or Ctrl C or Ctrl Y) Quit
  226.                    or exit.  The screen will be cleared and restored to
  227.                    its normal mode.
  228.  
  229.                  B Zoom up one magstep (1.2 times larger) from current
  230.                    size.
  231.  
  232.                  b Zoom up 1/2 magstep (1.09 times larger) from
  233.                    current size.
  234.  
  235.                  S Zoom down one magstep (1.2 times smaller) from
  236.                    current size.
  237.  
  238.                  s Zoom down 1/2 magstep (1.09 times smaller) from
  239.                    current size.
  240.  
  241.                    How well these zoom options work depends on how many
  242.                    fonts you have loaded: more is better.
  243.  
  244.                    The command sequence RDSS will result in a display of
  245.                    approximately the same size and origin as a printed
  246.                    page if your physical display is the same size as
  247.                    the IBM 8513, and you start at the normal defaults.
  248.  
  249.  
  250.  FONTSIZE MENU
  251.  
  252.  Zooms the page according to selected fontsize.
  253.  
  254.         fontsize   |    equivalent magnification
  255.         ----------------------------------------
  256.          92       |     459    
  257.         100       |     502
  258.         110       |     550    defualt value
  259.         121       |     603
  260.         132       |     660
  261.         145       |     723
  262.         174       |     868
  263.         208       |    1042
  264.         250       |    1250
  265.         300       |    1500 
  266.  
  267.  SPECIALS
  268.  
  269.  The TeX \special command is intended to allow the specification in a
  270.  .tex file of a request to the .DVI driver, usually for the insertion
  271.  of graphical material at that point in the document.  It is not
  272.  implemented for the DVI2PM driver.
  273.  
  274.  
  275.  BATCH FILES
  276.  
  277.  If you need to use other than the default size a lot, for instance if
  278.  your text is wider than 5.6 inches, you can make this convenient by
  279.  using a batch file. For example, make a batch file, say DVIWIDE.CMD
  280.  containing the line
  281.  
  282.                       DVI2PM -m459 -x0.1in %1
  283.  
  284.  and nothing else. Then if you say "DVIWIDE filename" you will get your
  285.  6.5 inch wide file to fit on the page. You can of course adjust these
  286.  numbers for your own favorite text shape, and can change other things
  287.  as well.
  288.  
  289.  
  290.  ENVIRONMENT VARIABLES
  291.  
  292.  The behaviour of the .DVI translators can be influenced by definition
  293.  of logical names under OS/2. They should be
  294.  entirely in upper case.
  295.  
  296.  The names currently recognized are as follows:
  297.  
  298.     FONTLIST  Normally, the drivers are prepared to search first for
  299.               .pk, then  .gf, then .pxl font files. This variable can
  300.               be used to change this search order, or remove one or
  301.               more of the possibilities.  It is expected to contain at
  302.               least one of the strings  PK,  GF, or PXL, possibly
  303.               separated by arbitrary punctuation and other text. Letter
  304.               case is not significant.    Some acceptable strings are
  305.               PXL-then-PK-then-GF,  pk.gf,  use-only-PXL-fonts, and
  306.               PXL/GF/PK. For the fonts provided with this product, use
  307.               "set FONTLIST=pk".
  308.  
  309.     TEXFONTS  This defines the directory path for finding font files.
  310.               Its value is  prepended to the name of a  font to get a
  311.               full file specification.  A typical value for TEXFONTS
  312.               would be d:\tex\texfonts\. 
  313.  
  314.     TEXINPUTS This defines the directory path for finding files which
  315.               are not in the current working directory. It is
  316.               prepended to file names. A typical value for TEXINPUTS
  317.               would be d:\tex\texinput\
  318.  
  319.  
  320.  You can omitting FONTLIST (which at worst would slow things down a bit).
  321.  You could get rid of TEXINPUTS entirely by putting a copy of texfonts.sub
  322.  in your current directory. 
  323.  
  324.  
  325.  
  326.  DIRECTORY STRUCTURE FOR FONTS
  327.  
  328.  The fonts have to be placed in a proper manner. Assuming you set, as I
  329.  do, TEXFONTS to d:\tex\texfonts\, you need to place all the fonts
  330.  for size 100 in directory d:\tex\texfonts\100, those for size 121 in
  331.  d:\tex\texfonts\121, etc. Note that this implies that you will have
  332.  a lot of subdirectories with names that are numbers. These numbers
  333.  are dot per inch values, and are 1/5 the "magnification value" used
  334.  with the "m" command line parameter. It is traditional to put .pk
  335.  and .gf fonts in directories numbered like that. Pixel (.pxl) files
  336.  are, on the other hand, placed in directories with the magnification
  337.  value in their name. Thus \100\cmr10.pk and \502\cmr10.pxl are likely
  338.  the same font. It appears that PcTeX uses .pxl files a lot for their
  339.  drivers. DVI2PM will use those if they are in the size series it expects.
  340.  Having .pk and .pxl files in the same directory structure PROBABLY
  341.  won't hurt, though it has not been tested. There is nothing magic
  342.  about these directory names - if you like \pixel\ instead of \texfonts\,
  343.  perhaps because it is already there, use it instead.
  344.  
  345.  
  346.  
  347.  BUGS
  348.  
  349.  May appear because the program is not tested under all conditions.
  350.  
  351.  
  352.  
  353.  WARRANTIES
  354.  
  355.  This program is distributed in the hope that it will be useful, but
  356.  without any warranty.
  357.  
  358.  
  359.  
  360.  
  361.  
  362.  
  363.  
  364.  
  365.  
  366.  
  367.  
  368.  
  369. 
  370.