Gtk.OffscreenWindow¶
| Subclasses: | None | 
|---|
Methods¶
| Inherited: | Gtk.Window (119), Gtk.Bin (1), Gtk.Container (35), Gtk.Widget (278), GObject.Object (37), Gtk.Buildable (10) | 
|---|---|
| Structs: | Gtk.ContainerClass (5), Gtk.WidgetClass (12), GObject.ObjectClass (5) | 
| class | new() | 
| get_pixbuf() | |
| get_surface() | 
Virtual Methods¶
| Inherited: | Gtk.Window (5), Gtk.Container (10), Gtk.Widget (82), GObject.Object (7), Gtk.Buildable (10) | 
|---|
Properties¶
| Inherited: | Gtk.Window (33), Gtk.Container (3), Gtk.Widget (39) | 
|---|
Style Properties¶
| Inherited: | Gtk.Window (2), Gtk.Widget (17) | 
|---|
Signals¶
| Inherited: | Gtk.Window (5), Gtk.Container (4), Gtk.Widget (69), GObject.Object (1) | 
|---|
Fields¶
| Inherited: | Gtk.Window (5), Gtk.Container (4), Gtk.Widget (69), GObject.Object (1) | 
|---|
| Name | Type | Access | Description | 
|---|---|---|---|
| parent_object | Gtk.Window | r | 
Class Details¶
- 
class Gtk.OffscreenWindow(*args, **kwargs)¶
- Bases: - Gtk.Window- Abstract: - No - Structure: - Gtk.OffscreenWindowClass- Gtk.OffscreenWindowis strictly intended to be used for obtaining snapshots of widgets that are not part of a normal widget hierarchy. Since- Gtk.OffscreenWindowis a toplevel widget you cannot obtain snapshots of a full window with it since you cannot pack a toplevel widget in another toplevel.- The idea is to take a widget and manually set the state of it, add it to a - Gtk.OffscreenWindowand then retrieve the snapshot as a- cairo.Surfaceor- GdkPixbuf.Pixbuf.- Gtk.OffscreenWindowderives from- Gtk.Windowonly as an implementation detail. Applications should not use any API specific to- Gtk.Windowto operate on this object. It should be treated as a- Gtk.Binthat has no parent widget.- When contained offscreen widgets are redrawn, - Gtk.OffscreenWindowwill emit a- Gtk.Widget- ::damage-eventsignal.- 
classmethod new()[source]¶
- Returns: - A pointer to a - Gtk.Widget- Return type: - Gtk.Widget- Creates a toplevel container widget that is used to retrieve snapshots of widgets without showing them on the screen. - New in version 2.20. 
 - 
get_pixbuf()[source]¶
- Returns: - A - GdkPixbuf.Pixbufpointer, or- None.- Return type: - GdkPixbuf.Pixbufor- None- Retrieves a snapshot of the contained widget in the form of a - GdkPixbuf.Pixbuf. This is a new pixbuf with a reference count of 1, and the application should unreference it once it is no longer needed.- New in version 2.20. 
 - 
get_surface()[source]¶
- Returns: - A - cairo.Surfacepointer to the offscreen surface, or- None.- Return type: - cairo.Surfaceor- None- Retrieves a snapshot of the contained widget in the form of a - cairo.Surface. If you need to keep this around over window resizes then you should add a reference to it.- New in version 2.20. 
 
- 
classmethod