Return false if and only if the workarea information cannot be
obtained via the _NET_WORKAREA root window property. */
-#if !defined USE_GTK || GTK_MAJOR_VERSION < 3 + (GTK_MINOR_VERSION < 4)
+#if ! (defined USE_GTK && GTK_PREREQ (3, 4))
static bool
x_get_net_workarea (struct x_display_info *dpyinfo, XRectangle *rect)
{
/ x_display_pixel_height (dpyinfo));
gdpy = gdk_x11_lookup_xdisplay (dpyinfo->display);
gscreen = gdk_display_get_default_screen (gdpy);
-#if GTK_MAJOR_VERSION > 2 || GTK_MINOR_VERSION >= 20
+#if GTK_PREREQ (2, 20)
primary_monitor = gdk_screen_get_primary_monitor (gscreen);
#endif
n_monitors = gdk_screen_get_n_monitors (gscreen);
gdk_screen_get_monitor_geometry (gscreen, i, &rec);
geometry = list4i (rec.x, rec.y, rec.width, rec.height);
-#if GTK_MAJOR_VERSION > 2 || GTK_MINOR_VERSION >= 14
+#if GTK_PREREQ (2, 14)
width_mm = gdk_screen_get_monitor_width_mm (gscreen, i);
height_mm = gdk_screen_get_monitor_height_mm (gscreen, i);
#endif
list2i (width_mm, height_mm)),
attributes);
-#if GTK_MAJOR_VERSION > 3 || (GTK_MAJOR_VERSION == 3 && GTK_MINOR_VERSION >= 4)
+#if GTK_PREREQ (3, 4)
gdk_screen_get_monitor_workarea (gscreen, i, &rec);
workarea = list4i (rec.x, rec.y, rec.width, rec.height);
#else
attributes = Fcons (Fcons (Qworkarea, workarea), attributes);
attributes = Fcons (Fcons (Qgeometry, geometry), attributes);
-#if GTK_MAJOR_VERSION > 2 || (GTK_MAJOR_VERSION == 2 && GTK_MINOR_VERSION >= 14)
+#if GTK_PREREQ (2, 14)
{
char *name = gdk_screen_get_monitor_plug_name (gscreen, i);
if (name)