summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/mupdf/fitz/font.h10
-rw-r--r--include/mupdf/fitz/path.h12
-rw-r--r--include/mupdf/fitz/shade.h10
-rw-r--r--include/mupdf/fitz/tree.h2
-rw-r--r--source/fitz/draw-edge.c18
-rw-r--r--source/fitz/font.c26
-rw-r--r--source/fitz/path.c75
-rw-r--r--source/fitz/shade.c42
-rw-r--r--source/fitz/tree.c20
-rw-r--r--source/xps/xps-doc.c22
-rw-r--r--source/xps/xps-resource.c18
11 files changed, 0 insertions, 255 deletions
diff --git a/include/mupdf/fitz/font.h b/include/mupdf/fitz/font.h
index 782f60b1..eae2e4cf 100644
--- a/include/mupdf/fitz/font.h
+++ b/include/mupdf/fitz/font.h
@@ -590,16 +590,6 @@ int fz_encode_character_with_fallback(fz_context *ctx, fz_font *font, int unicod
void fz_get_glyph_name(fz_context *ctx, fz_font *font, int glyph, char *buf, int size);
/*
- fz_print_font: Output textual information about a font
- to a given output stream.
-
- out: The output stream to output to.
-
- font: The font to output details for.
-*/
-void fz_print_font(fz_context *ctx, fz_output *out, fz_font *font);
-
-/*
Internal functions for our Harfbuzz integration
to work around the lack of thread safety.
*/
diff --git a/include/mupdf/fitz/path.h b/include/mupdf/fitz/path.h
index 40604a2f..47e80841 100644
--- a/include/mupdf/fitz/path.h
+++ b/include/mupdf/fitz/path.h
@@ -431,16 +431,4 @@ fz_stroke_state *fz_unshare_stroke_state_with_dash_len(fz_context *ctx, fz_strok
*/
fz_stroke_state *fz_clone_stroke_state(fz_context *ctx, fz_stroke_state *stroke);
-/*
- fz_print_path: Print a debug representation of a path to
- a given output stream. Not for use in production builds.
-
- out: The output stream to print to.
-
- path: The path to output.
-
- indent: The amount to indent the output by.
-*/
-void fz_print_path(fz_context *ctx, fz_output *out, fz_path *, int indent);
-
#endif
diff --git a/include/mupdf/fitz/shade.h b/include/mupdf/fitz/shade.h
index 7a90691d..1665fd1a 100644
--- a/include/mupdf/fitz/shade.h
+++ b/include/mupdf/fitz/shade.h
@@ -185,14 +185,4 @@ typedef void (fz_shade_process_fn)(fz_context *ctx, void *arg, fz_vertex *av, fz
void fz_process_shade(fz_context *ctx, fz_shade *shade, const fz_matrix *ctm,
fz_shade_prepare_fn *prepare, fz_shade_process_fn *process, void *process_arg);
-/*
- fz_print_shade: Output a textual representation of
- a shading.
-
- out: The stream to output to.
-
- shade: The shade to dump information about.
-*/
-void fz_print_shade(fz_context *ctx, fz_output *out, fz_shade *shade);
-
#endif
diff --git a/include/mupdf/fitz/tree.h b/include/mupdf/fitz/tree.h
index 7ce63cc1..92f45d34 100644
--- a/include/mupdf/fitz/tree.h
+++ b/include/mupdf/fitz/tree.h
@@ -21,6 +21,4 @@ fz_tree *fz_tree_insert(fz_context *ctx, fz_tree *root, const char *key, void *v
void fz_drop_tree(fz_context *ctx, fz_tree *node, void (*dropfunc)(fz_context *ctx, void *value));
-void fz_debug_tree(fz_context *ctx, fz_tree *root);
-
#endif
diff --git a/source/fitz/draw-edge.c b/source/fitz/draw-edge.c
index cb641b21..68c98690 100644
--- a/source/fitz/draw-edge.c
+++ b/source/fitz/draw-edge.c
@@ -264,24 +264,6 @@ struct fz_gel_s
fz_edge **active;
};
-#ifdef DUMP_GELS
-static void
-fz_dump_gel(fz_gel *gel)
-{
- int i;
-
- printf("%d edges\n", gel->len);
- for (i = 0; i < gel->len; i++)
- {
- fz_edge *e = &gel->edges[i];
- if (e->ydir > 0)
- printf("%d %d -> %d %d\n", e->x, e->y, e->x + e->h * e->xmove + e->xdir * e->h * e->adj_up / e->adj_down, e->y + e->h);
- else
- printf("%d %d -> %d %d\n", e->x + e->h * e->xmove + e->xdir * e->h * e->adj_up / e->adj_down, e->y + e->h, e->x, e->y);
- }
-}
-#endif
-
fz_gel *
fz_new_gel(fz_context *ctx)
{
diff --git a/source/fitz/font.c b/source/fitz/font.c
index 1ce8c89f..37d273ba 100644
--- a/source/fitz/font.c
+++ b/source/fitz/font.c
@@ -1356,32 +1356,6 @@ fz_render_t3_glyph_direct(fz_context *ctx, fz_device *dev, fz_font *font, int gi
font->t3run(ctx, font->t3doc, font->t3resources, contents, dev, &ctm, gstate, nested_depth);
}
-void
-fz_print_font(fz_context *ctx, fz_output *out, fz_font *font)
-{
- fz_write_printf(ctx, out, "font '%s' {\n", font->name);
-
- if (font->ft_face)
- {
- fz_write_printf(ctx, out, "\tfreetype face %p\n", font->ft_face);
- if (font->flags.ft_substitute)
- fz_write_printf(ctx, out, "\tsubstitute font\n");
- }
-
- if (font->t3procs)
- {
- fz_write_printf(ctx, out, "\ttype3 matrix [%g %g %g %g]\n",
- font->t3matrix.a, font->t3matrix.b,
- font->t3matrix.c, font->t3matrix.d);
-
- fz_write_printf(ctx, out, "\ttype3 bbox [%g %g %g %g]\n",
- font->bbox.x0, font->bbox.y0,
- font->bbox.x1, font->bbox.y1);
- }
-
- fz_write_printf(ctx, out, "}\n");
-}
-
fz_rect *
fz_bound_glyph(fz_context *ctx, fz_font *font, int gid, const fz_matrix *trm, fz_rect *rect)
{
diff --git a/source/fitz/path.c b/source/fitz/path.c
index 31ede8ec..b56d7b59 100644
--- a/source/fitz/path.c
+++ b/source/fitz/path.c
@@ -1346,81 +1346,6 @@ void fz_trim_path(fz_context *ctx, fz_path *path)
}
}
-void
-fz_print_path(fz_context *ctx, fz_output *out, fz_path *path, int indent)
-{
- float x, y;
- int i = 0, k = 0;
- int n;
- while (i < path->cmd_len)
- {
- uint8_t cmd = path->cmds[i++];
-
- for (n = 0; n < indent; n++)
- fz_write_byte(ctx, out, ' ');
- switch (cmd)
- {
- case FZ_MOVETO:
- case FZ_MOVETOCLOSE:
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g m%s\n", x, y, cmd == FZ_MOVETOCLOSE ? " z" : "");
- break;
- case FZ_LINETO:
- case FZ_LINETOCLOSE:
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g l%s\n", x, y, cmd == FZ_LINETOCLOSE ? " z" : "");
- break;
- case FZ_DEGENLINETO:
- case FZ_DEGENLINETOCLOSE:
- fz_write_printf(ctx, out, "d%s\n", cmd == FZ_DEGENLINETOCLOSE ? " z" : "");
- break;
- case FZ_HORIZTO:
- case FZ_HORIZTOCLOSE:
- x = path->coords[k++];
- fz_write_printf(ctx, out, "%g h%s\n", x, cmd == FZ_HORIZTOCLOSE ? " z" : "");
- break;
- case FZ_VERTTOCLOSE:
- case FZ_VERTTO:
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g i%s\n", y, cmd == FZ_VERTTOCLOSE ? " z" : "");
- break;
- case FZ_CURVETOCLOSE:
- case FZ_CURVETO:
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g ", x, y);
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g ", x, y);
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g c%s\n", x, y, cmd == FZ_CURVETOCLOSE ? " z" : "");
- break;
- case FZ_CURVETOVCLOSE:
- case FZ_CURVETOV:
- case FZ_CURVETOYCLOSE:
- case FZ_CURVETOY:
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g ", x, y);
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g %c%s\n", x, y, (cmd == FZ_CURVETOVCLOSE || cmd == FZ_CURVETOV ? 'v' : 'y'), (cmd == FZ_CURVETOVCLOSE || cmd == FZ_CURVETOYCLOSE) ? " z" : "");
- break;
- case FZ_RECTTO:
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g ", x, y);
- x = path->coords[k++];
- y = path->coords[k++];
- fz_write_printf(ctx, out, "%g %g r\n", x, y);
- break;
- }
- }
-}
-
const fz_stroke_state fz_default_stroke_state = {
-2, /* -2 is the magic number we use when we have stroke states stored on the stack */
FZ_LINECAP_BUTT, FZ_LINECAP_BUTT, FZ_LINECAP_BUTT,
diff --git a/source/fitz/shade.c b/source/fitz/shade.c
index 783a8630..b7e746d7 100644
--- a/source/fitz/shade.c
+++ b/source/fitz/shade.c
@@ -1087,45 +1087,3 @@ fz_bound_shade(fz_context *ctx, fz_shade *shade, const fz_matrix *ctm, fz_rect *
}
return fz_transform_rect(s, &local_ctm);
}
-
-void
-fz_print_shade(fz_context *ctx, fz_output *out, fz_shade *shade)
-{
- int i;
-
- fz_write_printf(ctx, out, "shading {\n");
-
- switch (shade->type)
- {
- case FZ_FUNCTION_BASED: fz_write_printf(ctx, out, "\ttype function_based\n"); break;
- case FZ_LINEAR: fz_write_printf(ctx, out, "\ttype linear\n"); break;
- case FZ_RADIAL: fz_write_printf(ctx, out, "\ttype radial\n"); break;
- default: /* MESH */ fz_write_printf(ctx, out, "\ttype mesh\n"); break;
- }
-
- fz_write_printf(ctx, out, "\tbbox [%g %g %g %g]\n",
- shade->bbox.x0, shade->bbox.y0,
- shade->bbox.x1, shade->bbox.y1);
-
- fz_write_printf(ctx, out, "\tcolorspace %s\n", fz_colorspace_name(ctx, shade->colorspace));
-
- fz_write_printf(ctx, out, "\tmatrix [%g %g %g %g %g %g]\n",
- shade->matrix.a, shade->matrix.b, shade->matrix.c,
- shade->matrix.d, shade->matrix.e, shade->matrix.f);
-
- if (shade->use_background)
- {
- int n = fz_colorspace_n(ctx, shade->colorspace);
- fz_write_printf(ctx, out, "\tbackground [");
- for (i = 0; i < n; i++)
- fz_write_printf(ctx, out, "%s%g", i == 0 ? "" : " ", shade->background[i]);
- fz_write_printf(ctx, out, "]\n");
- }
-
- if (shade->use_function)
- {
- fz_write_printf(ctx, out, "\tfunction\n");
- }
-
- fz_write_printf(ctx, out, "}\n");
-}
diff --git a/source/fitz/tree.c b/source/fitz/tree.c
index 070bbc71..bdd042dc 100644
--- a/source/fitz/tree.c
+++ b/source/fitz/tree.c
@@ -105,23 +105,3 @@ void fz_drop_tree(fz_context *ctx, fz_tree *node, void (*dropfunc)(fz_context *c
fz_free(ctx, node);
}
}
-
-static void print_tree_imp(fz_context *ctx, fz_tree *node, int level)
-{
- int i;
- if (node->left != &tree_sentinel)
- print_tree_imp(ctx, node->left, level + 1);
- for (i = 0; i < level; i++)
- putchar(' ');
- printf("%s = %p (%d)\n", node->key, node->value, node->level);
- if (node->right != &tree_sentinel)
- print_tree_imp(ctx, node->right, level + 1);
-}
-
-void fz_debug_tree(fz_context *ctx, fz_tree *root)
-{
- printf("--- tree dump ---\n");
- if (root && root != &tree_sentinel)
- print_tree_imp(ctx, root, 0);
- printf("---\n");
-}
diff --git a/source/xps/xps-doc.c b/source/xps/xps-doc.c
index d13e8fb0..95be593f 100644
--- a/source/xps/xps-doc.c
+++ b/source/xps/xps-doc.c
@@ -37,28 +37,6 @@ xps_rels_for_part(fz_context *ctx, xps_document *doc, char *buf, char *name, int
* which parts correspond to actual pages, and the page order.
*/
-void
-xps_print_page_list(fz_context *ctx, xps_document *doc)
-{
- xps_fixdoc *fixdoc = doc->first_fixdoc;
- xps_fixpage *page = doc->first_page;
-
- if (doc->start_part)
- printf("start part %s\n", doc->start_part);
-
- while (fixdoc)
- {
- printf("fixdoc %s\n", fixdoc->name);
- fixdoc = fixdoc->next;
- }
-
- while (page)
- {
- printf("page[%d] %s w=%d h=%d\n", page->number, page->name, page->width, page->height);
- page = page->next;
- }
-}
-
static void
xps_add_fixed_document(fz_context *ctx, xps_document *doc, char *name)
{
diff --git a/source/xps/xps-resource.c b/source/xps/xps-resource.c
index dcc83fb3..29ed864a 100644
--- a/source/xps/xps-resource.c
+++ b/source/xps/xps-resource.c
@@ -154,21 +154,3 @@ xps_drop_resource_dictionary(fz_context *ctx, xps_document *doc, xps_resource *d
dict = next;
}
}
-
-void
-xps_print_resource_dictionary(fz_context *ctx, xps_document *doc, xps_resource *dict)
-{
- while (dict)
- {
- if (dict->base_uri)
- printf("URI = '%s'\n", dict->base_uri);
- printf("KEY = '%s' VAL = %p\n", dict->name, dict->data);
- if (dict->parent)
- {
- printf("PARENT = {\n");
- xps_print_resource_dictionary(ctx, doc, dict->parent);
- printf("}\n");
- }
- dict = dict->next;
- }
-}