Namespaces

Variants
Actions

Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.

Archived:TextFields cannot be added to the same row using MIDP 2.0 item shrinking layout directives in S60 (Known Issue)

From Wiki
Jump to: navigation, search

Archived.pngArchived: This article is archived because it is not considered relevant for third-party developers creating commercial solutions today. If you think this article is still relevant, let us know by adding the template {{ReviewForRemovalFromArchive|user=~~~~|write your reason here}}.


Article Metadata
Tested with
Devices(s): All S60 2nd and 3rd Edition devices
CompatibilityArticle
Created: User:Technical writer 1 (19 Oct 2007)
Last edited: hamishwillee (25 Oct 2013)

Description

According to the Nokia Developer document MIDP 2.0: Introduction, two TextFields can be shrinked to fit on the same row by using the required layout directives LAYOUT_SHRINK and LAYOUT_2 in devices supporting MIDP 2.0. However, when using the directives as defined in the document, TextFields will be placed on different rows.

How to reproduce

The problem can be reproduced by using the following example code as defined in the document MIDP 2.0: Introduction (Section 2.7.2, "Layouts"):

  private TextField tfAreacode; // Areacode
private TextField tfNumber; // Phone number
...
// Create text message and commands
tfAreacode = new TextField("Phone:", null, 3, TextField.NUMERIC);
tfAreacode.setLayout(Item.LAYOUT_SHRINK | Item.LAYOUT_2);
tfNumber = new TextField(null, null, 7, TextField.NUMERIC);
tfNumber.setLayout(Item.LAYOUT_SHRINK | Item.LAYOUT_2);

Solution

No known solution. Current S60 MIDP implementations ignore these directives and do not add more than one Item on the same row.

This page was last modified on 25 October 2013, at 06:22.
95 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×