summaryrefslogtreecommitdiff
path: root/src/cairo-font.c
diff options
context:
space:
mode:
authorCarl Worth <cworth@cworth.org>2006-02-13 16:46:47 -0800
committerCarl Worth <cworth@cworth.org>2006-02-13 16:46:47 -0800
commit0b5ac24b1522b3287903c04fb894bfae4fc67403 (patch)
treeb8256ae476f183ba07c4f4ef031d31bc31927910 /src/cairo-font.c
parentdb163fcc882251188e0ce63d0b9606cb59664da0 (diff)
parent90689370267f3c02d6be62e3e8c85cccdad6f577 (diff)
Remove pixman and revert tessellation bug from SNAPSHOT_0_3_0SNAPSHOT_0_3_0
Diffstat (limited to 'src/cairo-font.c')
-rw-r--r--src/cairo-font.c16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/cairo-font.c b/src/cairo-font.c
index 5ad9f0417..f5fc0e981 100644
--- a/src/cairo-font.c
+++ b/src/cairo-font.c
@@ -36,7 +36,6 @@
#include "cairoint.h"
-
/* First we implement a global font cache for named fonts. */
typedef struct {
@@ -54,9 +53,9 @@ typedef struct {
static unsigned long
_font_cache_hash (void *cache, void *key)
{
+ unsigned long hash;
cairo_font_cache_key_t *in;
in = (cairo_font_cache_key_t *) key;
- unsigned long hash;
/* 1607 and 1451 are just a couple random primes. */
hash = _cairo_hash_string (in->family);
@@ -86,12 +85,11 @@ _font_cache_create_entry (void *cache,
void *key,
void **return_value)
{
+ const cairo_font_backend_t *backend = CAIRO_FONT_BACKEND_DEFAULT;
cairo_font_cache_key_t *k;
cairo_font_cache_entry_t *entry;
k = (cairo_font_cache_key_t *) key;
- const struct cairo_font_backend *backend = CAIRO_FONT_BACKEND_DEFAULT;
-
/* XXX: The current freetype backend may return NULL, (for example
* if no fonts are installed), but I would like to guarantee that
* the toy API always returns at least *some* font, so I would
@@ -145,7 +143,7 @@ _font_cache_destroy_cache (void *cache)
free (cache);
}
-const struct cairo_cache_backend cairo_font_cache_backend = {
+static const cairo_cache_backend_t cairo_font_cache_backend = {
_font_cache_hash,
_font_cache_keys_equal,
_font_cache_create_entry,
@@ -153,7 +151,6 @@ const struct cairo_cache_backend cairo_font_cache_backend = {
_font_cache_destroy_cache
};
-
static void
_lock_global_font_cache (void)
{
@@ -239,8 +236,8 @@ _cairo_font_init (cairo_font_t *scaled,
}
cairo_status_t
-_cairo_unscaled_font_init (cairo_unscaled_font_t *font,
- const struct cairo_font_backend *backend)
+_cairo_unscaled_font_init (cairo_unscaled_font_t *font,
+ const cairo_font_backend_t *backend)
{
font->refcount = 1;
font->backend = backend;
@@ -476,7 +473,7 @@ _image_glyph_cache_destroy_cache (void *cache)
free (cache);
}
-const cairo_cache_backend_t cairo_image_cache_backend = {
+static const cairo_cache_backend_t cairo_image_cache_backend = {
_cairo_glyph_cache_hash,
_cairo_glyph_cache_keys_equal,
_image_glyph_cache_create_entry,
@@ -484,7 +481,6 @@ const cairo_cache_backend_t cairo_image_cache_backend = {
_image_glyph_cache_destroy_cache
};
-
void
_cairo_lock_global_image_glyph_cache()
{