Android: Unwanted left/right margins on Nexus 10 in landscape mode -


i'm having issue seemingly inexplicable margins appear on left , right sides of layouts when using nexus 10 device in landscape mode. i'm sure it's embarrassingly straightforward, can't find mention of when searching around.

i'm pretty sure it's not related code, because default hello world project created eclipse exhibits phenomenon. following screenshot excerpts taken brand new project , change have made make textview textsize bit bigger clarity:

comparison of landscape , portrait orientations on nexus 10

you can see default margins layout xml file (shown below) applied correctly in portrait mode, there considerable additional margin applied in landscape mode - indicated red bar underneath screenshot.

<!-- default screen margins, per android design guidelines. --> <dimen name="activity_horizontal_margin">16dp</dimen> <dimen name="activity_vertical_margin">16dp</dimen> 

has else seen or have idea how can rid of them? don't know start, because seems specific 1 device , screen orientation. plus affects simplest program possible, own, there's no sense in pulling apart own code until find out how fix default case.
same screens display correctly on emulated devices , samsung galaxy s2 (running gingerbread). changing project build target api level 17 10 didn't alter unwanted effect either. thoughts?

ok, embarrassingly straightforward! margin nexus 10 in landscape mode taken 'values-sw720dp-land' resource folder, declares larger value:

<!--      customize dimensions defined in res/values/dimens.xml (such      screen margins) sw720dp devices (e.g. 10" tablets) in landscape here. --> <dimen name="activity_horizontal_margin">128dp</dimen> 

after year of lurking on , finding answers questions, first 1 decide ask turns out trivial this...


Comments

Popular posts from this blog

php - get table cell data from and place a copy in another table -

javascript - Mootools wait with Fx.Morph start -

php - Navigate throught databse rows -