mirror of
https://github.com/frosch95/SmartCSV.fx.git
synced 2026-04-11 13:38:23 +02:00
Compare commits
1 Commits
1.4.0
...
dark_theme
| Author | SHA1 | Date | |
|---|---|---|---|
| 355c9d3ce4 |
@@ -85,6 +85,9 @@ public class SmartCSV extends Application {
|
||||
private void showUI(Stage primaryStage, String name, String version) {
|
||||
SmartCSVController smartCVSController = appContext.getBean(SmartCSVController.class);
|
||||
Scene scene = new Scene((Parent) smartCVSController.getView());
|
||||
var darkThemeCss = scene.getRoot().getStylesheets().get(0);
|
||||
scene.getRoot().getStylesheets().remove(darkThemeCss);
|
||||
scene.getRoot().getStylesheets().add(darkThemeCss);
|
||||
|
||||
primaryStage.setScene(scene);
|
||||
primaryStage.setTitle(String.format("%s %s", name, version));
|
||||
|
||||
34
src/main/resources/ninja/javafx/smartcsv/fx/dark-theme.css
Normal file
34
src/main/resources/ninja/javafx/smartcsv/fx/dark-theme.css
Normal file
@@ -0,0 +1,34 @@
|
||||
.root {
|
||||
-fx-base: rgb(39, 40, 40);
|
||||
-fx-accent: rgb(80, 80, 80);
|
||||
-fx-default-button: rgb(39, 40, 40);
|
||||
-fx-focus-color: rgb(80, 80, 80);
|
||||
-fx-faint-focus-color: #efefef22;
|
||||
-fx-focused-text-base-color : ladder(
|
||||
-fx-selection-bar,
|
||||
-fx-light-text-color 45%,
|
||||
-fx-dark-text-color 46%,
|
||||
-fx-dark-text-color 59%,
|
||||
-fx-mid-text-color 60%
|
||||
);
|
||||
-fx-focused-mark-color : -fx-focused-text-base-color ;
|
||||
-fx-control-inner-background: rgb(39, 40, 40);
|
||||
-fx-control-inner-background-alt: rgb(20, 20, 20);
|
||||
}
|
||||
|
||||
|
||||
.table-row-cell:selected {
|
||||
-fx-background-color: rgb(80, 80, 80);
|
||||
}
|
||||
.table-row-cell {
|
||||
-fx-background-color: #81c483;
|
||||
}
|
||||
.text-input:focused {
|
||||
-fx-highlight-text-fill: ladder(
|
||||
-fx-highlight-fill,
|
||||
-fx-light-text-color 45%,
|
||||
-fx-dark-text-color 46%,
|
||||
-fx-dark-text-color 59%,
|
||||
-fx-mid-text-color 60%
|
||||
);
|
||||
}
|
||||
@@ -266,6 +266,7 @@
|
||||
<left>
|
||||
</left>
|
||||
<stylesheets>
|
||||
<URL value="@/ninja/javafx/smartcsv/fx/dark-theme.css" />
|
||||
<URL value="@/ninja/javafx/smartcsv/fx/smartcsv.css" />
|
||||
</stylesheets>
|
||||
<bottom>
|
||||
|
||||
Reference in New Issue
Block a user