Graphics.UI.Gtk.Misc.Viewport

gtk3-0.14.5: 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.Misc.Viewport

Contents

- Detail
- Class Hierarchy
- Types
- Constructors
- Methods
- Attributes

Description

An adapter which makes widgets scrollable

Synopsis

- data Viewport
- class BinClass o => ViewportClass o
- data ShadowType
  - = ShadowNone
  - | ShadowIn
  - | ShadowOut
  - | ShadowEtchedIn
  - | ShadowEtchedOut
- castToViewport :: GObjectClass obj => obj -> Viewport
- gTypeViewport :: GType
- toViewport :: ViewportClass o => o -> Viewport
- viewportNew :: Adjustment -> Adjustment -> IO Viewport
- viewportGetHAdjustment :: ViewportClass self => self -> IO Adjustment
- viewportGetVAdjustment :: ViewportClass self => self -> IO Adjustment
- viewportSetHAdjustment :: ViewportClass self => self -> Adjustment -> IO ()
- viewportSetVAdjustment :: ViewportClass self => self -> Adjustment -> IO ()
- viewportSetShadowType :: ViewportClass self => self -> ShadowType -> IO ()
- viewportGetShadowType :: ViewportClass self => self -> IO ShadowType
- viewportGetBinWindow :: ViewportClass self => self -> IO DrawWindow
- viewportGetViewWindow :: ViewportClass self => self -> IO DrawWindow
- viewportHAdjustment :: ViewportClass self => Attr self Adjustment
- viewportVAdjustment :: ViewportClass self => Attr self Adjustment
- viewportShadowType :: ViewportClass self => Attr self ShadowType

# Detail

A `Viewport` is a helper widget that adds Adjustment slots to a widget, i.e. the widget becomes scrollable. It can then be put into `ScrolledWindow` and will behave as expected.

# Class Hierarchy

    | GObject
    | +----Object
    | +----Widget
    | +----Container
    | +----Bin
    | +----Viewport

# Types

data Viewport #

Instances

Eq Viewport # |
Methods (==) :: Viewport -> Viewport -> Bool # (/=) :: Viewport -> Viewport -> Bool #
Ord Viewport # |
Methods compare :: Viewport -> Viewport -> Ordering # (<) :: Viewport -> Viewport -> Bool # (<=) :: Viewport -> Viewport -> Bool # (>) :: Viewport -> Viewport -> Bool # (>=) :: Viewport -> Viewport -> Bool # max :: Viewport -> Viewport -> Viewport # min :: Viewport -> Viewport -> Viewport #
GObjectClass Viewport # |
Methods toGObject :: Viewport -> GObject # unsafeCastGObject :: GObject -> Viewport #
ViewportClass Viewport # |
BinClass Viewport # |
ContainerClass Viewport # |
WidgetClass Viewport # |

class BinClass o => ViewportClass o #

Instances

ViewportClass Viewport # |

data ShadowType #

Shadow types

Constructors

ShadowNone |
ShadowIn |
ShadowOut |
ShadowEtchedIn |
ShadowEtchedOut |

Instances

Enum ShadowType # |
Methods succ :: ShadowType -> ShadowType # pred :: ShadowType -> ShadowType # toEnum :: Int -> ShadowType # fromEnum :: ShadowType -> Int # enumFrom :: ShadowType -> [ShadowType] # enumFromThen :: ShadowType -> ShadowType -> [ShadowType] # enumFromTo :: ShadowType -> ShadowType -> [ShadowType] # enumFromThenTo :: ShadowType -> ShadowType -> ShadowType -> [ShadowType] #
Eq ShadowType # |
Methods (==) :: ShadowType -> ShadowType -> Bool # (/=) :: ShadowType -> ShadowType -> Bool #
Show ShadowType # |
Methods showsPrec :: Int -> ShadowType -> ShowS # show :: ShadowType -> String # showList :: [ShadowType] -> ShowS #

castToViewport :: GObjectClass obj => obj -> Viewport #

gTypeViewport :: GType #

toViewport :: ViewportClass o => o -> Viewport #

# Constructors

viewportNew #

Arguments

:: Adjustment | `hadjustment` - horizontal adjustment.
-> Adjustment | `vadjustment` - vertical adjustment.
-> IO Viewport |

Creates a new `Viewport` with the given adjustments.

# Methods

viewportGetHAdjustment :: ViewportClass self => self -> IO Adjustment #

Returns the horizontal adjustment of the viewport.

viewportGetVAdjustment :: ViewportClass self => self -> IO Adjustment #

Returns the vertical adjustment of the viewport.

viewportSetHAdjustment :: ViewportClass self => self -> Adjustment -> IO () #

Sets the horizontal adjustment of the viewport.

viewportSetVAdjustment :: ViewportClass self => self -> Adjustment -> IO () #

Sets the vertical adjustment of the viewport.

viewportSetShadowType #

Arguments

:: ViewportClass self |
=> self |
-> ShadowType | `type` - the new shadow type.
-> IO () |

Sets the shadow type of the viewport.

viewportGetShadowType #

Arguments

:: ViewportClass self |
=> self |
-> IO ShadowType | returns the shadow type

Gets the shadow type of the `Viewport`. See `viewportSetShadowType`.

viewportGetBinWindow :: ViewportClass self => self -> IO DrawWindow #

Gets the bin window of the `Viewport`.

- Available since Gtk version 2.20

viewportGetViewWindow :: ViewportClass self => self -> IO DrawWindow #

Gets the view window of the `Viewport`.

- Available since Gtk+ version 2.22

# Attributes

viewportHAdjustment :: ViewportClass self => Attr self Adjustment #

The `Adjustment` that determines the values of the horizontal position for this viewport.

viewportVAdjustment :: ViewportClass self => Attr self Adjustment #

The `Adjustment` that determines the values of the vertical position for this viewport.

viewportShadowType :: ViewportClass self => Attr self ShadowType #

Determines how the shadowed box around the viewport is drawn.

Default value: `ShadowIn`