[gtk-list] Re: non-exiting gtk_exit()

2000-05-08 Thread David Benson
I would expect this to work: while (gtk_main_level () != 0) gtk_main_quit (); Look at the implementations: guint gtk_main_level (void) { return gtk_main_loop_level; } void gtk_main_quit (void) { g_return_if_fail (main_loops != NULL); g_main_quit (main_loops-data); } void

[gtk-list] Re: dialog communication, abusing gtk_main()?

2000-03-22 Thread David Benson
Though it isn't an abuse of gtk_main, as someone pointed out earlier (I lost the original email :( ) it does seem to bring up an unpleasant reentrance issue: basically, when you call something like gnome_dialog_run_and_close it can cause your handlers to reenter at that point [this is a call

[gtk-list] Re: how do i set the tooltip color?

2000-02-18 Thread David Benson
Except that I think they get the same style as popup windows. That tends to give low constrast in most themes. (Indeed basically all the time) Would a patch to add GdkColor tooltip_fg; GdkColor tooltip_bg; GdkGC *tooltip_fg_gc; GdkGC *tooltip_bg_gc; to GtkStyle be acceptable?

[gtk-list] Re: glib problem

2000-02-15 Thread David Benson
In order to *sometimes* read from a socket, I think you must use g_source_add and g_main_add_poll. Very briefly, something like: GPollFD poll_fd; gboolean needs_input; /* indicates whether the fd should be * read from. */ static gboolean

[gtk-list] Re: [ repeat message] toggle button: clicked ==toggled, and vice versa

2000-01-19 Thread David Benson
The problem I think is that applications (and esp derived classes) have already written been which do not fundamentally distinguish between `click' and `toggle'. You really need to modify your callbacks to ignore the emission you are causing -- probably by setting a variable somewhere, although

[gtk-list] Re: Documentation

2000-01-19 Thread David Benson
There is a *lot* of pretty good documentation. In per-object, per-function API documentation form: http://developer.gnome.org/doc/API/ For gtk is mostly a community-based documenation project, (with sgml-templates generated from the code, courtesy of Damon Chaplin), so if you notice

[gtk-list] Re: GIOChannel

2000-01-19 Thread David Benson
I presume you need to read the documentation for g_source_add g_main_add_poll to do socket i/o in the gtk framework. Assuming you always want to read or write if the fd is ready, you call g_main_add_watch(channel, G_IO_IN or G_IO_OUT,

[gtk-list] Re: Double float for spinbutton.adjustment.value ?

1999-11-24 Thread David Benson
I too have some could that would be radically simplified with a double-based GtkAdjustment. You see in my application there is a "rate" slider which the user can manually fiddle with. There is also a "synchronize rates" button that computes the rate from other sources. For this latter

[gtk-list] Re: compiling glib

1999-11-23 Thread David Benson
Probably you don't have the linux kernel headers. [under redhat] ftp://ftp.redhat.com/pub/redhat/redhat-6.1/i386/RedHat/RPMS or [under debian] apt-get install kernel-headers Or you may need a symlink in /usr/include/linux to /usr/src/linux/include/linux. On Tue, 23 Nov 1999,