You Are Here:

Community: Developer Discussion Boards

#1 Old appuifw.form: both FFormDoubleSpaced and FFormEditModeOnly - 2008-10-27, 16:23

Join Date: Oct 2008
Posts: 29
mango7
Offline
Registered User
Hi,

I have a working form that uses the FFormEditModeOnly flag. I need to add the FFormDoubleSpaced flag, so that I can allow the user to edit the form and to display the label on a different line from the value.

Does anyone have a working example of this?

Here is the __init__ code I have so far:

def __init__():
self.isSaved = False
self.fields = [(u'color', 'text', u'...'),
(u'tv show', 'text', u'...'),
(u'movie', 'text', u'...')]
self.currForm = appuifw.Form(self.fields, appuifw.FFormEditModeOnly)
self.currForm.save_hook = self.markSaved
self.currForm.flags = appuifw.FFormEditModeOnly

Does anyone know how to add FFormDoubleSpaced to this?

Thanks so much!
Reply With Quote

#2 Old Re: appuifw.form: both FFormDoubleSpaced and FFormEditModeOnly - 2008-10-27, 18:34

Join Date: Feb 2008
Posts: 743
Location: Belo Horizonte, Brazil
Send a message via Skype™ to Rafael T.
Rafael T.'s Avatar
Rafael T.
Offline
Forum Nokia Champion
Quote:
Originally Posted by mango7 View Post
Hi,

I have a working form that uses the FFormEditModeOnly flag. I need to add the FFormDoubleSpaced flag, so that I can allow the user to edit the form and to display the label on a different line from the value.

Does anyone have a working example of this?

Here is the __init__ code I have so far:

def __init__():
self.isSaved = False
self.fields = [(u'color', 'text', u'...'),
(u'tv show', 'text', u'...'),
(u'movie', 'text', u'...')]
self.currForm = appuifw.Form(self.fields, appuifw.FFormEditModeOnly)
self.currForm.save_hook = self.markSaved
self.currForm.flags = appuifw.FFormEditModeOnly

Does anyone know how to add FFormDoubleSpaced to this?

Thanks so much!
Hi mango7,

You can do this easily. Your code would be like this:

Code:
def __init__():
        self.isSaved = False
        self.fields = [(u'color', 'text', u'...'),
                       (u'tv show', 'text', u'...'),
                       (u'movie', 'text', u'...')]
        self.flags = appuifw.FFormEditModeOnly + appuifw.FFormDoubleSpaced
        self.currForm = appuifw.Form(self.fields, self.flags)
        self.currForm.save_hook = self.markSaved
So what I did there was just two things:

- add "+ appuifw.FFormDoubleSpaced" to self.flags ( I changed self.currForm.flags for self.flags because it's cleaner for me )

- set self.currForm to execute with self.fields and self.flags


Next time please use the code tag for posting codes


Hope it helps,

Rafael.
Last edited by Rafael T. : 2008-10-27 at 18:42.
Reply With Quote

#3 Old Re: appuifw.form: both FFormDoubleSpaced and FFormEditModeOnly - 2008-10-30, 01:45

Join Date: Feb 2008
Posts: 743
Location: Belo Horizonte, Brazil
Send a message via Skype™ to Rafael T.
Rafael T.'s Avatar
Rafael T.
Offline
Forum Nokia Champion
mango7, did you got it?


BR,

Rafael.
Reply With Quote

#4 Old Re: appuifw.form: both FFormDoubleSpaced and FFormEditModeOnly - 2008-10-30, 01:52

Join Date: Oct 2008
Posts: 29
mango7
Offline
Registered User
This was perfect - Thanks so much!
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules

You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia 
RDF Facets: qdcZidentifierQSxhttpE3aE2fE2fdiscussionE2eforumE2enokiaE2ecomhttpE3aE2fE2fdiscussionE2eforumE2enokiaE2ecomE2fforumE2fshowthreadE2ephpE3ftE3d81449X qdcZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qdcZtypeQUqfntypeZCommunityContentQ qdcZtypeQUqfntypeZE44iscussionQ qdcZtypeQUqfntypeZE44iscussionContentQ qdcZtypeQUqfntypeZE52esourceQ qdcZtypeQUqfntypeZWebpageQ qdcZtypeQUqmarsZManagedE52esourceQ qdcZtypeQUqwebZInformationE52esourceQ qdcZtypeQUqwebZPageQ qdcZtypeQUqwebZE52esourceQ qdcZtypeQUqrdfsZE52esourceQ qfnZtopicQUqfnTopicZpythonQ qfnZtypeQUqfntypeZCommunityContentQ qfnZtypeQUqfntypeZE44iscussionQ qfnZtypeQUqfntypeZE44iscussionContentQ qfnZtypeQUqfntypeZE52esourceQ qfnZtypeQUqfntypeZWebpageQ qfnZuserE5ftagQSxpythonX qmarsZlanguageQUxhttpE3aE2fE2fswE2enokiaE2ecomE2flanguageE2d1E2fenX qrdfZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qrdfZtypeQUqfntypeZCommunityContentQ qrdfZtypeQUqfntypeZE44iscussionQ qrdfZtypeQUqfntypeZE44iscussionContentQ qrdfZtypeQUqfntypeZE52esourceQ qrdfZtypeQUqfntypeZWebpageQ qrdfZtypeQUqmarsZManagedE52esourceQ qrdfZtypeQUqwebZInformationE52esourceQ qrdfZtypeQUqwebZPageQ qrdfZtypeQUqwebZE52esourceQ qrdfZtypeQUqrdfsZE52esourceQ