a mime type and a flag argument. Also fix the following bugs:
9746: get rid of bogus empty <style> in head.
8143: save wrap column in editor shell in case it's set before the
editor is created.
9470, 9488: allow explicit specification of formatted output.
nsIHTMLEditor, nsITextEditor, and nsIEditorShell and enabled
the "Start Log" and "End Log" menu items in the editor test bed.
* Modified makefiles for Unix and Win32 to turn on Editor API Logging.
* Added action argument to the DeleteSelection() method in nsIEditorShell.
* Modified nsJSTxnLog to use nsJSEditorLog when writing it's output.
* added focus listener. Doesn't do much yet, but when focus notifications start appearing, we'll be ready for them. The code is in
place to hide selection when we lose focus and paint selection when we get focus. That's probably not quite right, but it's a start.
We will need to be able to determine the distinction between losing focus to another control within our app, and losing focus to
another app.
* added support for disabled and readonly states in the editor. This is accomplished by having flags set by the client, and letting the
rules system deal with those flags. The flags I added are:
TEXT_EDITOR_FLAG_PLAINTEXT 0x01 // only plain text editing is allowed
TEXT_EDITOR_FLAG_SINGLELINE 0x02 // enter key and CR-LF handled specially
TEXT_EDITOR_FLAG_PASSWORD 0x04 // text is not entered into content, only a representative character
TEXT_EDITOR_FLAG_READONLY 0x08 // editing events are disabled. Editor may still accept focus.
TEXT_EDITOR_FLAG_DISALBED 0x10 // all events are disabled (like scrolling). Editor will not accept focus.
* added WillInsertBreak/DidInsertBreak into text rules, so flags could be checked. This gets us readonly, disabled, and single line
behavior.
* cleaned up the code that allocates, registers, and destroys event listeners. Thanks to Kin and Simon for cleaning up the
ownership model on the listeners, it was a big help.
* added support for a max text length. You can now tell the text editor, be no bigger than n characters.
features like set paragraph style, set list type, indent, etc. I'm sure there's holes in my
implementation that these high level features will make obvious.
2. I've factored a lot of utility methods from several modules into nsEditor as public static methods.
This makes them easily accessable to all, and will help Joe and I remove redundant methods.
3. I changed the HTML tags to lower case, and made all string compares case-insensitive. No, this
isn't quite the right thing to do, but we don't have atoms from layout yet. The Right Thing is for us
to reuse those atoms.
1. fix for bug 5796, crash on exit. This was a bad, bad memory smudge on my part, easily fixed by doing the right ref counting in the
right places.
2. some preliminary code for M6 block transformations has leaked into this checkin. It's safer than trying to re-code the fix above into
a fresh tree. Unless you're making calls to do block transformations, you won't see any difference.
* added TextEditorTest.cpp, a unit test module for nsTextEditor. It's use is actually commented out since my checkin is happening so late due
to all-day build bustage, and I don't have a Mac handy to verify. With someone's Mac help tomorrow, I can turn it on.
* some minor bug fixes to property handling