}
/* Looks for a PostScript font file or config file in all the
- appropriate places. Returns the filename on success, NULL on
+ appropriate places. Returns the file name on success, NULL on
failure. */
static char *
find_ps_file (const char *name)
return xstrdup (name);
else
{
- char *base_name = xasprintf ("psfonts%c%s", DIR_SEPARATOR, name);
+ char *base_name = xasprintf ("psfonts/%s", name);
char *file_name = fn_search_path (base_name, config_path, NULL);
free (base_name);
return file_name;
enum outp_line_style top, enum outp_line_style left,
enum outp_line_style bottom, enum outp_line_style right)
{
-/* The algorithm here is somewhat subtle, to allow it to handle
- all the kinds of intersections that we need.
-
- Three additional ordinates are assigned along the x axis. The
- first is xc, midway between x0 and x3. The others are x1 and
- x2; for a single vertical line these are equal to xc, and for
- a double vertical line they are the ordinates of the left and
- right half of the double line.
-
- yc, y1, and y2 are assigned similarly along the y axis.
-
- The following diagram shows the coordinate system and output
- for double top and bottom lines, single left line, and no
- right line:
-
- x0 x1 xc x2 x3
- y0 ________________________
- | # # |
- | # # |
- | # # |
- | # # |
- | # # |
- y1 = y2 = yc |######### # |
- | # # |
- | # # |
- | # # |
- | # # |
- y3 |________#_____#_______|
-*/
+ /* The algorithm here is somewhat subtle, to allow it to handle
+ all the kinds of intersections that we need.
+
+ Three additional ordinates are assigned along the x axis. The
+ first is xc, midway between x0 and x3. The others are x1 and
+ x2; for a single vertical line these are equal to xc, and for
+ a double vertical line they are the ordinates of the left and
+ right half of the double line.
+
+ yc, y1, and y2 are assigned similarly along the y axis.
+
+ The following diagram shows the coordinate system and output
+ for double top and bottom lines, single left line, and no
+ right line:
+
+ x0 x1 xc x2 x3
+ y0 ________________________
+ | # # |
+ | # # |
+ | # # |
+ | # # |
+ | # # |
+ y1 = y2 = yc |######### # |
+ | # # |
+ | # # |
+ | # # |
+ | # # |
+ y3 |________#_____#_______|
+ */
struct ps_driver_ext *ext = this->ext;
/* Offset from center of each line in a pair of double lines. */
fprintf (ext->file, "F%d setfont\n", font);
}
- ds_init (&out, 0);
+ ds_init (&out);
for (i = 0; i < char_cnt; i = j)
{
for (j = i + 1; j < char_cnt; j++)
continue;
fclose (ch->file);
- fputs ("%%%%EndDocument\n"
+ fputs ("%%EndDocument\n"
"end\n"
"sp restore\n",
x->file);
line_number = 0;
- ds_init (&line, 0);
+ ds_init (&line);
while (ds_get_config_line (file, &line, &line_number))
{
char *pschar, *code;