On Wednesday 02 July 2008 11.08:31 Mattias Gärtner wrote: > Zitat von Martin Schreiber <[EMAIL PROTECTED]>: > > For example lib/common/kernel/msedrawtext.pas:223, procedure layouttext. > > Nice code. > As far as I can see, it handles tabs, linebreaks, c_softhyphen and > charwidth. It uses single array element per character optimizations, like > the charwidths array. > I think I would simply keep that and define the characterwidth for the > follow up elements as 0. > Then you only need to change the places where you check for the > c_softhyphen. And because this is a constant you can even use some tricks > here. > I don't see how this have a big impact on the performance. > The code is complicated enough, don't you think? ;-)
Martin _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal