Click here to Skip to main content
Click here to Skip to main content
Add your own
alternative version

Classic Shell

, 23 Feb 2010 MIT
Classic Start menu and other shell features for Windows 7 and Vista.
ClassicShellSetup.zip
ClassicShellSetup.exe
ClassicShellSrc.zip
ClassicShell
ClassicExplorer
ClassicCopyExt.rgs
ClassicExplorer.rgs
ClassicExplorer32.def
ClassicExplorer64.def
Explorer.ini
ExplorerBand.rgs
ExplorerBHO.rgs
ExplorerL10N.ini
up.ico
up2Disabled.ico
up2Hot.ico
up2Normal.ico
up2Pressed.ico
upDisabled.ico
ClassicShellSetup
ClassicShell.ico
ClassicShellBanner.jpg
ClassicShellSetup.manifest
ClassicShellSetup32
ClassicShellSetup32.vdproj
ClassicShellSetup64
ClassicShellSetup64.vdproj
ClassicStartMenu
ClassicStartMenu.manifest
ClassicStartMenuDLL
StartMenu.ini
StartMenuItems.ini
StartMenuL10N.ini
Docs
ClassicExplorer_files
after.png
before.png
ClassicShell.png
FolderView.gif
iconoffset.png
statusbar.png
titlebar.png
toolbar.png
ClassicShellEULA.rtf
ClassicShellReadme.rtf
ClassicStartMenu_files
ClassicShell.png
screenshot.png
skins.gif
ParseSettings
Skins
ClassicSkin
main_bitmap.bmp
selection.bmp
VistaAero
main_bitmap.bmp
selection.bmp
Win7Aero
main_bitmap.bmp
selection.bmp
Win7Basic
main_bitmap.bmp
selection.bmp
// Classic Shell (c) 2009-2010, Ivo Beltchev
// The sources for Classic Shell are distributed under the MIT open source license

#pragma once

#include <vector>

struct MenuSkin
{
	CString About; // the text to show in the About box
	HICON AboutIcon; // the icon to show in the About box
	bool ForceRTL;
	std::vector<std::pair<int,CString>> Variations;

	// MAIN BITMAP SECTION - describes the background of the main menu
	HBITMAP Main_bitmap;
	bool Main_bitmap32; // 32-bit bitmap
	int Main_bitmap_slices_X[6];
	int Main_bitmap_slices_Y[3];

	enum TOpacity
	{
		OPACITY_SOLID,
		OPACITY_REGION,
		OPACITY_ALPHA,
		OPACITY_GLASS,
	};

	TOpacity Main_opacity;
	bool Main_large_icons;

	// CAPTION SECTION - describes the caption portion of the main menu
	HFONT Caption_font;
	COLORREF Caption_text_color;
	COLORREF Caption_glow_color;
	int Caption_glow_size;
	RECT Caption_padding;

	// MENU SECTION - describes the menu portion of the main menu
	HFONT Main_font;
	COLORREF Main_background;
	COLORREF Main_text_color[4]; // normal, selected, disabled, selected+disabled
	RECT Main_padding;
	bool Main_selectionColor;
	bool Main_selection32; // 32-bit bitmap
	union
	{
		HBITMAP bmp; // if Main_selectionColor is false
		COLORREF color; // if Main_selectionColor is true
	} Main_selection;
	int Main_selection_slices_X[3];
	int Main_selection_slices_Y[3];
	HBITMAP Main_separator;
	bool Main_thin_frame;
	bool Main_separator32; // 32-bit bitmap
	int Main_separatorHeight;
	int Main_separator_slices_X[3];

	// SUB-MENU SECTION - describes the menu portion of the sub-menu
	HFONT Submenu_font;
	COLORREF Submenu_background;
	COLORREF Submenu_text_color[4]; // normal, selected, disabled, selected+disabled
	RECT Submenu_padding;
	bool Submenu_selectionColor;
	bool Submenu_selection32; // 32-bit bitmap
	union
	{
		HBITMAP bmp; // if Submenu_selectionColor is false
		COLORREF color; // if Submenu_selectionColor is true
	} Submenu_selection;
	int Submenu_selection_slices_X[3];
	int Submenu_selection_slices_Y[3];
	HBITMAP Submenu_separator;
	bool Submenu_separator32; // 32-bit bitmap
	bool Submenu_thin_frame;
	int Submenu_separatorHeight;
	int Submenu_separator_slices_X[3];

	MenuSkin( void );
	~MenuSkin( void );
	void Reset( void );
};

bool LoadMenuSkin( const wchar_t *fname, MenuSkin &skin, const wchar_t *variation, bool bNoResources );
void LoadDefaultMenuSkin( MenuSkin &skin, const wchar_t *variation, bool bNoResources );
void FreeMenuSkin( MenuSkin &skin );

// Returns the path to the skin files. path must be _MAX_PATH characters
void GetSkinsPath( wchar_t *path );

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 MIT License

Share

About the Author

Ivo Beltchev
Software Developer (Senior)
United States United States
Ivo started programming in 1985 on an Apple ][ clone. He graduated from Sofia University, Bulgaria with a MSCS degree. Ivo has been working as a professional programmer for over 12 years, and as a professional game programmer for over 10. He is currently employed in Pandemic Studios, a video game company in Los Angeles, California.

| Advertise | Privacy | Terms of Use | Mobile
Web03 | 2.8.141223.1 | Last Updated 23 Feb 2010
Article Copyright 2009 by Ivo Beltchev
Everything else Copyright © CodeProject, 1999-2014
Layout: fixed | fluid