Re: Creating GObject/GTK bindings for language

2010-03-01 Thread Tristin Celestin
I apologize for being so terse. I was grasping at straws, trying to think
of a specific question regarding GTK binding to get me started. There
have been plenty of bindings to scripting languages in the past, so
I thought asking about them in general would be the quickest way to
get information about making binding.

I would like bindings for GTK from Objective C. I originally started
to bind classes manually, starting with GList in GLib. While I know
that this will take time, if I use that method, I'll die before
I finish.

I've looked at the obgtk and GTKKit bindings for GTK1, and some of it
does look helpful (like how to associate ObjC methods with signals),
but GTK has grown so much since then. I'm not sure if it's reasonable
to build off of that.

How much of this process is not automated? 

I would like to know how to minimize some of the work involved. Looking at
the gir xml stored in the GLib.typelib reveals xml descriptions of
what looks like all of the library's classes, but doing the same thing
for the libxml typelib shows a gir file that doesn't look complete. How
do I know I can trust the .gir file to have a complete description of
the library it purports to describe.

Secondly, is it header information that is usually automatically generated?
Do maintainers then go and manually write the implementations themselves?


Finally, do you have a suggestion as to where I can start? Am I on the
right track in first trying to get automatically generated headers from
the typelib information?



--- On Fri, 2/26/10, John Palmieri jo...@redhat.com wrote:

 From: John Palmieri jo...@redhat.com
 Subject: Re: Creating GObject/GTK bindings for language
 To: Tristin Celestin tristin_celes...@yahoo.com
 Cc: gtk-devel-list@gnome.org
 Date: Friday, February 26, 2010, 12:14 PM
 
 - Tristin Celestin tristin_celes...@yahoo.com
 wrote:
 
  I want to be able to use GObject and GObject based
 libraries from an
  object oriented scripting language with no bindings
 for GObject and
  GObject based libraries currently.
  
  
  How does one go about creating GObject bindings for
 another language?
  I've read the GObject-Introspection pages at gnome.org
 and looked at
  the
  PyGobject binding, but I still don't have a clear idea
 of where to
  start.
 
 Which language?  Have you ever done bindings in that
 language before?  Usually you would wrap a library by
 making equivalent API calls in that language and marshaling
 API parameters and results using the glue C/C++ libraries
 that the language provides for creating modules.  More
 complex libraries usually have some sort of automation for
 this and some languages have generic automated 
 binding tools like SWiG.  With the advent of
 GObject-Introspection you can now write a minimal interface
 module that reads in the gir files and routes and marshals
 method calls based on the gir data structure. 
 PyGObject is a poor library to look at because it does not
 yet use GObject-Introspect and does the wrapping with its
 own targeted tool.  It is better to look at the Gjs or
 Seed javascript bindings.  Every language is going to
 be different as they all have their own API for creating C
 extension modules so again, you need to know how to wrap a
 simple library in your language before tackling GTK+.
 
 --
 John (J5) Palmieri
 Software Engineer
 Red Hat, Inc.
 


  
___
gtk-devel-list mailing list
gtk-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-devel-list


Creating GObject/GTK bindings for language

2010-02-26 Thread Tristin Celestin
I want to be able to use GObject and GObject based libraries from an
object oriented scripting language with no bindings for GObject and
GObject based libraries currently.


How does one go about creating GObject bindings for another language?
I've read the GObject-Introspection pages at gnome.org and looked at the
PyGobject binding, but I still don't have a clear idea of where to start.


  
___
gtk-devel-list mailing list
gtk-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-devel-list


Gtk Widget Transparency

2010-02-04 Thread Tristin Celestin
I am trying to understand how to make individual widgets in GTK 
transparent, like how it is done in gnome-terminal, as opposed to 
setting the opacity of an entire heirarchy via set_opacity ().



All the examples demonstrating transparent widgets use a cairo canvas 
and require that you perform all the drawing yourself, such as the 
example at 
http://mikehearn.wordpress.com/2006/03/26/gtk-windows-with-alpha-channels/, 
posted in a  November 2009 mailing about the same topic. However, I 
don't want to draw a custom widget, I just want to adjust the opacity of 
an existing, non-toplevel one.



How do I do this?



Tristin 


  
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list