File tree 2 files changed +4
-4
lines changed
2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ def __init__(
42
42
super ().__init__ (parent = parent )
43
43
self .viewer = napari_viewer
44
44
self .napari_theme_style_sheet = style_sheet_from_theme (
45
- get_theme (napari_viewer .theme , as_dict = False )
45
+ get_theme (napari_viewer .theme )
46
46
)
47
47
48
48
# Sets figure.* style
@@ -84,7 +84,7 @@ def _on_napari_theme_changed(self, event: Event) -> None:
84
84
Event that triggered the callback.
85
85
"""
86
86
self .napari_theme_style_sheet = style_sheet_from_theme (
87
- get_theme (event .value , as_dict = False )
87
+ get_theme (event .value )
88
88
)
89
89
self ._replace_toolbar_icons ()
90
90
@@ -97,7 +97,7 @@ def _napari_theme_has_light_bg(self) -> bool:
97
97
bool
98
98
True if theme's background colour has hsl lighter than 50%, False if darker.
99
99
"""
100
- theme = napari .utils .theme .get_theme (self .viewer .theme , as_dict = False )
100
+ theme = napari .utils .theme .get_theme (self .viewer .theme )
101
101
_ , _ , bg_lightness = theme .background .as_hsl_tuple ()
102
102
return bg_lightness > 0.5
103
103
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ def _mock_up_theme() -> None:
29
29
Based on:
30
30
https://napari.org/stable/gallery/new_theme.html
31
31
"""
32
- blue_theme = napari .utils .theme .get_theme ("dark" , False )
32
+ blue_theme = napari .utils .theme .get_theme ("dark" )
33
33
blue_theme .label = "blue"
34
34
blue_theme .background = "#4169e1" # my favourite shade of blue
35
35
napari .utils .theme .register_theme (
You can’t perform that action at this time.
0 commit comments