Bug 87922 - 4.4.0.x Automatic font color no longer works
Summary: 4.4.0.x Automatic font color no longer works
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
4.4.0.1 rc
Hardware: Other All
: medium normal
Assignee: Miklos Vajna
URL:
Whiteboard: target:5.1.0 target:5.0.2 target:4.4.6
Keywords: bibisected, bisected, regression
: 90054 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-12-31 19:16 UTC by tmacalp
Modified: 2021-03-07 08:30 UTC (History)
6 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 tmacalp 2014-12-31 19:16:14 UTC
While testing 4.4.0.1 rc, I noticed that automatic font color does not appear to work in Writer.  

Steps to reproduce:
1. Open Writer
2. Set page background to Black
3. Type some text

Expected:
Since the text is being typed on pure black, the text color should flip to being white so it can actually be read.

Actual:
The text remains black and completely blends in with the black background.

I performed a brief test in Calc and Draw and didn't experience the same bug, so it appears limited to Writer.
Comment 1 Urmas 2014-12-31 20:40:01 UTC
Confirming, not in 4.3.0.
Comment 2 tmacalp 2015-01-09 19:15:35 UTC
I finally set up a 4.4.x bibisect environment:
 ac0bb760db68647bcda368fc13810850c888a1fa is the first bad commit
commit ac0bb760db68647bcda368fc13810850c888a1fa
Author: Bjoern Michaelsen <bjoern.michaelsen@canonical.com>
Date:   Sat Oct 18 07:12:11 2014 +0000

    source-hash-a7e1ffc248bed431693c6d50c02e7c936c67f360
    
    commit a7e1ffc248bed431693c6d50c02e7c936c67f360
    Author:     Caolán McNamara <caolanm@redhat.com>
    AuthorDate: Tue Jul 1 15:50:28 2014 +0100
    Commit:     Caolán McNamara <caolanm@redhat.com>
    CommitDate: Tue Jul 1 16:43:06 2014 +0100
    
        coverity#706988 Uncaught exception
    
        and
    
        coverity#706989 Uncaught exception
    
        Change-Id: I426ae26f69311effd60c0b60b7f4d677a2e35c80

:100644 100644 dfb919049ad61631d365f9038e78ea6a9bd2057b 554148af8d80ddbf565849328f3bc184847db05e M      ccache.log
:100644 100644 a9084aa481645c85bc8e09936010199b7ee524de 5aa1008cbe0a3bdd212effcbb0192de2ed947cb6 M      commitmsg
:100644 100644 f5c919ded771e0566a1a7ec9fbfcd59a2863e972 5a49acee48ed3dce1fda9141f1f51a55251f15c9 M      make.log
:040000 040000 08cb282a79a428e5cbb828c9a1a84a2808d3dc66 4301dffd0df84a13f6f81e4f0fb67f53900889dd M      opt

$ git bisect log
# 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
# good: [1efd4fa8897d1c45ae8a92b4cb5d74049cc7dec8] source-hash-0d55277947fbc2f92fb9fe40dcfa804dc619c37a
git bisect good 1efd4fa8897d1c45ae8a92b4cb5d74049cc7dec8
# bad: [be4d1e746b8125cb258a718397b8c0deadba09e5] source-hash-be8d4a5d8aa711e8eb9265fd38d17c8290770a0e
git bisect bad be4d1e746b8125cb258a718397b8c0deadba09e5
# bad: [ac0bb760db68647bcda368fc13810850c888a1fa] source-hash-a7e1ffc248bed431693c6d50c02e7c936c67f360
git bisect bad ac0bb760db68647bcda368fc13810850c888a1fa
# first bad commit: [ac0bb760db68647bcda368fc13810850c888a1fa] source-hash-a7e1ffc248bed431693c6d50c02e7c936c67f360
Comment 3 Matthew Francis 2015-01-10 13:50:26 UTC
The behaviour changed as of the below commit.

Adding Cc: to vmiklos@collabora.co.uk; Could you possibly take a look at this? Thanks

commit 7d9bb549d498d6beed2c4050c402d09643febdfa
Author:     Armin Le Grand <alg@apache.org>
AuthorDate: Mon Jun 2 15:00:50 2014 +0000
Commit:     Miklos Vajna <vmiklos@collabora.co.uk>
CommitDate: Tue Jul 1 13:30:09 2014 +0200

    Related: #i124638# Second step of DrawingLayer FillAttributes...
    
    for Writer objects, now added support for Paragraph and PageStyle (including
    Header and Footer) for direct attributes and style attributes
    
    (cherry picked from commit cc25c58f7052827bfebdc9fbeec668c8fa29ed1b)
Comment 4 Miklos Vajna 2015-08-07 16:15:17 UTC
The problem is that SwDrawTextInfo::ApplyAutoColor() does not handle fill attributes, so the page background color is ignored. I'll take care of this.
Comment 5 Commit Notification 2015-08-10 07:18:08 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

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

tdf#87922 SwDrawTextInfo::ApplyAutoColor: handle fill attributes

It will be available in 5.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 6 Commit Notification 2015-08-10 08:19:21 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

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

tdf#87922 testcase

It will be available in 5.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 7 Miklos Vajna 2015-08-11 08:25:05 UTC
*** Bug 90054 has been marked as a duplicate of this bug. ***
Comment 8 Commit Notification 2015-08-17 20:24:39 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-5-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=294f43d78f1662139e9308120667396f10cadde5&h=libreoffice-5-0

tdf#87922 SwDrawTextInfo::ApplyAutoColor: handle fill attributes

It will be available in 5.0.2.

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 9 Commit Notification 2015-09-03 10:49:19 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-4-4":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=7fcedb1325887b9ca810b28769cc9083addc0033&h=libreoffice-4-4

tdf#87922 SwDrawTextInfo::ApplyAutoColor: handle fill attributes

It will be available in 4.4.6.

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 10 Robinson Tryon (qubit) 2015-12-17 08:42:57 UTC Comment hidden (obsolete)
Comment 11 tmacalp 2015-12-21 20:50:38 UTC
Thanks for the fix!  Unfortunately, I just discovered that this behavior still isn't quite fixed for transparent frames.

To test this, simply change the original steps to reproduce to:

1. Open Writer
2. Set page background to Black
3. Set page background transparency to 10%
4. Type some text

Is this change worthy of opening another report or can it be handled here?