Re: Leo 6.7.4: status report

2023-07-24 Thread Edward K. Ream
> It is not expected for an undo operation to change the clipboard.  So
please restore the original clipboard contents after the undo.

Neither undo nor redo changes the clipboard. These operations merely delete
or reinsert the pasted node.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/leo-editor/CAMF8tS2mPyiOdev4WdMRcc7yvBaru3iuCVjGZpNsB5o%2Btx7hWQ%40mail.gmail.com.


Re: Leo 6.7.4: status report

2023-07-24 Thread Thomas Passin

On Monday, July 24, 2023 at 2:08:34 PM UTC-4 Edward K. Ream wrote:

The PR will complete #3452 
, a paste-based undo 
scheme. I'll write a new unit test for the new code. *Note*: the two new 
unit tests perform three cycles of undo/redo, so they will form the basis 
for testing the new undo scheme.


*Summary*


PR 3455 adds urgently needed unit tests for complex code that pastes 
outlines. 


It is not expected for an undo operation to change the clipboard.  So 
please restore the original clipboard contents after the undo.

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/leo-editor/daf0b9a9-4404-4eaf-bac0-6c0e97e667ccn%40googlegroups.com.


Leo 6.7.4: status report

2023-07-24 Thread Edward K. Ream
 

PR #3455  will fix 
three of the four remaining issues. The highlights:


I have spent several days creating demanding unit tests for Leo's 
paste-node and paste-retaining-clones commands. I shall soon write a 
similar test for the paste-as-template command.


For the first time, we can contemplate changes to all three commands. We 
can also (for the first time!) test any changes.


The unit tests verify that paste-node and paste-retaining-clones work when 
the clipboard is in copy-as-json format.


*Significant changes*


The unit tests prove we can remove the strange save/restore code in 
*fc.getLeoOutlineFromClipBoardRetainingClones* and 
*fc.getLeoOutlineFromClipBoard*. No amount of theorizing or study could 
have done the same. As a result, the PR will close #3453 
.


The paste-node and paste-retaining-clones commands now support the *pasted 
nodes win* rule. And yes, the unit tests verify this policy.


*To do*


The PR will complete #3452 
, a paste-based undo 
scheme. I'll write a new unit test for the new code. *Note*: the two new 
unit tests perform three cycles of undo/redo, so they will form the basis 
for testing the new undo scheme.


*Summary*


PR 3455 adds urgently needed unit tests for complex code that pastes 
outlines. The PR changes only about a dozen lines of code. All the rest is 
scaffolding. That's the way it should be.


For the first time, Leo's paste-node-related code rests on a firm 
foundation.


Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/leo-editor/bd8471f1-a994-4135-9eae-ee05e44c15acn%40googlegroups.com.