com gtk/php-gtk: Must be my lucky day! GtkScintilla also compiles now :) Also removed empty extension directories on Steph's request.: ext/scintilla/php_scintilla.c ext/scintilla/php_scintil la.h ext/scintilla/scintilla.defs

[email protected] (David Soria Parra) Mon, 06 Mar 2006 22:49:26 +0000
Newsgroups php.gtk.cvs
Message-ID <[email protected]>
Commit:    f3e0deca123059f9f0229fefa272853534999d11
Author:    Anant Narayanan <[email protected]>         Mon, 6 Mar 2006 22:49:26 +0000
Parents:   1ae7a428486c7982fd8cf4e2d3818c27caedef38
Branches:  master

Link:       http://git.php.net/?p=gtk/php-gtk.git;a=commitdiff;h=f3e0deca123059f9f0229fefa272853534999d11

Log:
Must be my lucky day! GtkScintilla also compiles now :)
Also removed empty extension directories on Steph's request.

Changed paths:
  M  ext/scintilla/php_scintilla.c
  M  ext/scintilla/php_scintilla.h
  M  ext/scintilla/scintilla.defs


Diff:
f3e0deca123059f9f0229fefa272853534999d11
diff --git a/ext/scintilla/php_scintilla.c b/ext/scintilla/php_scintilla.c
index f6fb19e..a727c90 100644
--- a/ext/scintilla/php_scintilla.c
+++ b/ext/scintilla/php_scintilla.c
@@ -30,8 +30,8 @@ PHP_GTK_GET_EXTENSION(scintilla)
 
 PHP_GTK_XINIT_FUNCTION(scintilla)
 {
-	php_scintilla_register_classes();
-    php_scintilla_register_constants("SCINTILLA_");
+	phpg_gtkscintilla_register_classes();
+    phpg_gtkscintilla_register_constants("SCINTILLA_");
 	
 	return SUCCESS;
 }
diff --git a/ext/scintilla/php_scintilla.h b/ext/scintilla/php_scintilla.h
index bb5e5d0..0c50050 100644
--- a/ext/scintilla/php_scintilla.h
+++ b/ext/scintilla/php_scintilla.h
@@ -32,8 +32,8 @@
 extern php_gtk_ext_entry scintilla_ext_entry;
 #define php_gtk_ext_scintilla_ptr &scintilla_ext_entry
 
-void phpg_scintilla_register_classes(void);
-void phpg_scintilla_register_constants(const char *strip_prefix);
+void phpg_gtkscintilla_register_classes(void);
+void phpg_gtkscintilla_register_constants(const char *strip_prefix);
 
 #else
 
diff --git a/ext/scintilla/scintilla.defs b/ext/scintilla/scintilla.defs
index a7376ee..ac32830 100644
--- a/ext/scintilla/scintilla.defs
+++ b/ext/scintilla/scintilla.defs
@@ -13,7 +13,7 @@
 
 (define-function gtk_scintilla_get_type
   (c-name "gtk_scintilla_get_type")
-  (return-type "guint")
+  (return-type "GType")
 )
 
 (define-function gtk_scintilla_new
@@ -22,6 +22,26 @@
   (return-type "GtkWidget*")
 )
 
+(define-method add_text
+  (of-object "GtkScintilla")
+  (c-name "gtk_scintilla_add_text")
+  (return-type "none")
+  (parameters
+    '("gint" "length")
+    '("const-gchar*" "text")
+  )
+)
+
+(define-method insert_text
+  (of-object "GtkScintilla")
+  (c-name "gtk_scintilla_insert_text")
+  (return-type "none")
+  (parameters
+    '("glong" "pos")
+    '("const-gchar*" "text"))
+)
+
+;; Added to stop errors
 (define-object Frame
   (in-module "Gtk")
   (parent "GtkBin")