Print Page | Close Window

Gallery item bug?

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=14229
Printed Date: 27 September 2024 at 3:50pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Gallery item bug?
Posted By: ABuenger
Subject: Gallery item bug?
Date Posted: 06 May 2009 at 9:04pm
In CXTPControlGalleryItem::Draw is the following line:

CRect rcText(rcItem);
rcText.left += 2 + nImageBoxWidth + szImage.cx / 3;

The result is that the text is not visible at all because left is actually greater then right after that line.
Shouldn't that line be:

rcText.top += szImage.cy + 5;

????



-------------
Codejock support



Replies:
Posted By: ABuenger
Date Posted: 06 May 2009 at 9:08pm
int nImageBoxWidth  = max(rcItem.Height() - 4, szImage.cx);

????????

This causes a misalignment if width != height.



-------------
Codejock support


Posted By: ABuenger
Date Posted: 06 May 2009 at 9:18pm
I've derived my own class from CXTPControlGalleryItem and fixed the drawing bugs (on the left)
On the right is the default CXTPControlGalleryItem.



-------------
Codejock support


Posted By: terrym
Date Posted: 08 May 2009 at 3:08am
Originally posted by ABuenger ABuenger wrote:

I've derived my own class from CXTPControlGalleryItem and fixed the drawing bugs (on the left)
On the right is the default CXTPControlGalleryItem.

 
Hi
 
We have never seen this bug, but this is obviously due to us always deriving our own classes for drawing of items :)
 


-------------
Thank you,
Terry Mancey

email terry@tmancey.ltd.uk | linkedin www.tmancey.ltd.uk | twitter @tmancey


Posted By: ABuenger
Date Posted: 08 May 2009 at 6:40am
I would like to see a property for the text orientation:




Also multiline captions (not only descriptions) and caption+description doesn't work without an image.



-------------
Codejock support


Posted By: terrym
Date Posted: 08 May 2009 at 6:48am
Originally posted by ABuenger ABuenger wrote:

I would like to see a property for the text orientation:




Also multiline captions (not only descriptions) and caption+description doesn't work without an image.

 
Sounds good, but for us we always write our own derived classes so never get the issue.
 


-------------
Thank you,
Terry Mancey

email terry@tmancey.ltd.uk | linkedin www.tmancey.ltd.uk | twitter @tmancey


Posted By: ABuenger
Date Posted: 08 May 2009 at 6:55am
Originally posted by terrym terrym wrote:

Sounds good, but for us we always write our own derived classes so never get the issue.


How much time does it take you and us to copy the code from the samples, figure out how to get a white background and write a custom Draw method for the items?

So why can't we put a custom control on the dialog and set the class to XTPGalleryControl like we can for the Report control or property grid? How many more customers have to waste their time? The sample was made 04/2008 and 1 year later it's still not in the toolkit.



-------------
Codejock support


Posted By: terrym
Date Posted: 08 May 2009 at 6:59am
Originally posted by ABuenger ABuenger wrote:

Originally posted by terrym terrym wrote:

Sounds good, but for us we always write our own derived classes so never get the issue.


How much time does it take you and us to copy the code from the samples, figure out how to get a white background and write a custom Draw method for the items?

So why can't we put a custom control on the dialog and set the class to XTPGalleryControl like we can for the Report control or property grid? How many more customers have to waste their time? The sample was made 04/2008 and 1 year later it's still not in the toolkit.

 
Very  true it has cost us much time in writing these custom controls, and if a solution can be added this would be great as would also clean up our project a bit :)
 


-------------
Thank you,
Terry Mancey

email terry@tmancey.ltd.uk | linkedin www.tmancey.ltd.uk | twitter @tmancey


Posted By: ABuenger
Date Posted: 15 May 2009 at 9:14am
Can someone from Codejock confirm this to be a bug? Do you need a sample to reproduce it? Can you implement an text orientation property and multiline captions for 13.1?



-------------
Codejock support


Posted By: Oleg
Date Posted: 18 May 2009 at 1:22am

Hi,

Gallery draws text always to right of image. if yo uneed another style you can always override and draw like you need.


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: terrym
Date Posted: 18 May 2009 at 2:35am
Originally posted by oleg oleg wrote:

Hi,

Gallery draws text always to right of image. if yo uneed another style you can always override and draw like you need.
 
Ah, that explains why we have an override for each draw we need different :), not a problem for us as we always want things different than standard lol.


-------------
Thank you,
Terry Mancey

email terry@tmancey.ltd.uk | linkedin www.tmancey.ltd.uk | twitter @tmancey



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net