Page 1 of 1

Posted: Sat Jan 05, 2002 8:00 am
by BackupUser
Restored from previous forum. Originally posted by FAKEFACTORY.

Hi,

I'm using the excellent RichEdit Library, but stumbled into some problems: I need a way to get the exact font-attributes (horizontal size, vertical size, fontname etc... ) of a opened RichEdit Control.

Some tests with GetTextExtentPoint32_ are showing, that this functions allways returns the textmetrics for the window-handle, not the RichEdit handle....

I'm out of ideas...

Someone here, who can help.

Registered PureBasic Coder

Posted: Sat Jan 05, 2002 12:31 pm
by BackupUser
Restored from previous forum. Originally posted by El_Choni.

Hi,

I'm adding a function to handle that, I guess it'll be online this evening. Thanks for requesting it, I had forgotten to add a function to GET font attributes.

Regards,

El_Choni

Posted: Sat Jan 05, 2002 12:44 pm
by BackupUser
Restored from previous forum. Originally posted by redacid.

while your`re here:

I tried to add a RichEdit to my program.
It worked fine but it had a different
font than the other gadgets and I didn`t
find a way to change this.

How can I change the font of the RichEdit
to the one that the other Gadgets use?

Only Amiga makes it possible!

Posted: Sat Jan 05, 2002 12:56 pm
by BackupUser
Restored from previous forum. Originally posted by El_Choni.

Add this just after the OpenRichEdit function:

Code: Select all

RichEditFont(RichEditIndex(), "MS Sans Serif", -1, -1, 0, 0, 0, 0, 0)
Or just this:

Code: Select all

RichEditFontFace("MS Sans Serif")
Bye,


Edited by - El_Choni on 05 January 2002 12:58:36

Posted: Sat Jan 05, 2002 1:22 pm
by BackupUser
Restored from previous forum. Originally posted by redacid.

Thanks, but what if the user has chosen a different font in the Windows-prefs?

regards,
Redacid
---
Only Amiga makes it possible!