Best Fit |
Post Reply |
Author | |
Warren
Groupie Joined: 23 February 2005 Status: Offline Points: 64 |
Post Options
Thanks(0)
Posted: 31 July 2005 at 4:24pm |
I'm having trouble with the Best Fit feature of the Report Control. The
best fit function makes the column width a few pixels too narrow. This
causes the "..." ellipses to be used when the item is drawn.
The problem exists in my application, and also in the "ReportSample" sample (use the best fit feature on the "Recieved" column - or any column except the last column). For Example: I'm using Toolkit Pro v9.60, with Visual Studio 2003 writing a MFC app, on a XP computer, with the default set of fonts. BTW --> Typo: the "Recieved" column should be "Received" in the sample Thanks Warren |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Thank you, it is fixed for 9.71, also added Double Click on Risize part to BestFit.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
Warren
Groupie Joined: 23 February 2005 Status: Offline Points: 64 |
Post Options
Thanks(0)
|
Thanks for looking into this so quickly! The support for this product is just great.
Thanks for also adding the feature I was about to suggest:
before I even got a chance to suggest it (psychic support ?!?!) Warren |
|
Warren
Groupie Joined: 23 February 2005 Status: Offline Points: 64 |
Post Options
Thanks(0)
|
I'd like to re-open this issue.
The Column-sizing algorithm doesn't seem to take into account the Width of Column Title. This causes the name to get cut off, and the "..." to appear when the Name of the Column is wider than any of the contents. To duplicate the behaviour (in the 9.80 version of the samples) Codejock Samples -> Report Sample -> Report Control Menu -> Task List Dialog and "double-click resize" on the "% Complete" Column. I'd also like the algorithm to take into account the width of the little sort-direction arrow that shows up too (so sorting the column doesn't cause the name to get cut off either). Thanks ! Warren I'm using Toolkit Pro v9.80, with Visual Studio 2003 writing a MFC app, on a XP computer, with the default set of fonts. |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Thakn you, good suggestion, fixed for 9.81 |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
Warren
Groupie Joined: 23 February 2005 Status: Offline Points: 64 |
Post Options
Thanks(0)
|
I'd like to re-open this issue once more (I'm using 9.81 right now). The best-fit still causes the name to get cut off, and the "..." to
appear
To duplicate the behaviour (in the 9.81 version of the samples) Codejock Samples -> Report Sample -> Report Control Menu -> Task List Dialog 1) Click on the "Subject" header, so the sort triangle shows up on the "subject" column. 2) Now "double-click resize" the "% Complete" Column (by double-clicking the right edge of the column) 3) Now click on the "% Complete" header, so the sort arrow shows up on the "% Complete" header. Result: "% Complete" name is now "% Co..." From looking at your source, I suggest the following: in file: "xtpreportcolumn.cpp" in function: "int CXTPReportColumn::GetBestFitWidth() const" replace the line: if (HasSortTriangle()) with the line: if (IsResizable()) Since the sort triangle may show up after the column has been best-fit sized. Thanks Warren |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hello, You can call wndReport.GetPaintManager()->m_bDrawSortTriangleAlways = FALSE; so it will acts exactly like in Office |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
Warren
Groupie Joined: 23 February 2005 Status: Offline Points: 64 |
Post Options
Thanks(0)
|
Oleg,
Yes, that does get rid of the "..." (which is a definite improvement), but it comes at the expense of not drawing the sort triangle (without which, it is really hard to tell what's going on) I think the "best-fit" column width (for a sortable column) should include the width of the sort-triangle. Don't you agree? (at the very least it would be nice for this to be an option) Sorry, in my suggested code above, I meant to say "IsSortable" by I wrote "IsResizable" when I was typing it in here.(That's got to be a record, I suggest one line of code and it has a bug ) It should read: replace the line: if (HasSortTriangle()) with the line: if (IsSortable()) |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |