Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Why does Ctrl + F4 not close a document that has been opened in Notepad++? Is there a way to enable it?

I have started using Notepad++ today and I expected Ctrl + F4 to close the current document as in most other applications on the Microsoft Windows platform (both non-Microsoft and Microsoft applications) with MDI (multiple document interface) or TDI (Tabbed document interface) interfaces: UltraEdit, Opera, Eudora, Firefox, OpenOffice, Visual Studio, etc.

Is there a reason for this?

Platform: Notepad++ v5.4.5, Windows XP 64 bit SP2, 8 GB RAM.

(Note: it is not enabled by default, but actually it can be enabled by changing the keyboard shortcut from Ctrl + W to Ctrl + F4: menu Settings -> Shortcut Mapper -> line 8, Close -> <right click> on Ctrl+W -> Modify -> Ctrl, F4 -> OK -> Close.

share|improve this question
up vote 26 down vote accepted

I don't actually know why it is set to be Ctrl + W but to answer your other question: To change the default tab closing behaviour, go to Settings > Shortcut Mapper. Change the Close shortcut [8] to Ctrl + F4

share|improve this answer
In Notepad++ 5.1 and 5.3 the Shortcut Mapper is directly under the Settings menu. – M. Dudley Aug 1 '09 at 22:44
Fixed. Thanks! – Ciaran Aug 1 '09 at 22:47
Ctrl + W is widely used within FLOSS applications. Gnome f.e. uses that shortcut to close windows, and I bet so does KDE...oh, and Firefox btw too. – Bobby Aug 3 '10 at 6:51
@Bobby: It isn't just FLOSS apps. Ctrl+W is a standard CUA shortcut for Close, introduced by MacOS and adopted by Windows in the 1980s. – paradroid Sep 17 '11 at 11:21
Ctrl+W works with almost all tabbed or multi-document applications like Excel, Word, Eclipse... – Lưu Vĩnh Phúc Feb 23 at 6:42

By default, Ctrl + W will close the current window. Notepad++ is not a Microsoft product, so it shouldn't be too surprising that it doesn't follow Windows 'conventions". If you go to Settings -> Shortcut Mapper you can change the Close function to map to whatever key combination you would like.

share|improve this answer
I guess its just something we got used to and love - It just makes sense to me to have Ctrl + F4 be the command to close. Most mainstream non-microsoft apps do it. Take Chrome and Firefox for example. There's nothing forcing the app to do this except common sense – Ciaran Aug 1 '09 at 21:56
@Ciaran: Actually I'm used to ctrl-w, I mean, seriously, what microsoft app has tabs?! IE only got them after firefox, and in firefox it was ctrl-w, so I got used to that. – hasen Aug 1 '09 at 22:12
@hasen: It's not about tabs. Every windows MDI application should implement ctrl-f4 to close a document en alt-f4 to close the application. – fretje Aug 1 '09 at 23:22
Both Microsoft and Apple have had user interface guidelines for more than 20 years. For instance expressed in the books "The Windows Interface. An Application Design Guide" (1987, ISBN 1-55615-439-9) and "Human Interface Guidelines: The Apple Desktop Interface" (1987, ISBN 0-201-17753-6). From the former, page 16, table 2.6, "Recommended PC Function Key Assignments", Ctrl+F4: "Close document window". – Peter Mortensen Aug 2 '09 at 0:40
It's about time MS changed thier guidelines then. Ctrl+F4 is an easy way to get wrist-ache. – DisgruntledGoat Aug 24 '09 at 15:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .