• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 709
  • Last Modified:

Android Spinner Layout Issue

I have been working in Android for a while but can't figure this one out.

I have a horizontal linear layout that includes two spinners... So far so good.

The first spinner is always offset about 40 dip below the first. No matter what layout I use (TableLayout, LinearLayout etc..) the first spinner is always below the second.

Has anyone seen this behavior before? If so, how can I correct it?

Geoff
0
gdrnec
Asked:
gdrnec
  • 2
1 Solution
 
Dejan PažinHead of SW DevelopmentCommented:

Please post the code, so we can see where the problem is.
0
 
alexey_gusevCommented:
from my experience with Android, it is likely to be due to "gravity" or "layout_gravity", but please post your xml so we all can see it
0
 
gdrnecAuthor Commented:
I solved it.  

My apologies to the experts. While I was putting together the code to post here, I found the issue.

The one spinner that was offset below the other was wrapped in an extra LinearLayout. Once both had the same layout parents, the problem was solved.

Working with such text based (xml) non compiled indirect code seems to lead to such confusions quite a bit.
0
 
gdrnecAuthor Commented:
This was solved by the asker of the question.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now