From: Philipp Zabel Date: Sat, 27 Feb 2010 09:13:41 +0000 (+0100) Subject: LED color widget: fix the clipping circle X-Git-Tag: v0.0.2~5 X-Git-Url: https://vcs.maemo.org/git/?p=led-pattern-ed;a=commitdiff_plain;h=50a29ffbfbe999167f07324b2bc18aa8a7ec2d84 LED color widget: fix the clipping circle --- diff --git a/src/led-color-widgets.vala b/src/led-color-widgets.vala index 258faec..867b3ab 100644 --- a/src/led-color-widgets.vala +++ b/src/led-color-widgets.vala @@ -47,7 +47,7 @@ class LedColorWidget : Gtk.DrawingArea { ctx.clip (); ctx.new_path (); - ctx.arc (width / 2.0, height / 2.0, width / 2.0, 0, 2 * Math.PI); + ctx.arc (width / 2.0, height / 2.0, Math.fmin (width, height) / 2.0, 0, 2 * Math.PI); ctx.clip ();