@@ -61,10 +61,10 @@ impl App {
6161 } ,
6262 ]
6363 }
64- pub fn render ( & self , show_icons : bool ) -> impl Into < iced:: Element < ' _ , Message > > {
64+ pub fn render ( & self , theme : & crate :: config :: Theme ) -> impl Into < iced:: Element < ' _ , Message > > {
6565 let mut tile = Row :: new ( ) . width ( Fill ) . height ( 55 ) ;
6666
67- if show_icons {
67+ if theme . show_icons {
6868 if let Some ( icon) = & self . icons {
6969 tile = tile
7070 . push ( Viewer :: new ( icon) . height ( 35 ) . width ( 35 ) )
@@ -83,6 +83,7 @@ impl App {
8383 Text :: new ( & self . name )
8484 . height ( Fill )
8585 . width ( Fill )
86+ . color ( theme. text_color ( 1. ) )
8687 . align_y ( Vertical :: Center ) ,
8788 )
8889 . on_press ( Message :: RunFunction ( self . open_command . clone ( ) ) )
@@ -98,7 +99,7 @@ impl App {
9899 ) ;
99100
100101 tile = tile
101- . push ( container ( Text :: new ( & self . desc ) ) . padding ( 15 ) )
102+ . push ( container ( Text :: new ( & self . desc ) . color ( theme . text_color ( 0.4 ) ) ) . padding ( 15 ) )
102103 . width ( Fill ) ;
103104
104105 container ( tile)
@@ -204,7 +205,7 @@ impl Tile {
204205 frontmost : None ,
205206 focused : false ,
206207 config : config. clone ( ) ,
207- theme : config. theme . to_owned ( ) . to_iced_theme ( ) ,
208+ theme : config. theme . to_owned ( ) . into ( ) ,
208209 open_hotkey_id : keybind_id,
209210 } ,
210211 Task :: batch ( [ open. map ( |_| Message :: OpenWindow ) ] ) ,
@@ -394,8 +395,7 @@ impl Tile {
394395
395396 let mut search_results = Column :: new ( ) ;
396397 for result in & self . results {
397- search_results =
398- search_results. push ( result. render ( self . config . theme . clone ( ) . show_icons ) ) ;
398+ search_results = search_results. push ( result. render ( & self . config . theme ) ) ;
399399 }
400400
401401 Column :: new ( )
0 commit comments