diff options
author | Kavindra Devi Palaraja <kavindra.palaraja@nokia.com> | 2009-06-04 14:25:12 +0200 |
---|---|---|
committer | con <qtc-committer@nokia.com> | 2009-06-05 10:34:02 +0200 |
commit | 6c14c86fab33ea10119dde90b8621a0562868bbd (patch) | |
tree | bb76da0d727530bc108e02f502c520bfb8e7a084 /doc/addressbook-sdk.qdoc | |
parent | 388c24ba78b03151ba1e6b680d65e1fdd6211c0d (diff) | |
download | qt-creator-6c14c86fab33ea10119dde90b8621a0562868bbd.tar.gz |
Fixes: Doc - more of Part 3
RevBy: TrustMe
Diffstat (limited to 'doc/addressbook-sdk.qdoc')
-rw-r--r-- | doc/addressbook-sdk.qdoc | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/doc/addressbook-sdk.qdoc b/doc/addressbook-sdk.qdoc index 041b8651fb..f20e1ae564 100644 --- a/doc/addressbook-sdk.qdoc +++ b/doc/addressbook-sdk.qdoc @@ -272,10 +272,11 @@ We shall continue with the form we had from the last chapter; we have the labels and input fields set up, but we need to add push buttons to complete the process of adding a contact. So, we begin by breaking the existing - layouts. Then, we add three push buttons. Double-click on each of them to - set their text to "Add", "Submit", and "Cancel". We now require a vertical - spacer to ensure that the push buttons will be laid out neatly; drag one - from the \gui{Widget Box}. + layouts: select \gui{Break Layout} from the context menu. You might have to + do a \gui{Select All} with \key{Ctrl+A} first.. Then, we add three push + buttons. Double-click on each of them to set their text to "Add", "Submit", + and "Cancel". We now require a vertical spacer to ensure that the push + buttons will be laid out neatly; drag one from the \gui{Widget Box}. Next, lay out these three push buttons and the spacer vertically, by selecting all three of them (using the \key{Ctrl + click}) and choosing @@ -447,6 +448,21 @@ \section1 Placing Widgets on the Form + So far, our application allows us to add new contacts. However, we also + need to traverse the existing contacts. To do so, we add two push buttons + at the bottom of our application and name them: \gui Next and + \gui Previous. Place them in a horizontal layout. + + To lay the buttons out, we begin by breaking our top level layout. Simply + right-click on \c AddressBook in the \gui{Object Inspector} and then select + \gui{Lay out|Break Layout} Then we drag two push buttons onto the form and + name them accordingly. The buttons' \c objectName should be \c nextButton + and \c previousButton, respectively. + \section1 The AddressBook Class + In order to add navigation functions to the address book application, we + need to add two more slots to our \c AddressBook class: \c next() and + \c previous(). + */ |