diff options
author | Tor Lillqvist <tml@iki.fi> | 2004-03-31 00:39:59 +0000 |
---|---|---|
committer | Tor Lillqvist <tml@src.gnome.org> | 2004-03-31 00:39:59 +0000 |
commit | 706e690288a6695d0e72be4dc66b1b6cb7ca0079 (patch) | |
tree | a2d54c0a8f2fcff4d5b582f18d68525bfd9ed3b0 | |
parent | c56787f9b523d8aae5845347944cf698658c2346 (diff) | |
download | gtk+-gtk-2-2.tar.gz |
Use X11 semantics for angles. Thanks to Tim Newsham.gtk-2-2
2004-03-31 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkdrawable-win32.c (draw_arc): Use X11 semantics for
angles. Thanks to Tim Newsham.
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | ChangeLog.pre-2-10 | 5 | ||||
-rw-r--r-- | ChangeLog.pre-2-4 | 5 | ||||
-rw-r--r-- | ChangeLog.pre-2-6 | 5 | ||||
-rw-r--r-- | ChangeLog.pre-2-8 | 5 | ||||
-rw-r--r-- | gdk/win32/gdkdrawable-win32.c | 26 |
6 files changed, 36 insertions, 15 deletions
@@ -1,3 +1,8 @@ +2004-03-31 Tor Lillqvist <tml@iki.fi> + + * gdk/win32/gdkdrawable-win32.c (draw_arc): Use X11 semantics for + angles. Thanks to Tim Newsham. + 2004-03-15 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkgc-win32.c (gdk_gc_copy): Don't just copy the whole diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index ca36e8411b..9d1de90347 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,8 @@ +2004-03-31 Tor Lillqvist <tml@iki.fi> + + * gdk/win32/gdkdrawable-win32.c (draw_arc): Use X11 semantics for + angles. Thanks to Tim Newsham. + 2004-03-15 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkgc-win32.c (gdk_gc_copy): Don't just copy the whole diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index ca36e8411b..9d1de90347 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,8 @@ +2004-03-31 Tor Lillqvist <tml@iki.fi> + + * gdk/win32/gdkdrawable-win32.c (draw_arc): Use X11 semantics for + angles. Thanks to Tim Newsham. + 2004-03-15 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkgc-win32.c (gdk_gc_copy): Don't just copy the whole diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index ca36e8411b..9d1de90347 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,8 @@ +2004-03-31 Tor Lillqvist <tml@iki.fi> + + * gdk/win32/gdkdrawable-win32.c (draw_arc): Use X11 semantics for + angles. Thanks to Tim Newsham. + 2004-03-15 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkgc-win32.c (gdk_gc_copy): Don't just copy the whole diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index ca36e8411b..9d1de90347 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,8 @@ +2004-03-31 Tor Lillqvist <tml@iki.fi> + + * gdk/win32/gdkdrawable-win32.c (draw_arc): Use X11 semantics for + angles. Thanks to Tim Newsham. + 2004-03-15 Tor Lillqvist <tml@iki.fi> * gdk/win32/gdkgc-win32.c (gdk_gc_copy): Don't just copy the whole diff --git a/gdk/win32/gdkdrawable-win32.c b/gdk/win32/gdkdrawable-win32.c index 14d76d43d4..59488b33fe 100644 --- a/gdk/win32/gdkdrawable-win32.c +++ b/gdk/win32/gdkdrawable-win32.c @@ -801,12 +801,9 @@ draw_arc (GdkGCWin32 *gcwin32, { HGDIOBJ old_pen; gboolean filled; - gint x; - gint y; - gint width; - gint height; - gint angle1; - gint angle2; + gint x, y; + gint width, height; + gint angle1, angle2; int nXStartArc, nYStartArc, nXEndArc, nYEndArc; filled = va_arg (args, gboolean); @@ -826,18 +823,17 @@ draw_arc (GdkGCWin32 *gcwin32, } else if (angle2 > 0) { - /* The 100. is just an arbitrary value */ - nXStartArc = x + width/2 + 100. * cos(angle1/64.*2.*G_PI/360.); - nYStartArc = y + height/2 + -100. * sin(angle1/64.*2.*G_PI/360.); - nXEndArc = x + width/2 + 100. * cos((angle1+angle2)/64.*2.*G_PI/360.); - nYEndArc = y + height/2 + -100. * sin((angle1+angle2)/64.*2.*G_PI/360.); + nXStartArc = x + width/2 + width * cos(angle1/64.*2.*G_PI/360.); + nYStartArc = y + height/2 + -height * sin(angle1/64.*2.*G_PI/360.); + nXEndArc = x + width/2 + width * cos((angle1+angle2)/64.*2.*G_PI/360.); + nYEndArc = y + height/2 + -height * sin((angle1+angle2)/64.*2.*G_PI/360.); } else { - nXEndArc = x + width/2 + 100. * cos(angle1/64.*2.*G_PI/360.); - nYEndArc = y + height/2 + -100. * sin(angle1/64.*2.*G_PI/360.); - nXStartArc = x + width/2 + 100. * cos((angle1+angle2)/64.*2.*G_PI/360.); - nYStartArc = y + height/2 + -100. * sin((angle1+angle2)/64.*2.*G_PI/360.); + nXEndArc = x + width/2 + width * cos(angle1/64.*2.*G_PI/360.); + nYEndArc = y + height/2 + -height * sin(angle1/64.*2.*G_PI/360.); + nXStartArc = x + width/2 + width * cos((angle1+angle2)/64.*2.*G_PI/360.); + nYStartArc = y + height/2 + -height * sin((angle1+angle2)/64.*2.*G_PI/360.); } if (filled) |