Bug 114675 - EDITING: pasting text (in Calc in a cell in edit mode, in Draw in a text shape), leaves the cursor in front of the pasted text
Summary: EDITING: pasting text (in Calc in a cell in edit mode, in Draw in a text shap...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
6.0.0.1 rc
Hardware: All All
: high major
Assignee: Eike Rathke
URL:
Whiteboard: target:6.1.0 target:6.0.3
Keywords: bibisected, bisected, regression
: 115536 115792 (view as bug list)
Depends on:
Blocks: Paste Cell-Edit-Mode
  Show dependency treegraph
 
Reported: 2017-12-23 21:43 UTC by Cor Nouws
Modified: 2018-05-11 18:14 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Cor Nouws 2017-12-23 21:43:27 UTC
spreadsheet
cell with several words, e.g.
   "Aap Noot Mies"
Enter edit mode, copy "Mies", push HOME, then Ctrl+V
Result (with | representing cursor position)
   "|MiesAap Noot "

Expected
   "Mies|Aap Noot "

Noticed in Versie: 6.0.0.1
Build ID: d2bec56d7865f05a1003dc88449f2b0fdd85309a
CPU-threads: 4; Besturingssysteem: Linux 4.13; UI-render: standaard; VCL: gtk2; 
Locale: nl-NL (nl_NL.UTF-8); Calc: group
Comment 1 Cor Nouws 2017-12-23 21:43:41 UTC
Works OK in 5.4.4.2 > regression
Comment 2 Xisco Faulí 2017-12-23 23:22:13 UTC
Regression introduced by:

author	Varun Dhall <varun.dhall@studentpartner.com>	2017-07-13 00:36:46 +0530
committer	Michael Stahl <mstahl@redhat.com>	2017-07-12 23:28:06 +0200
commit	e333183d4390da0b17a55f214e2b953dbb0a8883 (patch)
tree	680493fcca8e2a8239838db841cd623c2cedf1d3
parent	b392208dde22edbcba36fe516ac114284a111728 (diff)
EditEngine: Making ODF Format Default for Copy/Paste

Bisected with: bibisect-linux64-6.0

Adding Cc: to Varun Dhall
Comment 3 Cor Nouws 2018-01-17 13:22:54 UTC
Noticing the same problem when editing a text shape in Draw Version: 6.1.0.0.alpha0+
Build ID: 7a6df88f2579c4fcfa81eb27f6db9e8e21c9a6f8
CPU threads: 4; OS: Linux 4.13; UI render: default; VCL: gtk2; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2018-01-14_22:46:48
Locale: nl-NL (nl_NL.UTF-8); Calc: group threaded
Comment 4 Xisco Faulí 2018-01-17 13:28:48 UTC
Michael, one for you ?
Comment 5 Eike Rathke 2018-01-17 14:20:30 UTC
Commit mentioned in comment 2 is not the real cause, rather it switches the default clipboard format to the new implementation.

Note that this does not happen for "Unformatted text" (i.e. selecting that after Shift+Ctrl+V PasteSpecial) but also happens for "Formatted text [RTF]". Likely that path forgets to update the cursor position / selection with adding the length of the newly inserted text portion.
Comment 6 Xisco Faulí 2018-02-08 10:41:56 UTC
*** Bug 115536 has been marked as a duplicate of this bug. ***
Comment 7 Xisco Faulí 2018-02-08 10:45:17 UTC
(In reply to Eike Rathke from comment #5)
> Commit mentioned in comment 2 is not the real cause, rather it switches the
> default clipboard format to the new implementation.
> 
> Note that this does not happen for "Unformatted text" (i.e. selecting that
> after Shift+Ctrl+V PasteSpecial) but also happens for "Formatted text
> [RTF]". Likely that path forgets to update the cursor position / selection
> with adding the length of the newly inserted text portion.

@Eike, Do you think you could take a look at it at some point ?
Comment 8 Eike Rathke 2018-02-15 12:43:22 UTC
Well, actually I hoped for Varun fixing this.
Varun?
Comment 9 Eike Rathke 2018-03-02 19:02:16 UTC
Apparently not.. taking.
Comment 10 Eike Rathke 2018-03-02 19:04:22 UTC
*** Bug 115792 has been marked as a duplicate of this bug. ***
Comment 11 Commit Notification 2018-03-02 19:34:04 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=a44e62b82c7598471da9a5254953067613806337

Resolves: tdf#114675 return new EditPaM of insert position from SvxReadXML()

It will be available in 6.1.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 12 Eike Rathke 2018-03-02 19:48:57 UTC
Pending review https://gerrit.libreoffice.org/50646 for 6-0
Comment 13 Commit Notification 2018-03-05 09:18:25 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-6-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=2ebda414bfc5b4961ddb41e5512de215476a31a2&h=libreoffice-6-0

Resolves: tdf#114675 return new EditPaM of insert position from SvxReadXML()

It will be available in 6.0.3.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 14 Stefan_Lange_KA@T-Online.de 2018-03-22 07:06:47 UTC
Tested with

Version: 6.1.0.0.alpha0+ (x64)
Build ID: 751191ed2d7d6af6eddc3d738e8c45b0a2ab2572
CPU threads: 4; OS: Windows 10.0; UI render: GL; 
TinderBox: Win-x86_64@42, Branch:master, Time: 2018-03-22_00:36:35
Locale: de-DE (de_DE); Calc: CL

and with

Version: 6.0.4.0.0+ (x64)
Build ID: deb5db7bf6d45338c9b6f6f4a1d62fba168b7a85
CPU threads: 4; OS: Windows 10.0; UI render: GL; 
TinderBox: Win-x86_64@42, Branch:libreoffice-6-0, Time: 2018-03-22_03:08:26
Locale: de-DE (de_DE); Calc: CL

Both tests were succesful: Cursor was set correctly behind the pasted text.