![]() |
Property sheet wizard not painted correctly |
Post Reply
|
| Author | |
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Topic: Property sheet wizard not painted correctlyPosted: 05 November 2006 at 8:04am |
|
Hi,
Please have a look at this screenshot: I have CXTResizePropertySheet-derived wizard class with CXTResizePropertyPage-derived pages. There seem to be two problems with this.
1) The static controls are not painted correctly. I tried setting the transparent property, but it did not help. Nor did the WS_CLIPCHILDREN style.
2) When resizing, the wizard buttons do not react.
Any help is appreciated. Thanks!
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 06 November 2006 at 1:33am |
|
Hi,
I tried to reproduce it but failed - work as expected. Check that you call all base methods if you override CXTResizePropertySheet.
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Posted: 11 November 2006 at 11:23pm |
|
No, this is indeed a drawing bug ;) ... or perhaps I have missed something.
CPropertySheet + PSH_WIZARD97 style. That simply won't get painted correctly. When a traditional property sheet is created, the property pages are painted in a brighter color than the dialog. That is correct. In wizard mode however, the pages should be painted in the same color as the parent dialog. I managed to get the same background color by overrideing the OnPaint method: void CReservationPatientPage::OnPaint()
{
CPaintDC dc(this);
CRect r;
GetClientRect(&r);
CXTMemDC memDC(&dc, r);
CPropertyPage::DefWindowProc(WM_PAINT, (WPARAM)memDC.m_hDC, 0);
}
That works for the background, but not for the static controls (as can be seen in the screenshot above). Overriding OnCtlColor will not help as it is not being called. I have no more ideas.
Drawing bug in the Skin Framework?
|
|
![]() |
|
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Posted: 15 November 2006 at 7:32pm |
|
I actually found ONE post about this CPropertyPage issue on the net:
So, this is probably not a bug in the Skin Framework. But I bet Oleg knows a workaround! :D
Any ideas?
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 16 November 2006 at 12:41am |
|
Hello,
As I wrote I can't reprodce it. I need sample project from you to check what you do wrong :) Attach it in issue tack and I will point what you can fix.
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Posted: 17 November 2006 at 11:54am |
|
Take a look at my sample:
Just run the app (make sure the skins are placed in \Styles) and then close it. The wizard pops up. None of the pages are painted correctly.
Thanks!
/Chris |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 18 November 2006 at 3:31am |
|
Hello, Sorry now I see problem in PSH_WIZARD97 that we didn't try.
please add
BOOL CMyPropertyPage::OnInitDialog() { CPropertyPage::OnInitDialog(); XTPSkinManager()->EnableThemeDialogTexture(m_hWnd, ETDT_DISABLE); return TRUE;} |
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Posted: 18 November 2006 at 11:27pm |
|
Thanks!!!
|
|
![]() |
|
asparagusx
Groupie
Joined: 06 February 2007 Status: Offline Points: 57 |
Post Options
Thanks(0)
Quote Reply
Posted: 21 February 2007 at 3:47am |
|
Hallo I have a very similar problem and it does not appear to be easy to fix. I implemeted some derived dialogs from CXTResizeDialog (previously they were derived from CDialog). Resizing works a treat, but my dialogs have a 'custom' background which I display in OnEraseBkgnd however now all my static controls appear wrong. I used to override OnCtlColor to set a NULL brush and SetBkMode(TRANSPARENT) for static controls and the 'background' used to be visible, now I simply get it filled with a default colour. What should I do to get the background to be visible through the static controls? Thanks Anton |
|
![]() |
|
asparagusx
Groupie
Joined: 06 February 2007 Status: Offline Points: 57 |
Post Options
Thanks(0)
Quote Reply
Posted: 22 February 2007 at 12:02am |
|
Anybody got any ideas here! This is a serious problem.
Thanks
Anton
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 23 February 2007 at 1:32am |
|
Hi,
Write to support@codejock.com and send code you use.
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 26 February 2007 at 4:10am |
|
Hello,
To prevent flickers Resize dialog add WS_CLIPCHILDREN|WS_CLIPSIBLINGS styles, but it become cause of your problem. To fix it, just add SetFlag(xtResizeNoClipChildren); in constructor of your dialog. Thank you |
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
asparagusx
Groupie
Joined: 06 February 2007 Status: Offline Points: 57 |
Post Options
Thanks(0)
Quote Reply
Posted: 26 February 2007 at 6:35am |
|
Oleg
You are a STAR!
Thanks
Anton
|
|
![]() |
|
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 |