Poor menu layout

by Edward Falk » Thu, 05 Mar 2009 05:25:10 GMT


Sponsored Links
 Hi all; I took a bare-bones "hello world" application and added these
four menu items in onCreateOptionsMenu():

+--------------------------------------------+
|                    Start                   |
+--------------------------------------------+
|                    Find                    |
+----------------------+---------------------+
|Enable Location Provid|        About        |
+----------------------+---------------------+

[you'll need a fixed-width font to view this properly]

As you can see, the menu was very poorly laid out.  Making my 3rd
label shorter fixed the problem, but this definitely looks like broken
behavior to me.  Is there anything I'm doing wrong here?  The relevant
code is:

  @Override
  public boolean onCreateOptionsMenu(Menu menu) {
    super.onCreateOptionsMenu(menu);
    menu.add(Menu.NONE, Menu.NONE, Menu.NONE,
R.string.menu_start_label);
    menu.add(Menu.NONE, Menu.NONE, Menu.NONE,
R.string.menu_find_label);
    menu.add(Menu.NONE, Menu.NONE, Menu.NONE,
R.string.enable_location);
    menu.add(Menu.NONE, Menu.NONE, Menu.NONE,
R.string.menu_about_label);
    return true;
  }


full source available at  http://www.efalk.org/tester3.tar.gz 

ADVthanksANCE,

  -ed falk
--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. OOT WTB ipodtouch

Buat nyang asik2 androidan,bosen ma itouch 2nd gen 8gb nya..
Lempar kemari yah..
Kalo murmer ane tangkep..
*pemanasan sbelum ipad*

    yudhis...@gmail.com    [for JAPRI]  
    yudhistyaksyatria           [ for YM   ]   


~YK~

-- 
--------------
"Indonesian Android Community [id-android]" 

2. mirink at pim

Oh jadi yah, saya akhirnya nganter anak jalan2 nih, hmm kapan lagi bisa
mirink kyk gini ya?

wisnu




sedang mirink bersama AJ and Chippy. Rooting Nexus one dan gua msih problem
sync hero.
hehehe. maklum,aja yah.

send from big Hero, my Android phone

-- 
--------------
"Indonesian Android Community [id-android]"

3. Receiver during timeout: GentleAlarm developer needs help

4. IM native buat Her

5. sdk setup.exe and windows 7

6. berguru

7. Blocking on a Socket read operation