Граф коммитов

213 Коммитов

Автор SHA1 Сообщение Дата
kin%netscape.com f83e42cc70 Modifications to re-enable Editor API Logging which was broken after the last editor source reorg.
editor/base/Makefile.in
  editor/base/makefile.win
    - Modified makefiles build files that were
      renamed, and use new define to build the
      API Logging code.

  editor/base/nsEditor.cpp
  editor/base/nsEditor.h
  editor/base/nsHTMLEditor.cpp
    - Removed all ENABLE_JS_EDITOR_LOG ifdef'd code.
    - Removed all references to nsVector.h.

  editor/base/nsEditorFactory.cpp
    - Added ENABLE_EDITOR_API_LOG ifdef'd code
      that will create an instance of nsHTMLEditorLog
      instead of nsHTMLEditor.

  editor/base/nsEditorTxnLog.cpp
    - Initial checkin of file. File was originally named nsJSTxnLog.cpp.

  editor/base/nsEditorTxnLog.h
    - Initial checkin of file. File was originally named nsJSTxnLog.h.

  editor/base/nsHTMLEditorLog.cpp
    - Initial checkin of file. File was originally named nsJSEditorLog.cpp.
    - nsHTMLEditorLog.cpp now derives from nsHTMLEditor, and only
      overrides methods that modify the content tree and are publicly
      available via XPIDL.

  editor/base/nsHTMLEditorLog.h
    - Initial checkin of file. File was originally named nsJSEditorLog.h.
    - nsHTMLEditorLog.cpp now derives from nsHTMLEditor, and only
      overrides methods that modify the content tree and are publicly
      available via XPIDL.
1999-08-19 13:19:10 +00:00
jfrancis%netscape.com a099b1e5b6 some reorg of block transformation code; implemented make-{header,preformatted,address,normal}; tweaked make list to honor <br> in some circumstances; rewrote "return in list item" to pop you out of list if item is empty; rewrote "return in header" to work with non-trivial headers. 1999-08-18 08:13:06 +00:00
tague%netscape.com 11dad9b8c4 Fix bug #11687 - [Dogfood] Enable ender to save documents in encodings other than ISO-8859-1. Approved by chofmann@netscape.com, reviewed by buster@netscape.com. 1999-08-13 22:26:50 +00:00
akkana%netscape.com f673bdb804 11552: don't hardcode the character set for saving 1999-08-10 21:22:32 +00:00
jfrancis%netscape.com 70c5b10ce6 SplitNodeDeep() now emits an out param that tells you what the effective split offset was. This routine no longer splits text nodes unless it has to; ie, if the original offset was at the beginning or end of the text node, no split occurs in it. 1999-08-09 21:45:52 +00:00
sfraser%netscape.com d73dfd8ddb Landing editor API changes. Removed nsITextEditor and nsTextEditor, split interfaces into more, non-overlapping interfaces, and other general cleanup. 1999-08-09 01:37:50 +00:00
tague%netscape.com 58316bd322 Added support for replies from private DOM text events. See bug #4826 1999-08-06 02:32:13 +00:00
sfraser%netscape.com bbeffd28f0 Fix the document state listener mechanism so that you can install listeners after the editor has been created, and still get their 'document creation' notification called. 1999-08-03 06:53:45 +00:00
buster%netscape.com c05df307b2 added a missing break that was leading to an assert in NotifyDocumentListeners 1999-08-03 06:05:29 +00:00
warren%netscape.com 5f088dfe9e Fixing Simon's stuff. 1999-08-03 01:57:26 +00:00
sfraser%netscape.com dd24fdb884 Make the nsIDocumentStateListener interface more useful, with doc creation and destruction notifiers. 1999-08-03 00:58:38 +00:00
buster%netscape.com e0138bce18 enabled string bundles, now that NECKO has landed
selection and caret are not displayed at Init time any more.  This is done on Focus now.
1999-08-02 13:51:50 +00:00
cmanske%netscape.com 0fef13e963 Fixed lots of XUL (adjust for new titledbutton changes and XPMenus). Added initial table properties support and unit test for nsITableLayout methods. Removed unused InsertLink and InsertImage methods. Added lots of comments for interface methods. 1999-08-01 22:37:58 +00:00
akkana%netscape.com 2a0454f835 10525: Only handle plaintext paste in base and text editors 1999-07-30 23:46:18 +00:00
sfraser%netscape.com 6c31c915dd Implement support for nsIDocumentStateListeners. 1999-07-28 02:55:40 +00:00
buster%netscape.com cc49e3182a Clean-up
1) fixed unit tests
2) fixed a bunch of leaks having to do with using enumerators.  Thanks for noticing these, Simon.
3) fixed a tiny problem in nsTextEditRules::WillDoAction().
This method was overly aggressive in checking input args, sel can be null for some operations.
1999-07-25 18:14:44 +00:00
cmanske%netscape.com db6e5788b8 Fixed insert element bugs. Added message if no misspelled words. Changed 'More Atrributes' to 'Advanced Edit' in dialogs. Improved generic message dialog. Added remove link button to link dialog 1999-07-24 20:27:53 +00:00
cmanske%netscape.com 16ff2d941c Fixed bugs relating to insert element 1999-07-23 00:52:17 +00:00
sfraser%netscape.com 5f74f88c68 Turn on selection for all documents that are being edited. This enables selection in GFX ender widgets. 1999-07-23 00:11:00 +00:00
sfraser%netscape.com f4d8e41aad #ifdef out loading the string bundle, because it causes onEndDocumentLoad handlers to fire, which is very bad. 1999-07-22 23:52:08 +00:00
tague%netscape.com 27e1b6498d Fixed bug #10242 - crash when typing space after IME composition 1999-07-22 23:13:59 +00:00
tao%netscape.com 0d92312a0a Adopt new str res api prototype. 1999-07-22 04:41:11 +00:00
jfrancis%netscape.com 2ec53e1f90 assorted work to expose nav html dtd to the editor 1999-07-19 22:49:21 +00:00
akkana%netscape.com a0beec3a1a Fix paste html; remove some unneeded inclusions 1999-07-19 19:37:08 +00:00
mjudge%netscape.com c0b1525970 massive checkin for selection. adjusting nsIDOMSelection api and nsIFrameSelection. many "small" changes. this is not as bad as it looks. layout will not be affected other than "getter" calls for selection. and all consumers of selection should be in good shape. 1999-07-18 02:27:19 +00:00
buster%netscape.com dca6c49edd replaced IID's with CID's where they were appropriate, and removed lots of
NS_DEFINE_IID macros in favor of GetCID() wherever I could.
plus some minor bug fixes.
1999-07-15 19:13:46 +00:00
mjudge%netscape.com 21700e5d88 checkin for carpool for multiple seleciton/ime selection and api changes 1999-07-15 18:19:20 +00:00
sfraser%netscape.com ee9108dff0 Document modification count maintenance. 1999-07-14 22:29:39 +00:00
akkana%netscape.com a3fb11b98f Restructure the editor output routines to allow passing in
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.
1999-07-14 18:54:29 +00:00
cmanske%netscape.com f85acd993e Generic message dialog, fix insert element-related bugs, initial personal dictionary dialog, other editor bugs 1999-07-14 15:24:33 +00:00
rods%netscape.com 96b1b0347f Fixed up paste code to help support HTML paste 1999-07-09 19:43:59 +00:00
kin%netscape.com bc437183b9 Fix for bug #7495: [PP]Undo on Linux shows intermediate steps.
Modified Undo() and Redo() to call Begin/EndUpdateViewBatch().
1999-07-06 23:02:12 +00:00
cmanske%netscape.com 7e87a94450 Changes to editor XUL dialogs to accomodate new window-as-box changes 1999-07-02 22:52:34 +00:00
sfraser%netscape.com fecb23a8fd Added transactions for applying and removing style sheets 1999-07-02 03:57:50 +00:00
warren%netscape.com 3e3429dbf5 Fixed NewURL for necko. 1999-07-01 21:48:46 +00:00
buster%netscape.com 894d0f0085 minor bug fixes 1999-07-01 20:46:59 +00:00
kin%netscape.com 3b5b4d3b48 Added ApplyStyleSheet() method to the various editor interfaces. 1999-07-01 19:32:35 +00:00
buster%netscape.com 7bc9bfc2b0 0. possible fix for Sun build bustage.
1. IsEditable is much less hacky.  It basically says:
  1. if the node is a special bogus text node, it's not editable
  2. if the node is a text node with only newlines, then it's not editable
  3. if the node has no frame associated with it, then it is not editable
  4. otherwise, it is editable.
As part of this, I had to make IsEditable non-static.  This had some cascading effects on static methods that called
IsEditable, which likewise had to be made non-static.

2. SetTextProperties now works when the endpoints are leaf nodes (like images), not just text.  Charlie, you should
put this through some stress cases.
1999-07-01 18:42:28 +00:00
scc%netscape.com f79508bc68 |nsISupports::GetIID()| --> |nsCOMTypeInfo<nsISupports>::GetIID()| 1999-06-29 21:01:31 +00:00
tague%netscape.com 353d857fed Added clause and selection support for Input Methods. Fixes bug #8639, #8459, #6989, #7824 1999-06-29 20:31:22 +00:00
buster%netscape.com 96d97515ac implemented most of max length handling 1999-06-25 22:57:26 +00:00
mcafee%netscape.com 663392c33d Adding comment for BeOS. 1999-06-25 14:26:21 +00:00
jfrancis%netscape.com 7e6d227982 these are not the droids you are looking for 1999-06-25 10:36:54 +00:00
jfrancis%netscape.com 0db5edf4c8 improvement of editing rules for insert list, indent, outdent, and change alignment 1999-06-25 09:33:02 +00:00
cmanske%netscape.com ea7bde4716 Expanded nsIEditPropery to include all (I hope) HTML tags 1999-06-25 03:18:42 +00:00
buster%netscape.com 6eaba5847c added nsIEditProperty::img 1999-06-24 23:34:41 +00:00
cmanske%netscape.com aaa2213d4c Fixed GetBodyElement. Changed editor test doc to not use CSS for background. Initial code to edit element properties when double-clicking on element. 1999-06-24 20:59:45 +00:00
warren%netscape.com 1f76168d21 Renamed nsIURL to nsIURI in preperation for necko. More NECKO ifdefs too. 1999-06-23 03:29:44 +00:00
akkana%netscape.com 41d7f80962 Use deep first/last child for Beginning/EndOfDocument methods 1999-06-22 21:42:44 +00:00
jfrancis%netscape.com f66290066f turn off link following in the editor 1999-06-21 07:49:03 +00:00
valeski%netscape.com e23b3c673c NECKO ifdef (ifdef'd _off_ by default) this checkin should not impact anything. checkin approved. If someone runs into a problem, call me at 303.546.0061. 1999-06-18 17:34:08 +00:00
jfrancis%netscape.com 657c148e9e bug 8303; rvd kin; aprvd buster; aprvd chofmann 1999-06-16 21:38:04 +00:00
akkana%netscape.com 62144999f4 8283: Fix crash because selectin wasn't initialized. r=sfraser/a=leaf 1999-06-16 21:02:25 +00:00
jfrancis%netscape.com 41074bcccd editor rules framework for {make list, indent, outdent, change alignment} 1999-06-16 05:02:43 +00:00
kin%netscape.com e3bf912523 * Added StartLogging() and StopLogging() methods to nsIEditor,
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.
1999-06-14 20:02:46 +00:00
buster%netscape.com f9ffc2238d changed the way nsEditProperty is used. Right now, it's our placeholder
for HTML and CSS atoms, since we can't get these from layout yet.  The old
use assumed one editor, but as we know many editors can exist simultaneously.
Now, the editors share a singleton which is fetched from a factory method,
saving memory and allocation overhead.
1999-06-12 21:15:14 +00:00
sfraser%netscape.com 0f307500ed Add factory for EditorShell, and fix case of GetMonitor call. 1999-06-11 19:01:07 +00:00
akkana%netscape.com 87633c23c7 Implement InsertHTML.
Also, some minor fixes, like warning removal and addition of error checking
in files which needed it.
1999-06-10 21:31:42 +00:00
kin%netscape.com b5f80cce0c First pass checkin of the JavaScript editor logging mechanism. All changes are
ifdef'd with ENABLE_JS_EDITOR_LOG.
1999-06-10 19:41:40 +00:00
cmanske%netscape.com e351151970 Fixed fingers-to-quick checkin error 1999-06-09 02:28:47 +00:00
cmanske%netscape.com c56d124f5b Moved destination of editor string bundle file to editor's chrome directory 1999-06-09 02:26:48 +00:00
cmanske%netscape.com c624b316cb Added support for prefs and string bundles for editor, various bug fixes, preliminary Horizontal Line dialog work 1999-06-09 01:27:08 +00:00
buster%netscape.com 6a3429ddc2 * Added nsAutoSelectionReset, a tiny class that resets the selection to what it was before a block transformation.
* Added some code to restore selection after RemoveTextProperty.
* Made a tiny change to the way the editor holds onto the transaction manager, so client (like the ender text control) can
turn undo on and off effectively
* Fixed a bug in IsNodeInline that was causing GetBlockParent to return the wrong parent node (and who knows what
other mischief) where atom compares were being done on strings of different case, for <B>, "b" vs. "B".  The DOM
method nsIDOMElement::GetTagName forced the returned tag name to upper case.  I don't know how long that has
been true, but I assume it's a fairly recent change (or something on our side related to it changed recently) or this method
never would have worked.  I also found a few cases of nsString::Equals that I changed to EqualsIgnoreCase
* Made some general improvements to the interaction between editors and rules, so that the aCancel out param is always
intialized, and all rules with Will... are matched with a Did... call.  Added Will/DidSetTextProperty() and
Will/DidRemoveTextProperty().  This helps enable plain text mode.  Added a skeleton for max length support in text editor.
* fixed some warnings.
1999-06-08 06:04:51 +00:00
briano%netscape.com 8699ea0019 Handle the (Unix) platform-specific DLL naming conventions properly. 1999-06-04 22:17:30 +00:00
jfrancis%netscape.com 965cc90b46 fixing a comment 1999-06-03 05:58:38 +00:00
kin%netscape.com ae5b3d673c Fixed double addref in EnableUndo() that was causing us to leak the transaction manager on destruction of the editor. 1999-05-28 21:49:24 +00:00
jfrancis%netscape.com 38b9a7c369 cleanup util function duplication 1999-05-28 21:17:30 +00:00
sfraser%netscape.com f538ed4757 Removed obsolete IID definitions, use GetIID() instead. 1999-05-28 00:20:41 +00:00
sfraser%netscape.com 2239a8a64e Add unit test call to nsIEditor, and implement it in nsText- and nsHTMLEditors. 1999-05-27 04:10:04 +00:00
akkana%netscape.com d2c4947c26 Insert / Paste as Quotation. 1999-05-27 00:08:15 +00:00
cmanske%netscape.com a152976669 Continued UI work: Spell checker fixes, toolbar improvements, popup menus implemented for paragraph style, font face and color, setting font color test UI, etc. 1999-05-26 21:40:51 +00:00
kin%netscape.com 819e65af00 Disabled HACKForceRedraw() calls. Added calls to nsIViewManager::BeginUpdateViewBatch() and nsIViewManager::EndUpdateViewBatch(). 1999-05-26 21:18:12 +00:00
akkana%netscape.com c25fa13fd9 6773: an nsresult was being checked before it was initialized. Appv'd chofmann 1999-05-20 01:48:12 +00:00
kin%netscape.com 26a02881cd Fix for bug #4796: UMR: nsEditor::JoinNodesImpl(). 1999-05-17 18:59:40 +00:00
kin%netscape.com c8136e6dbe Commented out all calls to HACKForceRedraw(). We now call it from
nsEditor::EndTransaction().
1999-05-17 13:31:56 +00:00
jfrancis%netscape.com aaecdca8fb insert list and indent work 1999-05-17 12:22:31 +00:00
mjudge%netscape.com b4419648ae adding in selection ability for images in editor only 1999-05-17 00:21:50 +00:00
akkana%netscape.com b12ce1b2cf 5786: Cut shouldn't do anything when selection is collapsed 1999-05-14 19:24:10 +00:00
rods%netscape.com e4ee930f8c removed reference to nsIDataFlavor and merged nsITransferable and nsIGenericTransferable 1999-05-13 21:53:57 +00:00
sfraser%netscape.com 389fa2053b Fix misplaced ) 1999-05-13 04:42:11 +00:00
tague%netscape.com dce36849c6 Added work around for #5912 1999-05-12 23:23:14 +00:00
sfraser%netscape.com 9897e27ec2 Added file opening functionality 1999-05-12 22:24:47 +00:00
akkana%netscape.com b0b172cff8 Add test for IsDataFlavorSupported for xpfe folks to fix bug 6289 1999-05-11 23:34:40 +00:00
rods%netscape.com 52fabe8f5c Removed static IID defs and am now using GetIID from the interface 1999-05-07 19:39:58 +00:00
dp%netscape.com b5707f7a96 Converting stray UnregisterFactory calls to UnregisterComponent 1999-05-06 01:37:04 +00:00
akkana%netscape.com 1f3151a20d - Rename iDirection enum to ECollapsedSelectionAction
- Initial implementation of Insert HTML
1999-05-05 23:27:17 +00:00
waterson%netscape.com dc4863fc21 Fix nsCOMPtr bustage. 1999-05-05 05:56:58 +00:00
buster%netscape.com cadc514e1d added a param to GetPriorNode and GetNextNode to tell these methods whether to use or skip
non-editable content.
added some comments, turned off some debugging flags.
1999-05-05 04:51:54 +00:00
buster%netscape.com 99a96a39ec 1. block transformation infrastructure is now in place. We can go ahead and implement interesting
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.
1999-05-05 04:05:19 +00:00
tague%netscape.com 83e78f89e5 Fixed bug #5527 (Editor is not able to accumulate successive Japanese input) 1999-05-03 22:57:48 +00:00
sfraser%netscape.com 3b2d7aef50 Memory leak fixes for bug 5870. r mjudge, a chofmann. 1999-05-03 22:26:07 +00:00
mjudge%netscape.com f9a664a948 ok done Simon reviewed 5870. choffman approved for M5 1999-05-03 21:52:19 +00:00
kostello%netscape.com 860a8b9cfa Changed:
nsI*Editor::OutputText(nsString& aOutputString);
nsI*Editor::OutputHTML(nsString& aOutputString);

These methods always returns back a Unicode version of whatever is in the content model. It is the
responsibility of the caller then to call whatever converter is required to convert to the appropriate
charset.

Added:

nsI*Editor::OutputText(nsIOutputStream* aOutputStream, nsString* aCharsetOverride = nsnull)
nsI*Editor::OutputHTML(nsIOutputStream* aOutputStream, nsString* aCharsetOverride = nsnull)

These methods output the the current content model to aOutputStream. The document is encoded using the
document defined charset or if the user passes in a non-null value for aCharsetOverride then this
encoding overrides the encoding used by the document.
1999-05-03 18:48:39 +00:00
mjudge%netscape.com b77df20b6e FIXING M5 BUGS: making weak links to stop extra addreff to presshell. fixing xul to set editor doc type to "content" 1999-04-29 20:21:04 +00:00
kin%netscape.com 6aa1c4b270 Modified nsIEditActionListener to have Will*() and Do*() methods. Added
nsIEditActionListener support to nsEditor.cpp and nsEditor.h.
1999-04-27 17:14:28 +00:00
rods%netscape.com 4f4cf854ea Switch Paste support over to nsCOMPtr 1999-04-23 14:41:32 +00:00
mcafee%netscape.com 8c94674b00 Removing NEW_CLIPBOARD_SUPPORT ifdef. 1999-04-22 05:41:51 +00:00
cmanske%netscape.com 6228e33112 Added simple dialogs for insert link and restructured ui source directories 1999-04-21 18:53:55 +00:00
rods%netscape.com 333dab2402 Added additional comments for Paste 1999-04-19 19:35:55 +00:00
rods%netscape.com c514b25e3b Switched over to new nsIGenericTransferable 1999-04-17 13:51:42 +00:00