Re: [gtk-list] Calling function w/ multiple parameters



In a previous message, ajam says:
> How can I use "gtk_signal_connect()" to call
> a function that contains three or more parameters,
> which are not necessarily related to the object
> (widget) included in the 'signal handler'

Theres really only one way to do this.  The signal handler has a defined
set of parameters, so you call a "dummy" callback that is used to call your
function (the one with multiple parameters).  There might be trickier ways
to do this, but this is the most straightforward.  If you need to pass data
to your function then use the client_data argument of the 
gtk_signal_connect() call.

-- 
Michael J. Hammel           |Webster's definition of Win95: 32bit extensions and
The Graphics Muse           |graphical shell for a 16bit patch to an 8bit OS 
mjhammel@graphics-muse.org  |originally coded for a 4bit cpu, written by a 2 bit
http://www.graphics-muse.org  company, that can't stand 1 bit of competition.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]