Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - Embedded skin file?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Embedded skin file?

 Post Reply Post Reply
Author
Message
ibmldev View Drop Down
Groupie
Groupie


Joined: 17 October 2006
Status: Offline
Points: 19
Post Options Post Options   Thanks (0) Thanks(0)   Quote ibmldev Quote  Post ReplyReply Direct Link To This Post Topic: Embedded skin file?
    Posted: 04 October 2007 at 1:54pm

We currently load a skin with a call like

XTPSkinManager()->LoadSkin(m_csStylesPath + _T("Office2007.cjstyles"));

which reads the style file from disk. Is there any way to embed the style information in the VS2005 project itself, so that it is compiled into the application (perhaps as a resource of some sort) instead of residing on disk?
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


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: 05 October 2007 at 3:03am
Hello,
 
If you use 11.2 version, just include Source\SkinFramework\Styles\Office2007\Office2007.rc to your rc2 file.
if you have older version, Search on this forum - there was solution.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
ibmldev View Drop Down
Groupie
Groupie


Joined: 17 October 2006
Status: Offline
Points: 19
Post Options Post Options   Thanks (0) Thanks(0)   Quote ibmldev Quote  Post ReplyReply Direct Link To This Post Posted: 05 October 2007 at 9:07am

Oleg,

(1) That sounds like just what I was looking for, thanks very much!  Is there an example project in the 11.2 upgrade, or some documentation, that demonstrates exactly how to do this?
 
(2) Is it possible to have multiple skins available in this way and to switch between them, for example, to let the user tweak his GUI preferences?
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


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: 05 October 2007 at 10:42am
Hi,
see Samples\UserInterface\GUI_VisualStudio sample.
 
all you need in rc2 file add
#include "SkinFramework\Styles\Vista\Vista.rc"
and
in constructor of CMainFrame
XTPSkinManager()->GetResourceFile()->SetModuleHandle(AfxGetInstanceHandle());
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
BastianPL View Drop Down
Groupie
Groupie
Avatar

Joined: 15 April 2006
Status: Offline
Points: 69
Post Options Post Options   Thanks (0) Thanks(0)   Quote BastianPL Quote  Post ReplyReply Direct Link To This Post Posted: 21 December 2007 at 12:25pm
Yes how to do that.. I don't want to use separate style files. I am using version 10.2
Bastian
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


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: 22 December 2007 at 4:33am
Hi,
It was not possible in 10.2.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
BastianPL View Drop Down
Groupie
Groupie
Avatar

Joined: 15 April 2006
Status: Offline
Points: 69
Post Options Post Options   Thanks (0) Thanks(0)   Quote BastianPL Quote  Post ReplyReply Direct Link To This Post Posted: 23 December 2007 at 6:26am
What was not possible.
 
Skin framework is a part of XTP 10.2 ( Q2 ) !!! ;)
Bastian
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


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: 23 December 2007 at 2:27pm

 

In 10.2 was not possible to include style to exe.

 

... anyway I very recommend you update SkinnFramework. it was a lot for fixes after 10.2 release.

Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
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.045 seconds.