5B4AIT Calendar
November 2012
M T W T F S S
« Oct   Dec »
 1234
567891011
12131415161718
19202122232425
2627282930  
HamSphere Forums

HamSphere info

Yahoo! Weather Forecasts
Cyprus Mail News

Android update

I am still working on the HamSphere app for Android. It is hard work. The iOS platform is so much easier when it comes to screen sizes and op systems. Android has million versions it feels and all different kinds of screen resolutions. The biggest issue the beta testers had was the screen-size and the graphics. As the beta 1 app was written using Relative Layout with fixed positions it was not properly displayed in all gadgets. I have now reworked the layout and I am using:

DisplayMetrics metrics = context.getResources().getDisplayMetrics();
int screenWidth = metrics.widthPixels;
int screenHeight = metrics.heightPixels;

And the LinearLayout

LinearLayout ll = new LinearLayout(context);
ll.setLayoutParams(new LinearLayout.LayoutParams(LinearLayout.LayoutParams.FILL_PARENT, LinearLayout.LayoutParams.FILL_PARENT));
ll.setOrientation(LinearLayout.HORIZONTAL);

LinearLayout.LayoutParams llvParms = new LinearLayout.LayoutParams(screenWidth/5+screenWidth/30, LinearLayout.LayoutParams.FILL_PARENT);
LinearLayout.LayoutParams llmParms = new LinearLayout.LayoutParams(3*screenWidth/5-screenWidth/15, LinearLayout.LayoutParams.FILL_PARENT);
LinearLayout.LayoutParams llhParms = new LinearLayout.LayoutParams(screenWidth/5+screenWidth/30, LinearLayout.LayoutParams.FILL_PARENT);

LinearLayout llv = new LinearLayout(context);
llv.setOrientation(LinearLayout.VERTICAL);
llv.setLayoutParams(llvParms);

LinearLayout llm = new LinearLayout(context);
llm.setOrientation(LinearLayout.VERTICAL);
llm.setLayoutParams(llmParms);

LinearLayout llh = new LinearLayout(context);
llh.setOrientation(LinearLayout.VERTICAL);
llh.setLayoutParams(llhParms);

The above example shows how I place the three vertical colums on screen (Switches, LCD/S-meter, Band-selector)

I will release the result as Beta 2 soon – I promise. Just need to get this screen look pretty first.

73
Kelly

Leave a Reply

Solar-Terrestrial Data
free counters

IP address
Tag Cloud