On Jan 18, 2010, at 12:44 PM, colet.patrice@free.fr wrote:
Selon Hans-Christoph Steiner hans@at.or.at:
sys_gui.c. That code is pretty simple. I think you could do it by appending something like "; pdsend "#sys_gui-receiver bang" to every command sent, then bind to the receiver name "#sys_gui-receiver" to get that bang.
attached diff should be this binding method but it doesn't work, the
bang is sent before tcl is done; why attached patch works? (it bangs after tcl
command is done), the only difference is that the send command is trigged.pc
<sys_gui-send-bang.diff><createDir.pd>
Ah, the error came from [textfile] not wanting to write an empty
file. This works for me with your unchanged C code:
For the outlet, I would bind to a unique receive symbol generated from
the pointer to the instance of the sys_gui object, then use that
receive to send the bang in Tcl, receive it in C, then output it out
the outlet:
sprintf(buf,"#%lx", (long unsigned int)x);
.hc
News is what people want to keep hidden and everything else is
publicity. - Bill Moyers