[cairo] null stream pdf surface

Arjen Nienhuis a.g.nienhuis at gmail.com
Thu Aug 26 02:13:20 PDT 2010


2010/8/26 Dov Grobgeld <dov.grobgeld at gmail.com>

> Just to make sure, are you refering to the internal cairo text rendering? I
> guess if it was pango, then you would have said so.
>
> I'm curious what is there to fix? As far as I understand the only proper
> way of doing text scaling for hinted fonts is to do it iteratively until you
> satisfy some criteria. Even then you might get stuck in the problem that
> when you increase the font size by ε your rendered text is to large and when
> you decrease the font by the same ε, then text is too small.
>
>
*I* was talking about unhinted text. I implemented this funtion:

def caiiro_draw_text_proper(...):
      ..text_path(...)
      ...fill(...)

But I expected CAIRO_HINT_STYLE_NONE to do that. Maybe wee need
CAIRO_HINT_STYLE_REALY_NONE_REALLY_SLOW. Or just
cairo_font_options_disble_glyph_cache().

Regards,
> Dov
>
> On Thu, Aug 26, 2010 at 00:57, Behdad Esfahbod <behdad at behdad.org> wrote:
>
>> On 08/25/10 17:49, Arjen Nienhuis wrote:
>> >
>> >     You shouldn't do that.  You should measure it at a nominal size,
>> >     scale, and
>> >     draw to the target.  If you do that, you still find that your text
>> >     doesn't
>> >     quite fit in.  That's because (unfortunately) cairo doesn't do fully
>> >     linearly
>> >     scalable text yet :(.  What I suggest you do is to get the path for
>> >     the text
>> >     at the nominal size, scale, append path, fill.
>> >
>> > If you draw text like that it looks a lot better. Especially if the text
>> > is slightly rotated or skewed.
>> >
>> > Why is there no setting to draw all text like that?
>>
>> Fixing the cairo text implementation to do that internally has been on my
>> plate for way too long.  Would appreciate if someone takes it over.
>>
>> http://lists.freedesktop.org/archives/cairo/2008-May/014146.html
>>
>> behdad
>>
>>
>> > Groeten, Arjen
>> --
>> cairo mailing list
>> cairo at cairographics.org
>> http://lists.cairographics.org/mailman/listinfo/cairo
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cairographics.org/archives/cairo/attachments/20100826/8eddb9f4/attachment.html>


More information about the cairo mailing list