pub fn fill (&self, x: i32 , y: i32, color: Color){
        self.undo_save();  //save state for undo
        let mut image = if self.mask_flag.get() { self.mask.borrow_mut()} else {self.image.borrow_mut()};
        //take care of panning
        let Rect {x: panx, y: pany, ..} = self.view.get();
        
        image.fill(x + panx, y + pany, color);
    }
///wrapper for filling an image within a canvas with pan support
wrapper for filling an image within a canvas with pan support
wrapper for filling an image within a canvas with pan support
pub fn fill (&self, x: i32 , y: i32, color: Color){
        self.undo_save();  //save state for undo
        let mut image = if self.mask_flag.get() { self.mask.borrow_mut()} else {self.image.borrow_mut()};
        //take care of panning
        let Rect {x: panx, y: pany, ..} = self.view.get();
        image.fill(x + panx, y + pany, color);
    }
pub fn fill ( & self , x : i32 , y : i32 , color : Color ) { self . undo_save ( ) ; //save state for undo let mut image = if self . mask_flag . get ( ) { self . mask . borrow_mut ( ) } else { self . image . borrow_mut ( ) } ; //take care of panning let Rect { x : panx , y : pany , .. } = self . view . get ( ) ; image . fill ( x + panx , y + pany , color ) ; }
wrapper for filling an image within a canvas with pan support
wrapper for filling an image within a canvas with pan support
&self
x
i32
y
i32
color
Color
&self
x
i32
y
i32
color
Color