Skip to content

Commit

Permalink
Fix for Dark theme not readable (#8929)
Browse files Browse the repository at this point in the history
* changed background color entry-selected (#7927)

* chaged color summary text select active/inactive (#7927)

* resolved threads (#7927)

* update CHANGELOG

Co-authored-by: euEmica <[email protected]>
Co-authored-by: Victor Daniel <[email protected]>
  • Loading branch information
3 people authored Jun 27, 2022
1 parent 2d15917 commit 586d3e4
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Note that this project **does not** adhere to [Semantic Versioning](http://semve

### Changed

- Change in the color of the selection entries and the color of the summary in the Import Entries Dialog. [#7927](https://github.com/JabRef/jabref/issues/7927)
- We upgraded to Lucene 9.2 for the fulltext search.
Thus, the now created search index cannot be read from older versions of JabRef anylonger.
⚠️ JabRef will recreate the index in a new folder for new files and this will take a long time for a huge library.
Expand Down
3 changes: 3 additions & 0 deletions src/main/java/org/jabref/gui/Base.css
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,9 @@
-jr-drag-target: -jr-purple;
-jr-drag-target-hover: derive(-jr-purple, 80%);

-js-summary-text-color: #000000;
-js-summary-text-color-selected: #000000;

/*
Here are redefinitions of the default properties of modena. They should in principle all be derived from the
above colors. Goal should be to make as few as possible direct color-changes to elements and only do this for
Expand Down
3 changes: 3 additions & 0 deletions src/main/java/org/jabref/gui/Dark.css
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@

-jr-drag-target: -jr-accent;
-jr-drag-target-hover: -jr-accent;

-js-summary-text-color: derive(-fx-light-text-color, 70%);
-js-summary-text-color-selected: derive( -fx-dark-text-color, 70%);
}

#previewBody {
Expand Down
9 changes: 7 additions & 2 deletions src/main/java/org/jabref/gui/importer/ImportEntriesDialog.css
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,15 @@
/*-fx-padding: 0.5em 0em 0.5em 0em;*/
}

.list-cell {
.list-cell .summary > Text {
-fx-padding: 0.5em 0 1em 0.5em;
-fx-fill: -js-summary-text-color;
}

.list-cell:entry-selected {
-fx-background-color: derive(-jr-selected, 60%);
-fx-background-color: derive(-jr-selected, 35%);
}

.list-cell:entry-selected .summary > Text {
-fx-fill: js-summary-text-color-selected;
}

0 comments on commit 586d3e4

Please sign in to comment.