[gtk+/wip/alexl/no-offscreen] Drop support for offscreen GdkWindows



commit 70935f09526ba9f1d0b2f6af10e18712df73eda9
Author: Alexander Larsson <alexl redhat com>
Date:   Tue Oct 25 09:54:37 2016 +0200

    Drop support for offscreen GdkWindows
    
    These complicate a lot of GdkWindow internals to implement features
    that not a lot of apps use, and will be better achieved using gsk.
    So, we just drop it all.

 demos/gtk-demo/Makefile.am             |    2 -
 demos/gtk-demo/demo.gresource.xml      |    2 -
 demos/gtk-demo/offscreen_window.c      |  586 ------------------------
 demos/gtk-demo/offscreen_window2.c     |  503 ---------------------
 docs/reference/gdk/gdk4-sections.txt   |    6 -
 docs/reference/gtk/gtk-docs.sgml       |    1 -
 docs/reference/gtk/gtk4-sections.txt   |   20 -
 gdk/Makefile.am                        |    1 -
 gdk/broadway/gdkdisplay-broadway.h     |    3 -
 gdk/broadway/gdkwindow-broadway.c      |    6 +-
 gdk/gdkdevice.c                        |   12 -
 gdk/gdkinternals.h                     |   13 -
 gdk/gdkoffscreenwindow.c               |  764 --------------------------------
 gdk/gdkwindow.c                        |  523 ++--------------------
 gdk/gdkwindow.h                        |   39 --
 gdk/gdkwindowimpl.c                    |    2 +-
 gdk/makefile.msc                       |    1 -
 gdk/mir/gdkmirwindowimpl.c             |    4 +-
 gdk/quartz/gdkdevice-core-quartz.c     |    4 +-
 gdk/quartz/gdkevents-quartz.c          |    7 +-
 gdk/quartz/gdkscreen-quartz.c          |    6 +-
 gdk/quartz/gdkwindow-quartz.c          |    7 +-
 gdk/wayland/gdkdevice-wayland.c        |   12 -
 gdk/wayland/gdkwindow-wayland.c        |   14 +-
 gdk/win32/gdkdnd-win32.c               |    3 -
 gdk/win32/gdkwindow-win32.c            |    3 +-
 gdk/x11/gdkdisplay-x11.h               |    3 -
 gdk/x11/gdkdnd-x11.c                   |    3 -
 gdk/x11/gdkwindow-x11.c                |    3 -
 gtk/Makefile.am                        |    2 -
 gtk/gtk-autocleanups.h                 |    1 -
 gtk/gtk.h                              |    1 -
 gtk/gtkdnd-quartz.c                    |    4 +-
 gtk/gtkflowbox.c                       |    2 +-
 gtk/gtkgesture.c                       |    6 +-
 gtk/gtklistbox.c                       |    2 +-
 gtk/gtkoffscreenwindow.c               |  308 -------------
 gtk/gtkoffscreenwindow.h               |   74 ---
 gtk/gtkscrolledwindow.c                |    2 +-
 gtk/gtktooltip.c                       |    2 +-
 gtk/gtkwidget.c                        |   12 +-
 gtk/gtkwindow.c                        |    1 -
 gtk/makefile.msc.in                    |    2 -
 tests/Makefile.am                      |   12 -
 tests/gtkoffscreenbox.c                |  683 ----------------------------
 tests/gtkoffscreenbox.h                |   52 ---
 tests/makefile.msc                     |    6 +-
 tests/testoffscreen.c                  |  377 ----------------
 tests/testoffscreenwindow.c            |   87 ----
 testsuite/gtk/notify.c                 |    4 -
 testsuite/gtk/treeview.c               |    2 +-
 testsuite/reftests/label-sizing.ref.ui |    2 +-
 testsuite/reftests/label-sizing.ui     |    2 +-
 53 files changed, 79 insertions(+), 4120 deletions(-)
---
diff --git a/demos/gtk-demo/Makefile.am b/demos/gtk-demo/Makefile.am
index f470fc8..b873418 100644
--- a/demos/gtk-demo/Makefile.am
+++ b/demos/gtk-demo/Makefile.am
@@ -43,8 +43,6 @@ demos_base =                                  \
        markup.c                                \
        menus.c                                 \
        modelbutton.c                           \
-       offscreen_window.c                      \
-       offscreen_window2.c                     \
        overlay.c                               \
        overlay2.c                              \
        panes.c                                 \
diff --git a/demos/gtk-demo/demo.gresource.xml b/demos/gtk-demo/demo.gresource.xml
index f0c7201..3bd3d9f 100644
--- a/demos/gtk-demo/demo.gresource.xml
+++ b/demos/gtk-demo/demo.gresource.xml
@@ -167,8 +167,6 @@
     <file>markup.c</file>
     <file>menus.c</file>
     <file>modelbutton.c</file>
-    <file>offscreen_window.c</file>
-    <file>offscreen_window2.c</file>
     <file>overlay.c</file>
     <file>overlay2.c</file>
     <file>pagesetup.c</file>
diff --git a/docs/reference/gdk/gdk4-sections.txt b/docs/reference/gdk/gdk4-sections.txt
index 079fca6..d6fda17 100644
--- a/docs/reference/gdk/gdk4-sections.txt
+++ b/docs/reference/gdk/gdk4-sections.txt
@@ -484,14 +484,8 @@ gdk_window_get_event_compression
 gdk_window_set_event_compression
 
 <SUBSECTION>
-gdk_offscreen_window_get_surface
-gdk_offscreen_window_set_embedder
-gdk_offscreen_window_get_embedder
-gdk_window_geometry_changed
 gdk_window_coords_from_parent
 gdk_window_coords_to_parent
-gdk_window_get_effective_parent
-gdk_window_get_effective_toplevel
 
 <SUBSECTION Standard>
 GDK_WINDOW
diff --git a/docs/reference/gtk/gtk-docs.sgml b/docs/reference/gtk/gtk-docs.sgml
index 0e5030b..749d880 100644
--- a/docs/reference/gtk/gtk-docs.sgml
+++ b/docs/reference/gtk/gtk-docs.sgml
@@ -62,7 +62,6 @@
       <xi:include href="xml/gtkaboutdialog.xml" />
       <xi:include href="xml/gtkassistant.xml" />
       <xi:include href="xml/gtkinvisible.xml" />
-      <xi:include href="xml/gtkoffscreenwindow.xml" />
       <xi:include href="xml/gtkwindowgroup.xml" />
     </chapter>
 
diff --git a/docs/reference/gtk/gtk4-sections.txt b/docs/reference/gtk/gtk4-sections.txt
index a159bdd..55af959 100644
--- a/docs/reference/gtk/gtk4-sections.txt
+++ b/docs/reference/gtk/gtk4-sections.txt
@@ -2123,26 +2123,6 @@ GtkNotebookPrivate
 </SECTION>
 
 <SECTION>
-<FILE>gtkoffscreenwindow</FILE>
-<TITLE>GtkOffscreenWindow</TITLE>
-GtkOffscreenWindow
-GtkOffscreenWindowClass
-gtk_offscreen_window_new
-gtk_offscreen_window_get_surface
-gtk_offscreen_window_get_pixbuf
-<SUBSECTION Standard>
-GTK_OFFSCREEN_WINDOW
-GTK_IS_OFFSCREEN_WINDOW
-GTK_TYPE_OFFSCREEN_WINDOW
-GTK_OFFSCREEN_WINDOW_CLASS
-GTK_IS_OFFSCREEN_WINDOW_CLASS
-GTK_OFFSCREEN_WINDOW_GET_CLASS
-
-<SUBSECTION Private>
-gtk_offscreen_window_get_type
-</SECTION>
-
-<SECTION>
 <FILE>gtkpaned</FILE>
 <TITLE>GtkPaned</TITLE>
 GtkPaned
diff --git a/gdk/Makefile.am b/gdk/Makefile.am
index d309089..538d113 100644
--- a/gdk/Makefile.am
+++ b/gdk/Makefile.am
@@ -161,7 +161,6 @@ gdk_c_sources =                             \
        gdkkeys.c                               \
        gdkkeyuni.c                             \
        gdkmonitor.c                            \
-       gdkoffscreenwindow.c                    \
        gdkframeclock.c                         \
        gdkframeclockidle.c                     \
        gdkpango.c                              \
diff --git a/gdk/broadway/gdkdisplay-broadway.h b/gdk/broadway/gdkdisplay-broadway.h
index 38a9968..d8b094c 100644
--- a/gdk/broadway/gdkdisplay-broadway.h
+++ b/gdk/broadway/gdkdisplay-broadway.h
@@ -51,9 +51,6 @@ struct _GdkBroadwayDisplay
   /* drag and drop information */
   GdkDragContext *current_dest_drag;
 
-  /* The offscreen window that has the pointer in it (if any) */
-  GdkWindow *active_offscreen_window;
-
   GdkBroadwayServer *server;
 
   gpointer move_resize_data;
diff --git a/gdk/broadway/gdkwindow-broadway.c b/gdk/broadway/gdkwindow-broadway.c
index 7b478ce..9044144 100644
--- a/gdk/broadway/gdkwindow-broadway.c
+++ b/gdk/broadway/gdkwindow-broadway.c
@@ -48,13 +48,11 @@ static void        gdk_window_impl_broadway_finalize   (GObject            *obje
 static const cairo_user_data_key_t gdk_broadway_cairo_key;
 
 #define WINDOW_IS_TOPLEVEL_OR_FOREIGN(window) \
-  (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD &&   \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_OFFSCREEN)
+  (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD)
 
 #define WINDOW_IS_TOPLEVEL(window)                  \
   (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD &&   \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN && \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_OFFSCREEN)
+   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN)
 
 struct _GdkBroadwayWindow {
   GdkWindow parent;
diff --git a/gdk/gdkdevice.c b/gdk/gdkdevice.c
index e489d5a..13451a5 100644
--- a/gdk/gdkdevice.c
+++ b/gdk/gdkdevice.c
@@ -1456,18 +1456,6 @@ gdk_device_grab (GdkDevice        *device,
 
   native = gdk_window_get_toplevel (window);
 
-  while (native->window_type == GDK_WINDOW_OFFSCREEN)
-    {
-      native = gdk_offscreen_window_get_embedder (native);
-
-      if (native == NULL ||
-          (!_gdk_window_has_impl (native) &&
-           !gdk_window_is_viewable (native)))
-        return GDK_GRAB_NOT_VIEWABLE;
-
-      native = gdk_window_get_toplevel (native);
-    }
-
   if (native == NULL || GDK_WINDOW_DESTROYED (native))
     return GDK_GRAB_NOT_VIEWABLE;
 
diff --git a/gdk/gdkinternals.h b/gdk/gdkinternals.h
index ad59f76..b9b113c 100644
--- a/gdk/gdkinternals.h
+++ b/gdk/gdkinternals.h
@@ -309,8 +309,6 @@ struct _GdkWindow
   gint shadow_right;
   gint shadow_bottom;
 
-  guint num_offscreen_children;
-
   /* The clip region is the part of the window, in window coordinates
      that is fully or partially (i.e. semi transparently) visible in
      the window hierarchy from the toplevel and down */
@@ -492,17 +490,6 @@ void _gdk_synthesize_crossing_events_for_geometry_change (GdkWindow *changed_win
 gboolean    _gdk_window_has_impl (GdkWindow *window);
 GdkWindow * _gdk_window_get_impl_window (GdkWindow *window);
 
-/*****************************
- * offscreen window routines *
- *****************************/
-GType gdk_offscreen_window_get_type (void);
-void       _gdk_offscreen_window_new                 (GdkWindow     *window,
-                                                      GdkWindowAttr *attributes,
-                                                      gint           attributes_mask);
-cairo_surface_t * _gdk_offscreen_window_create_surface (GdkWindow *window,
-                                                        gint       width,
-                                                        gint       height);
-
 G_END_DECLS
 
 #endif /* __GDK_INTERNALS_H__ */
diff --git a/gdk/gdkwindow.c b/gdk/gdkwindow.c
index 6697a53..febc3c0 100644
--- a/gdk/gdkwindow.c
+++ b/gdk/gdkwindow.c
@@ -68,24 +68,6 @@
  * window, the thing a user might think of as a “window” with a titlebar
  * and so on; a #GtkWindow may contain many #GdkWindows. For example,
  * each #GtkButton has a #GdkWindow associated with it.
- *
- * # Offscreen Windows # {#OFFSCREEN-WINDOWS}
- *
- * Offscreen windows are more general than composited windows, since
- * they allow not only to modify the rendering of the child window onto
- * its parent, but also to apply coordinate transformations.
- *
- * To integrate an offscreen window into a window hierarchy, one has
- * to call gdk_offscreen_window_set_embedder() and handle a number of
- * signals. The #GdkWindow::pick-embedded-child signal on the embedder
- * window is used to select an offscreen child at given coordinates,
- * and the #GdkWindow::to-embedder and #GdkWindow::from-embedder signals
- * on the offscreen window are used to translate coordinates between
- * the embedder and the offscreen window.
- *
- * For rendering an offscreen window onto its embedder, the contents
- * of the offscreen window are available as a surface, via
- * gdk_offscreen_window_get_surface().
  */
 
 
@@ -95,23 +77,18 @@
  * and the actual platform specific implementation was in a delegate
  * object available as “impl” in the window object.
  *
- * With the addition of client side windows and offscreen windows this
- * changes a bit. The application-visible GdkWindow object behaves as
- * it did before, but not all such windows now have a corresponding native
- * window. Instead windows that are “client side” are emulated by the gdk
- * code such that clipping, drawing, moving, events etc work as expected.
+ * With the addition of client side windows this changes a bit. The
+ * application-visible GdkWindow object behaves as it did before, but
+ * not all such windows now have a corresponding native
+ * window. Instead windows that are “client side” are emulated by the
+ * gdk code such that clipping, drawing, moving, events etc work as
+ * expected.
  *
  * For GdkWindows that have a native window the “impl” object is the
  * same as before. However, for all client side windows the impl object
  * is shared with its parent (i.e. all client windows descendants of one
  * native window has the same impl.
  *
- * Additionally there is a new type of platform independent impl object,
- * GdkOffscreenWindow. All windows of type GDK_WINDOW_OFFSCREEN get an impl
- * of this type (while their children are generally GDK_WINDOW_CHILD virtual
- * windows). Such windows work by allocating a #cairo_surface_t as the backing
- * store for drawing operations, which is resized with the window.
- *
  * GdkWindows have a pointer to the “impl window” they are in, i.e.
  * the topmost GdkWindow which have the same “impl” value. This is stored
  * in impl_window, which is different from the window itself only for client
@@ -121,10 +98,10 @@
  * with respect to the impl window (abs_x, abs_y). We also track the clip
  * region of the window wrt parent windows, in window-relative coordinates (clip_region).
  *
- * All toplevel windows are native windows, but also child windows can be
- * native (although not children of offscreens). We always listen to
- * a basic set of events (see get_native_event_mask) for these windows
- * so that we can emulate events for any client side children.
+ * All toplevel windows are native windows, but also child windows can
+ * be native. We always listen to a basic set of events (see
+ * get_native_event_mask) for these windows so that we can emulate
+ * events for any client side children.
  *
  * For native windows we apply the calculated clip region as a window shape
  * so that eg. client side siblings that overlap the native child properly
@@ -135,10 +112,6 @@
 #define GDK_VISIBILITY_NOT_VIEWABLE 3
 
 enum {
-  PICK_EMBEDDED_CHILD, /* only called if children are embedded */
-  TO_EMBEDDER,
-  FROM_EMBEDDER,
-  CREATE_SURFACE,
   MOVED_TO_RECT,
   LAST_SIGNAL
 };
@@ -286,30 +259,6 @@ gdk_window_init (GdkWindow *window)
                                                  NULL, g_object_unref);
 }
 
-/* Stop and return on the first non-NULL parent */
-static gboolean
-accumulate_get_window (GSignalInvocationHint *ihint,
-                      GValue                  *return_accu,
-                      const GValue            *handler_return,
-                      gpointer               data)
-{
-  g_value_copy (handler_return, return_accu);
-  /* Continue while returning NULL */
-  return g_value_get_object (handler_return) == NULL;
-}
-
-static gboolean
-create_surface_accumulator (GSignalInvocationHint *ihint,
-                            GValue                *return_accu,
-                            const GValue          *handler_return,
-                            gpointer               data)
-{
-  g_value_copy (handler_return, return_accu);
-
-  /* Stop on the first non-NULL return value */
-  return g_value_get_boxed (handler_return) == NULL;
-}
-
 static GQuark quark_pointer_window = 0;
 
 static void
@@ -321,8 +270,6 @@ gdk_window_class_init (GdkWindowClass *klass)
   object_class->set_property = gdk_window_set_property;
   object_class->get_property = gdk_window_get_property;
 
-  klass->create_surface = _gdk_offscreen_window_create_surface;
-
   quark_pointer_window = g_quark_from_static_string ("gtk-pointer-window");
 
 
@@ -345,127 +292,6 @@ gdk_window_class_init (GdkWindowClass *klass)
   g_object_class_install_properties (object_class, LAST_PROP, properties);
 
   /**
-   * GdkWindow::pick-embedded-child:
-   * @window: the window on which the signal is emitted
-   * @x: x coordinate in the window
-   * @y: y coordinate in the window
-   *
-   * The ::pick-embedded-child signal is emitted to find an embedded
-   * child at the given position.
-   *
-   * Returns: (nullable) (transfer none): the #GdkWindow of the
-   *     embedded child at @x, @y, or %NULL
-   *
-   * Since: 2.18
-   */
-  signals[PICK_EMBEDDED_CHILD] =
-    g_signal_new (g_intern_static_string ("pick-embedded-child"),
-                 G_OBJECT_CLASS_TYPE (object_class),
-                 G_SIGNAL_RUN_LAST,
-                  G_STRUCT_OFFSET (GdkWindowClass, pick_embedded_child),
-                 accumulate_get_window, NULL,
-                 _gdk_marshal_OBJECT__DOUBLE_DOUBLE,
-                 GDK_TYPE_WINDOW,
-                 2,
-                 G_TYPE_DOUBLE,
-                 G_TYPE_DOUBLE);
-
-  /**
-   * GdkWindow::to-embedder:
-   * @window: the offscreen window on which the signal is emitted
-   * @offscreen_x: x coordinate in the offscreen window
-   * @offscreen_y: y coordinate in the offscreen window
-   * @embedder_x: (out) (type double): return location for the x
-   *     coordinate in the embedder window
-   * @embedder_y: (out) (type double): return location for the y
-   *     coordinate in the embedder window
-   *
-   * The ::to-embedder signal is emitted to translate coordinates
-   * in an offscreen window to its embedder.
-   *
-   * See also #GdkWindow::from-embedder.
-   *
-   * Since: 2.18
-   */
-  signals[TO_EMBEDDER] =
-    g_signal_new (g_intern_static_string ("to-embedder"),
-                 G_OBJECT_CLASS_TYPE (object_class),
-                 G_SIGNAL_RUN_LAST,
-                  G_STRUCT_OFFSET (GdkWindowClass, to_embedder),
-                 NULL, NULL,
-                 _gdk_marshal_VOID__DOUBLE_DOUBLE_POINTER_POINTER,
-                 G_TYPE_NONE,
-                 4,
-                 G_TYPE_DOUBLE,
-                 G_TYPE_DOUBLE,
-                 G_TYPE_POINTER,
-                 G_TYPE_POINTER);
-
-  /**
-   * GdkWindow::from-embedder:
-   * @window: the offscreen window on which the signal is emitted
-   * @embedder_x: x coordinate in the embedder window
-   * @embedder_y: y coordinate in the embedder window
-   * @offscreen_x: (out) (type double): return location for the x
-   *     coordinate in the offscreen window
-   * @offscreen_y: (out) (type double): return location for the y
-   *     coordinate in the offscreen window
-   *
-   * The ::from-embedder signal is emitted to translate coordinates
-   * in the embedder of an offscreen window to the offscreen window.
-   *
-   * See also #GdkWindow::to-embedder.
-   *
-   * Since: 2.18
-   */
-  signals[FROM_EMBEDDER] =
-    g_signal_new (g_intern_static_string ("from-embedder"),
-                 G_OBJECT_CLASS_TYPE (object_class),
-                 G_SIGNAL_RUN_LAST,
-                  G_STRUCT_OFFSET (GdkWindowClass, from_embedder),
-                 NULL, NULL,
-                 _gdk_marshal_VOID__DOUBLE_DOUBLE_POINTER_POINTER,
-                 G_TYPE_NONE,
-                 4,
-                 G_TYPE_DOUBLE,
-                 G_TYPE_DOUBLE,
-                 G_TYPE_POINTER,
-                 G_TYPE_POINTER);
-
-  /**
-   * GdkWindow::create-surface:
-   * @window: the offscreen window on which the signal is emitted
-   * @width: the width of the offscreen surface to create
-   * @height: the height of the offscreen surface to create
-   *
-   * The ::create-surface signal is emitted when an offscreen window
-   * needs its surface (re)created, which happens either when the
-   * window is first drawn to, or when the window is being
-   * resized. The first signal handler that returns a non-%NULL
-   * surface will stop any further signal emission, and its surface
-   * will be used.
-   *
-   * Note that it is not possible to access the window's previous
-   * surface from within any callback of this signal. Calling
-   * gdk_offscreen_window_get_surface() will lead to a crash.
-   *
-   * Returns: the newly created #cairo_surface_t for the offscreen window
-   *
-   * Since: 3.0
-   */
-  signals[CREATE_SURFACE] =
-    g_signal_new (g_intern_static_string ("create-surface"),
-                  G_OBJECT_CLASS_TYPE (object_class),
-                  G_SIGNAL_RUN_LAST,
-                  G_STRUCT_OFFSET (GdkWindowClass, create_surface),
-                  create_surface_accumulator, NULL,
-                  _gdk_marshal_BOXED__INT_INT,
-                  CAIRO_GOBJECT_TYPE_SURFACE,
-                  2,
-                  G_TYPE_INT,
-                  G_TYPE_INT);
-
-  /**
    * GdkWindow::moved-to-rect:
    * @window: the #GdkWindow that moved
    * @flipped_rect: (nullable): the position of @window after any possible
@@ -618,12 +444,6 @@ gdk_window_get_property (GObject    *object,
     }
 }
 
-static gboolean
-gdk_window_is_offscreen (GdkWindow *window)
-{
-  return window->window_type == GDK_WINDOW_OFFSCREEN;
-}
-
 static GdkWindow *
 gdk_window_get_impl_window (GdkWindow *window)
 {
@@ -691,11 +511,6 @@ remove_sibling_overlapped_area (GdkWindow *window,
       if (!GDK_WINDOW_IS_MAPPED (sibling) || sibling->input_only)
        continue;
 
-      /* Ignore offscreen children, as they don't draw in their parent and
-       * don't take part in the clipping */
-      if (gdk_window_is_offscreen (sibling))
-       continue;
-
       r.x = sibling->x;
       r.y = sibling->y;
       r.width = sibling->width;
@@ -753,11 +568,6 @@ remove_child_area (GdkWindow *window,
       if (!GDK_WINDOW_IS_MAPPED (child) || child->input_only)
        continue;
 
-      /* Ignore offscreen children, as they don't draw in their parent and
-       * don't take part in the clipping */
-      if (gdk_window_is_offscreen (child))
-       continue;
-
       r.x = child->x;
       r.y = child->y;
       r.width = child->width;
@@ -869,9 +679,7 @@ should_apply_clip_as_shape (GdkWindow *window)
 {
   return
     gdk_window_has_impl (window) &&
-    /* Not for offscreens */
-    !gdk_window_is_offscreen (window) &&
-    /* or for non-shaped toplevels */
+    /* Not for non-shaped toplevels */
     (!gdk_window_is_toplevel (window) ||
      window->shape != NULL || window->applied_shape) &&
     /* or for foreign windows */
@@ -1388,7 +1196,6 @@ gdk_window_new (GdkWindow     *parent,
     {
     case GDK_WINDOW_TOPLEVEL:
     case GDK_WINDOW_TEMP:
-    case GDK_WINDOW_OFFSCREEN:
       if (GDK_WINDOW_TYPE (parent) != GDK_WINDOW_ROOT)
        g_warning (G_STRLOC "Toplevel windows must be created as children of\n"
                   "of a window of type GDK_WINDOW_ROOT or GDK_WINDOW_FOREIGN");
@@ -1439,12 +1246,7 @@ gdk_window_new (GdkWindow     *parent,
   if (window->parent->window_type == GDK_WINDOW_ROOT)
     native = TRUE; /* Always use native windows for toplevels */
 
-  if (gdk_window_is_offscreen (window))
-    {
-      _gdk_offscreen_window_new (window, attributes, attributes_mask);
-      window->impl_window = window;
-    }
-  else if (native)
+  if (native)
     {
       event_mask = get_native_event_mask (window);
 
@@ -1748,7 +1550,6 @@ gdk_window_reparent (GdkWindow *window,
       else if (GDK_WINDOW_TYPE (window) == GDK_WINDOW_CHILD)
        GDK_WINDOW_TYPE (window) = GDK_WINDOW_TOPLEVEL;
       break;
-    case GDK_WINDOW_OFFSCREEN:
     case GDK_WINDOW_TOPLEVEL:
     case GDK_WINDOW_CHILD:
     case GDK_WINDOW_TEMP:
@@ -1823,8 +1624,6 @@ gdk_window_reparent (GdkWindow *window,
  * Tries to ensure that there is a window-system native window for this
  * GdkWindow. This may fail in some situations, returning %FALSE.
  *
- * Offscreen window and children of them can never have native windows.
- *
  * Some backends may not support native child windows.
  *
  * Returns: %TRUE if the window has a native window, %FALSE otherwise
@@ -1850,11 +1649,8 @@ gdk_window_ensure_native (GdkWindow *window)
 
   impl_window = gdk_window_get_impl_window (window);
 
-  if (gdk_window_is_offscreen (impl_window))
-    return FALSE; /* native in offscreens not supported */
-
   if (impl_window == window)
-    /* Already has an impl, and its not offscreen . */
+    /* Already has an impl. */
     return TRUE;
 
   /* Need to create a native window */
@@ -2056,7 +1852,6 @@ _gdk_window_destroy_hierarchy (GdkWindow *window,
     case GDK_WINDOW_CHILD:
     case GDK_WINDOW_TEMP:
     case GDK_WINDOW_FOREIGN:
-    case GDK_WINDOW_OFFSCREEN:
       if (window->window_type == GDK_WINDOW_FOREIGN && !foreign_destroy)
        {
          /* Logically, it probably makes more sense to send
@@ -2331,30 +2126,6 @@ gdk_window_is_destroyed (GdkWindow *window)
   return GDK_WINDOW_DESTROYED (window);
 }
 
-static void
-to_embedder (GdkWindow *window,
-             gdouble    offscreen_x,
-             gdouble    offscreen_y,
-             gdouble   *embedder_x,
-             gdouble   *embedder_y)
-{
-  g_signal_emit (window, signals[TO_EMBEDDER], 0,
-                 offscreen_x, offscreen_y,
-                 embedder_x, embedder_y);
-}
-
-static void
-from_embedder (GdkWindow *window,
-               gdouble    embedder_x,
-               gdouble    embedder_y,
-               gdouble   *offscreen_x,
-               gdouble   *offscreen_y)
-{
-  g_signal_emit (window, signals[FROM_EMBEDDER], 0,
-                 embedder_x, embedder_y,
-                 offscreen_x, offscreen_y);
-}
-
 /**
  * gdk_window_has_native:
  * @window: a #GdkWindow
@@ -2413,11 +2184,6 @@ gdk_window_get_position (GdkWindow *window,
  * matter for toplevel windows, because the window manager may choose
  * to reparent them.
  *
- * Note that you should use gdk_window_get_effective_parent() when
- * writing generic code that walks up a window hierarchy, because
- * gdk_window_get_parent() will most likely not do what you expect if
- * there are offscreen windows in the hierarchy.
- *
  * Returns: (transfer none): parent of @window
  **/
 GdkWindow*
@@ -2429,31 +2195,6 @@ gdk_window_get_parent (GdkWindow *window)
 }
 
 /**
- * gdk_window_get_effective_parent:
- * @window: a #GdkWindow
- *
- * Obtains the parent of @window, as known to GDK. Works like
- * gdk_window_get_parent() for normal windows, but returns the
- * window’s embedder for offscreen windows.
- *
- * See also: gdk_offscreen_window_get_embedder()
- *
- * Returns: (transfer none): effective parent of @window
- *
- * Since: 2.22
- **/
-GdkWindow *
-gdk_window_get_effective_parent (GdkWindow *window)
-{
-  g_return_val_if_fail (GDK_IS_WINDOW (window), NULL);
-
-  if (gdk_window_is_offscreen (window))
-    return gdk_offscreen_window_get_embedder (window);
-  else
-    return window->parent;
-}
-
-/**
  * gdk_window_get_toplevel:
  * @window: a #GdkWindow
  *
@@ -2463,11 +2204,6 @@ gdk_window_get_effective_parent (GdkWindow *window)
  * toplevel window, as is a %GDK_WINDOW_CHILD window that
  * has a root window as parent.
  *
- * Note that you should use gdk_window_get_effective_toplevel() when
- * you want to get to a window’s toplevel as seen on screen, because
- * gdk_window_get_toplevel() will most likely not do what you expect
- * if there are offscreen windows in the hierarchy.
- *
  * Returns: (transfer none): the toplevel window containing @window
  **/
 GdkWindow *
@@ -2486,35 +2222,6 @@ gdk_window_get_toplevel (GdkWindow *window)
 }
 
 /**
- * gdk_window_get_effective_toplevel:
- * @window: a #GdkWindow
- *
- * Gets the toplevel window that’s an ancestor of @window.
- *
- * Works like gdk_window_get_toplevel(), but treats an offscreen window's
- * embedder as its parent, using gdk_window_get_effective_parent().
- *
- * See also: gdk_offscreen_window_get_embedder()
- *
- * Returns: (transfer none): the effective toplevel window containing @window
- *
- * Since: 2.22
- **/
-GdkWindow *
-gdk_window_get_effective_toplevel (GdkWindow *window)
-{
-  GdkWindow *parent;
-
-  g_return_val_if_fail (GDK_IS_WINDOW (window), NULL);
-
-  while ((parent = gdk_window_get_effective_parent (window)) != NULL &&
-        (gdk_window_get_window_type (parent) != GDK_WINDOW_ROOT))
-    window = parent;
-
-  return window;
-}
-
-/**
  * gdk_window_get_children:
  * @window: a #GdkWindow
  *
@@ -3623,26 +3330,6 @@ gdk_window_schedule_update (GdkWindow *window)
 }
 
 static void
-gdk_window_add_damage (GdkWindow *toplevel,
-                       cairo_region_t *damaged_region)
-{
-  GdkDisplay *display;
-  GdkEvent event = { 0, };
-
-  /* This function only makes sense for offscreen windows. */
-  g_assert (gdk_window_is_offscreen (toplevel));
-
-  event.expose.type = GDK_DAMAGE;
-  event.expose.window = toplevel;
-  event.expose.send_event = FALSE;
-  event.expose.region = damaged_region;
-  cairo_region_get_extents (event.expose.region, &event.expose.area);
-
-  display = gdk_window_get_display (event.expose.window);
-  _gdk_event_queue_append (display, gdk_event_copy (&event));
-}
-
-static void
 _gdk_window_process_updates_recurse_helper (GdkWindow *window,
                                             cairo_region_t *expose_region)
 {
@@ -3670,9 +3357,6 @@ _gdk_window_process_updates_recurse_helper (GdkWindow *window,
   if (cairo_region_is_empty (clipped_expose_region))
     goto out;
 
-  if (gdk_window_is_offscreen (window))
-    gdk_window_add_damage (window, clipped_expose_region);
-
   /* Paint the window before the children, clipped to the window region */
 
   /* While gtk+ no longer handles exposes on anything but native
@@ -3717,11 +3401,6 @@ _gdk_window_process_updates_recurse_helper (GdkWindow *window,
       if (child->destroyed || !GDK_WINDOW_IS_MAPPED (child) || child->input_only)
         continue;
 
-      /* Ignore offscreen children, as they don't draw in their parent and
-       * don't take part in the clipping */
-      if (gdk_window_is_offscreen (child))
-        continue;
-
       /* Client side child, expose */
       if (child->impl == window->impl)
         {
@@ -5625,18 +5304,6 @@ gdk_window_set_device_events (GdkWindow    *window,
 
   native = gdk_window_get_toplevel (window);
 
-  while (gdk_window_is_offscreen (native))
-    {
-      native = gdk_offscreen_window_get_embedder (native);
-
-      if (native == NULL ||
-         (!_gdk_window_has_impl (native) &&
-          !gdk_window_is_viewable (native)))
-       return;
-
-      native = gdk_window_get_toplevel (native);
-    }
-
   device_mask = get_native_device_event_mask (window, device);
   GDK_DEVICE_GET_CLASS (device)->select_window_events (device, native, device_mask);
 }
@@ -6461,19 +6128,8 @@ gdk_window_get_root_coords (GdkWindow *window,
  * in parent’s coordinate system, or %NULL
  *
  * Transforms window coordinates from a child window to its parent
- * window, where the parent window is the normal parent as returned by
- * gdk_window_get_parent() for normal windows, and the window's
- * embedder as returned by gdk_offscreen_window_get_embedder() for
- * offscreen windows.
- *
- * For normal windows, calling this function is equivalent to adding
- * the return values of gdk_window_get_position() to the child coordinates.
- * For offscreen windows however (which can be arbitrarily transformed),
- * this function calls the GdkWindow::to-embedder: signal to translate
- * the coordinates.
- *
- * You should always use this function when writing generic code that
- * walks up a window hierarchy.
+ * window. Calling this function is equivalent to adding the return
+ * values of gdk_window_get_position() to the child coordinates.
  *
  * See also: gdk_window_coords_from_parent()
  *
@@ -6488,26 +6144,11 @@ gdk_window_coords_to_parent (GdkWindow *window,
 {
   g_return_if_fail (GDK_IS_WINDOW (window));
 
-  if (gdk_window_is_offscreen (window))
-    {
-      gdouble px, py;
-
-      to_embedder (window, x, y, &px, &py);
+  if (parent_x)
+    *parent_x = x + window->x;
 
-      if (parent_x)
-        *parent_x = px;
-
-      if (parent_y)
-        *parent_y = py;
-    }
-  else
-    {
-      if (parent_x)
-        *parent_x = x + window->x;
-
-      if (parent_y)
-        *parent_y = y + window->y;
-    }
+  if (parent_y)
+    *parent_y = y + window->y;
 }
 
 /**
@@ -6519,19 +6160,10 @@ gdk_window_coords_to_parent (GdkWindow *window,
  * @y: (out) (allow-none): return location for Y coordinate in child’s coordinate system
  *
  * Transforms window coordinates from a parent window to a child
- * window, where the parent window is the normal parent as returned by
- * gdk_window_get_parent() for normal windows, and the window's
- * embedder as returned by gdk_offscreen_window_get_embedder() for
- * offscreen windows.
- *
- * For normal windows, calling this function is equivalent to subtracting
- * the return values of gdk_window_get_position() from the parent coordinates.
- * For offscreen windows however (which can be arbitrarily transformed),
- * this function calls the GdkWindow::from-embedder: signal to translate
- * the coordinates.
+ * window.
  *
- * You should always use this function when writing generic code that
- * walks down a window hierarchy.
+ * Calling this function is equivalent to subtracting the return
+ * values of gdk_window_get_position() from the parent coordinates.
  *
  * See also: gdk_window_coords_to_parent()
  *
@@ -6546,26 +6178,11 @@ gdk_window_coords_from_parent (GdkWindow *window,
 {
   g_return_if_fail (GDK_IS_WINDOW (window));
 
-  if (gdk_window_is_offscreen (window))
-    {
-      gdouble cx, cy;
-
-      from_embedder (window, parent_x, parent_y, &cx, &cy);
-
-      if (x)
-        *x = cx;
-
-      if (y)
-        *y = cy;
-    }
-  else
-    {
-      if (x)
-        *x = parent_x - window->x;
+  if (x)
+    *x = parent_x - window->x;
 
-      if (y)
-        *y = parent_y - window->y;
-    }
+  if (y)
+    *y = parent_y - window->y;
 }
 
 /**
@@ -7000,17 +6617,6 @@ gdk_window_is_shaped (GdkWindow *window)
 }
 
 /* Gets the toplevel for a window as used for events,
-   i.e. including offscreen parents */
-static GdkWindow *
-get_event_parent (GdkWindow *window)
-{
-  if (gdk_window_is_offscreen (window))
-    return gdk_offscreen_window_get_embedder ((GdkWindow *)window);
-  else
-    return window->parent;
-}
-
-/* Gets the toplevel for a window as used for events,
    i.e. including offscreen parents going up to the native
    toplevel */
 static GdkWindow *
@@ -7018,7 +6624,7 @@ get_event_toplevel (GdkWindow *window)
 {
   GdkWindow *parent;
 
-  while ((parent = get_event_parent (window)) != NULL &&
+  while ((parent = window->parent) != NULL &&
         (parent->window_type != GDK_WINDOW_ROOT))
     window = parent;
 
@@ -7037,7 +6643,7 @@ _gdk_window_event_parent_of (GdkWindow *parent,
       if (w == parent)
        return TRUE;
 
-      w = get_event_parent (w);
+      w = w->parent;
     }
 
   return FALSE;
@@ -7078,7 +6684,7 @@ update_cursor (GdkDisplay *display,
      the cursor is inherited from the parent */
   while (cursor_window->cursor == NULL &&
          !g_hash_table_contains (cursor_window->device_cursor, device) &&
-        (parent = get_event_parent (cursor_window)) != NULL &&
+        (parent = cursor_window->parent) != NULL &&
         parent->window_type != GDK_WINDOW_ROOT)
     cursor_window = parent;
 
@@ -7207,7 +6813,7 @@ convert_toplevel_coords_to_window (GdkWindow *window,
   y = toplevel_y;
 
   children = NULL;
-  while ((parent = get_event_parent (window)) != NULL &&
+  while ((parent = window->parent) != NULL &&
         (parent->window_type != GDK_WINDOW_ROOT))
     {
       children = g_list_prepend (children, window);
@@ -7223,21 +6829,6 @@ convert_toplevel_coords_to_window (GdkWindow *window,
   *window_y = y;
 }
 
-static GdkWindow *
-pick_embedded_child (GdkWindow *window,
-                    gdouble    x,
-                     gdouble    y)
-{
-  GdkWindow *res;
-
-  res = NULL;
-  g_signal_emit (window,
-                signals[PICK_EMBEDDED_CHILD], 0,
-                x, y, &res);
-
-  return res;
-}
-
 GdkWindow *
 _gdk_window_find_child_at (GdkWindow *window,
                           double     x,
@@ -7264,14 +6855,6 @@ _gdk_window_find_child_at (GdkWindow *window,
                                     NULL, NULL, NULL))
            return (GdkWindow *)sub;
        }
-
-      if (window->num_offscreen_children > 0)
-       {
-         sub = pick_embedded_child (window,
-                                    x, y);
-         if (sub)
-           return (GdkWindow *)sub;
-       }
     }
 
   return NULL;
@@ -7315,18 +6898,6 @@ _gdk_window_find_descendant_at (GdkWindow *window,
                  break;
                }
            }
-         if (!found &&
-             window->num_offscreen_children > 0)
-           {
-             sub = pick_embedded_child (window,
-                                        x, y);
-             if (sub)
-               {
-                 found = TRUE;
-                 window = sub;
-                 from_embedder (sub, x, y, &x, &y);
-               }
-           }
        }
       while (found);
     }
@@ -7552,14 +7123,14 @@ find_common_ancestor (GdkWindow *win1,
   while (tmp != NULL && tmp->window_type != GDK_WINDOW_ROOT)
     {
       path1 = g_list_prepend (path1, tmp);
-      tmp = get_event_parent (tmp);
+      tmp = tmp->parent;
     }
 
   tmp = win2;
   while (tmp != NULL && tmp->window_type != GDK_WINDOW_ROOT)
     {
       path2 = g_list_prepend (path2, tmp);
-      tmp = get_event_parent (tmp);
+      tmp = tmp->parent;
     }
 
   list1 = path1;
@@ -7896,7 +7467,7 @@ _gdk_synthesize_crossing_events (GdkDisplay                 *display,
            notify_type = GDK_NOTIFY_VIRTUAL;
 
          last = a;
-         win = get_event_parent (a);
+         win = a->parent;
          while (win != c && win->window_type != GDK_WINDOW_ROOT)
            {
              send_crossing_event (display, toplevel,
@@ -7911,7 +7482,7 @@ _gdk_synthesize_crossing_events (GdkDisplay                 *display,
                                   serial);
 
              last = win;
-             win = get_event_parent (win);
+             win = win->parent;
            }
        }
     }
@@ -7924,11 +7495,11 @@ _gdk_synthesize_crossing_events (GdkDisplay                 *display,
       if (c != b)
        {
          path = NULL;
-         win = get_event_parent (b);
+         win = b->parent;
          while (win != c && win->window_type != GDK_WINDOW_ROOT)
            {
              path = g_list_prepend (path, win);
-             win = get_event_parent (win);
+             win = win->parent;
            }
 
          if (non_linear)
@@ -8039,22 +7610,6 @@ _gdk_display_set_window_under_pointer (GdkDisplay *display,
   _gdk_display_enable_motion_hints (display, device);
 }
 
-/**
- * gdk_window_geometry_changed:
- * @window: an embedded offscreen #GdkWindow
- *
- * This function informs GDK that the geometry of an embedded
- * offscreen window has changed. This is necessary for GDK to keep
- * track of which offscreen window the pointer is in.
- *
- * Since: 2.18
- */
-void
-gdk_window_geometry_changed (GdkWindow *window)
-{
-  _gdk_synthesize_crossing_events_for_geometry_change (window);
-}
-
 static void
 source_events_device_added (GdkDeviceManager *device_manager,
                             GdkDevice        *device,
@@ -8366,7 +7921,7 @@ get_event_window (GdkDisplay                 *display,
          return pointer_window;
        }
 
-      pointer_window = get_event_parent (pointer_window);
+      pointer_window = pointer_window->parent;
     }
 
   if (grab != NULL &&
@@ -8738,7 +8293,7 @@ proxy_button_event (GdkEvent *source_event,
       /* Find the event window, that gets the grab */
       w = pointer_window;
       while (w != NULL &&
-            (parent = get_event_parent (w)) != NULL &&
+            (parent = w->parent) != NULL &&
             parent->window_type != GDK_WINDOW_ROOT)
        {
          if (w->event_mask & GDK_BUTTON_PRESS_MASK &&
@@ -9068,7 +8623,7 @@ gdk_window_print (GdkWindow *window,
     "dialog",
     "temp",
     "foreign",
-    "offscreen"
+    "subsurface"
   };
 
   g_print ("%*s%p: [%s] %d,%d %dx%d", indent, "", window,
diff --git a/gdk/gdkwindow.h b/gdk/gdkwindow.h
index a6bc688..9a887b7 100644
--- a/gdk/gdkwindow.h
+++ b/gdk/gdkwindow.h
@@ -67,8 +67,6 @@ typedef enum
  * @GDK_WINDOW_TEMP: override redirect temporary window (used to implement
  *  #GtkMenu)
  * @GDK_WINDOW_FOREIGN: foreign window (see gdk_window_foreign_new())
- * @GDK_WINDOW_OFFSCREEN: offscreen window (see
- *  [Offscreen Windows][OFFSCREEN-WINDOWS]). Since 2.18
  * @GDK_WINDOW_SUBSURFACE: subsurface-based window; This window is visually
  *  tied to a toplevel, and is moved/stacked with it. Currently this window
  *  type is only implemented in Wayland. Since 3.14
@@ -82,7 +80,6 @@ typedef enum
   GDK_WINDOW_CHILD,
   GDK_WINDOW_TEMP,
   GDK_WINDOW_FOREIGN,
-  GDK_WINDOW_OFFSCREEN,
   GDK_WINDOW_SUBSURFACE
 } GdkWindowType;
 
@@ -460,25 +457,6 @@ struct _GdkWindowClass
 {
   GObjectClass      parent_class;
 
-  GdkWindow       * (* pick_embedded_child) (GdkWindow *window,
-                                             gdouble    x,
-                                             gdouble    y);
-
-  /*  the following 3 signals will only be emitted by offscreen windows */
-  void              (* to_embedder)         (GdkWindow *window,
-                                             gdouble    offscreen_x,
-                                             gdouble    offscreen_y,
-                                             gdouble   *embedder_x,
-                                             gdouble   *embedder_y);
-  void              (* from_embedder)       (GdkWindow *window,
-                                             gdouble    embedder_x,
-                                             gdouble    embedder_y,
-                                             gdouble   *offscreen_x,
-                                             gdouble   *offscreen_y);
-  cairo_surface_t * (* create_surface)      (GdkWindow *window,
-                                             gint       width,
-                                             gint       height);
-
   /* Padding for future expansion */
   void (*_gdk_reserved1) (void);
   void (*_gdk_reserved2) (void);
@@ -830,11 +808,6 @@ GDK_AVAILABLE_IN_ALL
 GdkWindow *   gdk_window_get_toplevel    (GdkWindow       *window);
 
 GDK_AVAILABLE_IN_ALL
-GdkWindow *   gdk_window_get_effective_parent   (GdkWindow *window);
-GDK_AVAILABLE_IN_ALL
-GdkWindow *   gdk_window_get_effective_toplevel (GdkWindow *window);
-
-GDK_AVAILABLE_IN_ALL
 GList *              gdk_window_get_children    (GdkWindow       *window);
 GDK_AVAILABLE_IN_ALL
 GList *       gdk_window_peek_children   (GdkWindow       *window);
@@ -1025,18 +998,6 @@ void       gdk_window_constrain_size      (GdkGeometry    *geometry,
 GDK_AVAILABLE_IN_ALL
 GdkWindow *gdk_get_default_root_window (void);
 
-/* Offscreen redirection */
-GDK_AVAILABLE_IN_ALL
-cairo_surface_t *
-           gdk_offscreen_window_get_surface    (GdkWindow     *window);
-GDK_AVAILABLE_IN_ALL
-void       gdk_offscreen_window_set_embedder   (GdkWindow     *window,
-                                               GdkWindow     *embedder);
-GDK_AVAILABLE_IN_ALL
-GdkWindow *gdk_offscreen_window_get_embedder   (GdkWindow     *window);
-GDK_AVAILABLE_IN_ALL
-void       gdk_window_geometry_changed         (GdkWindow     *window);
-
 /* Multidevice support */
 GDK_AVAILABLE_IN_ALL
 void       gdk_window_set_support_multidevice (GdkWindow *window,
diff --git a/gdk/gdkwindowimpl.c b/gdk/gdkwindowimpl.c
index c42c5aa..af445e3 100644
--- a/gdk/gdkwindowimpl.c
+++ b/gdk/gdkwindowimpl.c
@@ -184,7 +184,7 @@ traverse_to_toplevel (GdkWindow *window,
   gdouble xf = x;
   gdouble yf = y;
 
-  while ((parent = gdk_window_get_effective_parent (window)) != NULL &&
+  while ((parent = window->parent) != NULL &&
          (gdk_window_get_window_type (parent) != GDK_WINDOW_ROOT))
     {
       gdk_window_coords_to_parent (window, xf, yf, &xf, &yf);
diff --git a/gdk/makefile.msc b/gdk/makefile.msc
index 0d88d1e..ec5d6a9 100644
--- a/gdk/makefile.msc
+++ b/gdk/makefile.msc
@@ -77,7 +77,6 @@ gdk_OBJECTS = \
        gdkkeys.obj \
        gdkkeyuni.obj \
        gdkmarshalers.obj \
-       gdkoffscreenwindow.obj \
        gdkpango.obj \
        gdkpixbuf-drawable.obj \
        gdkrectangle.obj \
diff --git a/gdk/mir/gdkmirwindowimpl.c b/gdk/mir/gdkmirwindowimpl.c
index 61d0b60..e4fc56a 100644
--- a/gdk/mir/gdkmirwindowimpl.c
+++ b/gdk/mir/gdkmirwindowimpl.c
@@ -303,11 +303,11 @@ create_window_type_spec (GdkDisplay *display,
     {
       real_rect = *rect;
 
-      while (parent && !gdk_window_has_native (parent) && gdk_window_get_effective_parent (parent))
+      while (parent && !gdk_window_has_native (parent) && gdk_window_get_parent (parent))
         {
           real_rect.left += parent->x;
           real_rect.top += parent->y;
-          parent = gdk_window_get_effective_parent (parent);
+          parent = gdk_window_get_parent (parent);
         }
     }
   else
diff --git a/gdk/quartz/gdkdevice-core-quartz.c b/gdk/quartz/gdkdevice-core-quartz.c
index 6fc17aa..6cb3b6d 100644
--- a/gdk/quartz/gdkdevice-core-quartz.c
+++ b/gdk/quartz/gdkdevice-core-quartz.c
@@ -159,7 +159,7 @@ translate_coords_to_child_coords (GdkWindow *parent,
       *x -= tmp_x;
       *y -= tmp_y;
 
-      current = gdk_window_get_effective_parent (current);
+      current = gdk_window_get_parent (current);
     }
 }
 
@@ -209,7 +209,7 @@ gdk_quartz_device_core_query_state_helper (GdkWindow       *window,
       return NULL;
     }
 
-  toplevel = gdk_window_get_effective_toplevel (window);
+  toplevel = gdk_window_get_toplevel (window);
 
   if (mask)
     *mask = _gdk_quartz_events_get_current_keyboard_modifiers () |
diff --git a/gdk/quartz/gdkevents-quartz.c b/gdk/quartz/gdkevents-quartz.c
index d43695d..f8fdaf5 100644
--- a/gdk/quartz/gdkevents-quartz.c
+++ b/gdk/quartz/gdkevents-quartz.c
@@ -42,8 +42,7 @@
 
 #define WINDOW_IS_TOPLEVEL(window)                  \
   (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD &&   \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN && \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_OFFSCREEN)
+   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN)
 
 /* This is the window corresponding to the key window */
 static GdkWindow   *current_keyboard_window;
@@ -672,7 +671,7 @@ find_toplevel_for_keyboard_event (NSEvent *nsevent)
       grab = _gdk_display_get_last_device_grab (display, device);
       if (grab && grab->window && !grab->owner_events)
         {
-          window = gdk_window_get_effective_toplevel (grab->window);
+          window = gdk_window_get_toplevel (grab->window);
           break;
         }
     }
@@ -746,7 +745,7 @@ find_toplevel_for_mouse_event (NSEvent    *nsevent,
           /* Finally check the grab window. */
           GdkWindow *grab_toplevel;
 
-          grab_toplevel = gdk_window_get_effective_toplevel (grab->window);
+          grab_toplevel = gdk_window_get_toplevel (grab->window);
           get_window_point_from_screen_point (grab_toplevel, screen_point,
                                               x, y);
 
diff --git a/gdk/quartz/gdkscreen-quartz.c b/gdk/quartz/gdkscreen-quartz.c
index df645e6..13b0274 100644
--- a/gdk/quartz/gdkscreen-quartz.c
+++ b/gdk/quartz/gdkscreen-quartz.c
@@ -203,11 +203,7 @@ _gdk_quartz_screen_update_window_sizes (GdkScreen *screen)
   windows = gdk_screen_get_toplevel_windows (screen);
 
   for (list = windows; list; list = list->next)
-    {
-      if (GDK_WINDOW_TYPE(list->data) == GDK_WINDOW_OFFSCREEN)
-        continue;
-      _gdk_quartz_window_update_position (list->data);
-    }
+    _gdk_quartz_window_update_position (list->data);
 
   g_list_free (windows);
 }
diff --git a/gdk/quartz/gdkwindow-quartz.c b/gdk/quartz/gdkwindow-quartz.c
index e07f7b6..f15fbd0 100644
--- a/gdk/quartz/gdkwindow-quartz.c
+++ b/gdk/quartz/gdkwindow-quartz.c
@@ -64,8 +64,7 @@ static void clear_toplevel_order  (void);
 
 #define WINDOW_IS_TOPLEVEL(window)                  \
   (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD &&   \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN && \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_OFFSCREEN)
+   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN)
 
 /*
  * GdkQuartzWindow
@@ -386,7 +385,7 @@ _gdk_quartz_window_process_updates_recurse (GdkWindow *window,
     {
       GdkWindow *toplevel;
 
-      toplevel = gdk_window_get_effective_toplevel (window);
+      toplevel = gdk_window_get_toplevel (window);
       if (toplevel && WINDOW_IS_TOPLEVEL (toplevel))
         {
           GdkWindowImplQuartz *toplevel_impl;
@@ -2284,7 +2283,7 @@ gdk_quartz_window_get_frame_extents (GdkWindow    *window,
   rect->width = 1;
   rect->height = 1;
   
-  toplevel = gdk_window_get_effective_toplevel (window);
+  toplevel = gdk_window_get_toplevel (window);
   impl = GDK_WINDOW_IMPL_QUARTZ (toplevel->impl);
 
   ns_rect = [impl->toplevel frame];
diff --git a/gdk/wayland/gdkdevice-wayland.c b/gdk/wayland/gdkdevice-wayland.c
index f139b77..ce4915b 100644
--- a/gdk/wayland/gdkdevice-wayland.c
+++ b/gdk/wayland/gdkdevice-wayland.c
@@ -4620,18 +4620,6 @@ gdk_wayland_seat_grab (GdkSeat                *seat,
 
   native = gdk_window_get_toplevel (window);
 
-  while (native->window_type == GDK_WINDOW_OFFSCREEN)
-    {
-      native = gdk_offscreen_window_get_embedder (native);
-
-      if (native == NULL ||
-          (!_gdk_window_has_impl (native) &&
-           !gdk_window_is_viewable (native)))
-        return GDK_GRAB_NOT_VIEWABLE;
-
-      native = gdk_window_get_toplevel (native);
-    }
-
   if (native == NULL || GDK_WINDOW_DESTROYED (native))
     return GDK_GRAB_NOT_VIEWABLE;
 
diff --git a/gdk/wayland/gdkwindow-wayland.c b/gdk/wayland/gdkwindow-wayland.c
index f6b4b7b..a714b18 100644
--- a/gdk/wayland/gdkwindow-wayland.c
+++ b/gdk/wayland/gdkwindow-wayland.c
@@ -48,13 +48,11 @@ enum {
 static guint signals[LAST_SIGNAL];
 
 #define WINDOW_IS_TOPLEVEL_OR_FOREIGN(window) \
-  (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD &&   \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_OFFSCREEN)
+  (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD)
 
 #define WINDOW_IS_TOPLEVEL(window)                   \
   (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD &&   \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN && \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_OFFSCREEN)
+   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN)
 
 #define MAX_WL_BUFFER_SIZE (4083) /* 4096 minus header, string argument length and NUL byte */
 
@@ -1619,11 +1617,11 @@ get_real_parent_and_translate (GdkWindow *window,
 
   while (parent &&
          !gdk_window_has_native (parent) &&
-         gdk_window_get_effective_parent (parent))
+         gdk_window_get_parent (parent))
     {
       *x += parent->x;
       *y += parent->y;
-      parent = gdk_window_get_effective_parent (parent);
+      parent = gdk_window_get_parent (parent);
     }
 
   return parent;
@@ -2296,7 +2294,7 @@ gdk_wayland_window_map (GdkWindow *window)
             }
 
           if (transient_for)
-            transient_for = get_popup_parent (gdk_window_get_effective_toplevel (transient_for));
+            transient_for = get_popup_parent (gdk_window_get_toplevel (transient_for));
 
           /* If the position was not explicitly set, start the popup at the
            * position of the device that holds the grab.
@@ -2307,7 +2305,7 @@ gdk_wayland_window_map (GdkWindow *window)
         }
       else
         {
-          transient_for = gdk_window_get_effective_toplevel (impl->transient_for);
+          transient_for = gdk_window_get_toplevel (impl->transient_for);
           transient_for = get_popup_parent (transient_for);
         }
 
diff --git a/gdk/win32/gdkdnd-win32.c b/gdk/win32/gdkdnd-win32.c
index cec3dcc..f1e9ef5 100644
--- a/gdk/win32/gdkdnd-win32.c
+++ b/gdk/win32/gdkdnd-win32.c
@@ -2379,9 +2379,6 @@ _gdk_win32_window_register_dnd (GdkWindow *window)
 
   g_return_if_fail (window != NULL);
 
-  if (gdk_window_get_window_type (window) == GDK_WINDOW_OFFSCREEN)
-    return;
-
   if (g_object_get_data (G_OBJECT (window), "gdk-dnd-registered") != NULL)
     return;
   else
diff --git a/gdk/win32/gdkwindow-win32.c b/gdk/win32/gdkwindow-win32.c
index 6cc0b0e..12d57c1 100644
--- a/gdk/win32/gdkwindow-win32.c
+++ b/gdk/win32/gdkwindow-win32.c
@@ -132,8 +132,7 @@ static void    _gdk_win32_impl_release_dc (GdkWindowImplWin32 *impl);
 
 #define WINDOW_IS_TOPLEVEL(window)                \
   (GDK_WINDOW_TYPE (window) != GDK_WINDOW_CHILD && \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN && \
-   GDK_WINDOW_TYPE (window) != GDK_WINDOW_OFFSCREEN)
+   GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN)
 
 GdkScreen *
 GDK_WINDOW_SCREEN (GObject *win)
diff --git a/gdk/x11/gdkdisplay-x11.h b/gdk/x11/gdkdisplay-x11.h
index 48100dc..f53db8c 100644
--- a/gdk/x11/gdkdisplay-x11.h
+++ b/gdk/x11/gdkdisplay-x11.h
@@ -119,9 +119,6 @@ struct _GdkX11Display
   guint have_input_shapes : 1;
   gint shape_event_base;
 
-  /* The offscreen window that has the pointer in it (if any) */
-  GdkWindow *active_offscreen_window;
-
   GSList *error_traps;
 
   gint wm_moveresize_button;
diff --git a/gdk/x11/gdkdnd-x11.c b/gdk/x11/gdkdnd-x11.c
index b28407e..8946074 100644
--- a/gdk/x11/gdkdnd-x11.c
+++ b/gdk/x11/gdkdnd-x11.c
@@ -2496,9 +2496,6 @@ _gdk_x11_window_register_dnd (GdkWindow *window)
 
   g_return_if_fail (window != NULL);
 
-  if (gdk_window_get_window_type (window) == GDK_WINDOW_OFFSCREEN)
-    return;
-
   base_precache_atoms (display);
 
   if (g_object_get_data (G_OBJECT (window), "gdk-dnd-registered") != NULL)
diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c
index 5744d66..761bedb 100644
--- a/gdk/x11/gdkwindow-x11.c
+++ b/gdk/x11/gdkwindow-x11.c
@@ -1925,9 +1925,6 @@ _gdk_x11_window_set_window_scale (GdkWindow *window,
   GdkToplevelX11 *toplevel;
   GdkWindowHints geom_mask;
 
-  if (window->window_type == GDK_WINDOW_OFFSCREEN)
-    return;
-
   impl = GDK_WINDOW_IMPL_X11 (window->impl);
 
   impl->window_scale = scale;
diff --git a/gtk/Makefile.am b/gtk/Makefile.am
index 8277b33..356523f 100644
--- a/gtk/Makefile.am
+++ b/gtk/Makefile.am
@@ -250,7 +250,6 @@ gtk_public_h_sources =              \
        gtkmountoperation.h     \
        gtknativedialog.h       \
        gtknotebook.h           \
-       gtkoffscreenwindow.h    \
        gtkorientable.h         \
        gtkoverlay.h            \
        gtkpadcontroller.h      \
@@ -820,7 +819,6 @@ gtk_base_c_sources =                \
        gtkmountoperation.c     \
        gtknativedialog.c       \
        gtknotebook.c           \
-       gtkoffscreenwindow.c    \
        gtkorientable.c         \
        gtkoverlay.c            \
        gtkpadcontroller.c      \
diff --git a/gtk/gtk-autocleanups.h b/gtk/gtk-autocleanups.h
index ea47ba0..9ea63c6 100644
--- a/gtk/gtk-autocleanups.h
+++ b/gtk/gtk-autocleanups.h
@@ -116,7 +116,6 @@ G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkMenuToolButton, g_object_unref)
 G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkMessageDialog, g_object_unref)
 G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkMountOperation, g_object_unref)
 G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkNotebook, g_object_unref)
-G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkOffscreenWindow, g_object_unref)
 G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkOrientable, g_object_unref)
 G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkOverlay, g_object_unref)
 G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkPageSetup, g_object_unref)
diff --git a/gtk/gtk.h b/gtk/gtk.h
index 598f04f..5bc0b54 100644
--- a/gtk/gtk.h
+++ b/gtk/gtk.h
@@ -149,7 +149,6 @@
 #include <gtk/gtkmountoperation.h>
 #include <gtk/gtknativedialog.h>
 #include <gtk/gtknotebook.h>
-#include <gtk/gtkoffscreenwindow.h>
 #include <gtk/gtkorientable.h>
 #include <gtk/gtkoverlay.h>
 #include <gtk/gtkpadcontroller.h>
diff --git a/gtk/gtkdnd-quartz.c b/gtk/gtkdnd-quartz.c
index a8fd26a..240b107 100644
--- a/gtk/gtkdnd-quartz.c
+++ b/gtk/gtkdnd-quartz.c
@@ -1145,7 +1145,7 @@ gtk_drag_begin_internal (GtkWidget         *widget,
               * nswindow. Then, we convert to the NSWindow coordinate system.
               */
              window = event->any.window;
-             GdkWindow *toplevel = gdk_window_get_effective_toplevel (window);
+             GdkWindow *toplevel = gdk_window_get_toplevel (window);
 
              while (window != toplevel)
                {
@@ -1154,7 +1154,7 @@ gtk_drag_begin_internal (GtkWidget         *widget,
 
                  gdk_window_coords_to_parent (window, old_x, old_y,
                                               &dx, &dy);
-                 window = gdk_window_get_effective_parent (window);
+                 window = gdk_window_get_parent (window);
                }
            }
          time = (double)gdk_event_get_time (event);
diff --git a/gtk/gtkflowbox.c b/gtk/gtkflowbox.c
index 22c56d3..1866a69 100644
--- a/gtk/gtkflowbox.c
+++ b/gtk/gtkflowbox.c
@@ -2937,7 +2937,7 @@ gtk_flow_box_motion_notify_event (GtkWidget      *widget,
                                    &parent_x, &parent_y);
       relative_x = parent_x;
       relative_y = parent_y;
-      event_window = gdk_window_get_effective_parent (event_window);
+      event_window = gdk_window_get_parent (event_window);
     }
 
   child = gtk_flow_box_find_child_at_pos (box, relative_x, relative_y);
diff --git a/gtk/gtkgesture.c b/gtk/gtkgesture.c
index 8f92f1d..3d75510 100644
--- a/gtk/gtkgesture.c
+++ b/gtk/gtkgesture.c
@@ -408,7 +408,7 @@ _find_widget_window (GtkGesture *gesture,
           gtk_widget_get_window (widget) == window)
         return window;
 
-      window = gdk_window_get_effective_parent (window);
+      window = gdk_window_get_parent (window);
     }
 
   return NULL;
@@ -488,7 +488,7 @@ _update_widget_coordinates (GtkGesture *gesture,
       gdk_window_get_position (window, &wx, &wy);
       event_x += wx;
       event_y += wy;
-      window = gdk_window_get_effective_parent (window);
+      window = gdk_window_get_parent (window);
     }
 
   if (!window)
@@ -690,7 +690,7 @@ gesture_within_window (GtkGesture *gesture,
       if (window == parent)
         return TRUE;
 
-      window = gdk_window_get_effective_parent (window);
+      window = gdk_window_get_parent (window);
     }
 
   return FALSE;
diff --git a/gtk/gtklistbox.c b/gtk/gtklistbox.c
index 90ebaca..3bc3257 100644
--- a/gtk/gtklistbox.c
+++ b/gtk/gtklistbox.c
@@ -1871,7 +1871,7 @@ gtk_list_box_motion_notify_event (GtkWidget      *widget,
     {
       gdk_window_coords_to_parent (event_window, 0, relative_y, NULL, &parent_y);
       relative_y = parent_y;
-      event_window = gdk_window_get_effective_parent (event_window);
+      event_window = gdk_window_get_parent (event_window);
     }
 
   row = gtk_list_box_get_row_at_y (box, relative_y);
diff --git a/gtk/gtkscrolledwindow.c b/gtk/gtkscrolledwindow.c
index c6724cc..c96b0ee 100644
--- a/gtk/gtkscrolledwindow.c
+++ b/gtk/gtkscrolledwindow.c
@@ -1130,7 +1130,7 @@ translate_to_widget (GtkWidget *widget,
       gdk_window_get_position (window, &wx, &wy);
       event_x += wx;
       event_y += wy;
-      window = gdk_window_get_effective_parent (window);
+      window = gdk_window_get_parent (window);
     }
 
   if (!gtk_widget_get_has_window (event_widget))
diff --git a/gtk/gtktooltip.c b/gtk/gtktooltip.c
index 4a2c76f..b722f9e 100644
--- a/gtk/gtktooltip.c
+++ b/gtk/gtktooltip.c
@@ -622,7 +622,7 @@ _gtk_widget_find_at_coords (GdkWindow *window,
       child_loc.x = px;
       child_loc.y = py;
 
-      window = gdk_window_get_effective_parent (window);
+      window = gdk_window_get_parent (window);
     }
 
   /* Failing to find widget->window can happen for e.g. a detached handle box;
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index 25f2193..c070e14 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -5743,7 +5743,7 @@ gtk_widget_translate_coordinates (GtkWidget  *src_widget,
       src_x = dx;
       src_y = dy;
 
-      window = gdk_window_get_effective_parent (window);
+      window = gdk_window_get_parent (window);
 
       if (!window)             /* Handle GtkHandleBox */
        return FALSE;
@@ -5755,7 +5755,7 @@ gtk_widget_translate_coordinates (GtkWidget  *src_widget,
     {
       dest_list = g_list_prepend (dest_list, window);
 
-      window = gdk_window_get_effective_parent (window);
+      window = gdk_window_get_parent (window);
 
       if (!window)             /* Handle GtkHandleBox */
         {
@@ -11215,7 +11215,7 @@ _gtk_widget_synthesize_crossing (GtkWidget       *from,
 
       while (from_ancestor != NULL)
        {
-         from_ancestor = gdk_window_get_effective_parent (from_ancestor);
+         from_ancestor = gdk_window_get_parent (from_ancestor);
           if (from_ancestor == NULL)
             break;
           from_ancestors = g_list_prepend (from_ancestors, from_ancestor);
@@ -11240,7 +11240,7 @@ _gtk_widget_synthesize_crossing (GtkWidget       *from,
 
       while (to_ancestor != NULL)
        {
-         to_ancestor = gdk_window_get_effective_parent (to_ancestor);
+         to_ancestor = gdk_window_get_parent (to_ancestor);
          if (to_ancestor == NULL)
             break;
           to_ancestors = g_list_prepend (to_ancestors, to_ancestor);
@@ -11269,7 +11269,7 @@ _gtk_widget_synthesize_crossing (GtkWidget       *from,
        {
          if (from_ancestor != NULL)
            {
-             from_ancestor = gdk_window_get_effective_parent (from_ancestor);
+             from_ancestor = gdk_window_get_parent (from_ancestor);
              if (from_ancestor == to_window)
                break;
               if (from_ancestor)
@@ -11277,7 +11277,7 @@ _gtk_widget_synthesize_crossing (GtkWidget       *from,
            }
          if (to_ancestor != NULL)
            {
-             to_ancestor = gdk_window_get_effective_parent (to_ancestor);
+             to_ancestor = gdk_window_get_parent (to_ancestor);
              if (to_ancestor == from_window)
                break;
               if (to_ancestor)
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index 30ff7aa..c95231e 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -6049,7 +6049,6 @@ gtk_window_map (GtkWidget *widget)
   gdk_window_show (gdk_window);
 
   if (!disable_startup_notification &&
-      !GTK_IS_OFFSCREEN_WINDOW (window) &&
       priv->type != GTK_WINDOW_POPUP)
     {
       /* Do we have a custom startup-notification id? */
diff --git a/gtk/makefile.msc.in b/gtk/makefile.msc.in
index ad9934b..a2b2035 100644
--- a/gtk/makefile.msc.in
+++ b/gtk/makefile.msc.in
@@ -251,7 +251,6 @@ gtk_OBJECTS = \
        gtkmountoperation.obj \
        gtkmountoperation-stub.obj \
        gtknotebook.obj \
-       gtkoffscreenwindow.obj \
        gtkorientable.obj \
        gtkpagesetup.obj \
        gtkpaned.obj \
@@ -440,7 +439,6 @@ gtk_public_h_sources =              \
        gtkmodules.h            \
        gtkmountoperation.h     \
        gtknotebook.h           \
-       gtkoffscreenwindow.h    \
        gtkorientable.h         \
        gtkpagesetup.h          \
        gtkpaned.h              \
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 5e7c99a..cb17e28 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -98,8 +98,6 @@ noinst_PROGRAMS =  $(TEST_PROGS)      \
        testmultidisplay                \
        testnotebookdnd                 \
        testnouiprint                   \
-       testoffscreen                   \
-       testoffscreenwindow             \
        testorientable                  \
        testoverlay                     \
        testoverlaystyleclass           \
@@ -224,8 +222,6 @@ testmountoperation_DEPENDENCIES = $(TEST_DEPS)
 testmultidisplay_DEPENDENCIES = $(TEST_DEPS)
 testnotebookdnd_DEPENDENCIES = $(TEST_DEPS)
 testnouiprint_DEPENDENCIES = $(TEST_DEPS)
-testoffscreen_DEPENDENCIES = $(TEST_DEPS)
-testoffscreenwindow_DEPENDENCIES = $(TEST_DEPS)
 testappchooser_DEPENDENCIES = $(TEST_DEPS)
 testappchooserbutton_DEPENDENCIES = $(TEST_DEPS)
 testorientable_DEPENDENCIES = $(TEST_DEPS)
@@ -417,14 +413,6 @@ testcellarea_SOURCES =             \
 testtreemenu_SOURCES =         \
        testtreemenu.c
 
-testoffscreen_SOURCES =        \
-       gtkoffscreenbox.c       \
-       gtkoffscreenbox.h       \
-       testoffscreen.c
-
-testoffscreenwindow_SOURCES =  \
-       testoffscreenwindow.c
-
 testoverlay_SOURCES =  \
        testoverlay.c
 
diff --git a/tests/makefile.msc b/tests/makefile.msc
index 13b921a..db93d67 100644
--- a/tests/makefile.msc
+++ b/tests/makefile.msc
@@ -50,7 +50,7 @@ TESTAPPS = \
        testicontheme testiconview testimage testinput \
        testmountoperation testmenubars testmerge testmultidisplay testmultiscreen \
        testnouiprint testnotebookdnd \
-       testoffscreen testorientable \
+       testorientable \
        testprint \
        testrecentchooser testrecentchoosermenu testrichtext \
        testscale testselection testspinbutton \
@@ -79,10 +79,6 @@ EXTRA_OBJETCS = prop-editor.obj
 EXTRA_LIBS = $(ATK_LIBS)
 !ENDIF
 
-!IFDEF EXTRA_testoffscreen
-EXTRA_OBJETCS = gtkoffscreenbox.obj
-!ENDIF
-
 !IFDEF EXTRA_testprint
 EXTRA_OBJETCS = testprintfileoperation.obj
 EXTRA_LIBS = $(PANGOCAIRO_LIBS)
diff --git a/testsuite/gtk/notify.c b/testsuite/gtk/notify.c
index c5dbd23..65aba31 100644
--- a/testsuite/gtk/notify.c
+++ b/testsuite/gtk/notify.c
@@ -503,10 +503,6 @@ test_type (gconstpointer data)
       if (type == GTK_TYPE_COLOR_BUTTON && pspec->owner_type == GTK_TYPE_BUTTON)
         continue;
 
-      /* GdkOffscreenWindow is missing many implementations */
-      if (type == GTK_TYPE_OFFSCREEN_WINDOW)
-        continue;
-
       /* Too many special cases involving -set properties */
       if (g_str_equal (g_type_name (pspec->owner_type), "GtkCellRendererText") ||
           g_str_equal (g_type_name (pspec->owner_type), "GtkTextTag"))
diff --git a/testsuite/gtk/treeview.c b/testsuite/gtk/treeview.c
index b439dc3..9488cd7 100644
--- a/testsuite/gtk/treeview.c
+++ b/testsuite/gtk/treeview.c
@@ -192,7 +192,7 @@ test_row_separator_height (void)
   gtk_list_store_insert_with_values (store, &iter, 3, 0, "Row content", -1);
   gtk_list_store_insert_with_values (store, &iter, 4, 0, "Row content", -1);
 
-  window = gtk_offscreen_window_new ();
+  window = gtk_invisible_new ();
 
   tree_view = gtk_tree_view_new_with_model (GTK_TREE_MODEL (store));
   gtk_tree_view_set_row_separator_func (GTK_TREE_VIEW (tree_view),
diff --git a/testsuite/reftests/label-sizing.ref.ui b/testsuite/reftests/label-sizing.ref.ui
index 3289e15..5baf8f2 100644
--- a/testsuite/reftests/label-sizing.ref.ui
+++ b/testsuite/reftests/label-sizing.ref.ui
@@ -1,7 +1,7 @@
 <?xml version="1.0"?>
 <interface>
   <!-- interface-requires gtk+ 3.0 -->
-  <object class="GtkOffscreenWindow" id="window1">
+  <object class="GtkWindow" id="window1">
     <property name="can_focus">False</property>
     <property name="type">popup</property>
     <signal name="realize" handler="reftest:set_default_direction_ltr"/>
diff --git a/testsuite/reftests/label-sizing.ui b/testsuite/reftests/label-sizing.ui
index 83b2862..2a1c839 100644
--- a/testsuite/reftests/label-sizing.ui
+++ b/testsuite/reftests/label-sizing.ui
@@ -1,7 +1,7 @@
 <?xml version="1.0"?>
 <interface>
   <!-- interface-requires gtk+ 3.0 -->
-  <object class="GtkOffscreenWindow" id="window1">
+  <object class="GtkWindow" id="window1">
     <property name="can_focus">False</property>
     <property name="type">popup</property>
     <signal name="realize" handler="reftest:set_default_direction_ltr"/>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]