Hello Jeroen, Thanks a lot for contributing this. It's really nice to see that people outside of the original MapOSMatic core team are contributing code.
Le Tue, 17 Apr 2012 03:18:17 +0200, Jeroen van Rijn <[email protected]> a écrit : > + # Measure header text and rescale if needed > + ctx.save() > + # Tell Pango to not wrap text > + layout.set_width(-1) Why? If I understand correctly, you want each category title to fit without being wrapped. Is this really what we want to do? Another question is that, if I'm not mistaken, you are doing this font size adaptation algorithm on a per-category title basis, which means that depending on their length, each title might have a different font size, which is not really pretty. I think I would prefer a scheme where you first travel through all category titles, compute the maximum length, and then the adequate font size, which you then use to render all category titles. What do you think about this? Best regards, Thomas -- Thomas Petazzoni http://thomas.enix.org MapOSMatic http://www.maposmatic.org Logiciels Libres à Toulouse http://www.toulibre.org Embedded Linux http://www.free-electrons.com
