{-# LINE 2 "./Graphics/UI/Gtk/ImageView/ImageToolDragger.chs" #-} -- -*-haskell-*- -- GIMP Toolkit (GTK) Widget ImageToolDragger -- -- Author : Andy Stewart -- -- Created: 19 Aug 2010 -- -- Copyright (C) 2010 Andy Stewart -- -- This library is free software; you can redistribute it and/or -- modify it under the terms of the GNU Lesser General Public -- License as published by the Free Software Foundation; either -- version 2.1 of the License, or (at your option) any later version. -- -- This library is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -- Lesser General Public License for more details. -- -- | -- Maintainer : gtk2hs-users@lists.sourceforge.net -- Stability : provisional -- Portability : portable (depends on GHC) -- module Graphics.UI.Gtk.ImageView.ImageToolDragger ( -- * Details -- | 'ImageToolDragger' is the default image tool for 'ImageView'. Its only feature is that it can drag -- the image around. -- * Types ImageToolDragger, ImageToolDraggerClass, -- * Methods ) where import Control.Monad (liftM) import Data.Maybe (fromMaybe) import Graphics.UI.Gtk.Abstract.Object (makeNewObject) import Graphics.UI.Gtk.ImageView.Enums import System.Glib.Attributes import System.Glib.FFI import System.Glib.UTFString import Graphics.UI.Gtk.ImageView.Signals {-# LINE 47 "./Graphics/UI/Gtk/ImageView/ImageToolDragger.chs" #-} import Graphics.UI.Gtk.ImageView.Types {-# LINE 48 "./Graphics/UI/Gtk/ImageView/ImageToolDragger.chs" #-} import System.Glib.Properties {-# LINE 49 "./Graphics/UI/Gtk/ImageView/ImageToolDragger.chs" #-} {-# LINE 51 "./Graphics/UI/Gtk/ImageView/ImageToolDragger.chs" #-} -- | Creates and returns a new dragger tool. imageToolDraggerNew :: ImageViewClass view => view -> IO ImageToolDragger imageToolDraggerNew view = makeNewGObject mkImageToolDragger $ liftM (castPtr :: Ptr IImageTool -> Ptr ImageToolDragger) $ (\(ImageView arg1) -> withForeignPtr arg1 $ \argPtr1 ->gtk_image_tool_dragger_new argPtr1) {-# LINE 58 "./Graphics/UI/Gtk/ImageView/ImageToolDragger.chs" #-} (toImageView view) foreign import ccall unsafe "gtk_image_tool_dragger_new" gtk_image_tool_dragger_new :: ((Ptr ImageView) -> (IO (Ptr IImageTool)))