@@ -7,11 +7,9 @@ use cairo::{self, FontFace, FontSlant, FontWeight};
77use gio:: prelude:: * ;
88use gtk:: prelude:: * ;
99
10- use ux_primitives:: {
11- canvas:: { CanvasContext , Direction , LineCap , LineJoin , TextMetrics } ,
12- color:: { rgb, Color } ,
13- geom:: { Point , Rect , Size } ,
14- text:: { BaseLine , TextAlign , TextStyle , TextWeight } ,
10+ use primitives:: {
11+ BaseLine , CanvasContext , Color , Direction , LineCap , LineJoin , Point , Rect , RgbColor , Size ,
12+ TextAlign , TextMetrics , TextStyle , TextWeight ,
1513} ;
1614
1715pub struct CairoCanvas < ' a > {
@@ -48,7 +46,7 @@ impl<'a> CanvasContext for CairoCanvas<'a> {
4846 // }
4947
5048 fn set_fill_style_color ( & self , value : Color ) {
51- let color: rgb :: Color = value. into ( ) ;
49+ let color: RgbColor = value. into ( ) ;
5250 self . ctx . set_source_rgb (
5351 color. red as f64 / 255. ,
5452 color. green as f64 / 255. ,
@@ -212,7 +210,7 @@ impl<'a> CanvasContext for CairoCanvas<'a> {
212210 // }
213211
214212 fn set_stroke_style_color ( & self , value : Color ) {
215- let color: rgb :: Color = value. into ( ) ;
213+ let color: RgbColor = value. into ( ) ;
216214 self . ctx . set_source_rgb (
217215 color. red as f64 / 255. ,
218216 color. green as f64 / 255. ,
0 commit comments