Proper use of g_main_context_iteration

2015-08-11 Thread Jacques Pelletier
Hi, I'm using a separate thread for accepting clients on a socket server. In this thread, the g_main_context_iteration is called to update the GUI. Do I need to use g_main_context_acquire and/or g_main_context_release? Apart from the code and the reference manuals, there's not much infos

Re: Socket server not reacting to clients

2015-07-18 Thread Jacques Pelletier
I changed this line, from: g_socket_listener_accept_async(ptSocketListener,NULL,NULL,NULL); // The callback function was set to NULL to: g_socket_listener_accept_async(ptSocketListener,NULL,listener_accept_async_function,NULL); // Now works as expected JP

Socket server not reacting to clients

2015-07-11 Thread Jacques Pelletier
Hi, I'm starting a socket server, but clients can't connect. The code already worked before, but doesn't seem to work now. What could be wrong? Here is my code below. Thanks, JP void listener_accept_async_function(GObject *source_object, GAsyncResult *res,

How to use socket conditions ?

2015-07-10 Thread Jacques Pelletier
Hi, I'm using a glib socket: when a client (glib) is connected to a server, the client doesn't get the HUP messages when the server closes its connection. Here is my code below: gboolean SocketPollRead(gpointer data) { switch (g_socket_condition_check(ptSocket,G_IO_IN | G_IO_ERR |

Support for websockets

2014-04-24 Thread Jacques Pelletier
Hi, I would like to know if we can use the g_socket functions for opening a websocket client. JP ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

GtkFileChooserButton with SAVE action

2011-11-18 Thread Jacques Pelletier
Hi, I would like to use a GtkFileChooserButton to select a filename for a unix domain socket. The filename doesn't exit but will be created when opening the socket as a server. Unfortunately, GtkFileChooserButton doesn't support the save action. I have 2 questions: 1- Why GtkFileChooserButton

Many questions

2011-03-04 Thread Jacques Pelletier
Hi everybody, I have several questions: 1) How do we use the GThreadedSocketService and how do we specify the function to run when the connection is established? I'm using these function in a GUI application (see protocoltool on sourceforge); when the connection is made/closed, the GUI's

Serial port with GLIB

2011-02-27 Thread Jacques Pelletier
Hi all, In my application, I'm using the serial library, libezV24. This library is in alpha stage and has been unmaintained for quite a while. I was wondering if glib could be of help and possibly replace this library. JP ___ gtk-app-devel-list

Re: Using GSocket in a GTK application

2011-02-23 Thread Jacques Pelletier
On Wednesday 23 February 2011 08:01:12 you wrote: On Tue, 22 Feb 2011 23:25:43 -0500 Jacques Pelletier jpellet...@ieee.org wrote: [snip] ... /* Connect asynchronously */ mySocketClient = g_socket_client_new

Re: Using GSocket in a GTK application

2011-02-22 Thread Jacques Pelletier
On Sunday 13 February 2011 22:17:12 Jacques Pelletier wrote: Hi all, I'm using GSocket in a GTK application in non-blocking mode. Once the connection is done, I'm creating a source for the main event loop: my_source = g_socket_create_source(my_socket, my_events, NULL); How do we

Using GSocket in a GTK application

2011-02-13 Thread Jacques Pelletier
Hi all, I'm using GSocket in a GTK application in non-blocking mode. Once the connection is done, I'm creating a source for the main event loop: my_source = g_socket_create_source(my_socket, my_events, NULL); How do we specify a callback? Should I use g_source_set_callback ()? The

Re: gnome-file-entry

2011-02-01 Thread Jacques Pelletier
On Tuesday 01 February 2011 21:57:04 Jacques Pelletier wrote: Hi all, I would like to upgrade my application to GTK 3 but I still use gnome_file_entry functions which are deprecated. Is there some equivalent in GTK and some examples how to use them? JP

Sockets in GTK, how to use?

2011-01-30 Thread Jacques Pelletier
Hi, I'm using Gnet 2.08 in my application and I would like to convert it to GTK for its socket functions. From the docs, I was able to figure out how to open a connection, but once the connection is opened, how do we read and write to a socket? JP

Re: Sockets in GTK, how to use?

2011-01-30 Thread Jacques Pelletier
On Sunday 30 January 2011 12:03:57 Antono Vasiljev wrote: Excerpts from Jacques Pelletier's message of 2011-01-30 18:37:34 +0200: I'm using Gnet 2.08 in my application and I would like to convert it to GTK for its socket functions. From the docs, I was able to figure out how to open a

How to use the help system in GTK?

2008-10-11 Thread Jacques Pelletier
Hi all, I want to make some context sensitive help documentation for my application. On clicking the help buttons, depending on the context, appropriate help will be displayed. In windows, there are compiled help files that can be loaded for providing online help. Is there something similar

Re: Does gtk have issues with STL?

2008-02-11 Thread Jacques Pelletier
On February 11, 2008 05:37:54 pm Vallone, Anthony wrote: From: Vallone, Anthony [EMAIL PROTECTED] To: gtk-list@gnome.org Myself, I avoid the enter/leave calls in favor of g_idle_add() as a mechanism to queue all gui calls for the main event loop thread. Let your other threads stick to

Re: Glib: Adding watch in the glib event poll

2008-01-27 Thread Jacques Pelletier
On January 25, 2008 01:45:40 pm Jacques Pelletier wrote: Hi, I want to do a customized input routine for specialized hardware plugged into a parallel port. I don't have any device driver yet for this hardware. I have to poll bits; in my case, if the BUSY bit = 0, there's a character

Glib: Adding watch in the glib event poll

2008-01-25 Thread Jacques Pelletier
Hi, I want to do a customized input routine for specialized hardware plugged into a parallel port. I don't have any device driver yet for this hardware. I have to poll bits; in my case, if the BUSY bit = 0, there's a character available on the data lines. I made my own version of add watch