133 Commits

Author SHA1 Message Date
jfrancis%netscape.com
2a60fccebc making nsPresShell and nsDocument support weak references; using weak references to docs and pres shells within the editor
git-svn-id: svn://10.0.0.236/trunk@44483 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-25 10:51:55 +00:00
pinkerton%netscape.com
2d43935d4d toString -> ToString idl change.
git-svn-id: svn://10.0.0.236/trunk@44477 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-25 09:15:18 +00:00
pinkerton%netscape.com
6eb3a21da9 IDL-ifying nsITransferable, nsIDragService, nsIDragSession, nsIFormatConverter.
git-svn-id: svn://10.0.0.236/trunk@44476 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-25 08:35:06 +00:00
akkana%netscape.com
131d318ad4 Revise the doc encoder and content sink APIs yet again to make it easier
to add new flags (pass a flag in the constructor, rather than specific
booleans.  This in order to fix:
11249: Add flag to write only the body in html output.


git-svn-id: svn://10.0.0.236/trunk@44308 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-24 18:30:19 +00:00
buster%netscape.com
d2cf706ddc added a special case to the output text rules for an empty document
(one that contains the bogus node)


git-svn-id: svn://10.0.0.236/trunk@44286 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-24 13:48:08 +00:00
jfrancis%netscape.com
99de773e68 refactoring text insertion code; indent/outdent now work with lists and list items.
git-svn-id: svn://10.0.0.236/trunk@44276 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-24 08:56:51 +00:00
buster%netscape.com
d25319c9c2 Split out installing the editor's own event handler as a separate step.
The owner of the editor can now initialize the editor,
set up its own listeners if it wants to, then the editor will set up it's own
backstop listeners as part of PostCreate().
The backstop key listener now ignores ENTER for single line text controls.
Ugly to have to do it here, it would be better if the owner could just swallow the key event.


git-svn-id: svn://10.0.0.236/trunk@44121 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-23 06:42:04 +00:00
akkana%netscape.com
1a9e06b69b Handle plaintext wrapping in style, rather than a pre tag in the body. Also fix a couple of warnings.
git-svn-id: svn://10.0.0.236/trunk@43844 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-20 22:39:48 +00:00
brade%netscape.com
f10a2dbac1 keyhandling for keybindings moved to keypress (was keydown)
git-svn-id: svn://10.0.0.236/trunk@43813 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-20 13:14:03 +00:00
pinkerton%netscape.com
d7fdcb2e00 add DragGesture to drag listener.
git-svn-id: svn://10.0.0.236/trunk@43635 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-19 19:48:33 +00:00
buster%netscape.com
d1193affa0 Fixed a ton of errors where we were not handling error results correctly.
Added some comments of the form "// XXX: ERROR_HANDLING <explanation>"
wherever I saw a potential error but wasn't 100% sure of the intention of the code.
Fixed a few bugs along the way.


git-svn-id: svn://10.0.0.236/trunk@43590 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-19 13:30:48 +00:00
jfrancis%netscape.com
41485faa2c 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.
git-svn-id: svn://10.0.0.236/trunk@43484 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-18 08:13:06 +00:00
jfrancis%netscape.com
9b541be769 fixing bug 9366
git-svn-id: svn://10.0.0.236/trunk@42836 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-09 22:51:40 +00:00
buster%netscape.com
645dd7a8ea moved handling of flags from rules constructor to rules init, so
rules code can call SetFlags with mEditor initialized and do real
processing if it wants to.


git-svn-id: svn://10.0.0.236/trunk@42775 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-09 18:39:49 +00:00
sfraser%netscape.com
eabb55e416 Fix the nsTextEditRules init so that setting the flags works.
git-svn-id: svn://10.0.0.236/trunk@42769 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-09 18:22:13 +00:00
buster%netscape.com
54308be938 backed out my last change, it didn't fix the problem I thought it would.
git-svn-id: svn://10.0.0.236/trunk@42765 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-09 18:01:08 +00:00
buster%netscape.com
736e084433 call SetFlags from Init, so plaintext logic gets executed.
git-svn-id: svn://10.0.0.236/trunk@42762 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-09 17:44:14 +00:00
sfraser%netscape.com
4dd92661ce Landing editor API changes. Removed nsITextEditor and nsTextEditor, split interfaces into more, non-overlapping interfaces, and other general cleanup.
git-svn-id: svn://10.0.0.236/trunk@42725 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-09 01:37:50 +00:00
buster%netscape.com
a2574a2239 fixed handling of text controls with a max length set
git-svn-id: svn://10.0.0.236/trunk@42641 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-07 05:29:41 +00:00
buster%netscape.com
b2f791ecad fixed disabled and readonly handling
added redraw hack to blur (in addition to focus, already done)


git-svn-id: svn://10.0.0.236/trunk@42640 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-07 05:28:57 +00:00
tague%netscape.com
5f2b704a17 Added support for replies from private DOM text events. See bug #4826
git-svn-id: svn://10.0.0.236/trunk@42391 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-06 02:32:13 +00:00
buster%netscape.com
41a9e50cfc added the same hack for blur as for focus, to force a repaint
handle TAB in keyDown, not keyPress, so we can surpress focus manager
using TAB to swap focus from the editor.


git-svn-id: svn://10.0.0.236/trunk@41949 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-03 06:07:29 +00:00
buster%netscape.com
b96149959a selection and caret are not displayed at Init time any more. This is done on Focus now.
checking in temp hack to repaint on focus


git-svn-id: svn://10.0.0.236/trunk@41819 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-02 13:53:23 +00:00
buster%netscape.com
af08daa88b 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.


git-svn-id: svn://10.0.0.236/trunk@41056 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-25 18:14:44 +00:00
jfrancis%netscape.com
121b1074a2 making plaintext flag force a "white-space: pre" style on the body. this is a fix for bug 9153
git-svn-id: svn://10.0.0.236/trunk@41044 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-25 05:34:02 +00:00
joki%netscape.com
065c158182 Updating DOM event apis and changing behavior to properly respect capturing, bubbling, and cancellation methods.
git-svn-id: svn://10.0.0.236/trunk@40134 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-19 19:54:34 +00:00
mjudge%netscape.com
329d39ba11 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.
git-svn-id: svn://10.0.0.236/trunk@39971 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-18 02:27:19 +00:00
buster%netscape.com
6382cd2eea 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.


git-svn-id: svn://10.0.0.236/trunk@39546 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-15 19:13:46 +00:00
mjudge%netscape.com
757f22388f checkin for carpool for multiple seleciton/ime selection and api changes
git-svn-id: svn://10.0.0.236/trunk@39542 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-15 18:19:20 +00:00
sfraser%netscape.com
4dc3ba7bb6 Don't handle a key event as a keypress if the meta key is down.
git-svn-id: svn://10.0.0.236/trunk@39418 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-14 22:29:06 +00:00
akkana%netscape.com
a878369d02 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.


git-svn-id: svn://10.0.0.236/trunk@39332 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-14 18:54:29 +00:00
buster%netscape.com
81c8ed2576 workaround for blocker bug 8123. approved by chofmann.
git-svn-id: svn://10.0.0.236/trunk@38807 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-08 19:52:44 +00:00
buster%netscape.com
7200addfac minor fix for returning when a key is handled or not. This is a tiny part
of the fix for 8123, joki is working on the rest with tague and rods.


git-svn-id: svn://10.0.0.236/trunk@38470 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-06 23:31:08 +00:00
jfrancis%netscape.com
117edd04eb turning off ill fated coercion of selection for plaintext editing. I'll turn this back on when I know how to correctly detect when it's needed.
git-svn-id: svn://10.0.0.236/trunk@38247 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-03 05:13:30 +00:00
jfrancis%netscape.com
30aa13a1d0 making the plain text selection pinning savvy to the other flavors of text editors, the ones that DONT have <pre> tags wrapping all the text
git-svn-id: svn://10.0.0.236/trunk@38021 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-02 07:53:08 +00:00
akkana%netscape.com
49826cb224 Oops, making wrapcolumn unsigned was a mistake. (Thanks to slamm's
warnings page for showing me that!)  Change it back to signed.


git-svn-id: svn://10.0.0.236/trunk@37746 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-01 19:01:04 +00:00
buster%netscape.com
0513dccdf4 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.


git-svn-id: svn://10.0.0.236/trunk@37741 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-01 18:42:28 +00:00
jfrancis%netscape.com
aaaa87a18c some cleanup and also selection enforcement for plaintext documents: selection is pinned to within the PRE tag on any edit action
git-svn-id: svn://10.0.0.236/trunk@37698 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-01 13:42:03 +00:00
akkana%netscape.com
2fb45d996c - New dialog and editor shell API for Insert HTML Source
- Add wrapcolumn setting to document encoders, and use it in the editor
- Fix numbered lists in the html to text sink stream.


git-svn-id: svn://10.0.0.236/trunk@37529 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-30 19:26:08 +00:00
scc%netscape.com
a2d0be4d64 |nsISupports::GetIID()| --> |nsCOMTypeInfo<nsISupports>::GetIID()|
git-svn-id: svn://10.0.0.236/trunk@37444 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-29 21:01:31 +00:00
tague%netscape.com
ea708a16a8 Added clause and selection support for Input Methods. Fixes bug #8639, #8459, #6989, #7824
git-svn-id: svn://10.0.0.236/trunk@37435 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-29 20:31:22 +00:00
sfraser%netscape.com
20ffc454a0 Call the Output routines with a new param for selection only.
git-svn-id: svn://10.0.0.236/trunk@37426 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-29 20:14:58 +00:00
buster%netscape.com
a0e007d087 Moved GetTextSelectionOffsets and GetDocumentLength from nsTextEditRules to
nsTextEditor.  Added GetDocumentLength to nsITextEditor public interface.


git-svn-id: svn://10.0.0.236/trunk@37177 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-28 13:36:38 +00:00
buster%netscape.com
7391f40410 implemented most of max length handling
git-svn-id: svn://10.0.0.236/trunk@36964 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-25 22:57:26 +00:00
buster%netscape.com
e1f56f54b7 added rules for password behavior
git-svn-id: svn://10.0.0.236/trunk@36767 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-24 23:36:56 +00:00
cmanske%netscape.com
078a1a95b5 Fixed GetBodyElement. Changed editor test doc to not use CSS for background. Initial code to edit element properties when double-clicking on element.
git-svn-id: svn://10.0.0.236/trunk@36724 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-24 20:59:45 +00:00
jfrancis%netscape.com
ca6c1a3d36 editor rules framework for {make list, indent, outdent, change alignment}
git-svn-id: svn://10.0.0.236/trunk@35666 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-16 05:02:43 +00:00
mcafee%netscape.com
e481f068c2 Removing NEW_DRAG_AND_DROP ifdef, this is on by default now.
git-svn-id: svn://10.0.0.236/trunk@35660 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-16 04:52:05 +00:00
mcafee%netscape.com
c09a0a2dd8 Minor reformatting.
git-svn-id: svn://10.0.0.236/trunk@35344 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-15 04:07:36 +00:00
tague%netscape.com
7d9a2e947d backed out last change.
git-svn-id: svn://10.0.0.236/trunk@35308 18797224-902f-48f8-a5cc-f745e15eee43
1999-06-15 01:24:23 +00:00