glade

Creating columns with editable cells in Gtk treeview using Glade

孤街浪徒 提交于 2019-12-04 06:01:45
I am trying to create a simple GUI with table containing x and y coordinates of samples. I use treeview, and I want the cells of the table to be editable by user. Is it possible to specify if the cells should be editable directly in Glade in cellrenderer properties, or do I have to specify it in my code? I use Glade 3.6.1 I have just found out that unticking box "Editable" in the Tree View Editor when editing my treeview, enables me to specify whether the cells shall be editable or not, because if the box is unticked, the cells editable property is no longer connected with the model. But if I

PyGObject and glade send window to the front

假装没事ソ 提交于 2019-12-04 05:19:36
问题 im having some problems to send to the front a GTK window. I have a main window ( window_root ) with a button that launches another window ( window_programs ). with this commands: window_root.hide() window_programs.show() then, in window_programs , i have a button that displays another window ( window_list ) with the command: window_list.show() window_list is modal. The problem was that window_list appeared at the back of window_programs . so i did some research and i found window_list.show()

Load GUI from a Glade with GtkSourceView in PyGObject

匆匆过客 提交于 2019-12-04 03:54:30
I'm trying to use a Glade file that has a GtkSourceView widget in PyGObject. I've wrote a little guide on how to start using the new GtkSourceView 3.0 in Glade: http://cjenkins.wordpress.com/2012/05/08/use-gtksourceview-widget-in-glade/ The problem is when I want to load that Glade from PyGObject: from gi.repository import Gtk, GtkSource from os.path import abspath, dirname, join WHERE_AM_I = abspath(dirname(__file__)) class MyApp(object): def __init__(self): self.builder = Gtk.Builder() self.glade_file = join(WHERE_AM_I, 'test.glade') self.builder.add_from_file(self.glade_file) if __name__ ==

Use glade with pygobject Gtk3

ⅰ亾dé卋堺 提交于 2019-12-03 16:32:40
问题 I am converting a script to use Gtk3 using the migration guide (Porting GTK2 to GTK3). I converted my import pygtk to a from gi.repository import Gtk and so on... I'm stuck because the glade module was loaded from module gtk: import gtk import gtk.glade but there's no way now to do that anymore. Note that I would only need a replacement for gtk.glade.XML() ... 回答1: Well, the solution is pretty obvious, after calling to Gtk.Builder() one needs to convert the old glade interface with the gtk

Can't use a glade xml file with haskell

守給你的承諾、 提交于 2019-12-03 08:15:22
I'm not sure if I should say hi or not, being this my first post here. Anyway, I am following the glade tutorial from the gtk2hs website . The code compiled properly but when I try to execute it I get this error. (hellogtk2hs:8670): libglade-WARNING **: Expected <glade-interface>. Got <interface>. (hellogtk2hs:8670): libglade-WARNING **: did not finish in PARSER_FINISH state hellogtk2hs: user error (Pattern match failure in do expression at HelloGtk2Hs.hs:8:8-15) This is my glade file. <?xml version="1.0" encoding="UTF-8"?> <interface> <!-- interface-requires gtk+ 3.0 --> <object class=

putting glade interface in python

百般思念 提交于 2019-12-03 06:27:55
I've made a gui in glade that I want to put in a python program. I was adapting the instructions from a tutorial I found online to load in my glade file (http://www.pygtk.org/articles/pygtk-glade-gui/Creating_a_GUI_using_PyGTK_and_Glade.htm). When I had problems I tried something basic (one button) calling it the same thing as in that tutorial, and copy pasting their code, and it still didn't work. I also took a look at (http://www.linuxjournal.com/article/6586?page=0,2), which has a function being called slightly differently ("self.wTree=gtk.glade.XML (gladefile,windowname)" instead of

Use glade with pygobject Gtk3

风流意气都作罢 提交于 2019-12-03 05:49:13
I am converting a script to use Gtk3 using the migration guide ( Porting GTK2 to GTK3 ). I converted my import pygtk to a from gi.repository import Gtk and so on... I'm stuck because the glade module was loaded from module gtk: import gtk import gtk.glade but there's no way now to do that anymore. Note that I would only need a replacement for gtk.glade.XML() ... Well, the solution is pretty obvious, after calling to Gtk.Builder() one needs to convert the old glade interface with the gtk-builder-convert command to get the interface file in the right version. $ gtk-builder-convert myui.glade

GUI becomes unresponsive after clicking the button using GTK+ in C

拟墨画扇 提交于 2019-12-02 23:18:52
问题 #include <gtk/gtk.h> #include <stdlib.h> #include <stdio.h> #include <math.h> #include <string.h> void display(GtkButton * b, gpointer data) { while(1) { printf("hurrah!"); } } void closeapp(GtkButton * b, gpointer data) { gtk_main_quit(); } int main(int argc,char *argv[]) { Widgets widg; printf("hello"); GtkBuilder *gtkBuilder; GtkWidget *window; gtk_init(&argc,&argv); gtkBuilder = gtk_builder_new(); gtk_builder_add_from_file(gtkBuilder,"hello_world.glade",NULL); window = GTK_WIDGET(gtk

GUI becomes unresponsive after clicking the button using GTK+ in C

别来无恙 提交于 2019-12-02 13:16:41
#include <gtk/gtk.h> #include <stdlib.h> #include <stdio.h> #include <math.h> #include <string.h> void display(GtkButton * b, gpointer data) { while(1) { printf("hurrah!"); } } void closeapp(GtkButton * b, gpointer data) { gtk_main_quit(); } int main(int argc,char *argv[]) { Widgets widg; printf("hello"); GtkBuilder *gtkBuilder; GtkWidget *window; gtk_init(&argc,&argv); gtkBuilder = gtk_builder_new(); gtk_builder_add_from_file(gtkBuilder,"hello_world.glade",NULL); window = GTK_WIDGET(gtk_builder_get_object(gtkBuilder,"mywindow")); widg.e1 = GTK_ENTRY( gtk_builder_get_object(gtkBuilder, "entry1

PyGObject and glade send window to the front

妖精的绣舞 提交于 2019-12-02 05:40:56
im having some problems to send to the front a GTK window. I have a main window ( window_root ) with a button that launches another window ( window_programs ). with this commands: window_root.hide() window_programs.show() then, in window_programs , i have a button that displays another window ( window_list ) with the command: window_list.show() window_list is modal. The problem was that window_list appeared at the back of window_programs . so i did some research and i found window_list.show() . The problems is that window_list appears at the front, but when i click it window_programs comes to