Error about CharSpacing

General TRichView support forum. Please post your questions here
Post Reply
peong
Posts: 3
Joined: Sun Oct 30, 2005 4:55 pm

Error about CharSpacing

Post by peong »

I discovered a strange result in setting a value below:

RVStyle1.TextStyles[0].CharSpacing := SpinNo;

when SpinNo = -4, the charcpacing actually increate from -3. ??

My version is still 1.8.1, don't know that this error is't sloved in 1.9.8

Please help, thanks!
Sergey Tkachenko
Site Admin
Posts: 17557
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Post by Sergey Tkachenko »

Value of this property is interpreted by WinAPI. It is passed to SetTextCharacterExtra function.
peong
Posts: 3
Joined: Sun Oct 30, 2005 4:55 pm

Error about CharSpacing

Post by peong »

Sergey Tkachenko wrote:Value of this property is interpreted by WinAPI. It is passed to SetTextCharacterExtra function.
Hi Sergey,
I see, but can this problem solve in Richview as we are using the RVStyle to assign value? :wink:
peong
Posts: 3
Joined: Sun Oct 30, 2005 4:55 pm

Error about CharSpacing

Post by peong »

Hi Sergey,

Now I know why, it's because when compression meet the edge between two characters, further compression will first cause a 'unlogic' response. value of -4 mentioned is actually when font size at 10. :wink:
Sergey Tkachenko
Site Admin
Posts: 17557
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Post by Sergey Tkachenko »

As I said, currently this value is interpreted by Windows (SetTextCharacterExtra function).
If you have a better suggestion, let me know.
Post Reply