Print Page | Close Window

Skin Bug with CSliderCtrl

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Skin Framework
Forum Description: Topics Related to Codejock Skin Framework
URL: http://forum.codejock.com/forum_posts.asp?TID=10302
Printed Date: 23 September 2024 at 9:31pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Skin Bug with CSliderCtrl
Posted By: dedvalson
Subject: Skin Bug with CSliderCtrl
Date Posted: 18 April 2008 at 12:24pm
I am using the Skin Framework on an existing MFC Application.
 
One of my dialogs has a CSliderCtrl in it.
 
I have found that after I call XTPSkinManager()->LoadSkin for any skin the Slider Controls Selection (as set by SetSelection) is never drawn.
 
Can you suggest a workaround, or is this a real bug?
Thanks,
Don



Replies:
Posted By: Oleg
Date Posted: 18 April 2008 at 1:47pm
Hello,
SkinFramework do same as WindowsXP theming. You can see that Windows XP draws it same.
 
Add "Tick Marks" style and Slider will show Selection range.


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


Posted By: dedvalson
Date Posted: 18 April 2008 at 3:19pm
Hi,
 
I am afraid that this is not the case.
 
The slider already has the "Tick Marks" property set to true. When I call LoadSkin(), the selection is not drawn. If I comment out that one line of code then the selection is drawn properly.
 
I used Spy++ and verifed that the Window Style and Extended Styles are identical both when it is drawn and when it is not drawn.
 
Any further suggestions?
 
Thanks,
 
Don
 


Posted By: dedvalson
Date Posted: 18 April 2008 at 3:22pm
A further small bit of info.
 
The little triangles that go next to the tick marks are drawn. It is the bar itself in the middle of the trough that is not drawn.
 
Don
 


Posted By: Oleg
Date Posted: 18 April 2008 at 3:29pm

Hello,

SkinFramework do same as WindowsXP theming. You can see that Windows XP draws it same.


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


Posted By: dedvalson
Date Posted: 18 April 2008 at 3:38pm

OK, I think I understand what you are saying.

Here is the window when I apply the built-in Windows Theme using the LoadSkin() call.
 
 
Here it is if I don't call LoadSkin()
 
 
Is there a way to get the blue bar back even if I have loaded a Skin (Built in XP or otherwise?)
 
PS: Both pictures are from a system running XP


Posted By: Oleg
Date Posted: 19 April 2008 at 12:18am
Hello,
Afraid I have repeat it again :)
 
Give me screesnshot how you see it without SkinFramework, but with Enabled WinXP themes (comctr32.dll v6) . add manifest to your project:
 
To add manifest
1. Copy Samples\AboutDlg\res\manifest.xml  to your res folder
2. Add line in app.rc file
1           24      DISCARDABLE     "res\\manifest.xml"


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


Posted By: dedvalson
Date Posted: 21 April 2008 at 8:18am
Oleg,
 
You are absolutely right.  When I set up the manifest and so forth I got the same results.
 
That is what I meant to say last post, but I didn't say it very well.
 
I don't know why Microsoft did this, but it will not work for our app. So I guess my question now is could you advise me how I might proceed to fix this?
 
I tried putting some custom drawing on the control using the normal MFC methods, but that seems to conflict with the PaintManager. So I guess I need to modify that (or modify the theme) somehow.
 
Could you point me to where I ought to start.
 
Don
 


Posted By: Oleg
Date Posted: 21 April 2008 at 8:48am

Hi,

Check this post - https://forum.codejock.com/forum_posts.asp?TID=7993 - https://forum.codejock.com/forum_posts.asp?TID=7993


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


Posted By: dedvalson
Date Posted: 21 April 2008 at 8:55am

Hi,

Thank you , that solved my problem.

Sorry about all of the confusion I had in getting to the right question.

Don

 




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