summaryrefslogtreecommitdiff
path: root/include/mupdf/fitz
diff options
context:
space:
mode:
Diffstat (limited to 'include/mupdf/fitz')
-rw-r--r--include/mupdf/fitz/colorspace.h2
-rw-r--r--include/mupdf/fitz/compressed-buffer.h2
-rw-r--r--include/mupdf/fitz/context.h8
-rw-r--r--include/mupdf/fitz/device.h10
-rw-r--r--include/mupdf/fitz/display-list.h2
-rw-r--r--include/mupdf/fitz/document.h2
-rw-r--r--include/mupdf/fitz/filter.h2
-rw-r--r--include/mupdf/fitz/hash.h2
-rw-r--r--include/mupdf/fitz/image.h2
-rw-r--r--include/mupdf/fitz/link.h2
-rw-r--r--include/mupdf/fitz/outline.h4
-rw-r--r--include/mupdf/fitz/output.h4
-rw-r--r--include/mupdf/fitz/pixmap.h7
-rw-r--r--include/mupdf/fitz/shade.h2
-rw-r--r--include/mupdf/fitz/store.h18
-rw-r--r--include/mupdf/fitz/stream.h6
-rw-r--r--include/mupdf/fitz/structured-text.h4
-rw-r--r--include/mupdf/fitz/tree.h2
-rw-r--r--include/mupdf/fitz/unzip.h2
-rw-r--r--include/mupdf/fitz/xml.h4
20 files changed, 43 insertions, 44 deletions
diff --git a/include/mupdf/fitz/colorspace.h b/include/mupdf/fitz/colorspace.h
index 1572211f..7cd6aba5 100644
--- a/include/mupdf/fitz/colorspace.h
+++ b/include/mupdf/fitz/colorspace.h
@@ -84,7 +84,7 @@ fz_colorspace *fz_new_colorspace(fz_context *ctx, char *name, int n);
fz_colorspace *fz_new_indexed_colorspace(fz_context *ctx, fz_colorspace *base, int high, unsigned char *lookup);
fz_colorspace *fz_keep_colorspace(fz_context *ctx, fz_colorspace *colorspace);
void fz_drop_colorspace(fz_context *ctx, fz_colorspace *colorspace);
-void fz_free_colorspace_imp(fz_context *ctx, fz_storable *colorspace);
+void fz_drop_colorspace_imp(fz_context *ctx, fz_storable *colorspace);
void fz_convert_color(fz_context *ctx, fz_colorspace *dsts, float *dstv, fz_colorspace *srcs, const float *srcv);
diff --git a/include/mupdf/fitz/compressed-buffer.h b/include/mupdf/fitz/compressed-buffer.h
index 384a7744..5139b90d 100644
--- a/include/mupdf/fitz/compressed-buffer.h
+++ b/include/mupdf/fitz/compressed-buffer.h
@@ -76,6 +76,6 @@ struct fz_compressed_buffer_s
fz_buffer *buffer;
};
-void fz_free_compressed_buffer(fz_context *ctx, fz_compressed_buffer *buf);
+void fz_drop_compressed_buffer(fz_context *ctx, fz_compressed_buffer *buf);
#endif
diff --git a/include/mupdf/fitz/context.h b/include/mupdf/fitz/context.h
index dc134511..79406942 100644
--- a/include/mupdf/fitz/context.h
+++ b/include/mupdf/fitz/context.h
@@ -131,7 +131,7 @@ enum {
The global state contains an exception stack, resource store,
etc. Most functions in MuPDF take a context argument to be
- able to reference the global state. See fz_free_context for
+ able to reference the global state. See fz_drop_context for
freeing an allocated context.
alloc: Supply a custom memory allocator through a set of
@@ -176,7 +176,7 @@ fz_context *fz_new_context_imp(fz_alloc_context *alloc, fz_locks_context *locks,
fz_context *fz_clone_context(fz_context *ctx);
/*
- fz_free_context: Free a context and its global state.
+ fz_drop_context: Free a context and its global state.
The context and all of its global state is freed, and any
buffered warnings are flushed (see fz_flush_warnings). If NULL
@@ -184,7 +184,7 @@ fz_context *fz_clone_context(fz_context *ctx);
Does not throw exceptions.
*/
-void fz_free_context(fz_context *ctx);
+void fz_drop_context(fz_context *ctx);
/*
fz_aa_level: Get the number of bits of antialiasing we are
@@ -410,7 +410,7 @@ struct fz_warn_context_s
fz_context *fz_clone_context_internal(fz_context *ctx);
void fz_new_aa_context(fz_context *ctx);
-void fz_free_aa_context(fz_context *ctx);
+void fz_drop_aa_context(fz_context *ctx);
void fz_copy_aa_context(fz_context *dst, fz_context *src);
void fz_new_document_handler_context(fz_context *ctx);
diff --git a/include/mupdf/fitz/device.h b/include/mupdf/fitz/device.h
index ef27cd5d..4fdf2e43 100644
--- a/include/mupdf/fitz/device.h
+++ b/include/mupdf/fitz/device.h
@@ -100,7 +100,7 @@ struct fz_device_s
int flags;
void *user;
- void (*free_user)(fz_device *);
+ void (*drop_user)(fz_device *);
fz_context *ctx;
void (*rebind)(fz_device *);
@@ -171,9 +171,9 @@ void fz_end_tile(fz_device *dev);
fz_device *fz_new_device(fz_context *ctx, void *user);
/*
- fz_free_device: Free a devices of any type and its resources.
+ fz_drop_device: Free a devices of any type and its resources.
*/
-void fz_free_device(fz_device *dev);
+void fz_drop_device(fz_device *dev);
/*
fz_enable_device_hints : Enable hints in a device.
@@ -304,7 +304,7 @@ fz_device *fz_new_test_device(fz_context *ctx, int *is_color, float threshold);
for how to obtain a pixmap. The pixmap is not cleared by the
draw device, see fz_clear_pixmap* for how to clear it prior to
calling fz_new_draw_device. Free the device by calling
- fz_free_device.
+ fz_drop_device.
*/
fz_device *fz_new_draw_device(fz_context *ctx, fz_pixmap *dest);
@@ -315,7 +315,7 @@ fz_device *fz_new_draw_device(fz_context *ctx, fz_pixmap *dest);
for how to obtain a pixmap. The pixmap is not cleared by the
draw device, see fz_clear_pixmap* for how to clear it prior to
calling fz_new_draw_device. Free the device by calling
- fz_free_device.
+ fz_drop_device.
clip: Bounding box to restrict any marking operations of the
draw device.
diff --git a/include/mupdf/fitz/display-list.h b/include/mupdf/fitz/display-list.h
index 080ca5b5..269e8f9f 100644
--- a/include/mupdf/fitz/display-list.h
+++ b/include/mupdf/fitz/display-list.h
@@ -40,7 +40,7 @@ fz_display_list *fz_new_display_list(fz_context *ctx);
display list can later be reused to render a page many times
without having to re-interpret the page from the document file
for each rendering. Once the device is no longer needed, free
- it with fz_free_device.
+ it with fz_drop_device.
list: A display list that the list device takes ownership of.
*/
diff --git a/include/mupdf/fitz/document.h b/include/mupdf/fitz/document.h
index cc078044..f1a0a663 100644
--- a/include/mupdf/fitz/document.h
+++ b/include/mupdf/fitz/document.h
@@ -147,7 +147,7 @@ int fz_authenticate_password(fz_document *doc, const char *password);
/*
fz_load_outline: Load the hierarchical document outline.
- Should be freed by fz_free_outline.
+ Should be freed by fz_drop_outline.
*/
fz_outline *fz_load_outline(fz_document *doc);
diff --git a/include/mupdf/fitz/filter.h b/include/mupdf/fitz/filter.h
index d8a6729f..534ed34f 100644
--- a/include/mupdf/fitz/filter.h
+++ b/include/mupdf/fitz/filter.h
@@ -28,6 +28,6 @@ fz_stream *fz_open_predict(fz_stream *chain, int predictor, int columns, int col
fz_stream *fz_open_jbig2d(fz_stream *chain, fz_jbig2_globals *globals);
fz_jbig2_globals *fz_load_jbig2_globals(fz_context *ctx, unsigned char *data, int size);
-void fz_free_jbig2_globals_imp(fz_context *ctx, fz_storable *globals);
+void fz_drop_jbig2_globals_imp(fz_context *ctx, fz_storable *globals);
#endif
diff --git a/include/mupdf/fitz/hash.h b/include/mupdf/fitz/hash.h
index f70e9693..c56c9d13 100644
--- a/include/mupdf/fitz/hash.h
+++ b/include/mupdf/fitz/hash.h
@@ -12,7 +12,7 @@ typedef struct fz_hash_table_s fz_hash_table;
fz_hash_table *fz_new_hash_table(fz_context *ctx, int initialsize, int keylen, int lock);
void fz_empty_hash(fz_context *ctx, fz_hash_table *table);
-void fz_free_hash(fz_context *ctx, fz_hash_table *table);
+void fz_drop_hash(fz_context *ctx, fz_hash_table *table);
void *fz_hash_find(fz_context *ctx, fz_hash_table *table, const void *key);
void *fz_hash_insert(fz_context *ctx, fz_hash_table *table, const void *key, void *val);
diff --git a/include/mupdf/fitz/image.h b/include/mupdf/fitz/image.h
index 22d87988..3d40cb1d 100644
--- a/include/mupdf/fitz/image.h
+++ b/include/mupdf/fitz/image.h
@@ -57,7 +57,7 @@ fz_image *fz_new_image_from_pixmap(fz_context *ctx, fz_pixmap *pixmap, fz_image
fz_image *fz_new_image_from_data(fz_context *ctx, unsigned char *data, int len);
fz_image *fz_new_image_from_buffer(fz_context *ctx, fz_buffer *buffer);
fz_pixmap *fz_image_get_pixmap(fz_context *ctx, fz_image *image, int w, int h);
-void fz_free_image(fz_context *ctx, fz_storable *image);
+void fz_drop_image_imp(fz_context *ctx, fz_storable *image);
fz_pixmap *fz_decomp_image_from_stream(fz_context *ctx, fz_stream *stm, fz_image *image, int indexed, int l2factor, int native_l2factor);
fz_pixmap *fz_expand_indexed_pixmap(fz_context *ctx, fz_pixmap *src);
diff --git a/include/mupdf/fitz/link.h b/include/mupdf/fitz/link.h
index 47648a4c..586a5aa2 100644
--- a/include/mupdf/fitz/link.h
+++ b/include/mupdf/fitz/link.h
@@ -173,6 +173,6 @@ fz_link *fz_keep_link(fz_context *ctx, fz_link *link);
*/
void fz_drop_link(fz_context *ctx, fz_link *link);
-void fz_free_link_dest(fz_context *ctx, fz_link_dest *dest);
+void fz_drop_link_dest(fz_context *ctx, fz_link_dest *dest);
#endif
diff --git a/include/mupdf/fitz/outline.h b/include/mupdf/fitz/outline.h
index 48718be7..6a3ca81a 100644
--- a/include/mupdf/fitz/outline.h
+++ b/include/mupdf/fitz/outline.h
@@ -55,12 +55,12 @@ void fz_print_outline_xml(fz_context *ctx, fz_output *out, fz_outline *outline);
void fz_print_outline(fz_context *ctx, fz_output *out, fz_outline *outline);
/*
- fz_free_outline: Free hierarchical outline.
+ fz_drop_outline: Free hierarchical outline.
Free an outline obtained from fz_load_outline.
Does not throw exceptions.
*/
-void fz_free_outline(fz_context *ctx, fz_outline *outline);
+void fz_drop_outline(fz_context *ctx, fz_outline *outline);
#endif
diff --git a/include/mupdf/fitz/output.h b/include/mupdf/fitz/output.h
index 5bbf3d92..8398f83a 100644
--- a/include/mupdf/fitz/output.h
+++ b/include/mupdf/fitz/output.h
@@ -60,13 +60,13 @@ int fz_write(fz_output *out, const void *data, int len);
void fz_putc(fz_output *out, char c);
/*
- fz_close_output: Close a previously opened fz_output stream.
+ fz_drop_output: Close a previously opened fz_output stream.
Note: whether or not this closes the underlying output method is
method dependent. FILE * streams created by fz_new_output_with_file
are NOT closed.
*/
-void fz_close_output(fz_output *);
+void fz_drop_output(fz_output *);
void fz_rebind_output(fz_output *, fz_context *ctx);
diff --git a/include/mupdf/fitz/pixmap.h b/include/mupdf/fitz/pixmap.h
index 800effd0..c8d64dd1 100644
--- a/include/mupdf/fitz/pixmap.h
+++ b/include/mupdf/fitz/pixmap.h
@@ -267,8 +267,7 @@ void fz_convert_pixmap(fz_context *ctx, fz_pixmap *dst, fz_pixmap *src);
free_samples: Is zero when an application has provided its own
buffer for pixel data through fz_new_pixmap_with_bbox_and_data.
- If not zero the buffer will be freed when fz_drop_pixmap is
- called for the pixmap.
+ If non-zero the buffer will be freed along with the the pixmap.
*/
struct fz_pixmap_s
{
@@ -281,7 +280,7 @@ struct fz_pixmap_s
int free_samples;
};
-void fz_free_pixmap_imp(fz_context *ctx, fz_storable *pix);
+void fz_drop_pixmap_imp(fz_context *ctx, fz_storable *pix);
void fz_copy_pixmap_rect(fz_context *ctx, fz_pixmap *dest, fz_pixmap *src, const fz_irect *r);
void fz_premultiply_pixmap(fz_context *ctx, fz_pixmap *pix);
@@ -293,7 +292,7 @@ fz_pixmap *fz_scale_pixmap(fz_context *ctx, fz_pixmap *src, float x, float y, fl
typedef struct fz_scale_cache_s fz_scale_cache;
fz_scale_cache *fz_new_scale_cache(fz_context *ctx);
-void fz_free_scale_cache(fz_context *ctx, fz_scale_cache *cache);
+void fz_drop_scale_cache(fz_context *ctx, fz_scale_cache *cache);
fz_pixmap *fz_scale_pixmap_cached(fz_context *ctx, fz_pixmap *src, float x, float y, float w, float h, const fz_irect *clip, fz_scale_cache *cache_x, fz_scale_cache *cache_y);
void fz_subsample_pixmap(fz_context *ctx, fz_pixmap *tile, int factor);
diff --git a/include/mupdf/fitz/shade.h b/include/mupdf/fitz/shade.h
index 3cd43bd7..aa7061b9 100644
--- a/include/mupdf/fitz/shade.h
+++ b/include/mupdf/fitz/shade.h
@@ -74,7 +74,7 @@ struct fz_shade_s
fz_shade *fz_keep_shade(fz_context *ctx, fz_shade *shade);
void fz_drop_shade(fz_context *ctx, fz_shade *shade);
-void fz_free_shade_imp(fz_context *ctx, fz_storable *shade);
+void fz_drop_shade_imp(fz_context *ctx, fz_storable *shade);
fz_rect *fz_bound_shade(fz_context *ctx, fz_shade *shade, const fz_matrix *ctm, fz_rect *r);
void fz_paint_shade(fz_context *ctx, fz_shade *shade, const fz_matrix *ctm, fz_pixmap *dest, const fz_irect *bbox);
diff --git a/include/mupdf/fitz/store.h b/include/mupdf/fitz/store.h
index f954e3b8..b40aa89a 100644
--- a/include/mupdf/fitz/store.h
+++ b/include/mupdf/fitz/store.h
@@ -27,16 +27,16 @@
typedef struct fz_storable_s fz_storable;
-typedef void (fz_store_free_fn)(fz_context *, fz_storable *);
+typedef void (fz_store_drop_fn)(fz_context *, fz_storable *);
struct fz_storable_s {
int refs;
- fz_store_free_fn *free;
+ fz_store_drop_fn *drop;
};
-#define FZ_INIT_STORABLE(S_,RC,FREE) \
+#define FZ_INIT_STORABLE(S_,RC,DROP) \
do { fz_storable *S = &(S_)->storable; S->refs = (RC); \
- S->free = (FREE); \
+ S->drop = (DROP); \
} while (0)
void *fz_keep_storable(fz_context *, fz_storable *);
@@ -62,7 +62,7 @@ typedef struct fz_store_hash_s fz_store_hash;
struct fz_store_hash_s
{
- fz_store_free_fn *free;
+ fz_store_drop_fn *drop;
union
{
struct
@@ -138,7 +138,7 @@ void *fz_store_item(fz_context *ctx, void *key, void *val, unsigned int itemsize
/*
fz_find_item: Find an item within the store.
- free: The function used to free the value (to ensure we get a value
+ drop: The function used to free the value (to ensure we get a value
of the correct type).
key: The key to use to index the item.
@@ -148,21 +148,21 @@ void *fz_store_item(fz_context *ctx, void *key, void *val, unsigned int itemsize
Returns NULL for not found, otherwise returns a pointer to the value
indexed by key to which a reference has been taken.
*/
-void *fz_find_item(fz_context *ctx, fz_store_free_fn *free, void *key, fz_store_type *type);
+void *fz_find_item(fz_context *ctx, fz_store_drop_fn *drop, void *key, fz_store_type *type);
/*
fz_remove_item: Remove an item from the store.
If an item indexed by the given key exists in the store, remove it.
- free: The function used to free the value (to ensure we get a value
+ drop: The function used to free the value (to ensure we get a value
of the correct type).
key: The key to use to find the item to remove.
type: Functions used to manipulate the key.
*/
-void fz_remove_item(fz_context *ctx, fz_store_free_fn *free, void *key, fz_store_type *type);
+void fz_remove_item(fz_context *ctx, fz_store_drop_fn *drop, void *key, fz_store_type *type);
/*
fz_empty_store: Evict everything from the store.
diff --git a/include/mupdf/fitz/stream.h b/include/mupdf/fitz/stream.h
index fb3ef932..624060f3 100644
--- a/include/mupdf/fitz/stream.h
+++ b/include/mupdf/fitz/stream.h
@@ -10,7 +10,7 @@
directions.
Streams are reference counted, so references must be dropped
- by a call to fz_close.
+ by a call to fz_drop_stream.
Only the data between rp and wp is valid.
*/
@@ -91,7 +91,7 @@ fz_stream *fz_open_buffer(fz_context *ctx, fz_buffer *buf);
fz_stream *fz_open_leecher(fz_stream *chain, fz_buffer *buf);
/*
- fz_close: Close an open stream.
+ fz_drop_stream: Close an open stream.
Drops a reference for the stream. Once no references remain
the stream will be closed, as will any file descriptor the
@@ -99,7 +99,7 @@ fz_stream *fz_open_leecher(fz_stream *chain, fz_buffer *buf);
Does not throw exceptions.
*/
-void fz_close(fz_stream *stm);
+void fz_drop_stream(fz_stream *stm);
/*
fz_tell: return the current reading position within a stream
diff --git a/include/mupdf/fitz/structured-text.h b/include/mupdf/fitz/structured-text.h
index f325bf21..da67a864 100644
--- a/include/mupdf/fitz/structured-text.h
+++ b/include/mupdf/fitz/structured-text.h
@@ -202,7 +202,7 @@ fz_rect *fz_text_char_bbox(fz_rect *bbox, fz_text_span *span, int idx);
is used.
*/
fz_text_sheet *fz_new_text_sheet(fz_context *ctx);
-void fz_free_text_sheet(fz_context *ctx, fz_text_sheet *sheet);
+void fz_drop_text_sheet(fz_context *ctx, fz_text_sheet *sheet);
/*
fz_new_text_page: Create an empty text page.
@@ -211,7 +211,7 @@ void fz_free_text_sheet(fz_context *ctx, fz_text_sheet *sheet);
lines and spans of text on the page.
*/
fz_text_page *fz_new_text_page(fz_context *ctx);
-void fz_free_text_page(fz_context *ctx, fz_text_page *page);
+void fz_drop_text_page(fz_context *ctx, fz_text_page *page);
void fz_analyze_text(fz_context *ctx, fz_text_sheet *sheet, fz_text_page *page);
diff --git a/include/mupdf/fitz/tree.h b/include/mupdf/fitz/tree.h
index f2cc4848..0b299e27 100644
--- a/include/mupdf/fitz/tree.h
+++ b/include/mupdf/fitz/tree.h
@@ -17,7 +17,7 @@ void *fz_tree_lookup(fz_context *ctx, fz_tree *node, const char *key);
*/
fz_tree *fz_tree_insert(fz_context *ctx, fz_tree *root, const char *key, void *value);
-void fz_free_tree(fz_context *ctx, fz_tree *node, void (*freefunc)(fz_context *ctx, void *value));
+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);
diff --git a/include/mupdf/fitz/unzip.h b/include/mupdf/fitz/unzip.h
index dd9fb856..290cc16b 100644
--- a/include/mupdf/fitz/unzip.h
+++ b/include/mupdf/fitz/unzip.h
@@ -14,7 +14,7 @@ fz_archive *fz_open_archive_with_stream(fz_context *ctx, fz_stream *file);
int fz_has_archive_entry(fz_context *ctx, fz_archive *zip, const char *name);
fz_stream *fz_open_archive_entry(fz_context *ctx, fz_archive *zip, const char *entry);
fz_buffer *fz_read_archive_entry(fz_context *ctx, fz_archive *zip, const char *entry);
-void fz_close_archive(fz_context *ctx, fz_archive *ar);
+void fz_drop_archive(fz_context *ctx, fz_archive *ar);
void fz_rebind_archive(fz_archive *zip, fz_context *ctx);
diff --git a/include/mupdf/fitz/xml.h b/include/mupdf/fitz/xml.h
index 8006fa07..7e226f71 100644
--- a/include/mupdf/fitz/xml.h
+++ b/include/mupdf/fitz/xml.h
@@ -60,9 +60,9 @@ char *fz_xml_att(fz_xml *item, const char *att);
char *fz_xml_text(fz_xml *item);
/*
- fz_free_xml: Free the XML node and all its children and siblings.
+ fz_drop_xml: Free the XML node and all its children and siblings.
*/
-void fz_free_xml(fz_context *doc, fz_xml *item);
+void fz_drop_xml(fz_context *doc, fz_xml *item);
/*
fz_detach_xml: Detach a node from the tree, unlinking it from its parent.