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

25 Коммитов

Автор SHA1 Сообщение Дата
buster%netscape.com 3c2f906370 factored out re-parenting of content into MoveContentIntoNewParent
WIP on font handling.
1999-04-16 18:29:12 +00:00
buster%netscape.com 033ffdd7ed * beginnings of font handling. WIP, I did a big merge today and I'm checking in to synch up, not to announce new functionality here.
* 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
1999-04-15 06:06:33 +00:00
mcafee%netscape.com c98d0e698a Removing clipboard define comment. 1999-04-07 06:54:15 +00:00
rods%netscape.com ac37096cb3 Commented out the NEW_CLIPBOARD_SUPPORT 1999-04-07 01:35:49 +00:00
rods%netscape.com 1d0886bcf6 Turning on new Clipboard support 1999-04-06 23:01:55 +00:00
rods%netscape.com 946396a03f Upgraded to implement new methods in D&D interface 1999-04-06 20:24:09 +00:00
buster%netscape.com 16027c9454 implemented simple cases of RemoveTextProperty. other cases are no-op'd now.
added aFirst out param to GetTextProperty, so the caller can know if the first character has the property in the case of aAny=true and aAll=false.
fixed a bunch of places where result was being used incorrectly as a return val from do_QueryInterface
some minor undo/redo fixes to split and join of interior nodes.
1999-04-04 18:01:35 +00:00
buster%netscape.com 52bb18a74f As a reminder, we decided to do this based strictly content. Some support for style-based text properties is written, but not used
anywhere any more.

* Cleaned up split and join undo/redo.
* Added TypeInState, a data struct that remembers things about text properties for collapsed selections, so you can type
* Ctrl-B with an insertion point and the next character will be bold.
* Added all the logic to handle inline vs. block elements when setting text properties.
* Added some support for italic and underline as well.  Adding these things is pretty easy now.  Ctrl-B, Ctrl-I, Ctrl-U for testing bold, italic, underline.
* Added all the logic to make sure we only add style tags where they're needed, so you should never get the same style tag nested within itself, except as needed for block elements.
* Added methods for testing a node to see if a particular style is set.  This isn't 100% done yet, but with very little work we could have toolbar buttons that respond to selection changed notification that show the state of bold, italic, underline, etc. in real time.  Supports tri-state:  whole selection is bold, some of selection is bold, none of selection is bold, ...
* Fully undoable and redoable.
* Added some debug printfs to transactions and editors.  all controlled by a gNoisy static in each module.  helps me track down undo/redo problems.  if the output bugs people enough, I'll shut it off and re-enable it in my local tree.

Noticably missing:  make un-bold, make un-italic, etc.  This is coming soon.
1999-04-01 17:58:07 +00:00
akkana%netscape.com cf7607381c Editor: Add Insert Link and Image 1999-03-29 22:01:26 +00:00
jfrancis%netscape.com 22ec10b544 don't drop tab keys 1999-03-29 08:02:50 +00:00
joki%netscape.com e39e13cf18 Changing api uses in editor, rdf, and xpfe to match DOM2 api name/param changes. 1999-03-28 22:27:38 +00:00
akkana%netscape.com 5850dbaca8 Add hard-coded alt-I for testing insert html 1999-03-22 22:10:29 +00:00
tague%netscape.com 6e19645586 Added support for basic Japanese input on Win32 1999-03-19 23:36:20 +00:00
rods%netscape.com 61cfe9a3d0 Added DragListener for Drag & Drop (it's not turned on) 1999-03-14 04:45:00 +00:00
buster%netscape.com 4f91976666 added checks for DOM Key event returning 0x0 key code. If we get 0, we bail. 1999-03-14 04:12:21 +00:00
sfraser%netscape.com 895b199ee2 Throw the switch so we now pay attention to the charCode in the key event. 1999-03-12 05:28:22 +00:00
sfraser%netscape.com 452e7019bf Fix the key handling, and fix my macro for the charCode stuff 1999-03-11 19:34:28 +00:00
sfraser%netscape.com beb4a09d21 Adapted key listener to get char code directly from event, rather than trying to do a key code conversion (#ifdeffed out until char code is there on all platforms). 1999-03-11 06:42:09 +00:00
akkana%netscape.com 57638ea34c Implement editor cut/copy/paste 1999-03-10 22:46:15 +00:00
buster%netscape.com efe5fd63d6 SelectAll wired to Ctrl-A. 1999-03-10 19:49:43 +00:00
buster%netscape.com 5333e448a3 implemented GetTextProperty -- only works for bold and italic now,
trivial to add more properties
finished first cut at SetTextProperty.  This triggers lots of crashes in
range/selection code where we're holding onto a stale frame pointer (at
least, that's my best guess.)
synched with Charlie's change-o-rama
added an assert in DeleteTextTxn::Init() checking aNumCharsToDelete vs.
0
  NS_ASSERTION(0!=aNumCharsToDelete, "bad arg, numCharsToDelete");
if the number of chars to delete is 0, we shouldn't be creating a
transaction at all.  I had never seen this condition arise before
Charlie's checkin, I don't know if he introduced it or if it was a
latent bug I just never tripped over before.
1999-03-02 07:52:41 +00:00
buster%netscape.com c05dfef653 added InsertElementTxn
added nsEditProperty
beginning of implementation for SetTextProperties.  Currently, it only works if the selection is entirely within a single text node.  Currently only
supports bold and italic (mapped to ctrl-b and ctrl-i for testing purposes.)
changed a bunch of interfaces to make things easier, like CreateElement now returns (as an out-param) the element created.
1999-02-24 17:24:37 +00:00
brade%netscape.com fea14bd750 move local variable into comment block to reduce warnings on Macintosh compiler 1999-02-19 16:11:23 +00:00
danm%netscape.com fec8319485 fixing compilation problems with new nsCOMPtr. part of the carpool. 1999-02-17 06:18:11 +00:00
buster%netscape.com 1ceedf5abc * the viewer test app now instantiates an nsITextEditor via nsRepository for "Editor mode"
* the TxnMgr is invoked by the editor via nsRepository
* editor.h|cpp have been renamed nsEditor.h|cpp for consistency
* editorInterfaces.h|cpp have been renamed nsEditorEventListeners.c|hpp
* added nsITextEditor.h, nsTextEditor.h|cpp.  The text editor is a placeholder for the rules unique to text
editing.  It invokes the nsIEditor to do core editing operations.
* reworked nsIEditor and related interfaces as per emerging design.
* nsEditor::BeginTransaction and EndTransaction call nsTransactionManager::BeginBatch and EndBatch.
1999-02-12 17:18:58 +00:00