Back to index

tetex-bin  3.0
Functions | Variables
out_routines.c File Reference
#include "cpascal.h"
#include "list_routines.h"
#include "manifests.h"
#include "omfonts.h"
#include "out_routines.h"
#include "error_routines.h"
#include "header_routines.h"
#include "char_routines.h"

Go to the source code of this file.

Functions

void out_character_measure (unsigned measure)
void out_extensible_piece (unsigned piece)
void out_ligature_command (unsigned command)
void print_xerox_face (int face)
void out_named_parameter (unsigned parameter)
void out_named_mathsy_parameter (unsigned parameter)
void out_named_mathex_parameter (unsigned parameter)
void out_type_direction (unsigned direction)
void out_accent_kind (unsigned kind)
void out_move_direction (unsigned direction)
void out_rule_measure (unsigned measure)
void out_shrink_stretch (unsigned shrink_stretch)
void out_glue_order (unsigned order)
void out_glue_kind (unsigned kind)
void out_ln (void)
void left (void)
void right (void)
void out_char (unsigned val)
void out_num (unsigned val)
void out_int (unsigned val, unsigned base)
void out_as_fix (fix fval)
void out_fix (fix fval)
void out_digits (unsigned counter)
void out (string sval)

Variables

string character_measures []
string extensible_pieces []
string ligature_commands []
string xerox_faces []
string named_parameters []
string named_mathsy_parameters []
string named_mathex_parameters []
string type_directions []
string actual_directions []
string accent_kinds []
string move_directions []
string rule_measures []
string glue_shrink_stretch []
string glue_orders []
string glue_kinds []
unsigned parenthesis_level = 0
unsigned digits [12]

Function Documentation

void left ( void  )

Definition at line 268 of file out_routines.c.

{
    parenthesis_level++; out("(");
}
void out ( string  sval)

Definition at line 378 of file out_routines.c.

{
       fprintf(file_output, sval);
}

Here is the call graph for this function:

void out_accent_kind ( unsigned  kind)

Definition at line 175 of file out_routines.c.

{
    if ((kind < ACC_TOP) || (kind > ACC_BOT)) {
       internal_error_1("out_accent_kind (kind=%d)", kind);
    }
    out(accent_kinds[kind]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_as_fix ( fix  fval)

Definition at line 322 of file out_routines.c.

{
       register fix x=0;

       if (fval<0) {
              x = 0xff000000;
              fval = fval + 0x1000000;
       }
       x = x | (fval & 0xff);
       fval = fval % 0x100;
       x = x | ((fval & 0xff) << 8);
       fval = fval % 0x100;
       x = x | ((fval & 0xff) << 16);
        out_fix(x);
}

Here is the call graph for this function:

void out_char ( unsigned  val)

Definition at line 281 of file out_routines.c.

{
        if (char_format==CHAR_CODE_NUM) out_num(val);
        else if (font_type!=FT_VANILLA) out_num(val);
        else if (((val>='0') && (val<='9')) ||
                 ((val>='A') && (val<='Z')) ||
                 ((val>='a') && (val<='z')))
           fprintf(file_output, "C %c", val);
        else out_num(val);
}

Here is the call graph for this function:

void out_character_measure ( unsigned  measure)

Definition at line 44 of file out_routines.c.

{
    if ((measure < C_MIN) || (measure > C_MAX) ||
        (character_measures[measure]==NULL)) {
       internal_error_1("out_character_measure (measure=%d)", measure);
    }
    out(character_measures[measure]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_digits ( unsigned  counter)

Definition at line 367 of file out_routines.c.

{
       register unsigned j=counter, c;
       while (j>0) {
              c = digits[--j];
              if (c<10) fprintf(file_output, "%c", c+'0');
              else fprintf(file_output, "%c", c+'A'-10);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_extensible_piece ( unsigned  piece)

Definition at line 59 of file out_routines.c.

{
    if ((piece < E_MIN) || (piece > E_MAX)) {
       internal_error_1("out_extensible_piece (piece=%d)", piece);
    }
    out(extensible_pieces[piece]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_fix ( fix  fval)

Definition at line 339 of file out_routines.c.

{
       register int a = (fval & 0xfff00000) >> 20, f = fval & 0xfffff, j=0;
       register int delta;

       out("R ");
       if (a>0x7ff) {
              out("-"); a = 0x1000 - a;
              if (f>0) {
                     f = 0x100000 - f; a--;
              }
       }
       do {
              digits[j] = a % 10;
              j++;
              a = a / 10;
       } while (a > 0);
       out_digits(j);
       out(".");
       f = 10*f + 5; delta = 10;
       do {
              if (delta>0x100000) f = f + 0x80000 - (delta / 2);
              fprintf(file_output, "%c", (f / 0x100000) + '0');
              f = 10 * (f % 0x100000); delta = delta*10;
       } while (f>delta);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_glue_kind ( unsigned  kind)

Definition at line 246 of file out_routines.c.

{
    if ((kind < K_MIN) || (kind > K_MAX)) {
       internal_error_1("out_glue_kind (kind=%d)", kind);
    }
    out(glue_kinds[kind]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_glue_order ( unsigned  order)

Definition at line 232 of file out_routines.c.

{
    if ((order < O_MIN) || (order > O_MAX)) {
       internal_error_1("out_glue_order (order=%d)", order);
    }
    out(glue_orders[order]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_int ( unsigned  val,
unsigned  base 
)

Definition at line 300 of file out_routines.c.

{
       register unsigned j=0, acc=val;
       if (val < 0) internal_error_1("out_int (val=%d)", val);
       if (base==16)      out("H ");
       else if (base==10) out("D ");
       else if (base==8)  out("O ");
       else internal_error_1("out_int (base=%d)", base);
       do {
              digits[j] = acc % base;
              j++;
              acc = acc / base;
       } while (acc > 0);
/*
        if ((base==16) && (ec>=0x100)) {
            while (j<4) { digits[j] = 0; j++; }
        }
*/
       out_digits(j);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_ligature_command ( unsigned  command)

Definition at line 75 of file out_routines.c.

{
    if ((command < L_MIN) || (command > L_MAX) ||
        (ligature_commands[command]==NULL)) {
       internal_error_1("out_ligature_command (command=%d)", command);
    }
    out(ligature_commands[command]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_ln ( void  )

Definition at line 260 of file out_routines.c.

{
    unsigned i;
    out("\n");
    for (i = 0; i < parenthesis_level; i++) out("   ");
}

Here is the caller graph for this function:

void out_move_direction ( unsigned  direction)

Definition at line 189 of file out_routines.c.

{
    if ((direction < M_MIN) || (direction > M_MAX)) {
       internal_error_1("out_move_direction (direction=%d)", direction);
    }
    out(move_directions[direction]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_named_mathex_parameter ( unsigned  parameter)

Definition at line 142 of file out_routines.c.

{
    if ((parameter < P_MATHEX_MIN) || (parameter > P_MATHEX_MAX) ||
        (named_mathex_parameters[parameter]==NULL)) {
       internal_error_1("out_named_mathex_parameter (parameter=%d)",parameter);
    }
    out(named_mathex_parameters[parameter]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_named_mathsy_parameter ( unsigned  parameter)

Definition at line 124 of file out_routines.c.

{
    if ((parameter < P_MATHSY_MIN) || (parameter > P_MATHSY_MAX) ||
        (named_mathsy_parameters[parameter]==NULL)) {
       internal_error_1("out_named_mathsy_parameter (parameter=%d)",parameter);
    }
    out(named_mathsy_parameters[parameter]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_named_parameter ( unsigned  parameter)

Definition at line 107 of file out_routines.c.

{
    if ((parameter < P_MIN) || (parameter > P_MAX)) {
       internal_error_1("out_named_parameter (parameter = %d)", parameter);
    }
    out(named_parameters[parameter]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_num ( unsigned  val)

Definition at line 293 of file out_routines.c.

{
        if (num_format==NUM_CODE_OCTAL) out_int(val, 8);
        else out_int(val, 16);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_rule_measure ( unsigned  measure)

Definition at line 203 of file out_routines.c.

{
    if ((measure < RULE_MIN) || (measure > RULE_MAX)) {
       internal_error_1("out_rule_measure (measure=%d)", measure);
    }
    out(rule_measures[measure]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_shrink_stretch ( unsigned  shrink_stretch)

Definition at line 217 of file out_routines.c.

{
    if ((shrink_stretch < GLUE_MIN) || (shrink_stretch > GLUE_MAX)) {
       internal_error_1("out_shrink_stretch (shrink_stretch=%d)",
                         shrink_stretch);
    }
    out(glue_shrink_stretch[shrink_stretch]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void out_type_direction ( unsigned  direction)

Definition at line 160 of file out_routines.c.

{
    if ((direction < DIR_MIN) || (direction > DIR_MAX)) {
       internal_error_1("out_type_direction (direction=%d)", direction);
    }
    out(type_directions[direction/8]); out(" ");
    out(actual_directions[direction%8]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 92 of file out_routines.c.

{
    if ((face < F_MIN) || (face > F_MAX)) {
       internal_error_1("print_xerox_face (face=%d)", face);
    }
    out("F "); out(xerox_faces[face]);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void right ( void  )

Definition at line 274 of file out_routines.c.

Here is the call graph for this function:


Variable Documentation

Initial value:
     { NULL, "TOPACCENT", "MIDACCENT", "BOTACCENT", NULL }

Definition at line 171 of file out_routines.c.

Initial value:
     { "TL", "LT", "TR", "RT", "LB", "BL", "BR", "RB", NULL }

Definition at line 156 of file out_routines.c.

Initial value:
     { "CHARWD",      "CHARHT",         "CHARDP",        "CHARIC",
       "SECWD",       "SECHT",          "SECDP",         "SECIC",
       "PRIMTOPAXIS", "PRIMTOPAXISBIS", "PRIMBOTAXIS",   "PRIMBOTAXISBIS",
       "PRIMMIDHOR",  "PRIMMIDVERT",    "PRIMBASESLANT", NULL,
       "SECTOPAXIS",  "SECTOPAXISBIS",  "SECBOTAXIS",    "SECBOTAXISBIS",
       "SECMIDHOR",   "SECMIDVERT",     "SECBASESLANT",  NULL}

Definition at line 35 of file out_routines.c.

unsigned digits[12]

Definition at line 255 of file out_routines.c.

Initial value:
     { "TOP", "MID", "BOT", "REP", NULL }

Definition at line 55 of file out_routines.c.

Initial value:
     { "NORMAL", "ALEADERS", "CLEADERS", "ALEADERS", "XLEADERS", NULL }

Definition at line 242 of file out_routines.c.

Initial value:
     { "UNIT", "FI", "FIL", "FILL", "FILLL", NULL }

Definition at line 228 of file out_routines.c.

Initial value:
     { "GLUESHRINK", "GLUESTRETCH", NULL }

Definition at line 213 of file out_routines.c.

Initial value:
     { "LIG", "LIG/", "/LIG", "/LIG/", NULL,
       "LIG/>", "/LIG>", "/LIG/>", NULL, NULL,
       NULL, "/LIG/>>", NULL }

Definition at line 69 of file out_routines.c.

Initial value:
     { "MOVERIGHT", "MOVELEFT", "MOVEUP", "MOVEDOWN", NULL }

Definition at line 185 of file out_routines.c.

Initial value:
    { NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
      "DEFAULTRULETHICKNESS", "BIGOPSPACING1",
      "BIGOPSPACING2",        "BIGOPSPACING3",
      "BIGOPSPACING4",        "BIGOPSPACING5", NULL }

Definition at line 135 of file out_routines.c.

Initial value:
    { NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
      "NUM1",   "NUM2",    "NUM3",      "DENOM1",
      "DENOM2",  "SUP1",       "SUP2",   "SUP3",    "SUB1",      "SUB2",
      "SUPDROP", "SUBDROP",    "DELIM1", "DELIM2",  "AXISHEIGHT", NULL }

Definition at line 117 of file out_routines.c.

Initial value:
    { NULL,      "SLANT",      "SPACE",  "STRETCH", "SHRINK",    "XHEIGHT",
      "QUAD",    "EXTRASPACE", NULL }

Definition at line 102 of file out_routines.c.

unsigned parenthesis_level = 0

Definition at line 254 of file out_routines.c.

Initial value:
     { "RULEWD", "RULEHT", "RULEDP", NULL }

Definition at line 199 of file out_routines.c.

Initial value:
     { "FONTDIR", "NATURALFONTDIR", NULL }

Definition at line 153 of file out_routines.c.

Initial value:
    { "MRR", "MIR", "BRR", "BIR", "LRR", "LIR",
      "MRC", "MIC", "BRC", "BIC", "LRC", "LIC",
      "MRE", "MIE", "BRE", "BIE", "LRE", "LIE", NULL }

Definition at line 86 of file out_routines.c.