Hi guys. So, I'm trying to read data from a database and displaying in a GtkTreeview. I used glade to design the GUI when i click on the button (view movies) the list of movies should display as a list. def on_btnmovies_clicked(self,widget,data=None): store=self.builder.get_object('listmovies') connect=sqlite.connect('movies.db') db=connect.cursor() db.execute("SELECT * FROM movie") for title in db.fetchall(): store.append[(title[1])] #Get the movie Titles only and add to GtkListStore store=self.builder.get_object('listmovies') I've been looking around trying to find how to actullay display the list. I've been using [Click Here](http://python-gtk-3-tutorial.readthedocs.org/en/latest/treeview.html) to read more about GtkTreeviews In Glade I already set the GtkTree_model for GtKTreeview to GtkListStore, called listmovies, …

Member Avatar
Member Avatar
+0 forum 3

Hi, I'm trying to make a simple applet that will display battery status using gtk+ . For that purpose I have written code given below. It continously check for battery status using acpi command and display it. Do you think that I have done things in proper way? I want to modify it so that it will check for battery status in every two second. for that purpose i have used sleep function. But when I use sleep function program don't show gtk window. So what should I do now? Any suggestins are invited. With regards. `Inline Code Example Here …

Member Avatar
+0 forum 0

In the following code I am trying to select a file either from a file chooser or just typing out the path. The problem is I want the comboboxentry to change background color when something is put in it. The code works fine if it's a combobox (Line 7 is 'widget = gtk.combo_box_new_text()'), but not if it's the comboboxentry. An explanation for why this isn't working would be much appreciated. [CODE] import gtk class ComboBoxEntryExample: def __init__(self): window = gtk.Window() window.connect('destroy', lambda w: gtk.main_quit()) widget = gtk.combo_box_entry_new_text() window.add(widget) widget.append_text('Select a File:') widget.append_text('') widget.connect('changed', self.changed_cb) window.show_all() def open_file(self, widget): #"""Opens up …

Member Avatar
Member Avatar
+0 forum 1

Hello every one...I have a project in which I must visualize different kinds of sorts in C by using GTK+ library. I mean it must show the numbers moving and getting sorted! I don't have any idea how to start and how to make the numbers move! I`ll really appreciate it if you help me. please!

Member Avatar
Member Avatar
+0 forum 2

When I move my gtk window it freezes, it runs a timeout and I believe this may be the problem. May anyone provide further explanation on this subject?

Member Avatar
+0 forum 0

Why is this? [CODE] int kitty(GtkWidget* widget, float* foo) { if(*foo != .5f) std::cout << "this usually occurs" << std::endl; } int otherFunc(void) { float foo = .5f; //assume widget has been created g_signal_connect(G_OBJECT(widget), "clicked", G_CALLBACK(kitty), (gpointer)&foo); }[/CODE]

Member Avatar
Member Avatar
+0 forum 1

Hi, I am trying to make an image viewer, this is my first time developing a software and I was just wondering how to add properties in my application. I'm creating this software with the help of Gtk and C and now I'm stuck because I want to display the properties of an image(the default properties displayed by windows) when the user clicks on "Properties", but I don't know what function of windows.h can achieve this. Please help by giving a useful link or a small demonstration. Thanks a lot.

Member Avatar
Member Avatar
+0 forum 1

I'm having some trouble with some low-level tools. Any advice would be appreciated. Here's the situation: I've been having trouble with screwy rendering of GUI elements in gimp. Submitted a bug, the gimp people say it's a gtk problem. Since I'd been meaning to upgrade from 10.5.8, I figured I'd go ahead and do that, and see if that took care of the gtk issue - no dice. So I checked, and gtk --version said I was a little behind, so I downloaded their installer script for the current version, and ran .configure. The script says it's having trouble with …

Member Avatar
Member Avatar
+0 forum 6

hi, I want to run an application that is compiled in python 2.5 in fedora 13 but fedora 13 comes with python 2.6.4 so i manually install python 2.5 to run the application but it is saying that no module named gtk .. how to set path for gtk for python 2.5 i have installed in /usr/bin i want to run the application but its saying the error no module named gtk Kindly advice me a solution

Member Avatar
Member Avatar
+0 forum 1

Hi, I am trying to run an application that is developed in python and compiled in python 2.5 I have upgraded fedora 10 to fedora 13 now i am trying to install that application and run it fedora 13 it gives me an error File "kb.py", line 8, in <module> ImportError: No module named gtk But i have checked whether i installed pygtk through yum command but the terminal says Package pygtk2-2.17.0-3.fc13.i686 already installed and latest version Nothing to do So it has latest version of pygtk but still its giving an error msg File "kb.py", line 8, in <module> …

Member Avatar
Member Avatar
+0 forum 4

OK so i have written my fun Crossword assistant for Linux - I use Glade and it works like a dream. Well nearly ... I also have Gramps working well under Linux and would like to help my Windows friends use it too. But I want to port it to Windows so I can give it to my unenlightened friends. Python is no problem and I have Glade working. But I need the other bits and pieces - pyGTK, GTK, pycairo, pygobject. The trouble is which combinations of versions do I need of each. The most helpful documentation that I …

Member Avatar
+0 forum 0

Hi My question relates to Python GTK I have an image -a JPG - which I draw onto a drawing area. I want to reveal a portion of the image -say a 10pix by 10 px square -only where the mouse pointer is currently at. Everything 10 x 10 px square away from the mouse should be hidden i.e. black. I'm am new to PyGtk please can anyone help with a complete/part listing? Thanks

Member Avatar
+0 forum 0

This program hangs when trying to generate fixtures when the table is empty: [CODE] using System; using Gtk; using Mono.Data.Sqlite; using System.IO; public partial class MainWindow: Gtk.Window { //SQLite variables static SqliteConnection DataConn; static SqliteCommand DataComm = new SqliteCommand(); static SqliteDataReader DataReader; string dsn; //tree_1 variables Gtk.TreeViewColumn name_1 = new Gtk.TreeViewColumn (); Gtk.ListStore List_1 = new Gtk.ListStore (typeof (string)); Gtk.CellRendererText NameCell_1 = new Gtk.CellRendererText (); //tree_2 variables Gtk.TreeViewColumn home_team_2 = new Gtk.TreeViewColumn (); Gtk.TreeViewColumn away_team_2 = new Gtk.TreeViewColumn (); Gtk.TreeStore List_2 = new Gtk.TreeStore (typeof (string), typeof (string)); Gtk.CellRendererText homeCell_2 = new Gtk.CellRendererText (); Gtk.CellRendererText awayCell_2 = new Gtk.CellRendererText (); …

Member Avatar
Member Avatar
+0 forum 17

The End.