Repository: spyder-ide/spyder

Issue:
Red text in Dependency dialog window is hard to read
## Description

### What steps will reproduce the problem?

<!--- You can use Markdown here --->

1. Have an unsatisfied dependency.
2. Click `Dependencies` in the `Help` menu.

I find the version number next to `Jedi` very hard to read. The colour is hard coded in `widgets/dependencies.py`.

![Screenshot_20200624_092906](https://user-images.githubusercontent.com/7941918/85523633-288f7680-b5ff-11ea-86d6-0a5cf6907b93.png)


## Versions

* Spyder version: 4.2.0.dev0 a4d9ae4a4
* Python version: 3.7.6
* Qt version: 5.9.6
* PyQt5 version: 5.9.2
* Operating System: Linux 5.6.0-2-amd64

### Dependencies

These do not match the dependencies in the screen shot, but I don't think that matters.

```

# Mandatory:
atomicwrites >=1.2.0           :  1.4.0 (OK)
chardet >=2.0.0                :  3.0.4 (OK)
cloudpickle >=0.5.0            :  1.4.1 (OK)
diff_match_patch >=20181111    :  20181111 (OK)
intervaltree                   :  None (OK)
IPython >=4.0                  :  7.15.0 (OK)
jedi =0.17.0                   :  0.17.0 (OK)
keyring                        :  None (OK)
nbconvert >=4.0                :  5.6.1 (OK)
numpydoc >=0.6.0               :  1.0.0 (OK)
parso =0.7.0                   :  0.7.0 (OK)
pexpect >=4.4.0                :  4.8.0 (OK)
pickleshare >=0.4              :  0.7.5 (OK)
psutil >=5.3                   :  5.7.0 (OK)
pygments >=2.0                 :  2.6.1 (OK)
pylint >=1.0                   :  2.5.3 (OK)
pyls >=0.33.0;<0.34.0          :  v4.1.3+298.ga4d9ae4a4 (OK)
qdarkstyle >=2.8               :  2.8.1 (OK)
qtawesome >=0.5.7              :  0.7.2 (OK)
qtconsole >=4.6.0              :  4.7.5 (OK)
qtpy >=1.5.0                   :  1.9.0 (OK)
rtree >=0.8.3                  :  0.9.4 (OK)
sphinx >=0.6.6                 :  3.1.1 (OK)
spyder_kernels >=1.9.1;<1.10.0 :  1.10.0.dev0 (OK)
watchdog                       :  None (OK)
xdg >=0.26                     :  0.26 (OK)
zmq >=17                       :  18.1.1 (OK)

# Optional:
cython >=0.21                  :  None (OK)
matplotlib >=2.0.0             :  3.1.3 (OK)
numpy >=1.7                    :  1.18.5 (OK)
pandas >=0.13.1                :  None (OK)
scipy >=0.17.0                 :  None (OK)
sympy >=0.7.3                  :  None (OK)

# Spyder plugins:
spyder_notebook                :  0.3.0.dev0 (OK)
spyder_unittest                :  0.5.0.dev0 (OK)
```



Discussion:
You're totally right. We'll fix this for 4.2
Leaving this Spyder 5 because our new color palette will solve this problem.
@jitseniesen, would you say that this is still an issue?

![image](https://user-images.githubusercontent.com/365293/188053797-7a7e40e2-be91-4c75-94bb-17e8d1e5f68e.png)

I think the text is more readable now, but we could change it to be bold instead.
It's definitely better, but I'd still prefer the colour a shade brighter, more like `self` is shown in the code editor:

![colours](https://user-images.githubusercontent.com/7941918/188113637-795230c2-4882-45e5-bb10-e21953be4fc4.png)

However, I see that now the colour is chosen from a standard palette and I remember that there was a discussion about it, which I am loath to re-open ... ah, here it is: spyder-ide/ux-improvements#13.

Actually, on reading that issue, it seems that maybe the red colour was meant as a background colour, not as a text colour. Let's see how that looks:

![colours-bg](https://user-images.githubusercontent.com/7941918/188115446-305871f7-9d46-4a26-a829-2e73dc26df09.png)

I would say that's an improvement and a simple change. What do you think?
I like it, I think that's a really good improvement. Could you submit a PR for it?
Will do

Resolving patch:
diff --git a/spyder/widgets/dependencies.py b/spyder/widgets/dependencies.py
--- a/spyder/widgets/dependencies.py
+++ b/spyder/widgets/dependencies.py
@@ -60,10 +60,10 @@ def update_dependencies(self, dependencies):
                 item.setIcon(0, ima.icon('dependency_ok'))
             elif dependency.kind == OPTIONAL:
                 item.setIcon(0, ima.icon('dependency_warning'))
-                item.setForeground(2, QColor(SpyderPalette.COLOR_WARN_1))
+                item.setBackground(2, QColor(SpyderPalette.COLOR_WARN_1))
             else:
                 item.setIcon(0, ima.icon('dependency_error'))
-                item.setForeground(2, QColor(SpyderPalette.COLOR_ERROR_1))
+                item.setBackground(2, QColor(SpyderPalette.COLOR_ERROR_1))
 
             # Add to tree
             if dependency.kind == OPTIONAL:


Test patch: