0

I have an app that runs on both layout and handset. Some screens use fragments and everything works properly. The problem is in some activities like the login one.

I would like to constraint the width of the elements in signin page to a certain maximum width in order to not make it stretch (making it looks not natural).

Is there a clean solution besides creating new layouts?

Thanks Tobia Loschiavo

Matroska
  • 6,885
  • 14
  • 63
  • 99
  • 1
    I think this is exactly what you are looking for: http://stackoverflow.com/questions/5875877/setting-max-width-of-linearlayout-or-other-viewgroup-on-android – Ostkontentitan May 15 '12 at 10:46
  • Great...why isn't it a standard solution in android? – Matroska May 15 '12 at 19:41
  • Must have some thought in it. they imlemented an maxWidth attribute especially for imageView instead of just View: http://developer.android.com/reference/android/widget/ImageView.html – Ostkontentitan May 16 '12 at 05:30

0 Answers0