rgb
1
hi all,
I create a widget button with no parent window
but
after created
how to attach it to widget window ?
thanks,
bye
PtWidget_t *win,*but;
win = PtCreateWidget(PtWindow,… …);
PtRealizeWidget(win);
but = PtCreateWidget(PtButton,Pt_NO_PARENT,2,args);
{
// How to Attach to PtWidget_t button to Window ?
rgb <rgb@free.fr> wrote:
hi all,
I create a widget button with no parent window
but
after created
how to attach it to widget window ?
thanks,
bye
PtWidget_t *win,*but;
win = PtCreateWidget(PtWindow,… …);
PtRealizeWidget(win);
but = PtCreateWidget(PtButton,Pt_NO_PARENT,2,args);
{
// How to Attach to PtWidget_t button to Window ?
Change the last line to
but = PtCreateWidget(PtButton,win,2,args);
or
but = PtCreateWidget(PtButton,NULL,2,args);
If you specify NULL as the second argument, the widget will
be parented to the last container widget that was created
(in this case, your window)