GTK+ Forums

Discussion forum for GTK+ and Programming. Ask questions, troubleshoot problems, view and post example code, or express your opinions.
It is currently Sat Oct 25, 2014 4:18 am

All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Is it possible to create gtk object/widget which be at glad?
PostPosted: Thu Dec 06, 2007 2:35 pm 
Offline
Familiar Face

Joined: Thu Dec 06, 2007 2:15 pm
Posts: 20
Is it possible to create gtk object/widget which will appear at glade?

I want to add more widgets to glade, It is convenient that there is "events" which make easy programming...

I want to start with a timer widget.

Is it also possible to create non graphics widgets?
For example timer need only property interval and event for each interval.

Is it possible to make those widgets in Python?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Dec 06, 2007 2:41 pm 
Offline
Never Seen the Sunlight

Joined: Wed Sep 21, 2005 12:07 am
Posts: 563
Location: Portland, OR USA
Quote:
Is it possible to create gtk object/widget which will appear at glade?


Glade allows for "custom" widgets--I believe by using a "placeholder" which will then attempt to load your widget by name. I've never done that though, you'd have to check with the glade-users list.

Quote:
I want to start with a timer widget.


GLib already provides this functionality in g_timeout_add and the like.

Quote:
Is it also possible to create non graphics widgets?
For example timer need only property interval and event for each interval.


You could just as easily derive your custom object from GtkObject or GObject, although then we wouldn't call it a "widget" but just an object. For example, GError and GString are some objects.

Quote:
Is it possible to make those widgets in Python?


I dont' like this idea as I don't think people using C would be able to use your widget, nor would language bindings be created for it in any conventional sense, however, it can probably be done.

Check out: http://www.learningpython.com/2006/07/25/writing-a-custom-widget-using-pygtk/

_________________
Micah Carrick - Forum Administrator
http://www.micahcarrick.com


Top
 Profile  
 
 Post subject:
PostPosted: Fri Dec 07, 2007 11:33 am 
Offline
Familiar Face

Joined: Thu Dec 06, 2007 2:15 pm
Posts: 20
thanks


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group