[lazarus] cvs changes
Marc Weustink
Marc.Weustink at cuperus.nl
Thu Jan 20 05:47:27 EST 2000
+ From: Michal Bukovjan [mailto:mbukovjan at netscape.net]
+
+ New should also work, but it does not zero memory upon
+ allocation. This was causing all sorts of things,
+ instead of font of size 10 normal I was getting
+ font 14 italics, etc.
+ You could also see tons of messages like XLFD : could not find
+ courier-*-*-1254545465-14545412-* and other nonsense.
+
+ As I changed it to AllocMem, fonts display OK and the error
+ messages about fonts mostly disappeared.
It didn't change anything for me, I get still these messages.
Second, the origin of these messages is not the memory being
zeroed but the fact that GetFont doesn't return valid info
on a DC with HWND=0. Thats a part that had a low priority
to me so I didn't fix it yet.
Another thing to keep in mind is that AllocMem/FreeMem and
New/Despose should be used together. Since the rest of the
API uses dispose, I prefer to use New instead of AllocMem
Something else.
I allso saw that you changed the pointsize and the resolution
of the XLFD. As far as my docs go this shouldn't be done since
we are using the font height (and not point size). If you're
using font height the pointsize should be empty and a resolution
should only be given if a pointsize is used. Do you have other
sources of info ?
Marc
More information about the Lazarus
mailing list