Re: glade and/or gtkmm, insert a FileChooserDialog inside a Notebook tab

Tobias Schneider-Schönberg <[email protected]> Thu, 29 Jan 2015 09:52:06 +0100
Newsgroups gmane.comp.gnome.glade.user
Message-ID <CADwMZvVfW_-7Nx4nuCq32bBPHJaS8WCmZsJVOHh2dSL+1Zhevw@mail.gmail.com>
--===============0195224548==
Content-Type: multipart/alternative; boundary=001a113cd2ba486ec5050dc69a53

--001a113cd2ba486ec5050dc69a53
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

Hi Nicolas!

Putting a file chooser widget into a notebook works for me in Glade 3.18.3:

https://gist.github.com/f6b38748572903a17078

Maybe you are mixing up "file chooser dialog" with "file chooser widget".

atb, Tobias

2015-01-29 9:23 GMT+01:00 Nicolas J=C3=A4ger <[email protected]>:

> Hi,
>
> I would like to have a `FileChooserDialog` in a tab of a `Notebook`
> when I summon it. When I try to move the `FileChooserDialog` over the
> `Notebook`, glade seems to runs an infinite loop, in the console I get
> continuously :
>
> =E2=94=8B
> =E2=94=8B(glade:12662): Gtk-CRITICAL **: gtk_container_remove: assertion
> =E2=94=8B'gtk_widget_get_parent (widget) =3D=3D GTK_WIDGET (container) ||
> =E2=94=8BGTK_IS_ASSISTANT (container) || GTK_IS_ACTION_BAR (container)' f=
ailed
> =E2=94=8B
>
> I tried inside my program to get what I want with that code :
>
> =E2=94=8B
> =E2=94=8B  Notebook->append_page( FileChooserDialog, "whatever" );
> =E2=94=8B
>
> but I got these two messages :
>
> =E2=94=8B
> =E2=94=8BGtk-CRITICAL **: gtk_widget_set_child_visible:
> =E2=94=8Bassertion !gtk_widget_is_toplevel (widget)' failed
> =E2=94=8BGtk-WARNING **: Can't set a parent on a toplevel widget
> =E2=94=8B
>
> there is a way to do what I want ?
>
> regards,
> /nicoo
> _______________________________________________
> Glade-users maillist  -  [email protected]
> http://lists.ximian.com/mailman/listinfo/glade-users
>

--001a113cd2ba486ec5050dc69a53
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div>Hi Nicolas!<br><br></div>Putting a file chooser widge=
t into a notebook works for me in Glade 3.18.3:<br><div><div><br><a href=3D=
"https://gist.github.com/f6b38748572903a17078">https://gist.github.com/f6b3=
8748572903a17078</a><br><br></div><div>Maybe you are mixing up &quot;file c=
hooser dialog&quot; with &quot;file chooser widget&quot;.<br></div><div><br=
></div><div>atb, Tobias<br></div></div></div><div class=3D"gmail_extra"><br=
><div class=3D"gmail_quote">2015-01-29 9:23 GMT+01:00 Nicolas J=C3=A4ger <s=
pan dir=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=3D"_b=
lank">[email protected]</a>&gt;</span>:<br><blockquote class=3D"gmail=
_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:=
1ex">Hi,<br>
<br>
I would like to have a `FileChooserDialog` in a tab of a `Notebook`<br>
when I summon it. When I try to move the `FileChooserDialog` over the<br>
`Notebook`, glade seems to runs an infinite loop, in the console I get<br>
continuously :<br>
<br>
=E2=94=8B<br>
=E2=94=8B(glade:12662): Gtk-CRITICAL **: gtk_container_remove: assertion<br=
>
=E2=94=8B&#39;gtk_widget_get_parent (widget) =3D=3D GTK_WIDGET (container) =
||<br>
=E2=94=8BGTK_IS_ASSISTANT (container) || GTK_IS_ACTION_BAR (container)&#39;=
 failed<br>
=E2=94=8B<br>
<br>
I tried inside my program to get what I want with that code :<br>
<br>
=E2=94=8B<br>
=E2=94=8B=C2=A0 Notebook-&gt;append_page( FileChooserDialog, &quot;whatever=
&quot; );<br>
=E2=94=8B<br>
<br>
but I got these two messages :<br>
<br>
=E2=94=8B<br>
=E2=94=8BGtk-CRITICAL **: gtk_widget_set_child_visible:<br>
=E2=94=8Bassertion !gtk_widget_is_toplevel (widget)&#39; failed<br>
=E2=94=8BGtk-WARNING **: Can&#39;t set a parent on a toplevel widget<br>
=E2=94=8B<br>
<br>
there is a way to do what I want ?<br>
<br>
regards,<br>
/nicoo<br>
_______________________________________________<br>
Glade-users maillist=C2=A0 -=C2=A0 <a href=3D"mailto:[email protected]=
an.com">[email protected]</a><br>
<a href=3D"http://lists.ximian.com/mailman/listinfo/glade-users" target=3D"=
_blank">http://lists.ximian.com/mailman/listinfo/glade-users</a><br>
</blockquote></div><br></div>

--001a113cd2ba486ec5050dc69a53--

--===============0195224548==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Glade-users maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/glade-users

--===============0195224548==--