Notepad is a simple text editor for Microsoft Windows.
It has been included in a
ll versions of Microsoft Windows since Windows 1.0 in 1985. Contents [hide] 1 Features 2 Unicode detections 3 Competing software 4 See also 5 References 6 External links Features[edit] Notepad is a common text-only (plain text) editor. The resulting filestypically s aved with the .txt extensionhave no format tags or styles, making the program sui table for editing system files that are to be used in a DOS environment and occa sionally, source code for later compilation or execution, usually through a comm and prompt. Notepad supports both left-to-right and right-to-left based languages. Unlike WordPad, Notepad does not treat newlines in Unix- or Mac-style text files correctly. Notepad offers only the most basic text manipulation functions, such as finding text. Only newer versions of Windows include an updated version of Notepad with a search and replace function. However it has much less functionality in compari son to full-scale editors. Microsoft's first version of Notepad predates Windows it was included in a set o f utilities bundled with the Microsoft Mouse as early as 1983.[1] Like subsequen t versions, this was a plain text editor which utilizes the mouse for menu navig ation and text manipulation; however, unlike its Windows successors, it was a DO S program limited to full-screen operation. In all versions of Windows, Notepad makes use of a built-in window class named " EDIT". In older versions such as those included with Windows 95, Windows 98, Win dows Me and Windows 3.1, there is a 64k limit on the size of the file being edit ed, an operating system limit of the EDIT class. Up to Windows 95, Fixedsys was the only available display font for Notepad. Wind ows NT 4.0 and 98 introduced the ability to change this font. As of Windows 2000 , the default font was changed to Lucida Console. The font setting, however, onl y affects how the text is shown to the user and how it is printed, not how the f ile is saved to disk. The default font was changed to Consolas on Windows 8. Up to Windows Me, there were almost no keyboard shortcuts and no line-counting f eature. Starting with Windows 2000, shortcuts for common tasks like new, open an d save were added, as well as a status-bar with a line counter (available only w hen word-wrap is disabled). In the Windows NT-based versions of Windows, Notepad can edit traditional 8-bit text files as well as Unicode text files (both UTF-8 and UTF-16, and in case of UTF-16, both little-endian and big-endian). Notepad also has a simple built-in logging function. Each time a file that start s with .LOG is opened, the program inserts a text timestamp on the last line of the file.[2][3] Notepad accepts text from the Windows clipboard. When clipboard data with multip le formats is pasted into Notepad, the program will only accept text in the CF_T EXT format.[4] This is useful for stripping embedded font type and style codes f rom formatted text, such as when copying text from a web page and pasting into a n email message or other WYSIWYG text editor. Formatted text can be temporarily pasted into Notepad, and then immediately copied again in stripped format to be pasted into the other program. Files can be printed, but they will not print correctly if "Word Wrap" is turned on. Headers, footers, and margins can be set and adjusted when preparing to pri nt a file under "Page Setup". The date, file name, and other information can be placed in the headers and footers with various codes consisting of an ampersand ('&') followed by a letter. Unicode detections[edit] Main article: Bush hid the facts The Windows NT version of Notepad, installed by default on Windows 2000 and Wind ows XP, has the ability to detect Unicode files even when they are missing a byt e order mark. To do this, it utilizes a Windows API function called IsTextUnicod e().[5][6] However, this function is imperfect, incorrectly identifying some all -lowercase ASCII text as UTF-16. As a result, Notepad interprets a file containi ng a phrase like "aaaa aaa aaa aaaaa" ("4-3-3-5") as two-byte-encoded Unicode te xt file and attempts to display it as such. If a font with support for Chinese i s installed, nine Chinese characters (?????????) are displayed; otherwise, it wi ll display squares instead of Chinese characters. Some people misinterpreted this issue for an easter egg. Many phrases which fit the pattern (including "this app can break" and "bush hid the facts") appeared o n the web as hoaxes. Windows expert Raymond Chen correctly attributed it to the Unicode detection algorithm.[7] This issue has been resolved in the Windows Vista and Windows 7 versions of Note pad.