Re: [gtkmm] Gtk::Notebook problem
- From: Daniel Sundberg <dss home se>
- To: ioan nicu ines ro
- Cc: gtkmm-list gnome org
- Subject: Re: [gtkmm] Gtk::Notebook problem
- Date: Sun, 7 Sep 2003 15:32:52 +0200
On 07 Sep 2003 16:22:29 +0300
Ioan Nicu <ioan nicu ines ro> wrote:
> Hi
>
>
> Is there a way I can use the same widget as the contents for multiple
> pages in a Gtk::Notebook?
>
> Example:
>
> I have a Gtk::ScrolledWindow that contains a Gtk::TextView. I create a
> Gtk::Notebook and append a page containing the scrolledwindow widget.
> That works fine...
> But then I can't call append_page() again with the same scrolledwindow
> widget. I get the following error:
>
> Gtk-CRITICAL **: file gtkwidget.c: line 3817 (gtk_widget_set_parent):
> assertion `widget->parent == NULL' failed
>
> I want to be able to use the same TextView in multiple tabs (pages), and
> change only the contents of the underlying TextBuffer for the TextView.
>
I think you should create multiple textview that which uses the same textbuffer. As far as I know that is how you are supposed to use the gtk+ *view widgets.
To to answer your question: you can't add a widget to more than one container.
---
Daniel Sundberg
http://sumpan.com
> Please help! The gtkmm documentation, examples and source code
> didn't help me so far...
>
>
>
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtkmm-list
>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]