|
|
 |

|
 |
|
Microsoft® Windows® XP Registry Guide
|
|
 |
Author |
 |
Jerry Honeycutt
|
 |
|
Pages |
528
|
|
Disk |
N/A
|
|
Level |
Advanced
|
|
Published |
09/11/2002
|
|
ISBN |
9780735617889
|
|
ISBN-10 |
0-7356-1788-0
|
|
Price(USD) |
$39.99
To see this book's discounted price, select a reseller below.
|
|
|
|
|
 |
|
|
Chapter 5: Mapping Tweak UI
5 Mapping Tweak UI
Microsoft Tweak UI is a must-have tool for anyone customizing Microsoft Windows XP. It prevents users from opening the registry and customizing settings that aren't available in the operating system's user interface. Tweak UI started as a grassroots utility built by a handful of rebellious programmers and ended up one of the most popular downloads on the Internet. Microsoft has released versions of this tool for every version of Windows since Microsoft Windows 95. The company even included it on the Microsoft Windows 98 CD. And now, it's available for Windows XP, and it includes even more customizations.
You can download Tweak UI from http://www.microsoft.com/downloads (Microsoft split the original Microsoft Power- Toys programs apart). You can also download it from http://downloads-zdnet.com.com, one of my favorite download Web sites. The file you download is called TweakUiPowertoySetup.exe. Run this program to install Tweak UI on your computer. To run Tweak UI, click Start, All Programs, Powertoys for Windows XP, and Tweak UI for Windows XP. In the left pane, click a category, and then in the right pane, edit the settings you want to change. The program is mostly self-explanatory; you see a description of each setting at the bottom of the window. Pay attention to the bottom part of the windows. It tells you whether the settings in that category are per-user or per-machine. Per-user settings sometimes require you to log off and back on to Windows XP in order for them to take affect. Per-machine settings affect every user who logs on to the computer.
This chapter isn't about using Tweak UI—that's too easy. Instead, I'll tell you where in the registry Tweak UI changes each setting. Information like this is powerful. You can script Tweak UI customizations. For example, power users can write a script to apply their favorite Tweak UI settings, and then apply all those settings to every computer they use simply by running the script. The process is streamlined—compare one double-click to dozens of clicks and edits—and the consistency doesn't hurt, either. IT professionals can write a script to deploy useful settings to users or include those settings in default user profiles for new users (see Chapter 10, "Deploying User Profiles"). Scripting these settings is amazingly easy, and you learn how to do that in Chapter 9, "Scripting Registry Changes."
The sections in this chapter correspond to the major categories in Tweak UI. (I skipped the About and Repair categories because they have little to do with the registry. You should look at both, though. The About category contains useful tips for using Windows XP. The Repair category can fix a variety of small problems, including messed up icons, fonts, and folders.) Each section contains a brief description of the settings in that category and how to change them in the registry. In most cases, each section contains a table that describes each setting's value name, value type, and value data. Each table contains subheadings that show the key for the values following it.
General
The items in the Settings list in the General category are effects that you can enable or disable. In fact, the Settings list, shown in Figure 5-1, used to be called the Effects list in earlier versions of Tweak UI. Settings range from list box and window animations to menu fading. Disable these settings only on slower computers when you think you can improve the user interface's crispness; otherwise, these settings make Windows XP look great.
 Click to view graphic
Figure 5-1 Many of these settings are in the Performance Options dialog box. Right-click My Computer, click Properties, and in the Performance area of the Advanced tab of the Properties dialog box, click Settings.
You see all the settings in the General category in Table 5-1. One value needs a bit of explaining, though: UserPreferencesMask. The bits in this REG_BINARY value are various settings, which Chapter 4, "Hacking the Registry," and Appendix B, "Per-User Settings," describe in detail. To turn on a setting, set the appropriate bit to 1 in UserPreferencesMask. To turn off a setting, clear the corresponding bit. The number in the Data column tells you which bit to toggle. The easiest way to toggle the bit is to use Calculator in scientific mode. Bitwise math is beyond most simple scripting techniques, including REG files. If you want to create a script to change the settings in UserPreferencesMask, use INF files or look to Windows Scripting Host (see Chapter 9, "Scripting Registry Changes").
Table 5-1 Values in General
| Setting | Name | Type | Data |
HKCU\Control Panel\Sound | | | |
Beep on errors | Beep | REG_SZ | Yes | No |
HKCU\Control Panel\Desktop | | | |
Enable combo box animation | UserPreferencesMask | REG_BINARY | Bit 0x0004 |
Enable cursor shadow | UserPreferencesMask | REG_BINARY | Bit 0x2000 |
Enable list box animation | UserPreferencesMask | REG_BINARY | Bit 0x0008 |
Enable menu animation | UserPreferencesMask | REG_BINARY | Bit 0x0002 |
Enable menu fading | UserPreferencesMask | REG_BINARY | Bit 0x0200 |
Enable menu selection fading | UserPreferencesMask | REG_BINARY | Bit 0x0400 |
Enable mouse hot tracking effects | UserPreferencesMask | REG_BINARY | Bit 0x0080 |
Enable tooltip animation | UserPreferencesMask | REG_BINARY | Bit 0x0800 |
Enable tooltip fade | UserPreferencesMask | REG_BINARY | Bit 0x1000 |
Show Windows version on desktop | PaintDesktopVersion | REG_DWORD | 0X00 | 0X01 |
HKCU\Control Panel\Desktop\WindowMetrics | | | |
Enable Window Animation | MinAnimate | REG_SZ | 0 | 1 |
Focus
When an application needs your attention—or when it simply wants to annoy you—it steals the focus from the application in which you're currently working. This leads to frustration as you flip back and forth between windows. The settings in the Focus category prevent that scenario by causing applications to flash their taskbar buttons to get your attention rather than stealing focus from the application in the foreground.
Table 5-2 describes the settings in the Focus category. The default value for ForegroundLockTimeout is 0x00030D40, or 200000. This value is the time in milliseconds before Windows XP allows an application to steal the focus from the foreground application. To convert 200000 to seconds, divide it by 1000 (200 seconds). You see the value ForegroundFlashCount in the table twice, because setting it to 0 causes the taskbar button to flash until you click it; otherwise, the taskbar button flashes the number of times you set in ForegroundFlashCount.
Table 5-2 Values in Focus
| Setting | Name | Type | Data |
HKCU\Control Panel\Desktop | | | |
Prevent applications from stealing focus | ForegroundLockTimeout | REG_DWORD | N |
Flash taskbar button until I click on it | ForegroundFlashCount | REG_DWORD | 0x00 |
Flash taskbar button N times | ForegroundFlashCount | REG_DWORD | N |
Mouse
The settings in the Mouse category control the rodent's sensitivity. Before adjusting these values manually, use Tweak UI to figure out what the best settings are for you. You can use the test icon, shown in Figure 5-2, to try different values. After you've settled on a value, you're good to go.
 Click to view graphic
Figure 5-2 Use Tweak UI to find suitable values before trying to set mouse sensitivity values manually.
The first value in Table 5-3 (on the next page), MenuShowDelay, is the time in milliseconds that Windows XP waits before opening a menu to which you point. The default is 400, or .4 seconds, but you can cut that number in half if you want menus to open faster. The values DragHeight and DragWith are the settings that specify the distance (in number of pixels) that you must move the mouse with a button held down before Windows XP recognizes that you're dragging something. The default value is 4 pixels, and you should keep the height and width the same as each other. The last two values, DoubleClickHeight and DoubleClickWidth, are the settings that specify the maximum distance (in pixels) allowed between two mouse clicks before Windows XP recognizes that you're double-clicking something. The default value is 2. These are REG_SZ values; Windows XP expects decimal rather than hexadecimal numbers.
Table 5-3 Values in Mouse
| Setting | Name | Type | Data |
HKCU\Control Panel\Desktop | | | |
Menu speed | MenuShowDelay | REG_SZ | 0 to 65534 |
Drag | DragHeight DragWidth | REG_SZ | 0 to N |
HKCU\Control Panel\Mouse | | | |
Double-click | DoubleClickHeight DoubleClickWidth | REG_SZ | 0 to N |
Hover
The settings in the Hover category are similar to the settings in the Mouse category. They control the size of the area in pixels and the time in milliseconds that the mouse pointer must remain in one spot before Windows XP recognizes that the mouse is hovering over something. Table 5-4 describes the values for this category. The default sensitivity is 2, and you should keep the height and width equal to each other. The default hover time is 400. Cut that number in half to select objects quicker when you point to them. If you don't see these values in the registry, create them.
Table 5-4 Values in Hover
| Setting | Name | Type | Data |
HKCU\Control Panel\Mouse | | | |
Hover sensitivity | MouseHoverWidth MouseHoverHeight | REG_SZ | 0 to N |
Hover time (ms) | MouseHoverTime | REG_SZ | 0 to N |
Wheel
The setting in the Wheel category controls the mouse wheel. The value WheelScrollLines is the only value in Table 5-5. That's because the three different options in this category relate to the different data you can assign to this value. The default is 3, which enables the mouse wheel to scroll 3 lines at a time.
Table 5-5 Values in Wheel
| Setting | Name | Type | Data |
HKCU\Control Panel\Desktop | | | |
Use mouse wheel for scrolling | WheelScrollLines | REG_SZ | 0 |
Scroll a page at a time | WheelScrollLines | REG_SZ | -1 |
Scroll N lines at a time | WheelScrollLines | REG_SZ | 0 to N |
X-Mouse
The settings in the X-Mouse category, as described in Table 5-6, used to be one of my favorite customizations. I liked the idea of windows popping to the foreground when I pointed at them. It gets annoying after a while, but it's a novelty you should try because you might like it. Here's more on each of these settings:
- Activation follows mouse (X-Mouse). Gives focus to any window to which you point but doesn't raise the window to the foreground unless you check the next option in this list.
- Autoraise when activating. Brings the window that has focus to the foreground.
- Activation delay (ms). Specifies the delay (in milliseconds) before Windows XP brings the window to which you pointed to the foreground.
These settings in the value UserPreferencesMask are bits, which you learned about earlier in this chapter. The default value for ActiveWndTrkTimeout is 0, but 400 is a more reasonable delay. A higher timeout prevents windows from flipping between the foreground and background, making this feature much less annoying and more useful.
Table 5-6 Values in X-Mouse
| Setting | Name | Type | Data |
HKCU\Control Panel\Desktop | | | |
Activation follows mouse (X-Mouse) | UserPreferencesMask | REG_BINARY | Bit 0x0001 |
Autoraise when activating | UserPreferencesMask | REG_BINARY | Bit 0x0040 |
Activation delay (ms) | ActiveWndTrkTimeout | REG_DWORD | 0 to N |
Explorer
The settings in the Explorer category are all over the map: You can customize the Start menu, enable smooth scrolling, and automatically clear the document history. Table 5-7 on the next page maps the settings in this category to their registry values. Create any keys and values that you don't see in the registry.
You'll notice that the setting Show Links On Favorites Menu is missing from Table 5-7. This is because that setting isn't in the registry. When you disable the Links menu, Tweak UI simply sets the Links folder's hidden attribute. Enable the folder, and Tweak UI clears the Links folder's hidden attribute. This is the only way to prevent Internet Explorer from displaying the Links folder on the Favorites menu.
Table 5-7 Values in Explorer
| Setting | Name | Type | Data |
HKCU\Control Panel\Desktop | | | |
Enable smooth scrolling | SmoothScroll | REG_DWORD | 0x00 | 0x01 |
HKCU\Software\Microsoft\Internet Explorer\Main | | | |
Use Classic Search in Internet Explorer | Use Search Asst | REG_SZ | Yes | No |
HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer | | | |
Manipulate connected files as a unit | NoFileFolderConnection | REG_DWORD | 0x00 | 0x01 |
Prefix "Shortcut to" on new shortcuts | Link | REG_DWORD | 0x00 | 0x01 |
HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced | | | |
Detect accidental double-clicks | UseDoubleClickTimer | REG_DWORD | 0x00 | 0x01 |
HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\CabinetState | | | |
Use Classic Search in Explorer | Use Search Asst | REG_SZ | Yes | No |
HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer | | | |
Allow Help on Start Menu | NoSMHelp | REG_DWORD | 0x00 | 0x01 |
Allow Logoff on Start Menu | NoLogoff | REG_DWORD | 0x00 | 0x01 |
Allow Recent Documents on Start Menu | NoRecentDocsMenu | REG_DWORD | 0x00 | 0x01 |
Allow Web content to be added to the desktop | NoActiveDesktop | REG_DWORD | 0x00 | 0x01 |
Clear document history on exit | ClearRecentDocsOnExit | REG_DWORD | 0x00 | 0x01 |
Enable Windows+X hotkeys | NoWinKeys | REG_DWORD | 0x00 | 0x01 |
Lock Web content | NoActiveDesktopChanges | REG_DWORD | 0x00 | 0x01 |
Maintain document history | NoRecentDocsHistory | REG_DWORD | 0x00 | 0x01 |
Maintain network history | NoRecentDocsNetHood | REG_DWORD | 0x00 | 0x01 |
Show My Documents on classic Start Menu | NoSMMyDocs | REG_DWORD | 0x00 | 0x01 |
Show My Pictures on classic Start Menu | NoSMMyPictures | REG_DWORD | 0x00 | 0x01 |
Show Network Connections on classic Start Menu | NoNetworkConnections | REG_DWORD | 0x00 | 0x01 |
Shortcut
When you create a shortcut, Windows XP adds an overlay to the original document's icon so you can easily identify it as a shortcut. The Shortcut category enables you to customize that overlay. You can choose not to add an overlay, to add a light arrow, to use the normal arrow, or to use a custom icon as the overlay. Table 5-8 shows the value and data that Tweak UI uses for shortcuts.
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIcons is the key where you customize the shortcut overlay. Create this key if you don't see it in the registry. You add the REG_SZ value 29, and set it to filename,index, where filename is the name of the file containing the icon, and index is the index of that icon. For more information about using icons, see Chapter 4, "Hacking the Registry." Tweak UI removes 29 from ShellIcons if you choose the default arrow. It sets 29 to C:\WINDOWS\system32\tweakui.exe,2 for a light arrow or C:\WINDOWS\system32\tweakui.exe,3 for no arrow.
Table 5-8 Values in Shortcut
| Setting | Name | Type | Data |
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIcons | | | |
Arrow | 29 | REG_SZ | null |
Light Arrow | 29 | REG_SZ | C:\WINDOWS\system32\tweakui.exe,2 |
None | 29 | REG_SZ | C:\WINDOWS\system32\tweakui.exe,3 |
Custom | 29 | REG_SZ | filename,index |
Colors
Table 5-9, on the next page, describes the values in the Colors category. Create any values that you don't see in the registry. HotTrackingColor is a string value, and Windows XP expects an RGB value in decimal notation. For example, white is 255 255 255. The operating system expects binary RGB values in hexadecimal for the remaining values. Windows XP uses each color as follows:
- Hot-tracking. Windows XP displays file names in this color when you point to them and if you've enabled the single-click user interface.
- Compressed files. Windows XP displays compressed files in this color.
- Encrypted files. Windows XP displays encrypted files in this color.
Table 5-9 Values in Colors
| Setting | Name | Type | Data |
HKCU\Control Panel\Colors | | | |
Hot-tracking | HotTrackingColor | REG_SZ | RRR GGG BBB |
HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer | | | |
Compressed files | AltColor | REG_BINARY | 0xRR 0xGG 0xBB 0x00 |
Encrypted files | AltEncryptionColor | REG_BINARY | 0xRR 0xGG 0xBB 0x00 |
Thumbnails
The Thumbnails category controls the quality of thumbnails in Windows Explorer. Table 5-10 describes the values for Image Quality and Size. Create values that you don't see in the registry. The default value for ThumbnailQuality is 0x5A. The default value for ThumbnailSize is 0x60. Keep in mind that higher quality and larger thumbnails require more disk space, which is not usually a problem, but they also take longer to display. Changing the quality does not affect thumbnails that already exist on the file system.
Table 5-10 Values in Thumbnails
| Setting | Name | Type | Data |
HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer | | | |
Image Quality | ThumbnailQuality | REG_DWORD | 0x32 - 0x64 |
Size (pixels) | ThumbnailSize | REG_DWORD | 0x20 - 0xFF |
Command Keys
If you have a keyboard with navigation keys, such as the Microsoft Internet Keyboard Pro (I use this keyboard; learn more about it at http://www.microsoft.com/hardware), you can customize them. For example, you can reassign the Calculator key to open your favorite calculator, instead of the program that comes with Windows XP.
HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\AppKey is the key where you customize the navigation keys. If you don't see this key, create it. Look up the keyboard key you want to customize in Table 5-11, and then add the corresponding subkey to AppKey. Within that subkey, create the REG_SZ value ShellExecute, and set it to the path and file name of the program you want to execute by pressing that key. If you want to disable the navigation key, set it to an empty string. You can restore the original behavior by removing the subkey you added to AppKey. For example, to run PowerToy Calculator by pressing the Calculator key, add 18 to AppKey. Then create the REG_SZ value ShellExecute in 18, and set it to PowerCalc.exe.
Table 5-11 Subkeys for Command Keys
| Key | Subkey | Key | Subkey |
Back (Internet browser) | 1 | New | 29 |
Calculator | 18 | Open | 30 |
Close | 31 | Paste | 38 |
Copy | 36 | Print | 33 |
Corrections | 45 | Raise microphone volume | 26 |
Cut | 37 | Redo | 35 |
Favorites | 6 | Refresh (Internet browser) | 3 |
Find | 28 | Reply | 39 |
Forward (Internet browser) | 2 | Save | 32 |
Forward (mail) | 40 | Search | 5 |
Help | 27 | Send | 41 |
Lower microphone volume | 25 | Spelling checker | 42 |
Mail | 15 | Stop (Internet browser) | 4 |
Media | 16 | Toggle dictation and command/control | 43 |
Mute microphone | 24 | Toggle microphone | 44 |
Mute volume | 8 | Undo | 34 |
My Computer | 17 | WebHome | 7 |
Common Dialog Boxes
The common dialog boxes, such as the Save As dialog box, display the places bar on the left side. These are shortcuts to common folders, which make getting around much easier. By default, you see the History, Documents, Desktop, Favorites, and My Network Places folders there. You can customize the folders that appear in the places bar by using the Common Dialogs category in Tweak UI (see Figure 5-3 on the next page).
 Click to view graphic
Figure 5-3 Make network document folders easily accessible by adding them to the places bar.
First things first: Table 5-12 describes the settings that enable you to remove the Back button and history from common dialog boxes. You can also hide the places bar altogether by setting the value NoPlacesBar to 0x01. Create this value if it doesn't exist.
Table 5-12 Values in Common Dialog Boxes
| Setting | Name | Type | Data |
HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\comdlg32 | | | |
Show Back button on File Open/Save dialog box | NoBackButton | REG_DWORD | 0x00 | 0x01 |
Remember previously-used file names | NoFileMru | REG_DWORD | 0x00 | 0x01 |
Hide places bar | NoPlacesBar | REG_DWORD | 0x00 | 0x01 |
Customizing the places bar is a bit more complicated. First you add to HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\comdlg32\ the PlacesBar subkey. In PlacesBar, create the REG_DWORD values Place0, Place1, Place2, Place3, and Place4. These correspond to the five available buttons from top to bottom. The common dialog boxes will display only the buttons specified by these values; if there is a PlacesBar subkey with no values, an empty places bar will be displayed. Then set PlacesN to one of the settings in shown in Table 5-13. For example, to set the second button to My Music, create the REG_DWORD value Places1 in PlacesBar, and set it to 0x0D. You're not limited to the folders you see in Table 5-13, by the way. You can create the PlacesN value as a REG_SZ and then add the path of any folder. To restore the default places bar, remove the PlacesBar subkey and remove the NoPlacesBar value.
Table 5-13 Folders for the Places Bar
| Folder | Value | Folder | Value |
Desktop | 0x00 | Network Neighborhood | 0x12 |
Favorites | 0x06 | History | 0x22 |
My Documents | 0x05 | My Pictures | 0x27 |
My Music | 0x0D | Recent Documents | 0x08 |
My Computer | 0x11 | | |
Next
Last Updated: September 11, 2002
|