[Libreoffice-bugs] [Bug 57147] EDITING: Paste stops working after several copy-paste (steps: comment 28)
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Wed Oct 7 06:11:12 UTC 2020
https://bugs.documentfoundation.org/show_bug.cgi?id=57147
--- Comment #53 from b. <newbie-02 at gmx.de> ---
Created attachment 166145
--> https://bugs.documentfoundation.org/attachment.cgi?id=166145&action=edit
screenshot_with_'splitted_focus'
found another variant of this (or another variant of copy-paste) bug:
0. working in a big sheet, replacing formulas (patching strings together) by
their resulting string,
1. find a cell with a strng formula, ctrl-f and search for '&',
2. escape from search box by ESC,
3. run macro - see below - by assigned keyboard shortcut (alt-F7 n my case), it
copies the actual selection and pastes it back as it's result with 'paste
special',
4. ctrl-f and search for the next occurence of '&',
5. escape from the search box by ESC,
6. in this situation the sheet is displayed as in the attached screenshot, the
'old selection' / replaced cell is 'highlighted' with light blue-grey
background, a dotted border and the small black 'expand-square' bottom-right,
and the new / found cell is marked with the thick black border,
7. starting the replace macro in that situation results in a short display of
the hourglass and 'no action', the formula stays as formula,
8. changing the 'focus' / 'selection' by e.g. cursor-up - cursor-down (which
results in the new found cell being selcted and the highlighting of the former
cell disappearing) enables to start the macro with expected result,
it could be that some variants of the 'focus' / 'selection' status, being
'splitted'? (a thing that i had never consciously seen before) somehow plays
into copy/paste ... ???
(only reported because this bug has been unsolved for such long time and it
might be helpful to point out exotic side effects, and it looks to me as a
'stable reproducer'),
experienced in ver 6.1.6.3, retested in 7.1.0.0.a0+, same effect,
the macro (recorded and cutted away an unneeded cell change in the beginning):
++++++++++++
sub replace_formula
rem ----------------------------------------------------------------------
rem define variables
dim document as object
dim dispatcher as object
rem ----------------------------------------------------------------------
rem get access to the document
document = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
rem ----------------------------------------------------------------------
dispatcher.executeDispatch(document, ".uno:Copy", "", 0, Array())
rem ----------------------------------------------------------------------
dim args4(5) as new com.sun.star.beans.PropertyValue
args4(0).Name = "Flags"
args4(0).Value = "SVD"
args4(1).Name = "FormulaCommand"
args4(1).Value = 0
args4(2).Name = "SkipEmptyCells"
args4(2).Value = false
args4(3).Name = "Transpose"
args4(3).Value = false
args4(4).Name = "AsLink"
args4(4).Value = false
args4(5).Name = "MoveMode"
args4(5).Value = 4
dispatcher.executeDispatch(document, ".uno:InsertContents", "", 0, args4())
end sub 'sub replace_formula
++++++++++++
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20201007/05a2fe24/attachment.htm>
More information about the Libreoffice-bugs
mailing list