Created
September 24, 2011 02:57
-
-
Save akfish/1238898 to your computer and use it in GitHub Desktop.
MFC: How to change default application look
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//When using MFC wizard to generate a project, it will ask developer to choose an application look style. | |
//Say we have chosen "Office 2007 Blue" as default and want to change it into "Windows 7". Here is how to: | |
//1. In MainFrm.cpp, we will see: | |
CMainFrame::CMainFrame() | |
{ | |
// TODO: add member initialization code here | |
theApp.m_nAppLook = theApp.GetInt(_T("ApplicationLook"), ID_VIEW_APPLOOK_OFF_2007_BLUE); | |
} | |
//Replace ID_VIEW_APPLOOK_OFF_2007_BLUE with ID_VIEW_APPLOOK_WINDOWS_7 or whatever you want. | |
//2. We may see nothing changed if the application has launched before. | |
//This is because that MFC application stores settings in Windows's registry. | |
//Go regedit and delete \HKEY_CURRENT_USER\Software\[Company Name]\[Application Name]. | |
//Or modify \HKEY_CURRENT_USER\Software\[Company Name]\[Application Name]\Workspace\ApplicationLook. | |
//[Company Name] is default to "Local AppWizard-Generated Applications". |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment