Skip to content

Commit

Permalink
Inset and outset border coloring is incorrect on left side border.
Browse files Browse the repository at this point in the history
This patch will fix this issue.
  • Loading branch information
Adenilson authored and Adenilson Cavalcanti committed Dec 16, 2014
1 parent 905c30d commit 0e24194
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions components/gfx/paint_context.rs
Original file line number Diff line number Diff line change
Expand Up @@ -642,8 +642,7 @@ impl<'a> PaintContext<'a> {
let original_bounds = self.get_scaled_bounds(bounds, border, 0.0);
// select and scale the color appropriately.
let scaled_color = match direction {
Top => self.scale_color(color, if is_inset { 2.0/3.0 } else { 1.0 }),
Left => self.scale_color(color, if is_inset { 1.0/6.0 } else { 0.5 }),
Top | Left => self.scale_color(color, if is_inset { 2.0/3.0 } else { 1.0 }),
Right | Bottom => self.scale_color(color, if is_inset { 1.0 } else { 2.0/3.0 })
};
self.draw_border_path(&original_bounds, direction, border, radius, scaled_color);
Expand Down

0 comments on commit 0e24194

Please sign in to comment.