Bug 88457 - Copying and pasting text between comments makes text unreadable
Summary: Copying and pasting text between comments makes text unreadable
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
4.4.0.2 rc
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, regression
: 91099 93768 (view as bug list)
Depends on:
Blocks:
 
Reported: 2015-01-15 12:39 UTC by Andy
Modified: 2015-12-15 11:03 UTC (History)
11 users (show)

See Also:
Crash report or crash signature:


Attachments
an example of writer file with some comments showing the black background bug (11.91 KB, application/vnd.oasis.opendocument.text)
2015-01-15 12:39 UTC, Andy
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andy 2015-01-15 12:39:07 UTC
Created attachment 112287 [details]
an example of writer file with some comments showing the black background bug

Create a new writer document. 
Write any text in it, and then add a comment somewhere, writing any text in the comment. 
Then select the comment text and copy it (for example because you need a slightly different comment elsewhere but would like to avoid re-writing it from scratch).

Now move elsewhere in the document text, and add a second comment; then paste the text copied from the first comment into it.
Result: the text is pasted, but it will be in black color on a black background, therefore totally impossible to read.
Notice that any effort to change the background color of the pasted text won't work, it will stay black. 
The only workaround for this once you have pasted the text into the 2nd comment is to change the text color in the comment, e.g. making it white; of course this is severely tedious.

Notice also that:
- the problem is persistent if you save the document into odt format; saving it into MSword format cleans all the wrong black text background in comments
- you can avoid the problem if, after having copied the text in the first comment, you paste it into the document page, select it again there and cut it. This way, when you then create the 2nd comment and paste it, the background will not go black
Comment 1 Buovjaga 2015-01-17 13:49:08 UTC
Repro both on Win & Linux.
4.3.3 is fine -> regression.

Win 7 Pro 64-bit, LibO Version: 4.4.0.2
Build ID: a3603970151a6ae2596acd62b70112f4d376b99

Version: 4.5.0.0.alpha0+
Build ID: 5f6bdce0c0ac687f418821ce328f2987bf340cda
TinderBox: Win-x86@62-TDF, Branch:MASTER, Time: 2015-01-17_01:06:46

Ubuntu 14.10 64-bit Version: 4.5.0.0.alpha0+
Build ID: 0ffa3abc7d6c0437ece30cfb1430d28ffcc9f5c1
TinderBox: Linux-rpm_deb-x86_64@46-TDF-dbg, Branch:master, Time: 2015-01-15_22:47:16

Version: 4.3.3.2
Build ID: 430m0(Build:2)
Comment 2 Buovjaga 2015-01-17 13:51:51 UTC
Tip from Arnaud on IRC: selecting the black bg text and pressing Ctrl-M fixes the problem.
Comment 3 Michael Weghorn 2015-01-18 00:15:17 UTC
bibisect result:

1efd4fa8897d1c45ae8a92b4cb5d74049cc7dec8 is the first bad commit
commit 1efd4fa8897d1c45ae8a92b4cb5d74049cc7dec8
Author: Bjoern Michaelsen <bjoern.michaelsen@canonical.com>
Date:   Sat Oct 18 06:47:56 2014 +0000

    source-hash-0d55277947fbc2f92fb9fe40dcfa804dc619c37a
    
    commit 0d55277947fbc2f92fb9fe40dcfa804dc619c37a
    Author:     Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
    AuthorDate: Sun Jun 29 20:15:50 2014 +0200
    Commit:     Tomaž Vajngerl <tomaz.vajngerl@collabora.com>
    CommitDate: Tue Jul 1 09:11:33 2014 +0200
    
        LODroid: cleanup
    
        Change-Id: I3c2b156c6ed5c6a27ac845481150150812eef1ec

:100644 100644 9175649a432c48063d0a6677bbcf98bec57b120d dfb919049ad61631d365f9038e78ea6a9bd2057b M	ccache.log
:100644 100644 ec7186e7691e26fc8b8f65886cec7b1e99444780 a9084aa481645c85bc8e09936010199b7ee524de M	commitmsg
:100644 100644 0a031d6808382f09f1cbd8933e8590fcf3c3a99b f5c919ded771e0566a1a7ec9fbfcd59a2863e972 M	make.log
:040000 040000 413fdc559df56dbb0be9fa4d204aee4763757c07 08cb282a79a428e5cbb828c9a1a84a2808d3dc66 M	opt

--

# bad: [4a3091e95fa263d3e2dd81e56e83996f0bb12287] source-hash-2b5b04e1e62914bf0902dfd7943cdc44499c47a6
# good: [812c4a492375ac47b3557fbb32f5637fc89d60d9] source-hash-dea4a3b9d7182700abeb4dc756a24a9e8dea8474
git bisect start 'latest' 'oldest'
# good: [5d0dfb8e62ae61a240f8313c594d4560e7c8e048] source-hash-0c6cd530de13f80795881f61064f1bf1dcc4ea81
git bisect good 5d0dfb8e62ae61a240f8313c594d4560e7c8e048
# bad: [7dfacd0b8bd828331d74c0f79de6e8924bc4e6a5] source-hash-f93ce4f7eb90093d0ea3115d0a1c614612676dbd
git bisect bad 7dfacd0b8bd828331d74c0f79de6e8924bc4e6a5
# bad: [1a63057f6378db7c6b8af1171b7b140f7583f246] source-hash-59f84b4a2c082382767f12e0c7a06a3f0b52e721
git bisect bad 1a63057f6378db7c6b8af1171b7b140f7583f246
# good: [3787e4f82e47eaf4fa454afdca671272e50f875b] source-hash-0e09134a4a4cbb0639fc586c560c6fb2765487be
git bisect good 3787e4f82e47eaf4fa454afdca671272e50f875b
# bad: [13c63ebe51bd9151757981f75b62271c00a47bf1] source-hash-5ccb510ef7dd6688b86038b37563583f64107936
git bisect bad 13c63ebe51bd9151757981f75b62271c00a47bf1
# good: [c6f882c644d407425898f336d5395e4e9c2ba8e3] source-hash-2b9ad2ef6bf904a8c2ec94e58644e8a7f7a36ae3
git bisect good c6f882c644d407425898f336d5395e4e9c2ba8e3
# bad: [1efd4fa8897d1c45ae8a92b4cb5d74049cc7dec8] source-hash-0d55277947fbc2f92fb9fe40dcfa804dc619c37a
git bisect bad 1efd4fa8897d1c45ae8a92b4cb5d74049cc7dec8
# good: [357fc7f532c3c0194204a53fba56f1a5143f423c] source-hash-f90eb33a268bdcd1c52aea5670a58267b0907096
git bisect good 357fc7f532c3c0194204a53fba56f1a5143f423c
# first bad commit: [1efd4fa8897d1c45ae8a92b4cb5d74049cc7dec8] source-hash-0d55277947fbc2f92fb9fe40dcfa804dc619c37a
Comment 4 Michael Weghorn 2015-01-18 00:18:11 UTC
Note that also from that commit on, text inserted in the first comment has a white/grey background.
Comment 5 Andy 2015-01-18 13:50:51 UTC
The ctrl+M workaround is confirmed, but to use it you first have to select the whole text of the comment, otherwise it won't work
Comment 6 Matthew Francis 2015-01-19 04:47:46 UTC
Within the bibisect range, the pasted text first gets a purple background in ae915ba34f6b721b81747e7b90a46e1133d5238e, then goes all black somewhere in 
9ab4387532a9bd0df49f3e619f44108dea952a38..4e7f1f7f1113a1f0d60ed17d7712700683c35a24 (not individually buildable)

Adding Cc: to matteo.campanelli@gmail.com; Could you possibly take a look at this? Thanks


commit ae915ba34f6b721b81747e7b90a46e1133d5238e
Author: matteocam <matteo.campanelli@gmail.com>
Date:   Fri Jun 6 15:14:52 2014 -0400

    More debugging; fixed Font::IsTransparent
    
    Change-Id: Idcb54408dd3cf6561b78eb28fdb409d2e31df541
    (cherry picked from commit d84dba8b01c1f240f22b774c951ebf206d5a3ac9)




commit 4e7f1f7f1113a1f0d60ed17d7712700683c35a24
Author: matteocam <matteo.campanelli@gmail.com>
Date:   Mon Jun 30 21:17:56 2014 +0200

    Fix svgio build
    
    Change-Id: Ief84952f2b1dc077e871e42e419f41d99810af26

........

commit 9ab4387532a9bd0df49f3e619f44108dea952a38
Author: matteocam <matteo.campanelli@gmail.com>
Date:   Mon Jun 16 15:52:24 2014 +0200

    Added Text Fill Color in TextDecoratedPrimitive2D
    
    Change-Id: I8c3946c08d20cc2ca2af6f17a2a57d6c9a5cfa23
    (cherry picked from commit 00fc45e78d84dddf32b450441bf9028352ec9e52)
Comment 7 Matteo Campanelli 2015-01-20 20:36:12 UTC
Yes, I will be looking at this in the next few days.
Comment 8 Paul 2015-05-07 09:18:50 UTC
*** Bug 91099 has been marked as a duplicate of this bug. ***
Comment 9 PHM 2015-09-30 21:53:37 UTC
I confirm this as an ennoying bug on the OSX platform (10.6.8 to 10.9.5) since several LO version.
Last version : 5.0.0.5 rc

CTRL M is a good tip on Mac.
Comment 10 Buovjaga 2015-10-24 16:48:29 UTC
*** Bug 93768 has been marked as a duplicate of this bug. ***
Comment 11 Buovjaga 2015-10-24 16:50:44 UTC
Seems to be fixed in 5.0.2.2, thanks to Luke Kendall for noticing.

Win 7 Pro 64-bit, Version: 5.0.2.2 (x64)
Build ID: 37b43f919e4de5eeaca9b9755ed688758a8251fe
Locale: fi-FI (fi_FI)
Comment 12 PHM 2015-10-24 23:24:02 UTC
yes, corrected on Mac Version (LO 5.0.2.2, OSX 10.9.5)
Comment 13 Robinson Tryon (qubit) 2015-12-15 11:03:13 UTC
Migrating Whiteboard tags to Keywords: (bibisected)
[NinjaEdit]