Lists: | pgadmin-hackerspgadmin-support |
---|
From: | Raymond O'Donnell <rod(at)iol(dot)ie> |
---|---|
To: | Pgadmin-Support <pgadmin-support(at)postgresql(dot)org> |
Subject: | PgAdmin 1.10 beta 1 - scratch pad won't go away |
Date: | 2009-03-17 15:28:43 |
Message-ID: | [email protected] |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Lists: | pgadmin-hackers pgadmin-support |
Hi all,
Whenever I open a new instance of the Query Tool, the scratch pad pane
is always visible, even if I had closed it the last time I had a query
window open.
In previous versions, once I closed the scratch pad it remained hidden
thereafter.
I'm running on Windows XP SP2.
Ray.
------------------------------------------------------------------
Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland
rod(at)iol(dot)ie
Galway Cathedral Recitals: http://www.galwaycathedral.org/recitals
------------------------------------------------------------------
From: | Dave Page <dpage(at)pgadmin(dot)org> |
---|---|
To: | rod(at)iol(dot)ie |
Cc: | Pgadmin-Support <pgadmin-support(at)postgresql(dot)org>, Luis Ochoa <ziul1979(at)gmail(dot)com> |
Subject: | Re: PgAdmin 1.10 beta 1 - scratch pad won't go away |
Date: | 2009-03-17 22:12:43 |
Message-ID: | [email protected] |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Lists: | pgadmin-hackers pgadmin-support |
On Tue, Mar 17, 2009 at 3:28 PM, Raymond O'Donnell <rod(at)iol(dot)ie> wrote:
> Hi all,
>
> Whenever I open a new instance of the Query Tool, the scratch pad pane
> is always visible, even if I had closed it the last time I had a query
> window open.
>
> In previous versions, once I closed the scratch pad it remained hidden
> thereafter.
Thanks - fixed in SVN. This was a side effect of the way the query
builder hides/shows the scratch pad and output pane when it is
shown/hidden.
There is still a slight oddity there - when you return to the SQL pane
from the GQB, the width of the scratch pad returns to it's default.
Luis; any idea what's causing that?
--
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com
From: | Dave Page <dpage(at)pgadmin(dot)org> |
---|---|
To: | Luis Ochoa <ziul1979(at)gmail(dot)com> |
Cc: | Pgadmin-Support <pgadmin-support(at)postgresql(dot)org> |
Subject: | Re: PgAdmin 1.10 beta 1 - scratch pad won't go away |
Date: | 2009-03-18 09:42:00 |
Message-ID: | [email protected] |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Lists: | pgadmin-hackers pgadmin-support |
[Re-adding the support list]
Hi Luis
On Wed, Mar 18, 2009 at 2:06 AM, Luis Ochoa <ziul1979(at)gmail(dot)com> wrote:
> Then the bug:
>
>> There is still a slight oddity there - when you return to the SQL pane
>> from the GQB, the width of the scratch pad returns to it's default.
>> Luis; any idea what's causing that?
>
> The problem is the Scratch pad and outputPane are not inside the
> sqlNotebook:
> sqlNotebook->AddPage(sqlQuery, _("SQL Editor"));
> sqlNotebook->AddPage(controller->getViewContainer(), _("Graphical Query
> Builder"));
Yup.
> instead it's located at the wxAUI just like the sqlNotebook, because of this
> I create a little hack that show/hide the scratchPad when you change between
> the SQL Editor and the GQB, but this hack have a side effect that I don't
> know until now and right now I don't know how to fix it.
> ...
> manager.AddPane(outputPane, ...);
> manager.AddPane(scratchPad, ...);
> manager.AddPane(sqlNotebook, ...);
>
> The problem is here:
> if(sqlNotebook && sqlNotebook->GetPageCount() >= 2)
> {
>
> if (event.GetSelection() == 0)
> {
> ...
> if (viewMenu->IsChecked(MNU_OUTPUTPANE))
> manager.GetPane(wxT("outputPane")).Show(true);
> if (viewMenu->IsChecked(MNU_SCRATCHPAD))
> manager.GetPane(wxT("scratchPad")).Show(true);
> manager.Update();
> ...
> }
> else
> {
> manager.GetPane(wxT("outputPane")).Show(false);
> manager.GetPane(wxT("scratchPad")).Show(false);
> manager.Update();
> ...
> }
>
> When I use the show / hide function in wxAui the objects are hide, but when
> they're show they recover their original size and not the previous size,
> because of this the bug affect either scratchPad and outputPane.
That's the code I changed to fix Ray's problem - the code was
unconditionally re-enabling the two panes, whereas it now only
re-enables them if they were visible to begin with.
However, that isn't the cause of the resizing as far as I'm aware - we
can usually turn panes on and off without them losing their size. In
fact, when the scratch pad is re-displayed, it looks to me as though
it does take it's original size to begin with, and then resizes, so I
wonder if it's part of the GQB layout code that's causing a resize.
I'm suspicious of the code that's fired by the timer.
> I'm going to research for a solution and probably this weekend I will fix
> it, meanwhile I disable this function on this patch to demostrate how it
> affect the GUI. But if you have any ideas or suggestions welcome!
I haven't applied the patch as we're in beta now, so I don't want to
apply anything except the final bug fix. I have applied the control ID
fix though - thaks.
> P.S. I don't send this mail to pgadmin-hackers list because you sent it
> directly to me.
Only because I wasn't sure if you're watching the support list :-p
--
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com
From: | Dave Page <dpage(at)pgadmin(dot)org> |
---|---|
To: | Luis Ochoa <ziul1979(at)gmail(dot)com> |
Cc: | pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org> |
Subject: | Re: [pgadmin-support] PgAdmin 1.10 beta 1 - scratch pad won't go away |
Date: | 2009-04-06 09:44:46 |
Message-ID: | [email protected] |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Lists: | pgadmin-hackers pgadmin-support |
[moving to hackers]
On Fri, Apr 3, 2009 at 11:37 PM, Luis Ochoa <ziul1979(at)gmail(dot)com> wrote:
> Hi Dave I was researching today the resize output pane bug but I believe is
> something with wxAui, I'm not 100% sure but with a simple action I can test
> my point, if you start pgAdmin resize object browser pane, go to view menu
> unselect it (Ctrl-Alt-O) to hide and then show again, object browser pane
> returns to their original size?,
Right - but that's when the user explicitly hides the scratch pad.
When it is programmatically hidden as part of the way the UI is
implemented then it should restore its original position and size.
Given your finding, I would suggest that unless there's a way to
store/restore the pane position and size (which there may be - perhaps
you can use the wxPaneInfo), then we need to look at how the form is
laid out (maybe leave the scratch pad alone and simply don't hide it -
the user can always do so himself if he needs more space).
--
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com