Hello Jeroen,

Just a few comments...

2012/4/17 Jeroen van Rijn <jvr...@gmail.com>:
> +        # Measure header text and rescale if needed

I would put more hash marks (###) to separate more clearly this part
of the code. In fact, maybe this should be put in a specific
_rescale_something function. I don't know.

> +        if scale < 1.2:

How has been determined this 1.2 value?

> +        # Restore target width
> +        layout.set_width(target_width)
> +        layout.context_changed()
> +        # Restore context
> +        ctx.restore()

Is it really necessary to call set_width(target_width) as the context
is restored just afterwards?

Overall, very cleanly commented code, nice to read!

Best regards,
d.

Reply via email to