[cairo] Problems with using scale

Owen Taylor otaylor at redhat.com
Fri Dec 1 11:11:31 PST 2006

On Fri, 2006-12-01 at 15:23 +0000, Kieran McCusker wrote:
> Hi
> I am using cairo 1.2.2 on fc5 x86-64 via rcairo to create graphs as 
> pngs.  I create the pngs in two sizes using scale.  I do the following:-
> Apply the scale
> Measure the elements (using pango)
> Draw the elements
> What I find is that using a scale of 1 everything is measured and drawn 
> correctly.  When I scale to 3 I find that the trying to draw into a box 
> provided by pango fails if the text exactly fits the box (or comes 
> close) and I find myself applying fudge factors that then bring their 
> own problems.
> Is anyone aware of this issue?  Is it worth me trying the latest 
> snapshot?  I will produce a test case if no-one has any information.
> Many thanks

Test case? You can't assume linear scaling of text, but if you measure
the text at the final scale it should work fine.

						- Owen

More information about the cairo mailing list