I've been trying to work out a gnome panel applet since this friday
and have finally ended up in weird issue, this might have come due my
lack of understanding of applets/gtk+. So I seek some
The source of my applet can be checked out here -
To run it -
$ sudo ./install.sh
' it just copies files into /usr/share/gtweetbar and main script to
/usr/local/bin as source uses absolute path
$ python ./tweetbar.py run-in-window
' this would run the applet into its own window, where everything is
functioning properly - http://twitpic.com/k8lda/full - with respect to
the gtk.Entry in center.
While when you do a right click on a panel and add the applet to it,
the gtk.Entry box becomes un-typable. It never gets focus. I have
tried to put all the widgets into an EventBox() but still I didn't
find any change. - http://twitpic.com/k8lf8/full
I'm able to do a right click on the gtk.Entry(), am able to
cut-copy-paste stuff into it, but not able to see a cursor in to so as
to type in a tweet.
Relevant code - http://paste.pocoo.org/show/142852/
Let me know if you are aware of any applet that has been made in pygtk
and has an entry box in it. I tried looking at tracker-search bar's
code, but could'nt grasp much, it being written in C.
Let me know if there is a way to activate the gtk.Entry (txtTweet in
this code) when I run the code in applet mode.
Jus found a useful pastebin entry from random google search - http://fr.pastebin.ca/raw/314172
All I needed to do was an applet.request_focus() call whenever user interacts with the textbox or the applet itself. That would enable the Entry control. More on Ubuntuforums - http://ubuntuforums.org/showthread.php?p=8083187#post8083187
Labels: gnome, gtk+, linux, pygtk, python