ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Getting/setting annotation font size in points?
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

stuartclennett@gmail.com

United Kingdom
72 Posts

Posted - Jan 23 2017 :  05:19:20  Show Profile  Reply
Hi,

I'm wondering if there's a way to set the font size of an annotation in points (i.e. the Font.Size) property as well as the ObjFontHeight[idx] ?

When I retrieve the ObjfontHeight of an object is often returns -16, indicating that there's a size property available?

Thanks
Stuart

Stuart Clennett
Delphi Berlin 10.1

xequte

38615 Posts

Posted - Jan 23 2017 :  20:08:28  Show Profile  Reply
Hi Stuart

ObjFontHeight simply points to a Logfont lfHeight, so negative values should be supported. What issues do you encounter when doing so?



Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

stuartclennett@gmail.com

United Kingdom
72 Posts

Posted - Jan 24 2017 :  04:27:44  Show Profile  Reply
Hi Nigel,

I'm just trying to hook up a spin edit to show and set the font height of the selected object. When I select an object, I usually get -16 in the spin edit.

I'm not familiar with a "logfont lfHeight" -- is there some formula to convert to a recognisable "point size" ?

Cheers

Stuart Clennett
Delphi Berlin 10.1
Go to Top of Page

xequte

38615 Posts

Posted - Jan 24 2017 :  04:31:21  Show Profile  Reply
Please see:

https://msdn.microsoft.com/en-us/library/windows/desktop/dd145037(v=vs.85).aspx

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

stuartclennett@gmail.com

United Kingdom
72 Posts

Posted - Jan 24 2017 :  04:37:13  Show Profile  Reply
Thanks Nigel - I realise I spoke before searching. I will look at that link thanks.

I also found this in case anyone else is wondering:

http://stackoverflow.com/questions/2944149/converting-logfont-height-to-font-size-in-points

Cheers
Stu

Stuart Clennett
Delphi Berlin 10.1
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: