Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Skin Framework
  New Posts New Posts RSS Feed - HOWTO: Apply skinning to custom control?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

HOWTO: Apply skinning to custom control?

 Post Reply Post Reply
Author
Message
mgampi View Drop Down
Senior Member
Senior Member
Avatar

Joined: 14 July 2003
Status: Offline
Points: 1201
Post Options Post Options   Thanks (0) Thanks(0)   Quote mgampi Quote  Post ReplyReply Direct Link To This Post Topic: HOWTO: Apply skinning to custom control?
    Posted: 18 April 2011 at 4:43am
Hi;

I use a self created custom control several times on different places (dialogs, panes, views ...) of our app.
Now we want to apply skins to our app but I can't find a way how to skin this custom control. See my screenshot of the control with a short description of the contained elements.



What do I have to do to apply a dialog skinning (background, edit and button) to this special control when its placed inside a dialog and a docking pane based skinning when it's in a pane?

Any help is very welcome.


Martin

Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0
Platform: Windows 10 v 22H2 (64bit)
Language: VC++ 2022
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 18 April 2011 at 8:21am
Hi,

Do you have screen how you want to make it look like ?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
mgampi View Drop Down
Senior Member
Senior Member
Avatar

Joined: 14 July 2003
Status: Offline
Points: 1201
Post Options Post Options   Thanks (0) Thanks(0)   Quote mgampi Quote  Post ReplyReply Direct Link To This Post Posted: 18 April 2011 at 8:28am
Originally posted by oleg oleg wrote:

Hi,

Do you have screen how you want to make it look like ?
Hello Oleg;

here it is:



Background should be the same as the dialog / view / pane background and label, edit controls and button should be rendered using the currently applied skin.
At the moment I'm a little step further; I found CXTPWinThemeWrapper and I believe that I have to modify all my OnPaint() / OnEraseBkgd() functions, check whether a theme is applied and use the CXTPWinThemeWrapper::Draw... functions.
But I don't know which themes to open for background of overall control and for the label.
Martin

Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0
Platform: Windows 10 v 22H2 (64bit)
Language: VC++ 2022
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 19 April 2011 at 4:47am
Will continue in our issuetrack...
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
mgampi View Drop Down
Senior Member
Senior Member
Avatar

Joined: 14 July 2003
Status: Offline
Points: 1201
Post Options Post Options   Thanks (0) Thanks(0)   Quote mgampi Quote  Post ReplyReply Direct Link To This Post Posted: 19 April 2011 at 6:01am
OK!
Martin

Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0
Platform: Windows 10 v 22H2 (64bit)
Language: VC++ 2022
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.188 seconds.