Click here to Skip to main content
15,884,177 members
Articles / Programming Languages / C#

A Managed C++ Wrapper Around the Windows XP Theme API

Rate me:
Please Sign up or sign in to vote.
4.97/5 (31 votes)
27 Aug 2003CPOL5 min read 307.9K   5.5K   72  
Using the XP Theme API safely on any OS from C#
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
	ProjectType="Visual C++"
	Version="7.10"
	Name="System.Windows.Forms.Themes"
	ProjectGUID="{72E759E7-B12C-43F3-A7A7-DAA7BA0C2093}"
	RootNamespace="UxThemeNet"
	Keyword="ManagedCProj">
	<Platforms>
		<Platform
			Name="Win32"/>
	</Platforms>
	<Configurations>
		<Configuration
			Name="Debug|Win32"
			OutputDirectory="$(ProjectDir)$(ConfigurationName)"
			IntermediateDirectory="$(ConfigurationName)"
			ConfigurationType="2"
			CharacterSet="2"
			ManagedExtensions="TRUE">
			<Tool
				Name="VCCLCompilerTool"
				Optimization="0"
				PreprocessorDefinitions="WIN32;_DEBUG"
				MinimalRebuild="FALSE"
				BasicRuntimeChecks="0"
				RuntimeLibrary="1"
				UsePrecompiledHeader="3"
				WarningLevel="3"
				DebugInformationFormat="3"/>
			<Tool
				Name="VCCustomBuildTool"/>
			<Tool
				Name="VCLinkerTool"
				AdditionalOptions="/NOENTRY /NODEFAULTLIB:libcmtd.lib
"
				AdditionalDependencies="msvcrt.lib mscoree.lib"
				OutputFile="$(OutDir)\$(ProjectName).dll"
				LinkIncremental="2"
				ForceSymbolReferences="__DllMainCRTStartup@12"
				GenerateDebugInformation="TRUE"
				AssemblyDebug="1"/>
			<Tool
				Name="VCMIDLTool"/>
			<Tool
				Name="VCPostBuildEventTool"/>
			<Tool
				Name="VCPreBuildEventTool"/>
			<Tool
				Name="VCPreLinkEventTool"/>
			<Tool
				Name="VCResourceCompilerTool"/>
			<Tool
				Name="VCWebServiceProxyGeneratorTool"/>
			<Tool
				Name="VCXMLDataGeneratorTool"/>
			<Tool
				Name="VCWebDeploymentTool"/>
			<Tool
				Name="VCManagedWrapperGeneratorTool"/>
			<Tool
				Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
		</Configuration>
		<Configuration
			Name="Release|Win32"
			OutputDirectory="$(ProjectDir)$(ConfigurationName)"
			IntermediateDirectory="$(ConfigurationName)"
			ConfigurationType="2"
			CharacterSet="2"
			ManagedExtensions="TRUE"
			WholeProgramOptimization="FALSE">
			<Tool
				Name="VCCLCompilerTool"
				InlineFunctionExpansion="2"
				EnableIntrinsicFunctions="TRUE"
				FavorSizeOrSpeed="1"
				OptimizeForWindowsApplication="TRUE"
				PreprocessorDefinitions="WIN32;NDEBUG"
				MinimalRebuild="FALSE"
				RuntimeLibrary="0"
				TreatWChar_tAsBuiltInType="FALSE"
				ForceConformanceInForLoopScope="TRUE"
				UsePrecompiledHeader="3"
				WarningLevel="3"
				DebugInformationFormat="3"/>
			<Tool
				Name="VCCustomBuildTool"/>
			<Tool
				Name="VCLinkerTool"
				AdditionalOptions="/NOENTRY /NODEFAULTLIB:libcmt.lib
"
				AdditionalDependencies="msvcrt.lib mscoree.lib"
				OutputFile="$(OutDir)\$(ProjectName).dll"
				LinkIncremental="1"
				IgnoreAllDefaultLibraries="TRUE"
				ForceSymbolReferences="__DllMainCRTStartup@12"
				GenerateDebugInformation="FALSE"
				OptimizeForWindows98="1"
				TargetMachine="1"/>
			<Tool
				Name="VCMIDLTool"/>
			<Tool
				Name="VCPostBuildEventTool"/>
			<Tool
				Name="VCPreBuildEventTool"/>
			<Tool
				Name="VCPreLinkEventTool"/>
			<Tool
				Name="VCResourceCompilerTool"/>
			<Tool
				Name="VCWebServiceProxyGeneratorTool"/>
			<Tool
				Name="VCXMLDataGeneratorTool"/>
			<Tool
				Name="VCWebDeploymentTool"/>
			<Tool
				Name="VCManagedWrapperGeneratorTool"/>
			<Tool
				Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
		</Configuration>
	</Configurations>
	<References>
		<AssemblyReference
			RelativePath="mscorlib.dll"/>
		<AssemblyReference
			RelativePath="System.dll"/>
		<AssemblyReference
			RelativePath="System.Data.dll"/>
		<AssemblyReference
			RelativePath="{ReferencesPath}\System.Drawing.dll"/>
		<AssemblyReference
			RelativePath="{ReferencesPath}\System.Windows.Forms.dll"/>
		<AssemblyReference
			RelativePath="System.XML.dll"/>
	</References>
	<Files>
		<Filter
			Name="Source Files"
			Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
			UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}">
			<File
				RelativePath=".\AssemblyInfo.cpp">
			</File>
			<File
				RelativePath=".\PartsCollection.cpp">
			</File>
			<File
				RelativePath=".\PropTable.cpp">
			</File>
			<File
				RelativePath=".\StatesCollection.cpp">
			</File>
			<File
				RelativePath=".\Stdafx.cpp">
				<FileConfiguration
					Name="Debug|Win32">
					<Tool
						Name="VCCLCompilerTool"
						UsePrecompiledHeader="1"/>
				</FileConfiguration>
				<FileConfiguration
					Name="Release|Win32">
					<Tool
						Name="VCCLCompilerTool"
						UsePrecompiledHeader="1"/>
				</FileConfiguration>
			</File>
			<File
				RelativePath=".\TextMetric.cpp">
			</File>
			<File
				RelativePath=".\ThemeInfo.cpp">
			</File>
			<File
				RelativePath=".\ThemeItem.cpp">
			</File>
			<File
				RelativePath=".\ThemeItemCollection.cpp">
			</File>
			<File
				RelativePath=".\ThemeItemEnumerator.cpp">
			</File>
			<File
				RelativePath=".\ThemePart.cpp">
			</File>
			<File
				RelativePath=".\ThemePartState.cpp">
			</File>
			<File
				RelativePath=".\UxTheme.cpp">
			</File>
			<File
				RelativePath=".\VisualStylesXP.cpp">
			</File>
			<File
				RelativePath=".\WindowTheme.cpp">
			</File>
		</Filter>
		<Filter
			Name="Header Files"
			Filter="h;hpp;hxx;hm;inl;inc;xsd"
			UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">
			<File
				RelativePath=".\IHasThemePartId.h">
			</File>
			<File
				RelativePath=".\IRenderableItem.h">
			</File>
			<File
				RelativePath=".\IThemeItemCollection.h">
			</File>
			<File
				RelativePath=".\PartsCollection.h">
			</File>
			<File
				RelativePath=".\PropTable.h">
			</File>
			<File
				RelativePath=".\resource.h">
			</File>
			<File
				RelativePath=".\StatesCollection.h">
			</File>
			<File
				RelativePath=".\Stdafx.h">
			</File>
			<File
				RelativePath=".\TextMetric.h">
			</File>
			<File
				RelativePath=".\ThemeInfo.h">
			</File>
			<File
				RelativePath=".\ThemeItem.h">
			</File>
			<File
				RelativePath=".\ThemeItemCollection.h">
			</File>
			<File
				RelativePath=".\ThemeItemEnumerator.h">
			</File>
			<File
				RelativePath=".\ThemePart.h">
			</File>
			<File
				RelativePath=".\ThemePartState.h">
			</File>
			<File
				RelativePath=".\UxTheme.h">
			</File>
			<File
				RelativePath=".\VisualStylesXP.h">
			</File>
			<File
				RelativePath=".\WindowTheme.h">
			</File>
		</Filter>
		<Filter
			Name="Resource Files"
			Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
			UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}">
			<File
				RelativePath=".\app.ico">
			</File>
			<File
				RelativePath=".\app.rc">
			</File>
		</Filter>
		<File
			RelativePath=".\Properties.txt">
		</File>
		<File
			RelativePath=".\ReadMe.txt">
		</File>
		<File
			RelativePath=".\themes.txt">
		</File>
	</Files>
	<Globals>
	</Globals>
</VisualStudioProject>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Team Leader Starkey Laboratories
United States United States
The first computer program I ever wrote was in BASIC on a TRS-80 Model I and it looked something like:
10 PRINT "Don is cool"
20 GOTO 10

It only went downhill from there.

Hey look, I've got a blog

Comments and Discussions