[Lazarus] How can I improve my bitmap font drawing unit (attached) ?

Pavel Řezníček cigydd at gmail.com
Fri Aug 29 01:22:22 CEST 2008


Felipe Monteiro de Carvalho napsal(a):
> On 8/13/08, Peter Williams <pewtas at gmail.com> wrote:
>   
>> My main question is: would I be better off using a TImageList?!? Can someone
>> please post sample code. Note: I tried to run the TImageList example program
>> for Lazarus... it compiles okay... but when run it does not find some of its
>> files (BMPs) in the Image sub-folder of the example program. e.g. it gets a
>> runtime error.
>>     
>
> Answering to your main question, I have doubts if using TImageList
> would be better. It isn't really designed to read fonts, and I don't
> know how it would handle the multiple lines. Further, there is no
> reason to beliave that it would be faster then your own code.
>
> In short, well, no, I wouldn't bet in TImageList as a better solution.
You'd have to split your single bitmap for each font into many (128 or 
256) single character bitmaps. Then the Image List component would come 
in handy.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20080829/f9a8d881/attachment-0007.html>


More information about the Lazarus mailing list