mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-25 05:01:09 +00:00
Backed out change to close polygons since it caused problems for the
Sat Jan 31 00:13:33 1998 Owen Taylor <owt1@cornell.edu> * gtk/gtkstyle.c: Backed out change to close polygons since it caused problems for the Notebook.
This commit is contained in:
parent
b38b6f5f0f
commit
4ef94fd74e
@ -1,3 +1,8 @@
|
||||
Sat Jan 31 00:13:33 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkstyle.c: Backed out change to close polygons
|
||||
since it caused problems for the Notebook.
|
||||
|
||||
Fri Jan 30 22:28:09 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkclist.{c,h}:
|
||||
|
@ -1,3 +1,8 @@
|
||||
Sat Jan 31 00:13:33 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkstyle.c: Backed out change to close polygons
|
||||
since it caused problems for the Notebook.
|
||||
|
||||
Fri Jan 30 22:28:09 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkclist.{c,h}:
|
||||
|
@ -1,3 +1,8 @@
|
||||
Sat Jan 31 00:13:33 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkstyle.c: Backed out change to close polygons
|
||||
since it caused problems for the Notebook.
|
||||
|
||||
Fri Jan 30 22:28:09 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkclist.{c,h}:
|
||||
|
@ -1,3 +1,8 @@
|
||||
Sat Jan 31 00:13:33 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkstyle.c: Backed out change to close polygons
|
||||
since it caused problems for the Notebook.
|
||||
|
||||
Fri Jan 30 22:28:09 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkclist.{c,h}:
|
||||
|
@ -1,3 +1,8 @@
|
||||
Sat Jan 31 00:13:33 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkstyle.c: Backed out change to close polygons
|
||||
since it caused problems for the Notebook.
|
||||
|
||||
Fri Jan 30 22:28:09 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkclist.{c,h}:
|
||||
|
@ -1,3 +1,8 @@
|
||||
Sat Jan 31 00:13:33 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkstyle.c: Backed out change to close polygons
|
||||
since it caused problems for the Notebook.
|
||||
|
||||
Fri Jan 30 22:28:09 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkclist.{c,h}:
|
||||
|
@ -1,3 +1,8 @@
|
||||
Sat Jan 31 00:13:33 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkstyle.c: Backed out change to close polygons
|
||||
since it caused problems for the Notebook.
|
||||
|
||||
Fri Jan 30 22:28:09 1998 Owen Taylor <owt1@cornell.edu>
|
||||
|
||||
* gtk/gtkclist.{c,h}:
|
||||
|
@ -1186,27 +1186,19 @@ gtk_default_draw_polygon (GtkStyle *style,
|
||||
if (fill)
|
||||
gdk_draw_polygon (window, style->bg_gc[state_type], TRUE, points, npoints);
|
||||
|
||||
/* Check if polygon is closed */
|
||||
|
||||
if ((points[0].x == points[npoints-1].x) &&
|
||||
(points[0].y == points[npoints-1].y))
|
||||
npoints--;
|
||||
npoints--;
|
||||
|
||||
for (i = 0; i < npoints; i++)
|
||||
{
|
||||
GdkPoint *next;
|
||||
|
||||
next = (i == npoints-1) ? &points[0] : &points[i+1];
|
||||
|
||||
if ((points[i].x == next->x) &&
|
||||
(points[i].y == next->y))
|
||||
if ((points[i].x == points[i+1].x) &&
|
||||
(points[i].y == points[i+1].y))
|
||||
{
|
||||
angle = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
angle = atan2 (next->y - points[i].y,
|
||||
next->x - points[i].x);
|
||||
angle = atan2 (points[i+1].y - points[i].y,
|
||||
points[i+1].x - points[i].x);
|
||||
}
|
||||
|
||||
if ((angle > -pi_3_over_4) && (angle < pi_over_4))
|
||||
@ -1224,10 +1216,10 @@ gtk_default_draw_polygon (GtkStyle *style,
|
||||
|
||||
gdk_draw_line (window, gc1,
|
||||
points[i].x-xadjust, points[i].y-yadjust,
|
||||
next->x-xadjust, next->y-yadjust);
|
||||
points[i+1].x-xadjust, points[i+1].y-yadjust);
|
||||
gdk_draw_line (window, gc3,
|
||||
points[i].x, points[i].y,
|
||||
next->x, next->y);
|
||||
points[i+1].x, points[i+1].y);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -1244,10 +1236,10 @@ gtk_default_draw_polygon (GtkStyle *style,
|
||||
|
||||
gdk_draw_line (window, gc4,
|
||||
points[i].x+xadjust, points[i].y+yadjust,
|
||||
next->x+xadjust, next->y+yadjust);
|
||||
points[i+1].x+xadjust, points[i+1].y+yadjust);
|
||||
gdk_draw_line (window, gc2,
|
||||
points[i].x, points[i].y,
|
||||
next->x, next->y);
|
||||
points[i+1].x, points[i+1].y);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user