Bug 139307 - Particular seemingly selected contents not copied to clipboard
Summary: Particular seemingly selected contents not copied to clipboard
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.4.7.2 release
Hardware: All All
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, regression
Depends on:
Blocks:
 
Reported: 2020-12-29 17:46 UTC by Rainer Bielefeld Retired
Modified: 2024-08-18 20:01 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
Sample Document (50.96 KB, application/vnd.oasis.opendocument.spreadsheet)
2020-12-29 17:46 UTC, Rainer Bielefeld Retired
Details
New Sample Document (43.03 KB, application/vnd.oasis.opendocument.spreadsheet)
2021-01-06 07:30 UTC, Rainer Bielefeld Retired
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rainer Bielefeld Retired 2020-12-29 17:46:35 UTC
Created attachment 168559 [details]
Sample Document

Steps how to reproduce with Version: 6.4.7.2 (x64)
Build-ID: 639b8ac485750d5696d7590a72ef1b496725cfb5
CPU threads: 4; OS: Windows 6.1 Service Pack 1 Build 7601; UI-Render: Standard; VCL: win; Gebietsschema: de-DE (de_DE); UI-Sprache: de-DE, Calc: threaded, Tango theme:

0. Open attached "SampleForCopyPaste.ods" with activated Macros for LibO
   Please keep in mind that I Use German UI, for other languages 
   keyboard shortcuts might be different
1. ˋDouble click text document area → <Ctrl+a> → <Ctrl+c>ˊ for copying 
    text document contents to clipboard
2. Click on "a" between "insert below"
3. <Ctrl+shift+v> for opening paste special dialog
4. click on "Plain Text"
   » a, b, c, d will be replaced by numbers with dots as decimal separator
5. ˋClick → I40 → Click Button [Dot to Comma]ˊ  
   » Macro will replace dots by commas and leave 4 numbers highlighted
6. <ctrl+c> for 'copy'
7. ˋClick C33 → <Ctrl+shift+v> for opening paste special dialogˊ 
   » expected: dialog with lots of options (Numbers, Formatting, Texts, ...,
               transpose, ...) will open 
     actual: Selector for Text document, ... Plain Text appears
8. Proceed 'Plain Text' from step 7
   » clipboard contents from step 4 still is in clipboard - instead of
     cells with numbers

Additional information
=======================
a) ˋrightlick → copyˊ into the highlighted area will do the job in step 6
   So the problem is limited to "copy by <ctrl+c>  
b) Problem is not caused by the macro. Search and replace will show the 
   same problem
c) Not limited to my WIN7 PC, same problem on a WIN10 Laptop
d) Problem not limited to that particular text document source. The first
   time I observed the problem I copied a column of numbers from a 
   completely different application instead of step 1
e) Currently I see this one as a minor problem because context menu does 
   work. But it's really annoying until you know the context menu trick
f) still a problem in a few weeks old 7.2
Comment 1 Rainer Bielefeld Retired 2020-12-29 17:48:25 UTC
g) No obvious DUP found with <https://bugs.documentfoundation.org/buglist.cgi?cmdtype=dorem&remaction=run&namedcmd=DUPs139307&sharer_id=19321>
Comment 2 Rainer Bielefeld Retired 2020-12-29 17:55:59 UTC
h) an indication that <ctrl+c> does not work is that there will not appear
   a dotted frame around the highlighting to mark the clipboard contents
   in step 6
i) Still worked fine for me with Version: 4.2.0.0.alpha0+
   Build ID: f4a4fee523ff8a6d272eabda2ce9ca96bd3bbbb
   TinderBox: Win-x86@6, Branch:master, Time: 2013-06-14_23:53:13
   (No versions between that one and 6.4 tested yet)
   So REGRESSION (at least for me. Feature for other people?)
Comment 3 V Stuart Foote 2020-12-29 18:52:33 UTC
Hi Rainer, didn't check these exact STR. But, Mike K and Jan-Marek have been working on the Windows clipboard handling for current master against 7.2, with a back port to 7.1. 

Currently broken badly (bug 139074) but when they get it sorted--suspect/hope many of the spurious content Windows clipboard issues will resolve.  Keep an eye on it--Stuart
Comment 4 Rainer Bielefeld Retired 2020-12-29 21:43:12 UTC
(In reply to V Stuart Foote from comment #3)

Hi Stuart, I doubt that a fix for that Crash problem also might solve this one, but as you recommended, I will keep an eye on it. After fix for bug 139074
Comment 5 m_a_riosv 2020-12-30 10:13:55 UTC
I see that after point 5. if I go to the Edit in Menu there, 'Copy' it's not available, but resecting I41:I44, the 'Copy' it's available in the menu.

Seems after the macro we are where we don't think.
e.g. after run the macro.
[F2][Enter] Copy it's not available.
[F2][Enter] [space], button macro is selected
Editing on the input bar and [enter] make 'Copy' available.
Comment 6 Rainer Bielefeld Retired 2020-12-30 10:37:14 UTC
k)  As I told I saw the same problem with 'Find & Replace' instead of macro in
    step 5
k1) But no problem If I do 'Find & Replace - only selection'. After this
    in Menu 'Edit' 'Copy' will be available, and also <ctrl+c> will work 
    fine
l) I think m.a.riosv's suspect "we are where we don't think" (ore: "we
   haven't a clue where we are") is correct. Not only 'Copy' does not work
   after step 5. Also several formatting functions (bold ... character color
   ...) will not work any longer. You see the Icons in the Formatting Bar
   will become greyed out after step 5
Comment 7 m_a_riosv 2020-12-30 11:27:11 UTC
Sorry but I can't reproduce with 'Find & Replace', works fine for me doesn't matter if 'only selection' is marked.
Comment 8 Rainer Bielefeld Retired 2020-12-30 13:17:24 UTC
(In reply to m.a.riosv from comment #7)
> can't reproduce with 'Find & Replace'

Me too ...
I still reproduce it on WIN10 laptop with 7.0.3.1, but no longer with 7.4.7.2 on WIN7. There seem to be additional conditions? But what can that be that it appears for me just after your test? I will try to find out additional conditions. 

b1): Search and replace: Problem only reproducible if I leave open s&r dialog
     on WIN7. No longer reproducible with WIN 7 and 6.4.7.2  
     I will think about my mistake in tests.
Comment 9 m_a_riosv 2020-12-31 10:36:44 UTC
To my comment#7 I've tried both, with/without the S&R dialog open, and with/without in selection, also with search results box, and no issue.

Version: 7.0.5.0.0+ (x64)
Build ID: e29387a749edb1bf39ca2b558099964da42b3a4b
CPU threads: 4; OS: Windows 10.0 Build 20180; UI render: Skia/Vulkan; VCL: win
Locale: es-ES (es_ES); Interfaz: es-ES Calc: CL
Comment 10 m_a_riosv 2020-12-31 10:38:38 UTC
And with
Version: 7.1.0.1 (x64)
Build ID: b585d7d90ab863bf29b2d110c174c0c2a98f3ee4
CPU threads: 4; OS: Windows 10.0 Build 20180; UI render: Skia/Vulkan; VCL: win
Locale: es-ES (es_ES); UI: es-ES Calc: CL
Comment 11 Rainer Bielefeld Retired 2021-01-06 07:30:27 UTC
Created attachment 168718 [details]
New Sample Document

With new Sample Document I can reproduce the "highlighted not selected" issue after 'Find and Replace' with 
Version: 7.2.0.0.alpha0+ (x64)
Build ID: a470932949c3e8ee28aaf77a71a90a957bbfe1ce
CPU threads: 4; OS: Windows 6.1 Service Pack 1 Build 7601; UI render: default; VCL: win
Locale: de-DE (de_DE); UI: de-DE
Calc: threaded

And also a 7.0.3.1 (x64) Version on WIN10.

STR for 7.2:
10. Open attached New Sample Document
   Please keep in mind that I Use German UI, for other languages 
   keyboard shortcuts might be different
11. ˋClick Cell O29 → <shift>+click O32 → <Ctrl+c> for Copyˊ
12. ˋClick Cell P29 → In Standard Bar click Downarrow in Paste Icon → 
     Click "Unformatted Text"ˊ (NOT "Unformatted Text (TSV-CALC)")
     » Area becomes pasted
13. ˋClick P29 → <shift>+click P32ˊ to select area
     » Area becomes highlighted
14. <Shift+Alt+Ctrl+f> → Find and Replace all "," by "." 'in selection' 
    (is checked by default)
     » highlighted area numbers will get German decimal separator "comma", 
       are numbersnow instead of strings
15. [Close] Search Hits Dialog  →  <Ctrl+c> for Copy
16. ˋClick Cell Q29 → <Ctrl+Shift+v> 
     » Paste Special Dialog appears with checked "Text", "Numbers", 
       "Time,Date"
17. Replace all
     » Expected: Numbers with commas inserted
       Actual: Text strings copied in step 11 have been pasted 😥
Comment 12 Buovjaga 2021-11-26 14:34:06 UTC
(In reply to Rainer Bielefeld Retired from comment #11)
> Created attachment 168718 [details]
> New Sample Document
> 
> STR for 7.2:
> 10. Open attached New Sample Document
>    Please keep in mind that I Use German UI, for other languages 
>    keyboard shortcuts might be different
> 11. ˋClick Cell O29 → <shift>+click O32 → <Ctrl+c> for Copyˊ
> 12. ˋClick Cell P29 → In Standard Bar click Downarrow in Paste Icon → 
>      Click "Unformatted Text"ˊ (NOT "Unformatted Text (TSV-CALC)")
>      » Area becomes pasted
> 13. ˋClick P29 → <shift>+click P32ˊ to select area
>      » Area becomes highlighted
> 14. <Shift+Alt+Ctrl+f> → Find and Replace all "," by "." 'in selection' 
>     (is checked by default)
>      » highlighted area numbers will get German decimal separator "comma", 
>        are numbersnow instead of strings
> 15. [Close] Search Hits Dialog  →  <Ctrl+c> for Copy
> 16. ˋClick Cell Q29 → <Ctrl+Shift+v> 
>      » Paste Special Dialog appears with checked "Text", "Numbers", 
>        "Time,Date"
> 17. Replace all
>      » Expected: Numbers with commas inserted
>        Actual: Text strings copied in step 11 have been pasted 😥

I can't reproduce, I get the numbers with commas after step 16

Version: 7.4.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: ddc57169ac8d1de00403dbb09fef5221beaa0f3d
CPU threads: 2; OS: Windows 10.0 Build 19042; UI render: Skia/Raster; VCL: win
Locale: fi-FI (fi_FI); UI: en-US
Calc: threaded
Comment 13 Rainer Bielefeld Retired 2021-11-26 15:04:21 UTC
(In reply to Buovjaga from comment #12)
I'll Try 7.4, soon.
Comment 14 zcrhonek 2021-12-30 16:45:59 UTC
(In reply to Rainer Bielefeld Retired from comment #0)
> Created attachment 168559 [details]
> Sample Document
> 
> Steps how to reproduce with Version: 6.4.7.2 (x64)

I can reproduce with Version: 7.4.0.0.alpha0+ / LibreOffice Community
Build ID: c13db6e792cc347ffff4585f23866f195651f21f
CPU threads: 4; OS: Linux 5.11; UI render: default; VCL: gtk3
Locale: cs-CZ (cs_CZ.UTF-8); UI: en-US
Calc: threaded Jumbo
Comment 15 zcrhonek 2021-12-31 07:30:19 UTC
bibisect result with bibisect-41max on linux (steps from comment 0):
 298599954082397682f1c26d2563ec6ef9a094dd is the first bad commit
commit 298599954082397682f1c26d2563ec6ef9a094dd
Author: Matthew Francis <mjay.francis@gmail.com>
Date:   Fri Sep 18 11:12:53 2015 +0800

    source-hash-d8d55787b81cdc955b73c8befa4ab608f46e32aa
    
    Bibisect: This commit covers the following source commit(s) which failed to build
    6166282edeb1a5c44d34d4824eab1f82b6e7b15a
    32e716528560c22c8ec881ed88fd7a99a27c9efd
    360e017a7b58cc2c52ee13bca2836040396eabe0
    35f846ffea29943729de98ae8d50adf4d82c4aa0
    28ca8eeee8898c5cd3730ebfcbbf303b68d25150
    3cf4fffee796a7ee810bb9575b65f381d1e2a8a2
    859406009481fc3a42d027608ca685fcd90537ff
    8ba847daf0c6dc4ce0100e4623b5b7b6c1d91ba7
    b1415411a1f0f3ad5ad4c0f7b2600fb5ba1e6f82
    545e810da6758f78de45a00374877bd091dc051f
    859f28865c9761a3ea8608ef919fce1ff4037ac4
    0fd4d12c6233da2ac1936cd89838b006ffec5192
    fbdfd76d357ef82cacafdf12228b0025374fbc20
    08662568a590bfb20849fce077d8b5aff8b99b57
    a1dff2901e9b6f70ea87df5e76825367b38ceaf4
    cdc87e5f32056da77749304f3148f1c842a958d0
    5e9fe0ff4dfaec04ad821c4347fd8adcb5dfcb5a
    58e72f3a8eb63edc84cfb6141b1e87c436824a14
    7689697566016c43a9f633c7383232d152476c0e
    aa741ec6fa269cd64e7a40aa1e323d39db8183cc
    60169637833bf39f646162ef156347eec4b5da39
    31d898853e6898227c3416db0107285e2590d297
    3d8a7a435c2e97a02ccca30352a71e68ab112dfc
    e601660b89768dc01d0ef73ec3e6579d26b30f96
    d0edc4e4c3709a3d0300e0b2b035e10493f583f9
    3d1297419fa4f5d6ce6b07ee61594db1e9bdf038
    2df3ff140e5f803c3bb22fd621045e416c84c587
    e52f636aa44615b180bf799b2d664de9244c3138
    5b89d4c7fb1c3dd3a4af42380eb8de92d60a102e
    b281ffde21c44578f110531e469a8c0f02cdd958
    96c2986dd46d963dae1c3b9fa3a8f2ebf05e8f65
    bb7360ca9929e9b395b3c903f460c9ed5efdce4d
    38b06c661559e6eca60e2c4a4a3637b8293307b2
    93ceaadd6e40c458385471445e644f82815d9249
    7f17b33acc8c3076f0696542795a1ca74ee2d671
    737a580a3b96efa2e389d2e72546484af8d4d78f
    0c5320a63894919bf8dbb424b9ea52836034efde
    8186a4a1e478f5f869443d2c34d06877433e444c
    2bd3123174269a46898ddb08e24946c6407582c4
    f74e390ef2a6edd64ed976f169d56864e2c125ac
    539f4074dd37f3ba3abe8db3cbe379b9926b4618
    5573ee341b1fc38d26fcfabffbfb23eb3cadea68
    cd9d1bdf5e3351c929d5b651c009ee17b4d962c4
    71f990d286c603b3bf220c8d93af69f04a45dd7a
    fc63700181ab0f42eab5f98328074fe1682344f8
    0f28a2a5e29499b62074dad4442fafa57858677d
    4c3ad94c70f98f5062bf96a6f1339992b7ec2bd1
    6389bf38961d84fd3e1c8fbdc78040e1b1be3ba9
    7a5bfde13afd98f1a8e110a96a636119da2ad911
    33e0e0d843cd9ad0b7e698f9a3273af1ba78aa8c
    59d6bde4045e928b5d68fb23e3340fa0e48f3e33
    8fc9351f555cecdbb45dbf2752fea0efcaa6e0cd
    d68243cd663e55418831a157615ea588848804bb
    eea4a30a4332b92b5534d3d3dc0e6152108ed670
    8232eaf93f7f2837d049175a521ef05d68b12214
    4ed380d62abe283940dced63e0ad29f6f766545f
    8550935cb17ccc07e4928613a43d15797f4fe5de
    3126793480c8c8759a991ff7f516ad7bf69d4ac8
    67ba9fdb2c298cbc62e64b9768355a8bf8c5b098
    81b0155096fc369feae3fe33fc8cf09c2ed3de01
    affe3c57ada0a436ffa1ce1adeae96914977966a
    0ac4451161f404665f35d2b3c82a507f8238bb14
    455e21727572d6ac123781be292053cf13c68237
    d1bd0cbb41f6377607a1c18589eb5e24b16988ed
    81ec93f8448d32933e2697613449baf573b63e42
    e4088a68aa3d69da60f5a1e93c06ca8be3ff764f
    cb5000280e292042f36b07f2484026a4382899f9
    8230290c98f9fd77c933e350ca6c861566fefec6
    004881330da6b61bcfb2ee6377e9f2a962e54f47
    90af7007b77f9cd0fcbc9b49350b20d2a5cb6cf4
    13adadee52c71a1b7db95f36e34a8c622ab1179e
    e8ad612bf813579f7a3bd4ed32c719ee01c6ce2e
    01d839f257056ed2fb6a79fed3f1d33fdbd76b6e
    5ade04867f280b18dfbfb7e60568ed58b32d6bbc
    23dadfa9d3770c346d49b9d0941766abf3d96e67
    74970948bbd410278964bd02cb5741c6c87eb30d
    852bf3ad922ab8e5dfd8da2f5861b8b30d6c5782
    c0b455a664bae6047992a98e3c991b8b5dc84736
    196ec14db1d4f39e25c83517cc7bad4d78ee6572
    20dee85b6390ef3edc5434889523cd9fd0137bae
    569dfd22e09e954654f4a383da9d0ac7dad33737
    f47ed987388e4df58ba74b9aca574a7d1fba396a
    1f2555426a56b639ff430bf60fc4bd06d647ebaf
    042717e05e2fea96e1e892b715f98dc00e7a881c
    f9da1991ed0cf5936797d92f004462dbe93f1be7
    14589274cd9999dd3f9ef844cc1aff20e106a977
    7d2c9ac5c12232c15d21ee83387c31847553de80
    eb8971e5fe52bcb80eff56846182ac30c261e111
    87ee9a16b8993d4bc07292326ddfd4f8277bcd26
    977118753c3b4a05701866586136b78a669925c7
    3384f229a4a3812f57bd8864e9c916e6443a4899
    754fee5d1b6adcc04b58a834c84568585afd728a
    791b4eedfba1e913037d88a3c185dc01c9ea24be
    89001143ea5aeecf8af1b62748431dc785369f44
    10e03ade8fc9ee78b99f4f24bf962d968ffee346
    4f214b2b42dafe059f5bb4601ab4cbfac5a6934e
    9b9612f554bf8754ff911dec07253ffdddbcb216
    dab009a4fcd2b558a055b917e5ff48bfb998689e
    6b946f228397c370e09f487c470bafd9d046eee5
    cd2f2e772ce37808b0922358bf2f22adff6d2ea1
    7ac4c9dcc928d040c5a446efc256aa392f4bee2c
    db6ab9f8f11107b7c09c3a5139ee4b3d4afd2f80
    f2cf75d1886b031bbc058bb9399e91afff79a8f5
    72ced5a1e51435ecd4b0bba32d91f117a18a1eda
    48b29cd42ba10fbb3f7be697fd79a0984b4daa1b
    7bcebc31ed3d6693d0d747bebab4b82bc7c2062c
    b4d1fd3cca027ceecc1230e35c15b5363a591906
    e820522037ff95818b9a40dfd77671f84c714cd5
    73d23a54b8b930520788c891ddb12562198e94e8
    da99d73abfefd704f40ad6bc46172e267407a5ab
    38109d24ab5261959b316b7dacc99521858f0749
    abb6f47bd3941ec63a41a9b9fa4c7de620b5177d
    8feb5a20b8d7c4c4484153215b2dd688a52cf50c
    118a8ad8c6287e7a4cc81ec46504f6cdffdf826d
    42b4dc4f8cad68ebd1386c5b8ea76ffaf59fdeb4
    d0a956f1d80aaf4be6d19d339bd46addc8c16861
    b751e3915ef527c9af07b995c95fb353c3c81a42
    e84a04273b08bf4527155d348f2aebe840696b4e
    123c226af5b529e5b4fdb9d930eac089706049c5
    2d55b2e5ae0d4f1a05e1ce5b20a7b342d6ea8b1d
    5a6ed660ec74e445a827c7aa41e4793c64a46271
    79e5615fa103a52ce41ed682b624c13fd9a9d1eb
    43c234b0481fe63b8c4823affad066c6362f5068
    d3dde5d940d69d6b859fef3ff722e349d7d89c54
    38d02291f32d0f605a4046a96fd6c90abd935f6b
    acccf7a13fd0f87e5aecdc7d5412726a76dba275
    b9bea009ac27ffe822b43911a5c7a30d36c43c50
    96a7c619659ec153a8a9ad319c02c7182224801f
    c0b8dd85d4b49e8800e69e614c567ce272ac9780
    2d3baccf0249f8c68dcf8f9b0000453d0bc82d8f
    5861f62ee9a14a32c3a3eeb31487f74d6a79d0eb
    c9c2fbe485de2bb831bd2e58faef87a19ceff622
    5ef0015704ca67a8f9ffd8f4ae207be355da7f3e
    784e472aa24d2f2cb9c240b91af4a184c6fcb949
    d702dd4396161f8e2e7396f5c24554088b752fcb
    0c45b5548537cffddc3fbdd6b1c2b9a8a1bdbc4a
    869b787deeda5b45d5b0732d1bf777c26abce51e
    3df12741fa949d1b0e90d45aceeaa99679066b83
    fc91501f9f0a24ccfa69c2b4baf070aac9e2d0f0
    e42886ca2e4b62904c1eb2f424d74699a615a61c
    cf9078b54d3d436ad38cde254f426bd251b61b08
    e273602acd7da369e425f310fb2869d6cb55492b
    026001cd5ac84bf5aa72e09ff6d7fa3a1bd08e7a
    a9eab694d896426783c1826f4dfe3e2871043f84
    71ebe4404b6e7c78a7d2e352f6af88d57209680a
    62a68bbbe0acea471a04a702ca1372495fc7a2fb
    f937ef20f57b306191f7583c2d47b5ad3f2a73ee
    235941bcd0e59c2831d5bc28683119eb6a2fd982
Comment 16 Stéphane Guillou (stragu) 2022-11-11 09:20:48 UTC
From the range, I could only find this commit that mentions copy paste, but it looks completely innocuous (just a fixme comment): https://git.libreoffice.org/core/+/869b787deeda5b45d5b0732d1bf777c26abce51e%5E%21
Comment 17 Rainer Bielefeld Retired 2022-12-27 19:55:59 UTC
m) Observation, can't tell whether it can be useful ...
m1) In particular situations copy paste from other documents (email, Web page) 
   to LibO Spreadsheets (and also writer documents?!) fails using <ctrl+c> 
   <ctrl+v>  or similar
m2) But it seems to work if I select the text in the source document (Email)
    and put it by Drag and Drop into a Calc Cell. This success currently is 
    100% reproducible
m3) and also if I try <ctrl+v> after (m2) the old wrong clipboard contents will
   be pasted.
Comment 18 Buovjaga 2024-08-15 18:17:17 UTC
Bug 148647 was fixed last month, so it would be interesting to hear, if it helps here.
Comment 19 Rainer Bielefeld Retired 2024-08-18 20:01:01 UTC
I still see the problem described in #c11 with 
 Version: 25.2.0.0.alpha0+ (X86_64) / LibreOffice Community
 Build ID: d5143c058bfdc0f5674c3e0a88fae2f9cbe28a0a
 CPU threads: 12; OS: Windows 10 X86_64 (10.0 build 19045); UI render: default;  
 VCL: win
 Locale: de-DE (de_DE); UI: en-US
 Calc: CL threaded

It some kind of user error, but a tricky one.

I will check original report problem later