gtk3-0.15.10: Binding to the Gtk+ 3 graphical user interface library

Maintainer | gtk2hs-users@lists.sourceforge.net
Stability | provisional
Portability | portable (depends on GHC)
Safe Haskell | None
Language | Haskell98

Graphics.UI.Gtk.Windows.OffscreenWindow

Contents

- Detail
- Class Hierarchy
- Types
- Constructors
- Methods

Description

A toplevel container widget used to manage offscreen rendering of child widgets.

- Module available since Gtk+ version 2.20

Synopsis

- data OffscreenWindow
- class WindowClass o => OffscreenWindowClass o
- castToOffscreenWindow :: GObjectClass obj => obj -> OffscreenWindow
- gTypeOffscreenWindow :: GType
- toOffscreenWindow :: OffscreenWindowClass o => o -> OffscreenWindow
- offscreenWindowNew :: IO OffscreenWindow
- offscreenWindowGetPixbuf :: OffscreenWindowClass self => self -> IO (Maybe Pixbuf)

# Detail

`OffscreenWindow` is strictly intended to be used for obtaining snapshots of widgets that are not part of a normal widget hierarchy. It differs from `widgetGetSnapshot` in that the widget you want to get a snapshot of need not be displayed on the user's screen as a part of a widget hierarchy. However, since `OffscreenWindow` is 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 `OffscreenWindow` and then retrieve the snapshot as a `Pixmap` or `Pixbuf`.

`OffscreenWindow` derives from `Window` only as an implementation detail. Applications should not use any API specific to `Window` to operate on this object. It should be treated as a `Bin` that has no parent widget.

When contained offscreen widgets are redrawn, `OffscreenWindow` will emit a `damageEvent` signal.

# Class Hierarchy

    | GObject
    | +----Object
    | +----Widget
    | +----Container
    | +----Bin
    | +----Window
    | +----OffscreenWindow

# Types

data OffscreenWindow Source #

#### Instances

Instances details

Eq OffscreenWindow Source # |
Instance details Defined in Graphics.UI.Gtk.Types Methods (==) :: OffscreenWindow -> OffscreenWindow -> Bool Source # (/=) :: OffscreenWindow -> OffscreenWindow -> Bool Source #
Ord OffscreenWindow Source # |

Instance details

Defined in Graphics.UI.Gtk.Types

Methods

compare :: OffscreenWindow -> OffscreenWindow -> Ordering Source #

(<) :: OffscreenWindow -> OffscreenWindow -> Bool Source #

(<=) :: OffscreenWindow -> OffscreenWindow -> Bool Source #

(>) :: OffscreenWindow -> OffscreenWindow -> Bool Source #

(>=) :: OffscreenWindow -> OffscreenWindow -> Bool Source #

max :: OffscreenWindow -> OffscreenWindow -> OffscreenWindow Source #

min :: OffscreenWindow -> OffscreenWindow -> OffscreenWindow Source #

GObjectClass OffscreenWindow Source # |
Instance details Defined in Graphics.UI.Gtk.Types Methods toGObject :: OffscreenWindow -> GObject Source # unsafeCastGObject :: GObject -> OffscreenWindow Source #
BinClass OffscreenWindow Source # |
Instance details Defined in Graphics.UI.Gtk.Types
ContainerClass OffscreenWindow Source # |
Instance details Defined in Graphics.UI.Gtk.Types
OffscreenWindowClass OffscreenWindow Source # |
Instance details Defined in Graphics.UI.Gtk.Types
WidgetClass OffscreenWindow Source # |
Instance details Defined in Graphics.UI.Gtk.Types
WindowClass OffscreenWindow Source # |
Instance details Defined in Graphics.UI.Gtk.Types

class WindowClass o => OffscreenWindowClass o Source #

#### Instances

Instances details

OffscreenWindowClass OffscreenWindow Source # |
Instance details Defined in Graphics.UI.Gtk.Types

castToOffscreenWindow :: GObjectClass obj => obj -> OffscreenWindow Source #

gTypeOffscreenWindow :: GType Source #

toOffscreenWindow :: OffscreenWindowClass o => o -> OffscreenWindow Source #

# Constructors

offscreenWindowNew :: IO OffscreenWindow Source #

Creates a toplevel container widget that is used to retrieve snapshots of widgets without showing them on the screen. For widgets that are on the screen and part of a normal widget hierarchy, `widgetGetSnapshot` can be used instead.

- Available since Gtk+ version 2.20

# Methods

offscreenWindowGetPixbuf Source #

Arguments

:: OffscreenWindowClass self |
=> self | `offscreen` the `OffscreenWindow` contained widget.
-> IO (Maybe Pixbuf) | returns A `Pixbuf` pointer to the offscreen pixbuf, or `Nothing`.

Retrieves a snapshot of the contained widget in the form of a `Pixbuf`.

- Available since Gtk+ version 2.20