Showing results for October 2003 - Page 3 of 4 - The Old New Thing

Oct 13, 2003
Post comments count0
Post likes count0

Why is there no WM_MOUSEENTER message?

Raymond Chen
Raymond Chen

There is a message. Why isn't there a message? Because you can easily figure that out for yourself. When you receive a message, set a flag that says, "The mouse is outside the window." When you receive a message and the flag is set, then the mouse has entered the window. (And cle...

Code
Oct 10, 2003
Post comments count0
Post likes count0

Why doesn't the clock in the taskbar display seconds?

Raymond Chen
Raymond Chen

Early beta versions of the taskbar clock did display seconds, and it even blinked the colon like some clocks do. But we had to remove it. Why? Because that blinking colon and the constantly-updating time were killing our benchmark numbers. On machines with only 4...

History
Oct 9, 2003
Post comments count0
Post likes count0

Other uses for bitmap brushes

Raymond Chen
Raymond Chen

Bitmap brushes used to be these little 8x8 monochrome patterns that you could use for hatching and maybe little houndstooth patterns if you were really crazy. But you can do better. CreatePatternBrush lets you pass in any old bitmap - even a huge one, and it will create a brush from it. The bi...

Code
Oct 8, 2003
Post comments count0
Post likes count0

In Explorer, you can right-click the icon in the caption

Raymond Chen
Raymond Chen

In Explorer, you can right-click the icon in the caption to get the context menu for the folder you are viewing. (Very handy for "Search" or "Command Prompt Here".) Apparently not enough people realize this. In Windows 95, we tried to make it so most icons on the screen did something interesting when you right-clicked them.

Tips/Support
Oct 8, 2003
Post comments count0
Post likes count0

I'm doing this instead of writing a book

Raymond Chen
Raymond Chen

Some commenters mentioned that I should write a book. It turns out that writing a book is hard. A few years ago, MS Press actually approached me about writing a book for them. But I declined because the fashion for technical books is to take maybe fifty pages of information and pad it to a 700-page book, and I can't write that way. None of my to...

Non-Computer
Oct 7, 2003
Post comments count0
Post likes count0

Low-tech usability testing

Raymond Chen
Raymond Chen

My pal Jason Moore discusses using paper prototypes as a fast way to get usability feedback. I found it interesting that by going low-tech, you actually get better feedback, because people are more willing to criticize a paper model than running code. (And another advantage of the paper model is that you can make changes on the...

History
Oct 7, 2003
Post comments count0
Post likes count1

Stupid memory-mapping tricks

Raymond Chen
Raymond Chen

Shared memory is not just for sharing memory with other processes. It also lets you share memory with yourself in sneaky ways. For example, this sample program (all error checking and cleanup deleted for expository purposes) shows how you can map the same shared memory into two locations simultaneousl...

Code
Oct 6, 2003
Post comments count0
Post likes count0

Researchers discover link between music and drinking

Raymond Chen
Raymond Chen

A British scientific study shows that a bit of classical music can persuade diners to buy more fancy coffees, pricey wines and luxurious desserts. "North has shown that playing German or French music can persuade diners to buy wine from those countries." I found this to be true in my experience. If you get two thousand people i...

Non-Computer