[cairo] size of canvas
Kalle Vahlman
kalle.vahlman at gmail.com
Tue Jul 24 11:48:30 PDT 2007
2007/7/24, Behdad Esfahbod <behdad at behdad.org>:
> On Tue, 2007-07-24 at 10:23 -0400, Tamas K Papp wrote:
> > Given a context (or a surface), is it possible to find its size? Eg
> > if I created a pdf surface of size width x height, and a context on
> > it, could I recover its size solely from the context?
>
> Not currently, no.
For the record, there are at least two surface types (image and xlib)
that make this possible, trough querying first the target surface from
the context, then checking the type of the surface and then using the
surface-specific getters for the dimensions.
Hardly optimal though.
--
Kalle Vahlman, zuh at iki.fi
Powered by http://movial.fi
Interesting stuff at http://syslog.movial.fi
More information about the cairo
mailing list