IRC Networks
Irc Logs Stats
Start date: 2007-09-27 02:48:27
Last update: 2008-10-24 20:19:38
Channels: 41
Logged Lines: 6230436
Size: 1825.51 MB
Powered by
Channel Info
Network: freenodeChannel: #gtk |
Search in www.irclog.org
Log from #gtk at freenode 2006-06-02
Pages: 1
[17:50]<crgn66>hmm... can anyone tell me some good source for learning theming??
[19:08]<sgzzyus>(I've never done it)
[19:09]<sgzzyus>wait..treeviews only have 1 cell renderer per row, right?
[19:10]<sgzzyus>just try hiding one
[19:13]<svggrmw>i'll have a look...
[19:25]<mjgrvjre>hello
[19:25]<svggrmw>Snarius: it works i think, just keep cleaning and adding ;)
[19:25]<sgzzyus>yay
[19:34]<svggrmw>a bit slow though but it works :) great
[19:35]<mjgrvjre>why can't I pass $entry->get_text to instead of passing $entry?
[19:35]<mjgrvjre>this doesn't work:
[19:35]<mjgrvjre>$btnGetFare->signal_connect("clicked" => \&getFarePrice, [$entRefId->get_text]);
[19:36]<mjgrvjre>this works:
[19:36]<mjgrvjre>$btnGetFare->signal_connect("clicked" => \&getFarePrice, [$entRefId]);
[19:37]<sgzzyus>donatoaz, how does it not work?
[19:44]<mjgrvjre>when I send the get_text and print the received value
[19:44]<mjgrvjre>it shows empty
[19:44]<mjgrvjre>but if I send the widget and inside the function access get_text it is not (as expected)
[19:58]<mjgrvjre>I worked it out
[19:58]<mjgrvjre>now I call it like this
[19:59]<mjgrvjre>$btnGetFare->signal_connect("clicked" => sub { getFarePrice( [ $entRefId->get_text ] ); } );
[19:59]<mjgrvjre>it looks kinda ugly but I found no other way =(
[20:00]<sgzzyus>what does getFarePrice return?
[20:01]<sgzzyus>a float?
[20:06]<mjgrvjre>no, actualy it returns an integer
[20:06]<mjgrvjre>0 or 1
[20:06]<mjgrvjre>indicating success
[20:07]<mjgrvjre>actually I pass a label too
[20:07]<mjgrvjre>in case it finds the fare price it sets the label's text to that price
[20:07]<sgzzyus>Maybe the prob is in the way c handles strings.
[20:07]<mjgrvjre>in case it does not find it it sets it to "not found"
[20:08]<mjgrvjre>could be..
[20:09]<mjgrvjre>perl to c extensions has some weird issues on working with char *
[20:09]<mjgrvjre>* c to perl
[21:04]<nmsylnr>hi
[21:04]<sgzzyus>hi
[21:04]<nmsylnr>how can I refresh a TreeView
[21:04]<nmsylnr>using pygtk
[21:04]<nmsylnr>I have to use a thread ?
[21:04]<nmsylnr>I need auto-refresh
[21:06]<sgzzyus>I may be wrong, but doesn't calling gtk_widget_show_all refresh its contents?
[21:07]<sgzzyus>dunno about py syntax
[21:07]<nmsylnr>happen that I need to run a function every 1 second, this function load the data into the treeview
[21:07]<sgzzyus>there are timer things found in Glib
[21:07]<sgzzyus>1 min
[21:07]<nmsylnr>yeah I know
[21:08]<nmsylnr>if I use a button that's no problem
[21:08]<nmsylnr>but I need do that when the app starts
[21:08]<nmsylnr>without blocking my app
[21:09]<sgzzyus>why can't you set a function to be called every second then?
[21:09]<nmsylnr>because my aplication seems locked
[21:09]<nmsylnr>blocked
[21:10]<nmsylnr>exist some signal to call this function when the app starts ?
[21:11]<sgzzyus>there are signals that are called when a widget is created
[21:11]<nmsylnr>wich one ?
[21:11]<nmsylnr>I need a signal for my main gtk window
[21:12]<nmsylnr>activate_default ?
[21:15]<sgzzyus>I don't see any obvious signals
[21:16]<nmsylnr>I need run a function every 1 second when the app starts
[21:16]<nmsylnr>:(
[21:16]<nmsylnr>the other way it's to create a thread
[21:16]<nmsylnr>I think
[21:16]<sgzzyus>http://developer.gnome.org/doc/API/2.2/glib/glib-The-Main-Event-Loop.html#g-timeout-add
[21:17]<sgzzyus>it's called a timeout
[21:17]<sgzzyus>with g_timeout_add_full () you specify the interval
[21:17]<sgzzyus>in milliseconds probably
[21:18]<nmsylnr>yeah
[21:18]<nmsylnr>great
[21:18]<nmsylnr>happens that I'm using PyGTK, now I need to know how to do that with it
[21:18]<sgzzyus>there an api reference?
[21:19]<nmsylnr>I'm searching on www.pygtk.org
[21:19]<sgzzyus>http://www.pygtk.org/pygtktutorial/ch-timeouts.html
[21:20]<nmsylnr>http://www.pygtk.org/pygtk2reference/index.html
[21:21]<nmsylnr>Snarius, thanks!
[21:21]<sgzzyus>I just realized: there's no creation signal
[21:21]<sgzzyus>a widget needs to be created before signals are connected
[21:21]<sgzzyus>:)
[21:22]<nmsylnr>:)
[21:22]<sgzzyus>there is a "show" signal tho
[22:38]<mjgrvjre>When I close (click on th 'x') on a dialog
[22:38]<mjgrvjre>it gets destroyed, right?
[22:38]<mjgrvjre>can I make it hide the dialog instead of destroying it?
[23:33]<-- syzzzyus xzs puyv>http://www.bagdadsoftware.de")
[23:45]<-- svgvr2rmgg xrs fu>/dev/null")
Pages: 1







