![]() |
Flat-Style looking |
Post Reply ![]() |
Author | |
floydzhang ![]() Groupie ![]() Joined: 08 March 2008 Status: Offline Points: 50 |
![]() ![]() ![]() ![]() ![]() Posted: 16 March 2008 at 3:51am |
I want to use the flat-style looking control, button, tab... Just like Windows-XP theme does. But all the controls I created in the dialog are 3D-looking, like Windows 2000 theme. ANy idea for that? By the way, my operating system is Windows XP, and I create my application framework by with XTP wizard, and I set the theme xtpThemeWhidbey in the CMainFrame::OnCreate().
|
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
Hi,
Can you attach screenshot what you see? and project.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
floydzhang ![]() Groupie ![]() Joined: 08 March 2008 Status: Offline Points: 50 |
![]() ![]() ![]() ![]() ![]() |
![]() |
|
![]() |
|
floydzhang ![]() Groupie ![]() Joined: 08 March 2008 Status: Offline Points: 50 |
![]() ![]() ![]() ![]() ![]() |
Hi, Oleg,
This screenshot is catched from Windows 2000, but the appearence is the same what I see in the Windows XP. You can see the the style of mainframe is Visual Studio 2005, but the option dialog is old style, likes Win98, win2000. How to make the dialog and controls look like Windows XP style?
By the way, the appearence was flat mode before, but I don't know why it is old style now. Would you please tell give me some hits where to set this? The dialog must be derived from CXTPDialog?
Thanks
Boyang
|
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
I need screenshot from Windows XP. Windows 2000 don't have Luna themes support. |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
floydzhang ![]() Groupie ![]() Joined: 08 March 2008 Status: Offline Points: 50 |
![]() ![]() ![]() ![]() ![]() |
![]() |
|
![]() |
|
floydzhang ![]() Groupie ![]() Joined: 08 March 2008 Status: Offline Points: 50 |
![]() ![]() ![]() ![]() ![]() |
Hi, Oleg,
You can see the dialog is old windows style -- 3D looking. This is what I don't want.
|
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
Hi,
ok, I see.
You need manifest file.
If you use Visual Studio 2005 add in stdafx.h lines
#if (_MSC_VER > 1310) // VS2005
#if defined _M_IX86 #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='x86' publicKeyToken='6595b64144ccf1df' language='*'\"") #elif defined _M_IA64 #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='ia64' publicKeyToken='6595b64144ccf1df' language='*'\"") #elif defined _M_X64 #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='amd64' publicKeyToken='6595b64144ccf1df' language='*'\"") #else #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'\"") #endif #endif |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
floydzhang ![]() Groupie ![]() Joined: 08 March 2008 Status: Offline Points: 50 |
![]() ![]() ![]() ![]() ![]() |
Hi,
Great! Your comments let me find the root cause. Because my project is initialized with UNICODE, but we switched to ANSI later. So the definitions below doesn't work. Thank you, Oleg.
#ifdef _UNICODE
#if defined _M_IX86 #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='x86' publicKeyToken='6595b64144ccf1df' language='*'\"") #elif defined _M_IA64 #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='ia64' publicKeyToken='6595b64144ccf1df' language='*'\"") #elif defined _M_X64 #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='amd64' publicKeyToken='6595b64144ccf1df' language='*'\"") #else #pragma comment(linker,"/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'\"") #endif #endif |
|
![]() |
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 |