From: Duncan C. <dun...@us...> - 2005-05-21 02:11:40
|
Update of /cvsroot/gtk2hs/gtk2hs/gtk/Graphics/UI/Gtk/Abstract In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20749/gtk/Graphics/UI/Gtk/Abstract Modified Files: Bin.chs Paned.chs.pp Log Message: Various minor API changes: Bin.chs: make binGetChild return Maybe. Paned.chs.pp: make panedGetChild(1|2) return Maybe. ComboBox.chs.pp: make comboBoxSetModel accept the model argument in a Maybe type so it is possible to unset the model. TextBuffer.chs.pp: make textBufferGetIterAtLine folow the normal argument order convention. Frame.chs: make frameGetLabelAlign and frameSetLabelAlign get and set the yalign as well as just the xalign. TreeView.chs.pp: make treeViewExpandRow folow the normal argument order convention and change the docs a bit. APICHANGES: record these api changes. Index: Paned.chs.pp =================================================================== RCS file: /cvsroot/gtk2hs/gtk2hs/gtk/Graphics/UI/Gtk/Abstract/Paned.chs.pp,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- Paned.chs.pp 7 May 2005 19:13:30 -0000 1.9 +++ Paned.chs.pp 21 May 2005 02:11:30 -0000 1.10 @@ -198,9 +198,9 @@ -- * Available since Gtk+ version 2.4 -- panedGetChild1 :: PanedClass self => self - -> IO Widget -- ^ returns first child + -> IO (Maybe Widget) -- ^ returns first child, or @Nothing@ if it is not set. panedGetChild1 self = - makeNewObject mkWidget $ + maybeNull (makeNewObject mkWidget) $ {# call unsafe paned_get_child1 #} (toPaned self) @@ -209,9 +209,10 @@ -- * Available since Gtk+ version 2.4 -- panedGetChild2 :: PanedClass self => self - -> IO Widget -- ^ returns second child + -> IO (Maybe Widget) -- ^ returns second child, or @Nothing@ if it is not + -- set. panedGetChild2 self = - makeNewObject mkWidget $ + maybeNull (makeNewObject mkWidget) $ {# call unsafe paned_get_child2 #} (toPaned self) #endif Index: Bin.chs =================================================================== RCS file: /cvsroot/gtk2hs/gtk2hs/gtk/Graphics/UI/Gtk/Abstract/Bin.chs,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- Bin.chs 14 Mar 2005 23:55:06 -0000 1.5 +++ Bin.chs 21 May 2005 02:11:30 -0000 1.6 @@ -64,7 +64,7 @@ castToBin, -- * Methods - binGetChild + binGetChild, ) where import System.Glib.FFI @@ -76,11 +76,12 @@ -------------------- -- Methods --- | Gets the child of the 'Bin' +-- | Gets the child of the 'Bin', or @Nothing@ if the bin contains no child +-- widget. -- binGetChild :: BinClass self => self - -> IO Widget -- ^ returns the child of the 'Bin' + -> IO (Maybe Widget) -- ^ returns pointer to child of the 'Bin' binGetChild self = - makeNewObject mkWidget $ + maybeNull (makeNewObject mkWidget) $ {# call gtk_bin_get_child #} (toBin self) |