26th November 2006 | RICH TEXT CONTROLS |
Brian Grainger
|
As time moves on and I get to know more and more about Windows there is less and less to discover and write about. This week, having finally got exasperated with a long standing problem, I did some investigation and uncovered a new topic, that of Rich Text Controls, and the purpose behind one of those mysterious files in the Windows System folder. It all started with WordPad. I use WordPad for general purpose editing needs. It is quicker to load than Microsoft Word, yet supports Rich Text Formatted files, (.RTF). This allows quite sophisticated files to be created, especially when compared to Notepad. If you load an RTF file created with another application, such as Microsoft Word or Microsoft Outlook, you will see that WordPad will display files with embedded tables, indented paragraphs, bullet styles as well as variable line spacing and paragraph spacing. It is the latter that has been the long standing problem. Those of you who have written HTML pages will know that if you use the <p> and </p> to delineate paragraphs then there is a single line space between each paragraph. Copy such text to WordPad and the spaced paragraphs are preserved. However, if you try to type a new file there seems to be no way to create such paragraph spacing. If you look on the WordPad paragraph formatting options then all that is available is indentation and alignment, not paragraph spacing. Having looked on the web to try and solve the paragraph spacing problem in WordPad I discovered a related problem - that of double spacing lines. Sadly, it seems the paragraph spacing problem cannot be solved, but pressing CRTL-2 will create double spaced lines. I have to admit that this tip was not widely known on the web. I got intrigued and wondered whether there were other keyboard functions that would work. Rather than start pressing random key combinations to see what they did, I got out my list of Microsoft Word keyboard shortcuts. There are a lot of them but I went through each one to see which worked in WordPad. The results were intriguing and also a bit haphazard in what is and is not implemented. The following gives a resume of my findings. I have excluded those, such as File and Edit commands, that are mentioned in the WordPad menus.
I think you will agree that the list above is a fairly motley collection of functions - none more so than the last two. The only bullet style that can be selected from the WordPad menus or toolbar is similar to that used in the list above. However, using CTRL-SHIFT-L you can select numeric, lower case alpha, upper case alpha, roman and upper case roman styles. What is more, Word does not do this. Pressing CTRL-SHIFT-L will just select the basic bullet type. While I knew of much of the functionality above the new bits I found out, in particular CTRL-SHIFT-L, intrigued me. I googled for CTRL-SHIFT-L and found out all about Rich Text Controls. Rich Text Controls are implemented by a DLL file in the Windows System folder. The filename varies depending on the version used.
The Version 3 must have been included with something else, probably an Internet Explorer upgrade, because it appears on my Windows 98 machine. The functionality of Rich Text Controls has increased from version to version - but why it includes some things and not others seems to suggest it has been developed as an 'I forgot it' application! For example, why are the indenting commands of Microsoft Word not included, (CTRL-M, CTRL-T and the equivalent SHIFT commands). Similarly, why the inclusion of CTRL-1, CTRL-5 and CTRL-2 but not CTRL-0. The latter is the paragraph spacing command I needed to solve my original problem! Perhaps these will come in Version 5. Anybody who is interested in Rich Text Controls in detail, including how to call them in your own applications, can refer to the following page on the Microsoft Developers Network: http://msdn2.microsoft.com/en-us/library/ms651760(d=printer).aspx You can also refer to that page for further keyboard shortcuts - such as the tilde accent, (which is not accepted in WordPad but works in Microsoft Word), and how to incorporate Unicode characters. |
|
|
|
|
|
|
|
|