December 13th, 2010

Why are the Compression and Encryption options check boxes instead of radio buttons?

Tanveer Badar asks why the file properties Advanced dialog shows two checkboxes (compression and encryption) even though NTFS supports only one or the other at a time. “Why not have two radio buttons instead of these silly check boxes?” Actually, if you want radio buttons, you’d need three, one to cover the “neither” case. Let’s look at what those radio buttons would look like:

Compress contents to save disk space
Encrypt contents to secure data
Neither compress nor encrypt

This takes an implementation detail (that NTFS currently does not support simultaneous compression and encryption) and elevates it to the user interface, so that it can provide maximum confusion to the user. “What a strange way of exposing compression and encryption. If I want to turn on encryption, I should just check a box that says ‘Encryption’.” The current implementation (two check boxes) matches user expectations, but then says “Sorry, we can’t do that” if the user picks a combination that is not currently supported. But who knows, maybe someday, NTFS will support simultaneously encryption and compression, and all that will happen is that the error message goes away. You don’t have to redesign the property sheet (and invalidate all the training materials that had been produced in the meantime).

Either way, it’s a leaky abstraction that sucks, but at least the suckiness isn’t shoved in the user’s face.

Topics
Other

Author

Raymond has been involved in the evolution of Windows for more than 30 years. In 2003, he began a Web site known as The Old New Thing which has grown in popularity far beyond his wildest imagination, a development which still gives him the heebie-jeebies. The Web site spawned a book, coincidentally also titled The Old New Thing (Addison Wesley 2007). He occasionally appears on the Windows Dev Docs Twitter account to tell stories which convey no useful information.

0 comments

Discussion are closed.