home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Source Code 1993 July / THE_SOURCE_CODE_CD_ROM.iso / gnu / graphics-0.17 / plot2ps / alabel.c next >
Encoding:
C/C++ Source or Header  |  1991-03-11  |  20.9 KB  |  596 lines

  1. /* plot2ps, a utility for converting Unix plot files into postscript.
  2.    Copyright (C) 1989 Free Software Foundation, Inc.
  3.  
  4. Plot2ps is distributed in the hope that it will be useful, but WITHOUT ANY
  5. WARRANTY.  No author or distributor accepts responsibility to anyone for the
  6. consequences of using it or for whether it serves any particular purpose or
  7. works at all, unless he says so in writing.  Refer to the GNU General Public
  8. License for full details.
  9.  
  10. Everyone is granted permission to copy, modify and redistribute plot2ps, but
  11. only under the conditions described in the GNU General Public License.  A copy
  12. of this license is supposed to have been given to you along with plot2ps so
  13. you can know your rights and responsibilities.  It should be in a file named
  14. COPYING.  Among other things, the copyright notice and this notice must be
  15. preserved on all copies.  */
  16.  
  17. #include "sys-defines.h"
  18. #include "libplot.h"
  19.  
  20. /* CURRENT_FONT is a string containing the name of the current font.  Since
  21.    postscript symbols must generally be less that 256 characters long, we can
  22.    reasonably assume that the name will fit in a string this long. */
  23.  
  24. char* current_font = 0;
  25.  
  26. /* DEFAULT_FONT is a string containing the name of the default font.
  27.    This string should be a valid match for one of the font names.
  28.    It is allocated and set in openpl(). */
  29.  
  30. char* default_font = 0;
  31.  
  32. /* FIND_FONT takes a string argument S containing a font name and returns the
  33.    index of the font structure FONT_INFO corresponding to that name. If no match
  34.    is found for the font name, an error message is printed and the index of the
  35.    default font is returned. */
  36.  
  37. int find_font(s)
  38.      char *s;
  39. {
  40.   int font_index;
  41.   for (font_index=0; font_index<NO_OF_FONTS; font_index++)
  42.     {
  43.       if (strcmp (font_info[font_index].name, s) == 0)
  44.     return font_index;
  45.     }
  46.   fprintf (stderr, "Unable to find font `%s'. Using default font `%s'.\n",
  47.        current_font, default_font);
  48.   font_index = find_font (default_font);
  49.  
  50.   return font_index;
  51. };
  52.  
  53. /* STRING_WIDTH is takes a string argument and returns the width of the
  54.    string in font coordinates (1/1000 points). */
  55.  
  56. int
  57. string_width (s)
  58.      char *s;
  59. {
  60.   int indx = 0;
  61.   int width = 0;
  62.   int font_index;
  63.   
  64.   font_index = find_font (current_font);
  65.  
  66.   for (indx=0; s[indx]!='\0'; indx++)
  67.     width += font_info[font_index].width[ s[indx]];
  68.  
  69.   return width;
  70. }
  71.  
  72.  
  73. /* TEXT_ROTATION is the angle in degress counterclockwise from the
  74.    horizontal for rotation of labels. */
  75.  
  76. int text_rotation=0;
  77.  
  78. /* FONT_SIZE is the font size in printer's points (-f option). */
  79.  
  80. double font_size = 14.;
  81.  
  82. /* FONT_SCALING takes into account the font scaling by idraw.  Version 2.4
  83.    of idraw scales the whole drawing down by a factor of SCALING, we must
  84.    scale the fonts back up by 1.25 so that a 14 point fonts appears as
  85.    a 14 point font on the hardcopy. Version 2.5 of idraw does not seem
  86.    to need this adjustment, but it is left here for compatibility. */
  87.  
  88. double font_scaling = 1.;
  89.  
  90. /* ALABEL takes three arguments X_JUSTIFY, Y_JUSTIFY, and S and places
  91.    the label S according to the x and y axis adjustments specified in
  92.    X_JUSTIFY and Y_JUSTIFY respectively.  X_JUSTIFY is a character
  93.    containing either l, c, or r for left, center or right justified with
  94.    respect to the current x coordinate.  Y_JUSTIFY is a character
  95.    containing either b, c, or t for placing the bottom center or top of
  96.    the label even with the current y coordinate. S is a string containing
  97.    the label. The current point is moved to follow the end of the text. */
  98.  
  99. int
  100. alabel (x_justify, y_justify, s)
  101.      int x_justify, y_justify;
  102.      char *s;
  103. {
  104.   int i;
  105.   int font_index;
  106.   double width;
  107.   double x_char_offset = 0., y_char_offset = 0.;
  108.  
  109.   font_index = find_font (current_font);
  110.   draw_line ();
  111.   fputs ("Begin %I Text\n", stdout);
  112.   printf ("%%I cfg Black\n%g %g %g SetCFg\n",
  113.       fgcolor_red, fgcolor_green, fgcolor_blue);
  114.   printf("%%I f *%s*-%d-*\n", font_info[font_index].X_name, (int) (font_size));
  115.   printf ("/%s %g SetF\n", font_info[font_index].ps_name,
  116.       font_size * font_scaling);
  117.   fputs ("%I t\n[ ", stdout);
  118.   for (i=0; i<4; i++ )
  119.     printf ("%g ", text_transformation_matrix[i]);
  120.  
  121.   /* first we figure out the offsets, then apply them depending on rotation. */
  122.  
  123.   /* width in printer's points */
  124.   width = string_width (s) * font_size / 1000.;
  125.   switch (x_justify)
  126.     {
  127.     case 'l': /* left justified */
  128.       x_char_offset = 0.0;
  129.       break;
  130.  
  131.     case 'c': /* centered */
  132.       x_char_offset = -0.5;
  133.       break;
  134.  
  135.     case 'r': /* right justified */
  136.       x_char_offset = -1.0;
  137.       break;
  138.     }
  139.  
  140.   switch (y_justify)
  141.     {
  142.     case 'b': /* bottom */
  143.       y_char_offset = 1.0;
  144.       break;
  145.  
  146.     case 'c': /* centered */
  147.       y_char_offset = 0.5;
  148.       break;
  149.  
  150.     case 't': /* top */
  151.       y_char_offset = 0.0;
  152.       break;
  153.     }
  154.  
  155.   if (text_rotation == 90 )
  156.     {
  157.       printf ("%g ", x_output_min +
  158.           last_x/scaleup - font_size * font_scaling * y_char_offset);
  159.       printf ("%g ", y_output_min +
  160.           last_y/scaleup + width * font_scaling * x_char_offset);
  161.       set_range (last_x/scaleup - font_size * font_scaling * y_char_offset,
  162.          last_y/scaleup + width * font_scaling * x_char_offset);
  163.       set_range (last_x/scaleup - font_size * font_scaling *(y_char_offset-1.2),
  164.          last_y/scaleup + width * font_scaling * (x_char_offset+1.0));
  165.       last_y += width * scaleup;
  166.     }
  167.   else
  168.     {
  169.       printf ("%g ", x_output_min +
  170.           last_x/scaleup + width * font_scaling * x_char_offset);
  171.       printf ("%g ", y_output_min +
  172.           last_y/scaleup + font_size * font_scaling * y_char_offset);
  173.       set_range (last_x/scaleup + width * font_scaling * x_char_offset,
  174.          last_y/scaleup + font_size * font_scaling*(y_char_offset-1.2));
  175.       set_range (last_x/scaleup + width * font_scaling * (x_char_offset+1.0),
  176.          last_y/scaleup + font_size * font_scaling*(y_char_offset+.0));
  177.       last_x += width * scaleup;
  178.     }
  179.  
  180.   fputs (" ] concat\n\
  181. %I\n\
  182. [\n\
  183. (", stdout);
  184.   for (i=0; s[i]!='\0'; i++)
  185.     {
  186.       switch (s[i])
  187.     {
  188.     case '(':
  189.     case ')':
  190.     case '\\':
  191.       fputc ((char) '\\', stdout);
  192.     default:
  193.       fputc (s[i], stdout);
  194.     }
  195.     }
  196.   printf (")\n\
  197. ] Text\n\
  198. End\n\
  199. \n");
  200.   return 0;
  201. }
  202.  
  203.  
  204. struct font_info_struct font_info[NO_OF_FONTS] = {
  205. {
  206.   "courier-bold",
  207.   "courier-bold-r",
  208.   "Courier-Bold",
  209.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  210.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  211.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  212.  0, 0, 600, 600, 600, 600, 600, 600, 600, 600,
  213.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  214.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  215.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  216.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  217.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  218.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  219.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  220.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  221.  600, 600, 600, 600, 600, 600, 600, 0, 0, 0,
  222.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  223.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  224.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  225.  0, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  226.  600, 600, 600, 600, 0, 0, 0, 600, 600, 600,
  227.  600, 0, 600, 600, 600, 600, 600, 600, 600, 0,
  228.  0, 600, 0, 600, 600, 600, 600, 600, 600, 600,
  229.  600, 0, 600, 600, 0, 600, 600, 600, 600, 0,
  230.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  231.  0, 0, 0, 0, 0, 0, 0, 600, 0, 0,
  232.  0, 0, 600, 600, 0, 600, 0, 0, 0, 0,
  233.  0, 0, 0, 0, 0, 600, 0, 0, 600, 600,
  234.  0, 600, 0, 0, 0, 0}},
  235. {
  236.   "courier-boldoblique",
  237.   "courier-bold-o",
  238.   "Courier-BoldOblique",
  239.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  240.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  241.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  242.  0, 0, 600, 600, 600, 600, 600, 600, 600, 600,
  243.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  244.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  245.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  246.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  247.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  248.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  249.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  250.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  251.  600, 600, 600, 600, 600, 600, 600, 0, 0, 0,
  252.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  253.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  254.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  255.  0, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  256.  600, 600, 600, 600, 0, 0, 0, 600, 600, 600,
  257.  600, 0, 600, 600, 600, 600, 600, 600, 600, 0,
  258.  0, 600, 0, 600, 600, 600, 600, 600, 600, 600,
  259.  600, 0, 600, 600, 0, 600, 600, 600, 600, 0,
  260.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  261.  0, 0, 0, 0, 0, 0, 0, 600, 0, 0,
  262.  0, 0, 600, 600, 0, 600, 0, 0, 0, 0,
  263.  0, 0, 0, 0, 0, 600, 0, 0, 600, 600,
  264.  0, 600, 0, 0, 0, 0}},
  265. {
  266.   "courier-oblique",
  267.   "courier-medium-o",
  268.   "Courier-Oblique",
  269.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  270.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  271.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  272.  0, 0, 600, 600, 600, 600, 600, 600, 600, 600,
  273.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  274.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  275.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  276.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  277.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  278.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  279.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  280.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  281.  600, 600, 600, 600, 600, 600, 600, 0, 0, 0,
  282.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  283.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  284.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  285.  0, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  286.  600, 600, 600, 600, 0, 0, 0, 600, 600, 600,
  287.  600, 0, 600, 600, 600, 600, 600, 600, 600, 0,
  288.  0, 600, 0, 600, 600, 600, 600, 600, 600, 600,
  289.  600, 0, 600, 600, 0, 600, 600, 600, 600, 0,
  290.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  291.  0, 0, 0, 0, 0, 0, 0, 600, 0, 0,
  292.  0, 0, 600, 600, 0, 600, 0, 0, 0, 0,
  293.  0, 0, 0, 0, 0, 600, 0, 0, 600, 600,
  294.  0, 600, 0, 0, 0, 0}},
  295. {
  296.   "courier",
  297.   "courier-medium-r",
  298.   "Courier",
  299.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  300.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  301.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  302.  0, 0, 600, 600, 600, 600, 600, 600, 600, 600,
  303.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  304.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  305.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  306.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  307.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  308.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  309.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  310.  600, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  311.  600, 600, 600, 600, 600, 600, 600, 0, 0, 0,
  312.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  313.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  314.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  315.  0, 600, 600, 600, 600, 600, 600, 600, 600, 600,
  316.  600, 600, 600, 600, 0, 0, 0, 600, 600, 600,
  317.  600, 0, 600, 600, 600, 600, 600, 600, 600, 0,
  318.  0, 600, 0, 600, 600, 600, 600, 600, 600, 600,
  319.  600, 0, 600, 600, 0, 600, 600, 600, 600, 0,
  320.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  321.  0, 0, 0, 0, 0, 0, 0, 600, 0, 0,
  322.  0, 0, 600, 600, 0, 600, 0, 0, 0, 0,
  323.  0, 0, 0, 0, 0, 600, 0, 0, 600, 600,
  324.  0, 600, 0, 0, 0, 0}},
  325. {
  326.   "helvetica-bold",
  327.   "helvetica-bold-r",
  328.   "Helvetica-Bold",
  329.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  330.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  331.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  332.  0, 0, 556, 333, 474, 556, 556, 889, 722, 278,
  333.  333, 333, 389, 584, 278, 333, 278, 278, 556, 556,
  334.  556, 556, 556, 556, 556, 556, 556, 556, 333, 333,
  335.  584, 584, 584, 611, 975, 722, 722, 722, 722, 667,
  336.  611, 778, 722, 278, 556, 722, 611, 833, 722, 778,
  337.  667, 778, 722, 667, 611, 722, 667, 944, 667, 667,
  338.  611, 333, 278, 333, 584, 556, 278, 556, 611, 556,
  339.  611, 556, 333, 611, 611, 278, 278, 556, 278, 889,
  340.  611, 611, 611, 611, 389, 556, 333, 611, 556, 778,
  341.  556, 556, 500, 389, 280, 389, 584, 0, 0, 0,
  342.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  343.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  344.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  345.  0, 333, 556, 556, 167, 556, 556, 556, 556, 238,
  346.  500, 556, 333, 333, 611, 611, 0, 556, 556, 556,
  347.  278, 0, 556, 350, 278, 500, 500, 556, 1000, 1000,
  348.  0, 611, 0, 333, 333, 333, 333, 333, 333, 333,
  349.  333, 0, 333, 333, 0, 333, 333, 333, 1000, 0,
  350.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  351.  0, 0, 0, 0, 0, 1000, 0, 370, 0, 0,
  352.  0, 0, 611, 778, 1000, 365, 0, 0, 0, 0,
  353.  0, 889, 0, 0, 0, 278, 0, 0, 278, 611,
  354.  944, 611, 0, 0, 0, 0}},
  355. {
  356.   "helvetica-boldoblique",
  357.   "helvetica-bold-o",
  358.   "Helvetica-BoldOblique",
  359.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  360.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  361.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  362.  0, 0, 556, 333, 474, 556, 556, 889, 722, 278,
  363.  333, 333, 389, 584, 278, 333, 278, 278, 556, 556,
  364.  556, 556, 556, 556, 556, 556, 556, 556, 333, 333,
  365.  584, 584, 584, 611, 975, 722, 722, 722, 722, 667,
  366.  611, 778, 722, 278, 556, 722, 611, 833, 722, 778,
  367.  667, 778, 722, 667, 611, 722, 667, 944, 667, 667,
  368.  611, 333, 278, 333, 584, 556, 278, 556, 611, 556,
  369.  611, 556, 333, 611, 611, 278, 278, 556, 278, 889,
  370.  611, 611, 611, 611, 389, 556, 333, 611, 556, 778,
  371.  556, 556, 500, 389, 280, 389, 584, 0, 0, 0,
  372.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  373.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  374.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  375.  0, 333, 556, 556, 167, 556, 556, 556, 556, 238,
  376.  500, 556, 333, 333, 611, 611, 0, 556, 556, 556,
  377.  278, 0, 556, 350, 278, 500, 500, 556, 1000, 1000,
  378.  0, 611, 0, 333, 333, 333, 333, 333, 333, 333,
  379.  333, 0, 333, 333, 0, 333, 333, 333, 1000, 0,
  380.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  381.  0, 0, 0, 0, 0, 1000, 0, 370, 0, 0,
  382.  0, 0, 611, 778, 1000, 365, 0, 0, 0, 0,
  383.  0, 889, 0, 0, 0, 278, 0, 0, 278, 611,
  384.  944, 611, 0, 0, 0, 0}},
  385. {
  386.   "helvetica-oblique",
  387.   "helvetica-medium-o",
  388.   "Helvetica-Oblique",
  389.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  390.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  391.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  392.  0, 0, 556, 278, 355, 556, 556, 889, 667, 222,
  393.  333, 333, 389, 584, 278, 333, 278, 278, 556, 556,
  394.  556, 556, 556, 556, 556, 556, 556, 556, 278, 278,
  395.  584, 584, 584, 556, 1015, 667, 667, 722, 722, 667,
  396.  611, 778, 722, 278, 500, 667, 556, 833, 722, 778,
  397.  667, 778, 722, 667, 611, 722, 667, 944, 667, 667,
  398.  611, 278, 278, 278, 469, 556, 222, 556, 556, 500,
  399.  556, 556, 278, 556, 556, 222, 222, 500, 222, 833,
  400.  556, 556, 556, 556, 333, 500, 278, 556, 500, 722,
  401.  500, 500, 500, 334, 260, 334, 584, 0, 0, 0,
  402.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  403.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  404.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  405.  0, 333, 556, 556, 167, 556, 556, 556, 556, 191,
  406.  333, 556, 333, 333, 500, 500, 0, 556, 556, 556,
  407.  278, 0, 537, 350, 222, 333, 333, 556, 1000, 1000,
  408.  0, 611, 0, 333, 333, 333, 333, 333, 333, 333,
  409.  333, 0, 333, 333, 0, 333, 333, 333, 1000, 0,
  410.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  411.  0, 0, 0, 0, 0, 1000, 0, 370, 0, 0,
  412.  0, 0, 556, 778, 1000, 365, 0, 0, 0, 0,
  413.  0, 889, 0, 0, 0, 278, 0, 0, 222, 611,
  414.  944, 611, 0, 0, 0, 0}},
  415. {
  416.   "helvetica",
  417.   "helvetica-medium-r",
  418.   "Helvetica",
  419.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  420.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  421.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  422.  0, 0, 556, 278, 355, 556, 556, 889, 667, 222,
  423.  333, 333, 389, 584, 278, 333, 278, 278, 556, 556,
  424.  556, 556, 556, 556, 556, 556, 556, 556, 278, 278,
  425.  584, 584, 584, 556, 1015, 667, 667, 722, 722, 667,
  426.  611, 778, 722, 278, 500, 667, 556, 833, 722, 778,
  427.  667, 778, 722, 667, 611, 722, 667, 944, 667, 667,
  428.  611, 278, 278, 278, 469, 556, 222, 556, 556, 500,
  429.  556, 556, 278, 556, 556, 222, 222, 500, 222, 833,
  430.  556, 556, 556, 556, 333, 500, 278, 556, 500, 722,
  431.  500, 500, 500, 334, 260, 334, 584, 0, 0, 0,
  432.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  433.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  434.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  435.  0, 333, 556, 556, 167, 556, 556, 556, 556, 191,
  436.  333, 556, 333, 333, 500, 500, 0, 556, 556, 556,
  437.  278, 0, 537, 350, 222, 333, 333, 556, 1000, 1000,
  438.  0, 611, 0, 333, 333, 333, 333, 333, 333, 333,
  439.  333, 0, 333, 333, 0, 333, 333, 333, 1000, 0,
  440.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  441.  0, 0, 0, 0, 0, 1000, 0, 370, 0, 0,
  442.  0, 0, 556, 778, 1000, 365, 0, 0, 0, 0,
  443.  0, 889, 0, 0, 0, 278, 0, 0, 222, 611,
  444.  944, 611, 0, 0, 0, 0}},
  445. {
  446.   "symbol",
  447.   "symbol-medium-r",
  448.   "Symbol",
  449.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  450.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  451.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  452.  0, 0, 500, 333, 713, 500, 549, 833, 778, 439,
  453.  333, 333, 500, 549, 250, 549, 250, 278, 500, 500,
  454.  500, 500, 500, 500, 500, 500, 500, 500, 278, 278,
  455.  549, 549, 549, 444, 549, 696, 660, 710, 612, 652,
  456.  763, 603, 765, 351, 631, 724, 686, 918, 739, 750,
  457.  768, 741, 580, 592, 632, 690, 439, 768, 645, 795,
  458.  650, 333, 863, 333, 658, 500, 500, 631, 549, 549,
  459.  494, 439, 521, 411, 603, 329, 603, 549, 549, 576,
  460.  521, 549, 549, 521, 549, 603, 439, 576, 713, 686,
  461.  493, 686, 494, 480, 200, 480, 549, 0, 0, 0,
  462.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  463.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  464.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  465.  0, 620, 247, 549, 167, 713, 500, 753, 753, 753,
  466.  753, 1042, 987, 603, 987, 603, 400, 549, 411, 549,
  467.  549, 713, 494, 460, 549, 549, 549, 549, 1000, 603,
  468.  1000, 658, 823, 686, 795, 987, 768, 768, 823, 768,
  469.  768, 713, 713, 713, 713, 713, 713, 713, 768, 713,
  470.  790, 790, 890, 823, 549, 250, 713, 603, 603, 1042,
  471.  987, 603, 987, 603, 494, 329, 790, 790, 786, 713,
  472.  384, 384, 384, 384, 384, 384, 494, 494, 494, 494,
  473.  790, 329, 274, 686, 686, 686, 384, 384, 384, 384,
  474.  384, 384, 494, 494, 494, 0}},
  475. {
  476.   "times-bold",
  477.   "times-bold-r",
  478.   "Times-Bold",
  479.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  480.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  481.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  482.  0, 0, 500, 333, 555, 500, 500, 1000, 833, 333,
  483.  333, 333, 500, 570, 250, 333, 250, 278, 500, 500,
  484.  500, 500, 500, 500, 500, 500, 500, 500, 333, 333,
  485.  570, 570, 570, 500, 930, 722, 667, 722, 722, 667,
  486.  611, 778, 778, 389, 500, 778, 667, 944, 722, 778,
  487.  611, 778, 722, 556, 667, 722, 722, 1000, 722, 722,
  488.  667, 333, 278, 333, 581, 500, 333, 500, 556, 444,
  489.  556, 444, 333, 500, 556, 278, 333, 556, 278, 833,
  490.  556, 500, 556, 556, 444, 389, 333, 556, 500, 722,
  491.  500, 500, 444, 394, 220, 394, 520, 0, 0, 0,
  492.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  493.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  494.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  495.  0, 333, 500, 500, 167, 500, 500, 500, 500, 278,
  496.  500, 500, 333, 333, 556, 556, 0, 500, 500, 500,
  497.  250, 0, 540, 350, 333, 500, 500, 500, 1000, 1000,
  498.  0, 500, 0, 333, 333, 333, 333, 333, 333, 333,
  499.  333, 0, 333, 333, 0, 333, 333, 333, 1000, 0,
  500.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  501.  0, 0, 0, 0, 0, 1000, 0, 300, 0, 0,
  502.  0, 0, 667, 778, 1000, 330, 0, 0, 0, 0,
  503.  0, 722, 0, 0, 0, 278, 0, 0, 278, 500,
  504.  722, 556, 0, 0, 0, 0}},
  505. {
  506.   "times-bolditalic",
  507.   "times-bold-i",
  508.   "Times-BoldItalic",
  509.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  510.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  511.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  512.  0, 0, 500, 389, 555, 500, 500, 833, 778, 333,
  513.  333, 333, 500, 570, 250, 333, 250, 278, 500, 500,
  514.  500, 500, 500, 500, 500, 500, 500, 500, 333, 333,
  515.  570, 570, 570, 500, 832, 667, 667, 667, 722, 667,
  516.  667, 722, 778, 389, 500, 667, 611, 889, 722, 722,
  517.  611, 722, 667, 556, 611, 722, 667, 889, 667, 611,
  518.  611, 333, 278, 333, 570, 500, 333, 500, 500, 444,
  519.  500, 444, 333, 500, 556, 278, 278, 500, 278, 778,
  520.  556, 500, 500, 500, 389, 389, 278, 556, 444, 667,
  521.  500, 444, 389, 348, 220, 348, 570, 0, 0, 0,
  522.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  523.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  524.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  525.  0, 389, 500, 500, 167, 500, 500, 500, 500, 278,
  526.  500, 500, 333, 333, 556, 556, 0, 500, 500, 500,
  527.  250, 0, 500, 350, 333, 500, 500, 500, 1000, 1000,
  528.  0, 500, 0, 333, 333, 333, 333, 333, 333, 333,
  529.  333, 0, 333, 333, 0, 333, 333, 333, 1000, 0,
  530.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  531.  0, 0, 0, 0, 0, 944, 0, 266, 0, 0,
  532.  0, 0, 611, 722, 944, 300, 0, 0, 0, 0,
  533.  0, 722, 0, 0, 0, 278, 0, 0, 278, 500,
  534.  722, 500, 0, 0, 0, 0}},
  535. {
  536.   "times-italic",
  537.   "times-medium-i",
  538.   "Times-Italic",
  539.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  540.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  541.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  542.  0, 0, 500, 333, 420, 500, 500, 833, 778, 333,
  543.  333, 333, 500, 675, 250, 333, 250, 278, 500, 500,
  544.  500, 500, 500, 500, 500, 500, 500, 500, 333, 333,
  545.  675, 675, 675, 500, 920, 611, 611, 667, 722, 611,
  546.  611, 722, 722, 333, 444, 667, 556, 833, 667, 722,
  547.  611, 722, 611, 500, 556, 722, 611, 833, 611, 556,
  548.  556, 389, 278, 389, 422, 500, 333, 500, 500, 444,
  549.  500, 444, 278, 500, 500, 278, 278, 444, 278, 722,
  550.  500, 500, 500, 500, 389, 389, 278, 500, 444, 667,
  551.  444, 444, 389, 400, 275, 400, 541, 0, 0, 0,
  552.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  553.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  554.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  555.  0, 389, 500, 500, 167, 500, 500, 500, 500, 214,
  556.  556, 500, 333, 333, 500, 500, 0, 500, 500, 500,
  557.  250, 0, 523, 350, 333, 556, 556, 500, 889, 1000,
  558.  0, 500, 0, 333, 333, 333, 333, 333, 333, 333,
  559.  333, 0, 333, 333, 0, 333, 333, 333, 889, 0,
  560.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  561.  0, 0, 0, 0, 0, 889, 0, 276, 0, 0,
  562.  0, 0, 556, 722, 944, 310, 0, 0, 0, 0,
  563.  0, 667, 0, 0, 0, 278, 0, 0, 278, 500,
  564.  667, 500, 0, 0, 0, 0}},
  565. {
  566.   "times-roman",
  567.   "times-medium-r",
  568.   "Times-Roman",
  569.  {0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  570.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  571.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  572.  0, 0, 500, 333, 408, 500, 500, 833, 778, 333,
  573.  333, 333, 500, 564, 250, 333, 250, 278, 500, 500,
  574.  500, 500, 500, 500, 500, 500, 500, 500, 278, 278,
  575.  564, 564, 564, 444, 921, 722, 667, 667, 722, 611,
  576.  556, 722, 722, 333, 389, 722, 611, 889, 722, 722,
  577.  556, 722, 667, 556, 611, 722, 722, 944, 722, 722,
  578.  611, 333, 278, 333, 469, 500, 333, 444, 500, 444,
  579.  500, 444, 333, 500, 500, 278, 278, 500, 278, 778,
  580.  500, 500, 500, 500, 333, 389, 278, 500, 500, 722,
  581.  500, 500, 444, 480, 200, 480, 541, 0, 0, 0,
  582.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  583.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  584.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  585.  0, 333, 500, 500, 167, 500, 500, 500, 500, 180,
  586.  444, 500, 333, 333, 556, 556, 0, 500, 500, 500,
  587.  250, 0, 453, 350, 333, 444, 444, 500, 1000, 1000,
  588.  0, 444, 0, 333, 333, 333, 333, 333, 333, 333,
  589.  333, 0, 333, 333, 0, 333, 333, 333, 1000, 0,
  590.  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
  591.  0, 0, 0, 0, 0, 889, 0, 276, 0, 0,
  592.  0, 0, 611, 722, 889, 310, 0, 0, 0, 0,
  593.  0, 667, 0, 0, 0, 278, 0, 0, 278, 500,
  594.  722, 500, 0, 0, 0, 0}}
  595. };
  596.