XP - Visual styles
With Windows XP getting to the masses, so does "skinning". But is it skinning, and how to do so then. Even, is it recommended ?
Ok, it's hot. XP comes with a (one) "visual style", with three color variations, that uses bitmaps to draw a window and most of the UI. That skinning ? In essence, yes, but this time the bitmaps, .ini files, .xml files and some more are incorporated in some heavy .dll, .theme, and .msstyles files. Plus you can't just add your own, stuff is "digitally signed". Whatever it is, it's a challenge!
Want the challenge, take it. Just want your UI skinned, maybe reconsider. Brad Wardell from Stardock/WindowBlinds wrote
this article, comparing "visual styles" and WindowBlinds in XP. It's biased, but it's good. Fact is, it's true that the latest WindowBlinds runs smoother than ever on XP, possibly smoother than the visual styles, has more (extra) features, is freeform where visual styles are pretty fixed for now, and you're allowed to run the basic version for free. Can't, won't argue with that.
But this place is about molding your OS - by hand - anyway, so we need to know if we can anyhow (and probably will run it too). And the answer is you can do it. It's still a hard job, but it can be done. Tools are available from
TgtSoft, and understanding of the format is growing.
Some
links: there's talk about the process, new themes released and much more at
neowin.net (forums) and
DT² Forums (most active spearheads),
ieXbeta.com and
tweakxp.com. Thé online archive of themes (prepare for a lot of colorizations, though) can be found at
ThemeXP.
Howto; with a little help
Help available are Style XP and the Stylebuilder, both from
TgtSoft. Both tools are shareware.
Style XP is the part that bypasses Windows file protection, and is now a style changer and more. Beta's 1 - 3 simply replaced uxtheme.dll with a patched version, with version 4 and above there's a memory resident process running. As TGT provides the patched .dll as a free alternative, that will make 3rd party themes available to you, no real need for it.
The
Stylebuilder lets you edit/create themes. It's actually quite good with that, limitations you find are most likely to be caused by limitations in format MS provided. You'll find format "not finished" in a lot of ways, especially when wanting to change sizing/aligning of items. The titlebar i.e. is a real pain to revamp, but most things cán be done, though. It often pays to experiment with addition of transparant area's to the bitmaps that make up the part you want to change. And with a now working import function, it's easy to disect another theme, to see how stuff got accomplished.
Additionally, you may need a resource editor still to edit default theme and/or the more simple theme provided with the beta. Read about that
here, in particular the piece on XP file protection (sfc_os.dll mod saved me some time...).
Some additional info to perfect your theme and/or alternative ways to accomplish changes:
-
You can bypass Windows checking if themes are signed, by patching uxtheme.dll yourself. That is, if you're comfortable with a hex editor. Here's the changes necessary, documented by Ishmael at Neowin, thanks :):
- At offset 0x00009C27, change "02" to "00";
- At offset 0x0000B624 to 0x0000B629, change the string "0F 8C 80 00 00 00" to "90 90 90 90 90 90";
- At offset 0x0000B6BB to 0x0000B6C2, change the string "81 EC 80 00 00 00 56 57" to "33 F6 8B C6 C9 C2 08 00";
- At offset 0x0000B71E and 0x0000B71F, change the string "7C 38" to "90 90".
Since these are made available all around, as patchers and what not - two plain .dll files, one for XP fresh, one for XP with Servicepack 1 installed. Version 6.00.2600.0000 (105 kB) and 6.00.2800.1106 (106 kB) - check file version and backup original file first.
-
Themes are in \Windows\Resources\Themes. A theme usually consists of a .theme file, a folder with the theme's name, containing a .msstyle file, and a folder named "Shell", containg one or more folders, named after available color variations, and containing a shellstyle.dll file.
-
Have a look in a .theme file first! If you're annoyed, when switching themes, cursors/colors/wallpaper and more of your choice keep getting lost, there's the reason. If an edited .msstyle file is called a "visual style", how about making a "theme", including a wallpaper, maybe some icons/cursors. The .theme file is easily edited in notepad, plus you can use some triggers after Path= for folders, bypassing the fact that not everybody got XP installed on the C:\ drive. Those are %WinDir%, %SystemRoot% and %ResourceDir%.
-
Bitmap resources and .ini files controlling them are in the .msstyles files. While the bitmaps are easily exchanged, editing the configuration stuff is a pain, and using the stylebuilder is much easier, mostly.
-
Wanted feature, no text and a custom logo on the startbutton. Can do, but you'll need to set some settings for the area to negative. Thus moves text and icon outside, left of screen area (!). Hence, startbutton background becomes the actual button. Stylebuilder won't let you do that. Heh, but TGT also has Resbuilder to edit some more (recommended editor here, as other show information as hex, which is hard to edit). If you open the .msstyles file, go to TEXTFILE section, check first 3 .ini's there. They all have a section like this (note these are my specific settings, yours will differ a lot):
[Start::Button]
BgType = ImageFile
ContentMargins = -29, 50, 1, 4
FillColorHint = 156 207 255
Font = Haettenschweiler, -1
Etc. It's the -29 that moves icon and text off the screen, but font(size) and more have an influence, you'll need to experiment a bit. Also, fontsize is set to -1 just to be sure. Note: new versions of stylebuilder allow negative values at some places where effects like this can be accomplished.
-
Accompanying shellstyle.dll contains graphics and settings for the XP webview. Only way to edit for now is using a resource editor, but these don't let you edit the UIFILE and .css files easily, mostly. Recommended tool is Resbuilder again, very conveniënt!