Re: gdk_threads_leave is possible to cause segmentation fault?

2017-03-28 Thread Rúben Rodrigues
Thanks! So i could replate enter and leave to g_iddle_add, right? gdk_threads_enter(); g_printf("UpdateConfigNow\n"); iUpdateConfigNow(); gdk_threads_leave(); To g_idle_add((GCallback)iUpdateConfigNow, NULL); Why i get this error? Main.c:1824: undefined reference to `g_iddle_add' Thanks

Re: Howto integrate an inotify watch on editor file in GTK+2 event loop?

2017-03-28 Thread David C. Rankin
On 03/28/2017 10:38 PM, David C. Rankin wrote: > Emmanuele, > > I need more help. I have implemented the watch with 'g_file_monitor_file' > and registered a callback on the "changed" signal for the file, but I cannot > get it to respond to any changes in the underlying file. I got it -- it was

Re: Howto integrate an inotify watch on editor file in GTK+2 event loop?

2017-03-28 Thread David C. Rankin
On 03/28/2017 01:34 PM, David C. Rankin wrote: > On 03/28/2017 02:06 AM, Emmanuele Bassi wrote: >> Use GFileMonitor from GIO instead of directly dealing with inotify. >> >> Ciao, >> Emmanuele. >> > > Now that is the type of answer I was looking for! Thanks Emmanuele. That > definitely keeps it

Re: Howto integrate an inotify watch on editor file in GTK+2 event loop?

2017-03-28 Thread David C. Rankin
On 03/28/2017 02:06 AM, Emmanuele Bassi wrote: > Use GFileMonitor from GIO instead of directly dealing with inotify. > > Ciao, > Emmanuele. > Now that is the type of answer I was looking for! Thanks Emmanuele. That definitely keeps it much cleaner. -- David C. Rankin, J.D.,P.E.

GtkIconView with custom icons

2017-03-28 Thread zahlenmeer
Usually, a GtkIconView uses a GtkTreeModel with a few important columns. A column of type G_TYPE_STRING for the label or the markup and a column of type GDK_TYPE_PIXBUF for the icon. In my application I have a G_TYPE_OBJECT derived object that resembles such an icon in the few, a row if you wish.

Re: gdk_threads_leave is possible to cause segmentation fault?

2017-03-28 Thread Gabriele Greco
> But now this functions aren't running. This is my main thread > void *vGtkMain_Thread(gpointer data) > { > gdk_threads_enter(); > gtk_main(); > gdk_threads_leave(); > return NULL; > } > You should remove everywhere in your code gtk_threads_ calls. You cannot call

SpinButton size

2017-03-28 Thread Rúben Rodrigues
hi guysm it's possible to change size of spinbuttons? In touchscreen mode spinbutton are still small.. We can change it's size with css provider? Thanks ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org

Re: gdk_threads_leave is possible to cause segmentation fault?

2017-03-28 Thread Gabriele Greco
> > > In gdk manual i see thath gdk_threads_enter and leave has been > deprecated and alll gdk and gtk+ calls should be made from main thread. > How we do this? Someone have any example? > > You have to call g_idle_add (that is thread safe) every time you need to update one or more widgets from an

gdk_threads_leave is possible to cause segmentation fault?

2017-03-28 Thread Rúben Rodrigues
Hi guys, My application sometimes have segmentation fault error. In debug mode and using g_print() i see that the applications stops in gdk_thread_leave function. In gdk manual i see thath gdk_threads_enter and leave has been deprecated and alll gdk and gtk+ calls should be made from main

Re: Howto integrate an inotify watch on editor file in GTK+2 event loop?

2017-03-28 Thread Emmanuele Bassi
Use GFileMonitor from GIO instead of directly dealing with inotify. Ciao, Emmanuele. On Tue, 28 Mar 2017 at 07:58, David C. Rankin < drankina...@suddenlinkmail.com> wrote: > All, > > I have a small editor project I've worked on the past several months[1]. > I > want to add an `inotify` watch

Howto integrate an inotify watch on editor file in GTK+2 event loop?

2017-03-28 Thread David C. Rankin
All, I have a small editor project I've worked on the past several months[1]. I want to add an `inotify` watch on the current filename after each open or save to detect modification by a foreign process. I have the details of adding the watch and polling the file descriptor with `pselect`,