Index: main/cdk.lisp
===================================================================
--- main/cdk.lisp	(revision main,5)
+++ main/cdk.lisp	(revision main,6)
@@ -11,4 +11,14 @@
 (use-foreign-library cdk)
 
+
+
+;;; Global constants.
+
+(defctype chtype :uint64)
+
+(defcvar ("cdk_exit_early" +cdk-exit-early+) :int :read-only t)
+(defcvar ("cdk_exit_escape" +cdk-exit-escape+) :int :read-only t)
+(defcvar ("cdk_exit_normal" +cdk-exit-normal+) :int :read-only t)
+(defcvar ("cdk_exit_never" +cdk-exit-never+) :int :read-only t)
 
 ;;; Screen-wide, initialization, and finalization routines.
@@ -45,10 +55,21 @@
 (defcfun ("box" c-box) :int
   (window :pointer)
-  (vertical-ch :int)
-  (horizontal-ch :int))
+  (vertical-ch chtype)
+  (horizontal-ch chtype))
 
 
 
 ;;; Generic functions.
+
+(defcfun ("bindCDKObject" c-bind-key) :void
+  (object-type :int)
+  (object :pointer)
+  (key chtype)
+  (function :pointer)
+  (user-data :pointer))
+
+(defcfun ("cleanCDKObjectBindings" c-clear-bindings) :void
+  (object-type :int)
+  (object :pointer))
 
 (defcfun ("setCDKObjectBackgroundColor" c-set-background-color) :void
@@ -112,4 +133,18 @@
 (defcfun ("setCDKEntryHighlight" c-set-entry-highlight) :void
   (entry :pointer)
-  (highlight :unsigned-long)
+  (highlight :unsigned-int)             ; Still not sure about this.
   (cursor :boolean))
+
+(defcfun ("getCDKEntryExitType" c-entry-exit-type) :int
+  (entry :pointer))
+
+(defcfun ("getCDKEntryValue" c-get-entry-value) :string
+  (entry :pointer))
+
+(defcfun ("setCDKEntryValue" c-set-entry-value) :void
+  (entry :pointer)
+  (new-value :string))
+
+(defcfun ("setCDKEntryExitType" c-set-entry-exit-type) :void
+  (entry :pointer)
+  (ch chtype))
