maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   Tutorial / best practices for Qt development? (https://talk.maemo.org/showthread.php?t=34879)

robbie 2009-11-21 17:01

Tutorial / best practices for Qt development?
 
I'm trying to port an application to Maemo (keepassx). I manage to get it running with the latest 4.6 environment but some screens need some rework.

Are there any docs/tutorials with best practices?

For example, the keepassx screens are designed so that a user can resize them. That makes no sense on the N900 because all windows are fixed (the width anyway). Are there guidelines/tips for screensizes?

The input fields are too small when using the default (see image below). If i make them 41 pixels high, it's usable. Are there any guidelines/tips for object sizes?

Are there any good/simple examples that shows usage of qt objects?

Maemo version:
http://www.xs4all.nl/~gnista/qt46maemo_edit.png

Qt Creator version:
http://www.xs4all.nl/~gnista/qt46maemo_edit2.png

Fargus 2009-11-21 17:20

Re: Tutorial / best practices for Qt development?
 
Quote:

Originally Posted by robbie (Post 385308)
I'm trying to port an application to Maemo (keepassx). I manage to get it running with the latest 4.6 environment but some screens need some rework.

Are there any docs/tutorials with best practices?

For example, the keepassx screens are designed so that a user can resize them. That makes no sense on the N900 because all windows are fixed (the width anyway). Are there guidelines/tips for screensizes?

The input fields are too small when using the default (see image below). If i make them 41 pixels high, it's usable. Are there any guidelines/tips for object sizes?

Are there any good/simple examples that shows usage of qt objects? ....

Have you tried the GUI Guidelines ? http://www.forum.nokia.com/info/sw.n...yle_Guide.html

pH5 2009-11-21 17:22

Re: Tutorial / best practices for Qt development?
 
Quote:

Originally Posted by robbie (Post 385308)
For example, the keepassx screens are designed so that a user can resize them. That makes no sense on the N900 because all windows are fixed (the width anyway). Are there guidelines/tips for screensizes?

The input fields are too small when using the default (see image below). If i make them 41 pixels high, it's usable. Are there any guidelines/tips for object sizes?

I'm not sure about Qt specifics, but to all layout questions you should be able to find an answer in the Fremantle Master Layout Guide.

robbie 2009-11-21 17:47

Re: Tutorial / best practices for Qt development?
 
Thanks!

The master layout guide provides at least some sizes. Now see if i can translate that to the gui designer of Qt Designer..

qgil 2009-11-22 20:18

Re: Tutorial / best practices for Qt development?
 
Maybe this helps: http://wiki.forum.nokia.com/index.ph...velopers_Guide

More at http://www.forum.nokia.com/Tools_Doc...on/Maemo.xhtml

robbie 2009-11-23 07:13

Re: Tutorial / best practices for Qt development?
 
qgil, Thanks for the links. I think the first link would be helpfull on the page of the second link as well. The second link unfortunatly doesn't have an application that is created with the gui designer of Qt creator.

My problem is that i'm trying to port an existing application to Maemo. Most of the code runs fine but the gui is all messed up because keepassx normally is used on screens larger than 800x400 (aprox availible size without menubar).

What i'm looking for is a guide that tells how big you have to make the objects so that you can see what you get on the device. Here's what i found out so far:
  • You should create a gui specially for Maemo. Standard gui's won't work well (see screenshot).
  • Menu's look nice. Probably need a stylus to use them (but thats alright)
  • The labels are Nokia Sans 18
  • The textfields should be at least 40 pixels high so that the text fits in
  • You must disable code for handling the systray because the N900 doesn't have a systray and the application won't compile

Some anoyances:
  • Creation a gui with Qt creator designer is not wysiwyg. It's trial and error.
  • I can't seem to get the scrollarea working. That would probably make life easier on a limited screen height.

labra 2010-01-06 14:55

Re: Tutorial / best practices for Qt development?
 
Is this still under development?

http://maemo.org/packages/view/keepassx/


All times are GMT. The time now is 00:01.

vBulletin® Version 3.8.8