What s New in the Fourth Edition

[Previous] [Next]

Readers of Advanced Windows will notice one big change right away: the book's title. Microsoft Press and I both felt that Advanced Windows didn't convey enough information about the book's content. For starters, the previous title didn't indicate that the book is for developers. Consequently, bookstores filed the book in the wrong category. Second, I received much e-mail from potential readers who thought my book was "advanced" and wanted me to recommend a more beginner- or intermediate-level Windows programming book.

As for content, the fourth edition is practically a whole new book. I focused on shorter chapters, better isolation of material, and reorganization. I hope that these changes will make the material easier to follow and understand. For example, the Unicode chapter is now at the front of the book, since Unicode influences most of the other topics in one way or another.

In addition, I give each topic much more depth than in previous editions. Specifically, I explain more of the system's inner workings so that you'll know exactly what the system is doing under the covers. I also give much more coverage of how the C/C++ run-time library interacts with the operating system—particularly on process and thread creation and destruction, as well as dynamic-link libraries.

In addition to the new organization and greater depth, I added a ton of new content. Here is a partial list of enhancements made for this edition:

  • New Windows 2000 features. Of course, the book would not be a true revision unless it covered new features offered in Windows 2000. This edition has new information on the job kernel object, thread pooling functions, thread scheduling issues, address windowing extensions, toolhelp functions, sparse files, and more.
  • 64-bit Windows support. The text addresses 64-bit Windows-specific issues; all sample applications have been built and tested on 64-bit Windows.
  • Practical sample applications. I have replaced many of the old sample applications with more relevant sample applications that show how to solve real-world programming problems.
  • Use of C++. The sample applications now use C++ since many readers have requested it. As a result, the sample applications require fewer lines of code, and their logic is easier to follow and understand.
  • Reusable code. Whenever possible, I created the source code to be generic and reusable. This should allow you to take individual functions or entire C++ classes and drop them into your own applications with little or no modification. The use of C++ made reusability much easier.
  • The VMMap utility. This particular sample application from the earlier editions has been greatly enhanced. The new VMMap sample can now walk any process's address space, show the pathnames of any data files that have been memory-mapped into the address space, refresh its display, copy the memory information to the clipboard, and (optionally) show only the regions or blocks within the regions.
  • The ProcessInfo utility. This sample application is new. It shows which processes are running on the system and which DLLs are being used by that module. Once you select a process, this utility can spawn the VMMap utility to walk that process's entire address space. ProcessInfo can also show which modules are loaded in the system and which executables are using that module. It also shows which modules have been relocated because of improper basing.
  • The LISWatch utility. This sample application is also new. It monitors the system-wide and thread-specific local input state changes for windows. This utility can greatly help you track down user-interface focus change problems.
  • Performance issues. I give much more information and numerous tips on how to make smaller, faster-running code. Specifically, I've added coverage on data alignment, processor affinity, CPU cache line boundary issues, thread synchronization concerns, module rebasing, module binding, and delay-loading DLLs.
  • Greatly improved threading synchronization material. I completely rewrote and reorganized all of the thread synchronization material. The new presentation introduces the high-performance thread synchronization methods first and the lower-performance methods last. I've added a new "thread synchronization toolkit" chapter that offers reusable code for solving common thread synchronization scenarios.
  • Executable file format details. I go into much more detail about executable and DLL module file formats. I discuss the various sections of these modules and show special linker switches that allow you to do some pretty cool things to a module.
  • More detailed DLL information. I've rewritten and reorganized the DLL chapters. The first DLL chapter answers the two basic DLL questions: "What is a DLL?" and "How do I create a DLL?" The remaining DLL chapters dig into advanced DLL features (many of which are new) such as explicit linking, delay loading, function forwarders, DLL redirection (new for Windows 2000), module rebasing, and binding.
  • API hooking. Yes, it's true. I've received so much e-mail over the years about API hooking that I have finally added it to the book. I present C++ classes that make it trivial to hook APIs in one or all modules of a process. My code even traps run-time calls to LoadLibrary and GetProcAddress so that your API hooks are enforced.
  • Structured exception handling improvements. I have rewritten and reorganized much of the structured exception handling material. I have more information on unhandled exceptions, and I offer a C++ class that wraps the proper way of handling virtual memory with structured exception handling. I've added coverage on debugging exceptions and how C++ exception handling relates to structured exception handling.
  • Error handling. This new chapter shows how to properly detect errors when calling Windows functions. The chapter also describes some debugging techniques and how to have your functions report errors.
  • Windows Installer. Oh yeah, before I forget: The sample applications on the CD-ROM take advantage of the new Windows Installer built into Windows 2000. This allows you fine control over the parts that you want to install and also allows you to easily uninstall the book's sample applications and executable files using the Add/Remove Programs Control Panel applet. If you are using Windows 95, Windows 98, or Windows NT 4.0, the Setup program on the CD-ROM will automatically install the Windows Installer first. Of course, you can always just access the source files and executable files directly off the CD-ROM if you prefer.


Programming Applications for Microsoft Windows
Programming Applications for Microsoft Windows (Microsoft Programming Series)
ISBN: 1572319968
EAN: 2147483647
Year: 1999
Pages: 193

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net