notebook: Fix rounding error in vertical alignment of arrow

https://bugzilla.gnome.org/show_bug.cgi?id=707920
This commit is contained in:
William Jon McCann 2013-08-07 13:01:34 +02:00
parent e07fec3e83
commit b609377e3e

View File

@ -27,6 +27,7 @@
#include <stdio.h>
#include <string.h>
#include <math.h>
#include "gtknotebook.h"
@ -2713,7 +2714,7 @@ gtk_notebook_get_arrow_rect (GtkNotebook *notebook,
else
rectangle->x = event_window_pos.x + event_window_pos.width - 2 * rectangle->width;
}
rectangle->y = event_window_pos.y + (event_window_pos.height - rectangle->height) / 2;
rectangle->y = floor ((gdouble)event_window_pos.y + (event_window_pos.height - rectangle->height) / 2.0 + 0.5);
break;
}
}