cairo-1.0.x 斜体补丁。
个人认为这是目前最为干净的补丁。diff -up cairo-1.0.0.orig/src/cairo-ft-font.c cairo-1.0.0/src/cairo-ft-font.c
--- cairo-1.0.0.orig/src/cairo-ft-font.c 2005-09-18 09:47:09.000000000 +0800
+++ cairo-1.0.0/src/cairo-ft-font.c 2005-10-19 15:39:17.000000000 +0800
@@ -1207,7 +1207,8 @@ _cairo_ft_unscaled_font_create_glyph (vo
FT_Glyph_Metrics *metrics;
cairo_status_t status = CAIRO_STATUS_SUCCESS;
double x_factor, y_factor;
-
+ int load_flags = val->key.flags & ~PRIVATE_FLAGS_MASK;
+
face = _cairo_ft_unscaled_font_lock_face (unscaled);
if (!face)
return CAIRO_STATUS_NO_MEMORY;
@@ -1217,7 +1218,10 @@ _cairo_ft_unscaled_font_create_glyph (vo
_cairo_ft_unscaled_font_set_scale (unscaled, &val->key.scale);
- if (FT_Load_Glyph (face, val->key.index, val->key.flags & ~PRIVATE_FLAGS_MASK) != 0) {
+ if (unscaled->have_shape)
+ load_flags |= FT_LOAD_NO_BITMAP;
+
+ if (FT_Load_Glyph (face, val->key.index, load_flags) != 0) {
status = CAIRO_STATUS_NO_MEMORY;
goto FAIL;
}
最近的补丁太多,我觉得应该逐个反应给上游。
我突然找到我先前开的一个斜体bug report:
https://bugs.freedesktop.org/show_bug.cgi?id=4509 这个补丁已经发到邮件列表上了, 其它的我慢慢分解发上去的:) 邮件列表不方便顶,bug report可以去顶顶:mrgreen::mrgreen:
页:
[1]