I have two panes that are already displayed in the aui-managed frame.
I want to "put one on another" to make a notebook, programatically.
How do I do it?
(I tried `.NotebookPage` and `.NotebookControl` but got exceptions, so
I'm probably doing something wrong.)
Ram.
···
--
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en
Hi,
I have two panes that are already displayed in the aui-managed frame.
I want to "put one on another" to make a notebook, programatically.
How do I do it?
(I tried `.NotebookPage` and `.NotebookControl` but got exceptions, so
I'm probably doing something wrong.)
Try this:
self._mgr.AddPane(window_1, aui.AuiPaneInfo().Name("AutoNotebook")
self._mgr.AddPane(window_2, aui.AuiPaneInfo(),
target=self._mgr.GetPane("AutoNotebook"))
It's just another version of "AddPane", but when you specify a
"target" keyword it will programmatically create a new AuiNotebook
with the "target" and the newly added pane. There is an example on the
AUI demo too.
Andrea.
"Imagination Is The Only Weapon In The War Against Reality."
http://xoomer.alice.it/infinity77/
==> Never *EVER* use RemovalGroup for your house removal. You'll
regret it forever.
The Doomed City: Removal Group: the nightmare <==
···
On 17 April 2010 13:30, cool-RR wrote:
--
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en
I saw this method in the code, the reason I didn’t use it is that in my case the panes have already been added. I can’t add them again, can’t I?
Ram.
···
On Sat, Apr 17, 2010 at 3:32 PM, Andrea Gavana andrea.gavana@gmail.com wrote:
Hi,
On 17 April 2010 13:30, cool-RR wrote:
I have two panes that are already displayed in the aui-managed frame.
I want to “put one on another” to make a notebook, programatically.
How do I do it?
(I tried .NotebookPage
and .NotebookControl
but got exceptions, so
I’m probably doing something wrong.)
Try this:
self._mgr.AddPane(window_1, aui.AuiPaneInfo().Name(“AutoNotebook”)
self._mgr.AddPane(window_2, aui.AuiPaneInfo(),
target=self._mgr.GetPane(“AutoNotebook”))
It’s just another version of “AddPane”, but when you specify a
“target” keyword it will programmatically create a new AuiNotebook
with the “target” and the newly added pane. There is an example on the
AUI demo too.
Andrea.
–
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en
Hi,
Hi,
> I have two panes that are already displayed in the aui-managed frame.
> I want to "put one on another" to make a notebook, programatically.
> How do I do it?
>
> (I tried `.NotebookPage` and `.NotebookControl` but got exceptions, so
> I'm probably doing something wrong.)
Try this:
self._mgr.AddPane(window_1, aui.AuiPaneInfo().Name("AutoNotebook")
self._mgr.AddPane(window_2, aui.AuiPaneInfo(),
target=self._mgr.GetPane("AutoNotebook"))
It's just another version of "AddPane", but when you specify a
"target" keyword it will programmatically create a new AuiNotebook
with the "target" and the newly added pane. There is an example on the
AUI demo too.
Andrea.
I saw this method in the code, the reason I didn't use it is that in my case
the panes have already been added. I can't add them again, can't I?
Yes you can:
self._mgr.DetachPane(window_2)
self._mgr.AddPane(window_2, aui.AuiPaneInfo().Name("PaneName"),
target=self._mgr.GetPane("AutoNotebook"))
self._mgr.Update()
Andrea.
"Imagination Is The Only Weapon In The War Against Reality."
http://xoomer.alice.it/infinity77/
==> Never *EVER* use RemovalGroup for your house removal. You'll
regret it forever.
The Doomed City: Removal Group: the nightmare <==
···
On 17 April 2010 14:37, cool-RR wrote:
On Sat, Apr 17, 2010 at 3:32 PM, Andrea Gavana <andrea.gavana@gmail.com> > wrote:
On 17 April 2010 13:30, cool-RR wrote:
--
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en
I eventually used your first method and it worked. Thanks.
Ram.
···
On Sat, Apr 17, 2010 at 3:45 PM, Andrea Gavana andrea.gavana@gmail.com wrote:
Hi,
On 17 April 2010 14:37, cool-RR wrote:
On Sat, Apr 17, 2010 at 3:32 PM, Andrea Gavana andrea.gavana@gmail.com > > > wrote:
Hi,
On 17 April 2010 13:30, cool-RR wrote:
I have two panes that are already displayed in the aui-managed frame.
I want to “put one on another” to make a notebook, programatically.
How do I do it?
(I tried .NotebookPage
and .NotebookControl
but got exceptions, so
I’m probably doing something wrong.)
Try this:
self._mgr.AddPane(window_1, aui.AuiPaneInfo().Name(“AutoNotebook”)
self._mgr.AddPane(window_2, aui.AuiPaneInfo(),
target=self._mgr.GetPane(“AutoNotebook”))
It’s just another version of “AddPane”, but when you specify a
“target” keyword it will programmatically create a new AuiNotebook
with the “target” and the newly added pane. There is an example on the
AUI demo too.
Andrea.
I saw this method in the code, the reason I didn’t use it is that in my case
the panes have already been added. I can’t add them again, can’t I?
Yes you can:
self._mgr.DetachPane(window_2)
self._mgr.AddPane(window_2, aui.AuiPaneInfo().Name(“PaneName”),
target=self._mgr.GetPane(“AutoNotebook”))
self._mgr.Update()
Andrea.
–
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en