We are glad to announce that yesterday the translation of the sixth edition of the legendary book by Charles Petzold
“Programming Windows” , which had to wait more than 15 years, went on sale! The book is devoted to developing applications for Windows 8 using C # and XAML.

In his new book,
Charles Petzold , a well-known author and one of the pioneers of Windows programming, talks about developing applications for the Windows Store using C # and XAML in the Windows Runtime environment.
')
The first part of the book "Fundamentals" is devoted to techniques that are particularly important for most ordinary programmers: the assembly of ready-made controls in the application and their association with code and data. It fully explains the entire program code and markup generated by Visual Studio for different project templates.
In the second part of the book “Special features”, low-level and non-standard tasks are described - touch input, raster graphics, advanced text formatting, printing, work with orientation sensors and GPS.
The book is addressed to developers who are confident in C #, who want to learn the API for developing applications for Windows 8.
A little excursion into the history of the book from Charles Petzold
Before you is the 6th edition of Programming Windows, a book whose idea appeared in Microsoft Press in the fall of 1986. I was attracted to the project because at that time I was writing articles on Windows programming for Microsoft Systems Journal (predecessor of MSDN Magazine).
On the cover of the first edition of Programming Windows, the book was described as "Programming Guide for MS-DOS Presentation Manager: Windows 2.0 and Windows / 386". The reference to Presentation Manager recalls the days when Windows and OS / 2 Presentation Manager peacefully coexisted as different environments for two different operating systems.
The first edition of Programming Windows (1988) went almost unnoticed by the programmer community. When MS-DOS programmers gradually realized that they would have to learn the brave new world of Windows, the 2nd edition (published in 1990 and focused on Windows 3) and the 3rd edition (1992, Windows 3.1) helped them.
When the transition from the 16-bit Windows API to the 32-bit interface occurred, the 4th edition of Programming Windows (1996, Windows 95) and the 5th edition (1998, Windows 98) were released. And although the 5th edition is still on sale, the messages I receive from readers show that the book is popular mainly in India and China.
Over the years, Programming Windows has gained a reputation for books for programmers who want to work at a low level, with no additional layers between their code and the operating system. But I absolutely did not consider the early editions of "Programming Windows" from such positions. At that time, “working at a low level” meant programming in assembler, writing output characters directly to the memory of a video adapter, and using MS-DOS only for file input / output. On the other hand, programming for Windows meant a high-level language, graphics without acceleration, and access to hardware only through a thick layer of API functions and device drivers.
The transition from MS-DOS to Windows was a deliberate rejection of speed and efficiency for other benefits. But which ones? Many veteran programmers simply did not understand why. Graphics? Pictures? Colors? Fonts? Mouse? Not for this computers are created!
If you wait long enough, the high-level language becomes low-level, and multiple interface layers are compressed to the API. Some modern C and C ++ programmers reject managed languages (such as C #) for reasons of efficiency, and the Windows environment has even brought back vigorous debate on this topic to life. Windows 8 is probably the most revolutionary Windows update since the first version was released in 1985, but many experienced Windows users doubt the rationality of using a touch-sensitive interface adapted for smartphones and tablets on common desktop computers and grumble when they cannot find familiar features. .
Probably the only thing that could bring back the “Programming Windows” series from a half-forgetting is an impressive and ambiguous new Windows user interface, as well as an API and programming language adapted to its modern aspirations.
This book is devoted exclusively to programming Windows Store applications. Many other books have been written about writing Win32 desktop applications, including the 5th edition of Programming Windows. Occasionally, the text will mention the Win32 API and desktop applications, but the book is written about programming new Windows 8 applications.
To write these applications, a new object-oriented programming interface called Windows Runtime or WinRT was introduced (not to be confused with Windows RT — the version of Windows 8 for ARM processors).
Currently, there are three main programming options for Windows 8 applications, each of which is based on a specific programming language and markup language:
- C ++ and XAML
- C # or Visual Basic and XAML
- JavaScript and HTML5
All three options use the Windows Runtime interface, but it is also supported by another programming interface for a particular language. Although mixed use of multiple languages in a single application is not possible, you can create libraries (such as the Windows Runtime Component) with your own .winmd files, available from any Windows 8 language.
After much deliberation (and mental agony), I decided that this book should be almost entirely devoted to C # and XAML. For many years I have been convinced of the advantages of managed languages for development and debugging, and in my opinion, C # is the best language for Windows Runtime. I hope the C # code will be clear enough for C ++ programmers to make this book useful.
I am also confident that a book concentrated on one language is more useful than a book trying to equally consider several languages at once.
Table of contents
Table of contents of the book can be viewed
here , and an excerpt to read
here .
Where can one buy
You can buy the book
on piter.com (paper and electronic version is available (PDF format)) . The book is also available (or will be available within a few days) in all popular online stores and bookstores of the country.
A discount
Till October 23, 2013,
a 25% discount coupon is valid for Habra visitors when buying a book. The discount is valid both on paper and on the electronic version of the book. To receive a discount, when
placing the order, enter the coupon code:
220b30cdc9b580a142889