Merge remote-tracking branch 'andy128k/master'
[cl-gtk2.git] / gdk / gdk.functions.lisp
blob030216b0a514b9dcdaa39a62888ba87e7d912b4e
1 (in-package :gdk)
3 (defcfun (default-screen "gdk_screen_get_default") (g-object gdk-screen))
4 (export 'default-screen)
6 (defcfun gdk-atom-name (glib:g-string :free-from-foreign t)
7 (atom gdk-atom))
9 (defcfun gdk-atom-intern gdk-atom
10 (name :string)
11 (only-if-exists :boolean))
13 (defcfun gdk-pixbuf-savev :boolean
14 (pixbuf (g-object pixbuf))
15 (filename :string)
16 (type :string)
17 (option-keys (:pointer (:pointer :char)))
18 (option-values (:pointer (:pointer :char)))
19 (error :pointer))
21 (defun pixbuf-save (pixbuf filename type)
22 (gdk-pixbuf-savev pixbuf
23 (etypecase filename
24 (string filename)
25 (pathname (namestring filename)))
26 type
27 (null-pointer)
28 (null-pointer)
29 (null-pointer)))
31 (export 'pixbuf-save)
33 (defcfun gdk-pixbuf-new-from-file (g-object pixbuf :already-referenced)
34 (filename :string)
35 (error :pointer))
37 (defun pixbuf-new-from-file (filename)
38 (glib:with-g-error (err)
39 (gdk-pixbuf-new-from-file filename err)))
41 (export 'pixbuf-new-from-file)