Обсуждение: Rework on the dialogs UI

Поиск
Список
Период
Сортировка

Rework on the dialogs UI

От
Guillaume Lelarge
Дата:
Hi,

The patch attached changes some dialogs UI so that they work on a
800x600 screen.

What i did, mostly, was to keep name, oid, owner, comment, and
replication widgets in the first tab, and added a second one for the
rest of the definition of the object (hence the tab's name, Definition).

Comments?

PS: there is still work to do on the frmOptions dialog which is bigger
than a 800x600 screen.


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

Re: Rework on the dialogs UI

От
Guillaume Lelarge
Дата:
Le 07/04/2011 12:10, Guillaume Lelarge a écrit :
> [...]
> The patch attached changes some dialogs UI so that they work on a
> 800x600 screen.
>
> What i did, mostly, was to keep name, oid, owner, comment, and
> replication widgets in the first tab, and added a second one for the
> rest of the definition of the object (hence the tab's name, Definition).
>
> Comments?
>
> PS: there is still work to do on the frmOptions dialog which is bigger
> than a 800x600 screen.
>
>

Sorry, patch attached this time.


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

Вложения

Re: Rework on the dialogs UI

От
Dave Page
Дата:
On Thu, Apr 7, 2011 at 11:11 AM, Guillaume Lelarge
<guillaume@lelarge.info> wrote:
> Le 07/04/2011 12:10, Guillaume Lelarge a écrit :
>> [...]
>> The patch attached changes some dialogs UI so that they work on a
>> 800x600 screen.
>>
>> What i did, mostly, was to keep name, oid, owner, comment, and
>> replication widgets in the first tab, and added a second one for the
>> rest of the definition of the object (hence the tab's name, Definition).
>>
>> Comments?
>>
>> PS: there is still work to do on the frmOptions dialog which is bigger
>> than a 800x600 screen.
>>
>>
>
> Sorry, patch attached this time.
>

Hi

Just took a quick look at a number of dialogues and had some comments:

- Did you do a pass over *all* dialogues? dlgJob for example, isn't
touched, but I'm not sure it needs to be.

- dlgDatabase isn't wide enough by default on the Mac (you cannot see
all of the tabs). Also applies to dlgFunction, and maybe others.

- The catalog properties dialogue crashes horribly.

- Have you come up with a new set of standard sizes?

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Re: Rework on the dialogs UI

От
Guillaume Lelarge
Дата:
Le 07/04/2011 14:58, Dave Page a écrit :
> On Thu, Apr 7, 2011 at 11:11 AM, Guillaume Lelarge
> <guillaume@lelarge.info> wrote:
>> Le 07/04/2011 12:10, Guillaume Lelarge a écrit :
>>> [...]
>>> The patch attached changes some dialogs UI so that they work on a
>>> 800x600 screen.
>>>
>>> What i did, mostly, was to keep name, oid, owner, comment, and
>>> replication widgets in the first tab, and added a second one for the
>>> rest of the definition of the object (hence the tab's name, Definition).
>>>
>>> Comments?
>>>
>>> PS: there is still work to do on the frmOptions dialog which is bigger
>>> than a 800x600 screen.
>>>
>>>
>>
>> Sorry, patch attached this time.
>>
>
> Hi
>
> Just took a quick look at a number of dialogues and had some comments:
>
> - Did you do a pass over *all* dialogues? dlgJob for example, isn't
> touched, but I'm not sure it needs to be.
>

Yeah, I looked at all of them. I decided not to change dialogs that are
not related to a SQL type (IOW, replication ones and pgAgent ones). They
seem to work on a 800x600 screen.

> - dlgDatabase isn't wide enough by default on the Mac (you cannot see
> all of the tabs). Also applies to dlgFunction, and maybe others.
>

Should apply to dlgTable too.

> - The catalog properties dialogue crashes horribly.
>

It doesn't crash on my laptop (I tried with information_schema and
pg_catalog on a PostgreSQL HEAD).

> - Have you come up with a new set of standard sizes?
>

Yeah, two sizes:

 * small one: 220,250
 * big one: 270,250

But it seems I forgot dlgServer and dlgTable. Just fixed dlgServer.
Working on dlgTable right now.

(once again, I didn't touch replication dialogs and pgAgent dialogs)


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

Re: Rework on the dialogs UI

От
Guillaume Lelarge
Дата:
Le 07/04/2011 15:17, Guillaume Lelarge a écrit :
> Le 07/04/2011 14:58, Dave Page a écrit :
>> On Thu, Apr 7, 2011 at 11:11 AM, Guillaume Lelarge
>> <guillaume@lelarge.info> wrote:
>>> Le 07/04/2011 12:10, Guillaume Lelarge a écrit :
>>>> [...]
>>>> The patch attached changes some dialogs UI so that they work on a
>>>> 800x600 screen.
>>>>
>>>> What i did, mostly, was to keep name, oid, owner, comment, and
>>>> replication widgets in the first tab, and added a second one for the
>>>> rest of the definition of the object (hence the tab's name, Definition).
>>>>
>>>> Comments?
>>>>
>>>> PS: there is still work to do on the frmOptions dialog which is bigger
>>>> than a 800x600 screen.
>>>>
>>>>
>>>
>>> Sorry, patch attached this time.
>>>
>>
>> Hi
>>
>> Just took a quick look at a number of dialogues and had some comments:
>>
>> - Did you do a pass over *all* dialogues? dlgJob for example, isn't
>> touched, but I'm not sure it needs to be.
>>
>
> Yeah, I looked at all of them. I decided not to change dialogs that are
> not related to a SQL type (IOW, replication ones and pgAgent ones). They
> seem to work on a 800x600 screen.
>
>> - dlgDatabase isn't wide enough by default on the Mac (you cannot see
>> all of the tabs). Also applies to dlgFunction, and maybe others.
>>
>
> Should apply to dlgTable too.
>

Fixed that issue. I was only looking at a new database, rather than at
an existing one (a tab is added when looking at an existing database).

>> - The catalog properties dialogue crashes horribly.
>>
>
> It doesn't crash on my laptop (I tried with information_schema and
> pg_catalog on a PostgreSQL HEAD).
>

Still didn't reproduce it.

>> - Have you come up with a new set of standard sizes?
>>
>
> Yeah, two sizes:
>
>  * small one: 220,250

new small size is 250,250

>  * big one: 270,250
>
> But it seems I forgot dlgServer and dlgTable. Just fixed dlgServer.
> Working on dlgTable right now.
>

Fixed too.

I fixed also the frmOptions window.

New patch (to apply after the old one... I mean they both need to be
applied).


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

Вложения

Re: Rework on the dialogs UI

От
Dave Page
Дата:
On Thu, Apr 7, 2011 at 2:57 PM, Guillaume Lelarge
<guillaume@lelarge.info> wrote:
>>> - The catalog properties dialogue crashes horribly.
>>>
>>
>> It doesn't crash on my laptop (I tried with information_schema and
>> pg_catalog on a PostgreSQL HEAD).
>>
>
> Still didn't reproduce it.

When it opens I can briefly see the cancel button at the top left
before it crashes, then:

Exception Type:  EXC_BAD_ACCESS (SIGBUS)
Exception Codes: KERN_PROTECTION_FAILURE at 0x00000000000001c8
Crashed Thread:  0  Dispatch queue: com.apple.main-thread

Thread 0 Crashed:  Dispatch queue: com.apple.main-thread
0   pgAdmin3-Debug                    0x00173f08
dlgSecurityProperty::OnChangeSize(wxSizeEvent&) + 24
1   libwx_base_carbonu-2.8.dylib      0x014e24d3
wxEvtHandler::ProcessEventIfMatches(wxEventTableEntryBase const&,
wxEvtHandler*, wxEvent&) + 131
2   libwx_base_carbonu-2.8.dylib      0x014e2b51
wxEventHashTable::HandleEvent(wxEvent&, wxEvtHandler*) + 113
3   libwx_base_carbonu-2.8.dylib      0x014e2e7f
wxEvtHandler::ProcessEvent(wxEvent&) + 207
4   libwx_macu_core-2.8.dylib         0x0102ea3d
wxTopLevelWindowMac::Show(bool) + 397
5   libwx_macu_core-2.8.dylib         0x00fe1d3d wxDialog::Show(bool) + 45
6   pgAdmin3-Debug                    0x0017c47b dlgProperty::Go(bool) + 4155
7   pgAdmin3-Debug                    0x0017cd36
dlgDefaultSecurityProperty::Go(bool, bool, wxString const&, wxString
const&, wxString const&) + 38
8   pgAdmin3-Debug                    0x0019235a dlgSchema::Go(bool) + 474
9   pgAdmin3-Debug                    0x0017a37f
dlgProperty::EditObjectDialog(frmMain*, ctlSQLBox*, pgObject*) + 559
10  pgAdmin3-Debug                    0x0017a6f3
propertyFactory::StartDialog(frmMain*, pgObject*) + 35
11  pgAdmin3-Debug                    0x001fb316
frmMain::OnAction(wxCommandEvent&) + 70
...
...

>>> - Have you come up with a new set of standard sizes?
>>>
>>
>> Yeah, two sizes:
>>
>>  * small one: 220,250
>
> new small size is 250,250

I wonder if it should be 300 wide? The tab labels are all visible now,
but the edges aren't.

>>  * big one: 270,250
>>
>> But it seems I forgot dlgServer and dlgTable. Just fixed dlgServer.
>> Working on dlgTable right now.
>>
>
> Fixed too.

:-)

> I fixed also the frmOptions window.

Not quite - see the attached screenshot.

BTW, that one also seems to be missing the status bar. Wanna fix that
while you're there?

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Вложения

Re: Rework on the dialogs UI

От
Guillaume Lelarge
Дата:
Le 07/04/2011 17:07, Dave Page a écrit :
> On Thu, Apr 7, 2011 at 2:57 PM, Guillaume Lelarge
> <guillaume@lelarge.info> wrote:
>>>> - The catalog properties dialogue crashes horribly.
>>>>
>>>
>>> It doesn't crash on my laptop (I tried with information_schema and
>>> pg_catalog on a PostgreSQL HEAD).
>>>
>>
>> Still didn't reproduce it.
>
> When it opens I can briefly see the cancel button at the top left
> before it crashes, then:
>
> Exception Type:  EXC_BAD_ACCESS (SIGBUS)
> Exception Codes: KERN_PROTECTION_FAILURE at 0x00000000000001c8
> Crashed Thread:  0  Dispatch queue: com.apple.main-thread
>
> Thread 0 Crashed:  Dispatch queue: com.apple.main-thread
> 0   pgAdmin3-Debug                    0x00173f08
> dlgSecurityProperty::OnChangeSize(wxSizeEvent&) + 24
> 1   libwx_base_carbonu-2.8.dylib      0x014e24d3
> wxEvtHandler::ProcessEventIfMatches(wxEventTableEntryBase const&,
> wxEvtHandler*, wxEvent&) + 131
> 2   libwx_base_carbonu-2.8.dylib      0x014e2b51
> wxEventHashTable::HandleEvent(wxEvent&, wxEvtHandler*) + 113
> 3   libwx_base_carbonu-2.8.dylib      0x014e2e7f
> wxEvtHandler::ProcessEvent(wxEvent&) + 207
> 4   libwx_macu_core-2.8.dylib         0x0102ea3d
> wxTopLevelWindowMac::Show(bool) + 397
> 5   libwx_macu_core-2.8.dylib         0x00fe1d3d wxDialog::Show(bool) + 45
> 6   pgAdmin3-Debug                    0x0017c47b dlgProperty::Go(bool) + 4155
> 7   pgAdmin3-Debug                    0x0017cd36
> dlgDefaultSecurityProperty::Go(bool, bool, wxString const&, wxString
> const&, wxString const&) + 38
> 8   pgAdmin3-Debug                    0x0019235a dlgSchema::Go(bool) + 474
> 9   pgAdmin3-Debug                    0x0017a37f
> dlgProperty::EditObjectDialog(frmMain*, ctlSQLBox*, pgObject*) + 559
> 10  pgAdmin3-Debug                    0x0017a6f3
> propertyFactory::StartDialog(frmMain*, pgObject*) + 35
> 11  pgAdmin3-Debug                    0x001fb316
> frmMain::OnAction(wxCommandEvent&) + 70
> ...
> ...
>

I think I know why. The OnChangeSize() method is specific to the Mac
platform. It substracts 550 to the height, but I lower the height a bit,
so 550 is probably too big now.

I tried all this afternoon to have a mac build, but still have no
result. Either you try smaller number in
dlgSecurityProperty::OnChangeSize() or you'll have to wait that I'm able
to compile on my Mac :-/

>>>> - Have you come up with a new set of standard sizes?
>>>>
>>>
>>> Yeah, two sizes:
>>>
>>>  * small one: 220,250
>>
>> new small size is 250,250
>
> I wonder if it should be 300 wide? The tab labels are all visible now,
> but the edges aren't.
>

Done in the patch attached.

>>>  * big one: 270,250
>>>
>>> But it seems I forgot dlgServer and dlgTable. Just fixed dlgServer.
>>> Working on dlgTable right now.
>>>
>>
>> Fixed too.
>
> :-)
>
>> I fixed also the frmOptions window.
>
> Not quite - see the attached screenshot.
>

Should be fixed in the patch attached.

> BTW, that one also seems to be missing the status bar. Wanna fix that
> while you're there?
>

AFAIR, there is no status bar in the frmOptions window. Do you really
want to add it to this window? what for?


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

Вложения

Re: Rework on the dialogs UI

От
Dave Page
Дата:
On Fri, Apr 8, 2011 at 10:50 AM, Guillaume Lelarge
<guillaume@lelarge.info> wrote:
> I think I know why. The OnChangeSize() method is specific to the Mac
> platform. It substracts 550 to the height, but I lower the height a bit,
> so 550 is probably too big now.

Ahh no - it's because securityPage is NULL for a catalog dialogue - it
just needs the first 2 lines to be guarded with "if (securityPage)".
Not sure what the size is for - it seems to work whatever I set that
too.

>> I wonder if it should be 300 wide? The tab labels are all visible now,
>> but the edges aren't.
>>
>
> Done in the patch attached.

Looks better.

>>>>  * big one: 270,250
>>>>
>>>> But it seems I forgot dlgServer and dlgTable. Just fixed dlgServer.
>>>> Working on dlgTable right now.
>>>>
>>>
>>> Fixed too.
>>
>> :-)

Hmm, actually the height is still an issue on the Privileges page. See
the attached screenshot.

>>> I fixed also the frmOptions window.
>>
>> Not quite - see the attached screenshot.
>>
>
> Should be fixed in the patch attached.

Still a little too small - see the other screenshot.

>> BTW, that one also seems to be missing the status bar. Wanna fix that
>> while you're there?
>>
>
> AFAIR, there is no status bar in the frmOptions window. Do you really
> want to add it to this window? what for?

It looks a bit crappy for a start - particularly the positioning of
the OK/Cancel buttons. Also for consistency with the other dialogues,
which I think all have a status bar these days.

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Вложения

Re: Rework on the dialogs UI

От
Guillaume Lelarge
Дата:
Le 08/04/2011 12:35, Dave Page a écrit :
> On Fri, Apr 8, 2011 at 10:50 AM, Guillaume Lelarge
> <guillaume@lelarge.info> wrote:
>> I think I know why. The OnChangeSize() method is specific to the Mac
>> platform. It substracts 550 to the height, but I lower the height a bit,
>> so 550 is probably too big now.
>
> Ahh no - it's because securityPage is NULL for a catalog dialogue - it
> just needs the first 2 lines to be guarded with "if (securityPage)".
> Not sure what the size is for - it seems to work whatever I set that
> too.
>

Oh OK. Thanks for the heads-up. This is now fixed (or at least, I hope
so :) ).

>>> I wonder if it should be 300 wide? The tab labels are all visible now,
>>> but the edges aren't.
>>>
>>
>> Done in the patch attached.
>
> Looks better.
>

Good to know.

>>>>>  * big one: 270,250
>>>>>
>>>>> But it seems I forgot dlgServer and dlgTable. Just fixed dlgServer.
>>>>> Working on dlgTable right now.
>>>>>
>>>>
>>>> Fixed too.
>>>
>>> :-)
>
> Hmm, actually the height is still an issue on the Privileges page. See
> the attached screenshot.
>

Fixed.

>>>> I fixed also the frmOptions window.
>>>
>>> Not quite - see the attached screenshot.
>>>
>>
>> Should be fixed in the patch attached.
>
> Still a little too small - see the other screenshot.
>

The patch attached makes it a bit bigger. I won't be able to make it
bigger though if you want this dialog to work on a 800x600 pixels screen.

Wish I had the time to work on the new frmOptions dialog. We wouldn't
have this issue...

>>> BTW, that one also seems to be missing the status bar. Wanna fix that
>>> while you're there?
>>>
>>
>> AFAIR, there is no status bar in the frmOptions window. Do you really
>> want to add it to this window? what for?
>
> It looks a bit crappy for a start - particularly the positioning of
> the OK/Cancel buttons. Also for consistency with the other dialogues,
> which I think all have a status bar these days.
>

Status bar added (but unused).


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

Re: Rework on the dialogs UI

От
Dave Page
Дата:
On Fri, Apr 8, 2011 at 2:38 PM, Guillaume Lelarge
<guillaume@lelarge.info> wrote:
>
> The patch attached makes it a bit bigger. I won't be able to make it
> bigger though if you want this dialog to work on a 800x600 pixels screen.
>
> Wish I had the time to work on the new frmOptions dialog. We wouldn't
> have this issue...

It's still not great - but if you reduce the vgap to 4 between the
sections on the colour tab, it seems to fit (and look) better.

>>>> BTW, that one also seems to be missing the status bar. Wanna fix that
>>>> while you're there?
>>>>
>>>
>>> AFAIR, there is no status bar in the frmOptions window. Do you really
>>> want to add it to this window? what for?
>>
>> It looks a bit crappy for a start - particularly the positioning of
>> the OK/Cancel buttons. Also for consistency with the other dialogues,
>> which I think all have a status bar these days.
>>
>
> Status bar added (but unused).

Looks better - thanks.



--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Re: Rework on the dialogs UI

От
Guillaume Lelarge
Дата:
Le 08/04/2011 20:28, Dave Page a écrit :
> On Fri, Apr 8, 2011 at 2:38 PM, Guillaume Lelarge
> <guillaume@lelarge.info> wrote:
>>
>> The patch attached makes it a bit bigger. I won't be able to make it
>> bigger though if you want this dialog to work on a 800x600 pixels screen.
>>
>> Wish I had the time to work on the new frmOptions dialog. We wouldn't
>> have this issue...
>
> It's still not great - but if you reduce the vgap to 4 between the
> sections on the colour tab, it seems to fit (and look) better.
>

See attached patch. No problem on Linux. Is it OK for you?


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

Re: Rework on the dialogs UI

От
Dave Page
Дата:
On Fri, Apr 8, 2011 at 9:22 PM, Guillaume Lelarge
<guillaume@lelarge.info> wrote:
> Le 08/04/2011 20:28, Dave Page a écrit :
>> On Fri, Apr 8, 2011 at 2:38 PM, Guillaume Lelarge
>> <guillaume@lelarge.info> wrote:
>>>
>>> The patch attached makes it a bit bigger. I won't be able to make it
>>> bigger though if you want this dialog to work on a 800x600 pixels screen.
>>>
>>> Wish I had the time to work on the new frmOptions dialog. We wouldn't
>>> have this issue...
>>
>> It's still not great - but if you reduce the vgap to 4 between the
>> sections on the colour tab, it seems to fit (and look) better.
>>
>
> See attached patch. No problem on Linux. Is it OK for you?

Perfect :-)

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Re: Rework on the dialogs UI

От
Guillaume Lelarge
Дата:
Le 08/04/2011 22:32, Dave Page a écrit :
> On Fri, Apr 8, 2011 at 9:22 PM, Guillaume Lelarge
> <guillaume@lelarge.info> wrote:
>> Le 08/04/2011 20:28, Dave Page a écrit :
>>> On Fri, Apr 8, 2011 at 2:38 PM, Guillaume Lelarge
>>> <guillaume@lelarge.info> wrote:
>>>>
>>>> The patch attached makes it a bit bigger. I won't be able to make it
>>>> bigger though if you want this dialog to work on a 800x600 pixels screen.
>>>>
>>>> Wish I had the time to work on the new frmOptions dialog. We wouldn't
>>>> have this issue...
>>>
>>> It's still not great - but if you reduce the vgap to 4 between the
>>> sections on the colour tab, it seems to fit (and look) better.
>>>
>>
>> See attached patch. No problem on Linux. Is it OK for you?
>
> Perfect :-)
>

Great, so, I can push the whole thing, right?


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com

Re: Rework on the dialogs UI

От
Dave Page
Дата:
On Fri, Apr 8, 2011 at 9:40 PM, Guillaume Lelarge
<guillaume@lelarge.info> wrote:
> Le 08/04/2011 22:32, Dave Page a écrit :
>> On Fri, Apr 8, 2011 at 9:22 PM, Guillaume Lelarge
>> <guillaume@lelarge.info> wrote:
>>> Le 08/04/2011 20:28, Dave Page a écrit :
>>>> On Fri, Apr 8, 2011 at 2:38 PM, Guillaume Lelarge
>>>> <guillaume@lelarge.info> wrote:
>>>>>
>>>>> The patch attached makes it a bit bigger. I won't be able to make it
>>>>> bigger though if you want this dialog to work on a 800x600 pixels screen.
>>>>>
>>>>> Wish I had the time to work on the new frmOptions dialog. We wouldn't
>>>>> have this issue...
>>>>
>>>> It's still not great - but if you reduce the vgap to 4 between the
>>>> sections on the colour tab, it seems to fit (and look) better.
>>>>
>>>
>>> See attached patch. No problem on Linux. Is it OK for you?
>>
>> Perfect :-)
>>
>
> Great, so, I can push the whole thing, right?

If you're happy with it. I didn't check every last dialogue, but we
can fix any issues that are spotted on different platforms, should
they arise.

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company