Bug 257958 - White background in the Code Browser when using black KDE theme
Summary: White background in the Code Browser when using black KDE theme
Status: RESOLVED DUPLICATE of bug 257378
Alias: None
Product: kdevelop
Classification: Applications
Component: general (show other bugs)
Version: 5.3.0
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: 4.2.0
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-26 11:38 UTC by Mario Hros
Modified: 2019-10-06 23:34 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mario Hros 2010-11-26 11:38:35 UTC
Version:           4.0.2 (using KDE 4.4.5) 
OS:                Linux

I am using dark KDE theme. Whole KDevelop looks nice, it automagically selected syntax colors, but only Code Browser has white background and black text which is to light in otherwise dark environment.

Reproducible: Always

Steps to Reproduce:
Change KDE theme to dark one (e.g. Obsidian Coast).
Start KDevelop.
Select Code Browser and see white background.

Actual Results:  
White background, black text.

Expected Results:  
Something like grey background, light text.
Comment 1 Milian Wolff 2010-11-26 14:15:51 UTC
Sorry, I have to tell you that this cannot be fixed. We embed arbitrary HTML into the context browser (e.g. the Qt documentation or PHP documentation). Sadly, most web developers expect a white background by default. It's very common to e.g. only set the foreground color but not change the background.

If I'd set the background to a system color (possibly dark) you easily end up with unreadable text. I spent some time on this back then (I use obsidian coast as well) but had to give up in the end...
Comment 2 Miguel Raggi 2010-11-30 20:22:36 UTC
I'd also like to see some way of fixing this, even with a hack. For example, with CSS. In firefox, I use a plugin called "stylish", that let's me style every webpage. I never see problems like black text on black background. I can see every website with a black background and grey text and it's great. Something like that can't be added? I can't imagine it being too hard, just add some lines to "add the following css file" in the code browser? 

Sorry, I don't know much programming yet, but I'm learning :)

I had posted this too a while ago but never got any reply.
Comment 3 Kevin Funk 2016-11-07 22:40:42 UTC
I also think we should find a way to fix this. Patches / solution approaches welcome.

I'm surprised you're not annoyed by this Milian :)
Comment 4 Francis Herne 2018-11-09 23:18:29 UTC
Reopening this - it's obviously a problem, and there are few good reasons for us to respect HTML colouring.

I think the easiest way to strip any such codes would be at the QTextDocument stage.
Comment 5 Francis Herne 2018-11-09 23:19:54 UTC
Ah, there's another old duplicate with more discussion.

*** This bug has been marked as a duplicate of bug 257378 ***