2014-07-02 10:00 GMT+02:00 Henrik Sperre Johansen < henrik.s.johan...@veloxit.no>:
> On 01.07.2014 22:05, Nicolai Hess wrote: > > > 2014-07-01 3:16 GMT+02:00 Igor Stasenko <siguc...@gmail.com>: > >> >> >> >> On 30 June 2014 21:36, Nicolai Hess <nicolaih...@web.de> wrote: >> >>> The real question was: >>> Why can't we draw a text with StrikeFont and with Athens. >>> >>> Igor, can't we use AthensCairoText (cairo toy text api) for >>> non-truetype fonts? >>> >>> >> Because strike fonts are stored in special format which you cannot render >> directly by cairo library. Because strike fonts are not scalable. Because >> it will be horribly slow. Choose one. >> > > > > I choose the first one, horrible slow or not scaleable is better than a > drawing error :) > > If someday all rendering is done through Athens, how do we solve this > problem with the StrikeFont? > > You would have to implement a special rendering path for StrikeFonts > utilizing essentially the same method used for rendering bitmaps. > In theory, if cairo bitmap perf is about the same as traditional bitmap > perf, that'd be about as slow as FT-rendering is in non-cairo images, if > there's no scaling involved. > Scaled, it would probably look horrible, take a screenshot of this mail, > zoom to 400% in Paint or something, that's what to expect. > (Though, one *could* do some tricks translating point size /scale factor > to another font with point size closer to the final result (if one exists) > and get slightly less horrible results) > another solution in: 13458 <https://pharo.fogbugz.com/default.asp?13458> Rendering text with Athens and StrikeFonts Here I use Athens/Cairos simple text api. Maybe not a good solution, but it is better than the drawing error, I think. > > Cheers, > Henry >