TTreePage.Count error

TeeTree VCL for Borland Delphi and C++ Builder.
Post Reply
David
Newbie
Newbie
Posts: 4
Joined: Mon Jan 31, 2005 5:00 am
Location: Idaho
Contact:

TTreePage.Count error

Post by David » Wed Feb 16, 2005 5:50 pm

In TTreePage.Count the number of pages uses the TTree's TotalBounds to calculate the number of pages. It uses the ROUND function that inflates the actual number of pages due to rounding. The SetPage correctly sets the page using the DIV functions. The result is that the TreeNavigator and Printing ends up having multiple blank pages.

Any ideas how to get around this bug?

tom
Advanced
Posts: 211
Joined: Mon Dec 01, 2003 5:00 am
Contact:

Post by tom » Wed Mar 09, 2005 6:12 pm

Hi,

you could change the code in to using DIV

result:=1+(ITree.IBounds.Bottom div FHeight);

Thanks for reporting the bug.

Regards,
tom

tom
Advanced
Posts: 211
Joined: Mon Dec 01, 2003 5:00 am
Contact:

Post by tom » Wed Mar 09, 2005 6:13 pm

I meant:

You could change the code in TTreePage.InternalGetCount

Post Reply