My Spinner Widgets look different on different devices. How can I define a own Spinner that looks th
Posted
by Janusz
on Stack Overflow
See other posts from Stack Overflow
or by Janusz
Published on 2010-05-20T13:49:15Z
Indexed on
2010/05/20
13:50 UTC
Read the original article
Hit count: 285
I use this code to generate a spinner in my app:
subCatAdapter = new ArrayAdapter<Subcategory>(this, android.R.layout.simple_spinner_item, subCategories);
subCatAdapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
On my device (Motorola Milestone) and in the emulator this looks like the standard gray spinner widget. On of my colleagues uses a Motorola Backflip and on his device the Spinner is black. Now its very hard to read the font in the spinner.
What do I have to do to use my own view for the spinner? I don't mind to have the gray spinner on all devices, but it should always look the same on all devices.
© Stack Overflow or respective owner