@@ -196,17 +196,21 @@ private void initialize() {
196196
197197 calendarButton .setOnAction (ae -> calendarClicked ());
198198
199- calendarButton .textFillProperty ().bind (fontColorProperty );
200- calendarButton .setGraphic (SvgNodeProvider .getSvgNodeWithScale (RESOURCE .SVG_CALENDAR_DAYS_ICON , 0.03 , 0.03 ));
199+ SVGPath calendarSvgPath = SvgNodeProvider .getSvgNodeWithScale (RESOURCE .SVG_CALENDAR_DAYS_ICON , 0.03 , 0.03 );
200+ calendarSvgPath .fillProperty ().bind (fontColorProperty );
201+ calendarButton .setGraphic (calendarSvgPath );
201202
202- closeButton .textFillProperty ().bind (fontColorProperty );
203- closeButton .setGraphic (SvgNodeProvider .getSvgNodeWithScale (RESOURCE .SVG_CLOSE_ICON , 0.03 , 0.03 ));
203+ SVGPath closeSvgPath = SvgNodeProvider .getSvgNodeWithScale (RESOURCE .SVG_CLOSE_ICON , 0.03 , 0.03 );
204+ closeSvgPath .fillProperty ().bind (fontColorProperty );
205+ closeButton .setGraphic (closeSvgPath );
204206
205- settingsButton .textFillProperty ().bind (fontColorProperty );
206- settingsButton .setGraphic (SvgNodeProvider .getSvgNodeWithScale (RESOURCE .SVG_SETTINGS_ICON , 0.03 , 0.03 ));
207+ SVGPath settingsSvgPath = SvgNodeProvider .getSvgNodeWithScale (RESOURCE .SVG_SETTINGS_ICON , 0.03 , 0.03 );
208+ settingsSvgPath .fillProperty ().bind (fontColorProperty );
209+ settingsButton .setGraphic (settingsSvgPath );
207210
208- minimizeButton .textFillProperty ().bind (fontColorProperty );
209- minimizeButton .setGraphic (SvgNodeProvider .getSvgNodeWithScale (RESOURCE .SVG_MINUS_ICON , 0.03 , 0.03 ));
211+ SVGPath minimizeSvgPath = SvgNodeProvider .getSvgNodeWithScale (RESOURCE .SVG_MINUS_ICON , 0.03 , 0.03 );
212+ minimizeSvgPath .fillProperty ().bind (fontColorProperty );
213+ minimizeButton .setGraphic (minimizeSvgPath );
210214
211215 final Runnable updateMainBackgroundColor = this ::runUpdateMainBackgroundColor ;
212216
0 commit comments