Android Question [UnSolved] Adjust Margin/Padding in Preference?

monic

Active Member
Licensed User
Longtime User
Hi All, I'm using the preference library and since updating the android sdk 28 i now have a margin when i open the preference activity padding or icon issue?

Ive redownloaded the sdk into a fresh folder and still the same results

https://stackoverflow.com/questions...preferencefragment-width-or-get-rid-of-margin

I will edit this post with a sample.

Example of the problem



issue.jpg
 

Attachments

  • example.zip
    199.1 KB · Views: 249
Last edited:

monic

Active Member
Licensed User
Longtime User
Hi Peter,

Thanks for your suggestion I've tried Corwin42 example and it doesn't appear. Up until the point of updating the sdk it didn't exist and no app changes on the affected app.
 
Upvote 0

yiankos1

Well-Known Member
Licensed User
Longtime User
Hi All, I'm using the preference library and since updating the android sdk 28 i now have a margin when i open the preference activity padding or icon issue?

Ive redownloaded the sdk into a fresh folder and still the same results

https://stackoverflow.com/questions...preferencefragment-width-or-get-rid-of-margin

I will edit this post with a sample.

Example of the problem



issue.jpg
I have exaclty same problem with @corwin42 material preferences wrap after update to 28sdk. Did you figure it out how solve this?
 
Upvote 0

Semen Matusovskiy

Well-Known Member
Licensed User
I don't have troubles with corwin42 samples, because I saved mavens 27.1.1. But ok, you use 28.0.0. In corwin42's example there are activities Prefs1, Prefs2.
Like I understand a picture from stackoverflow, new maven makes wide left/right margins

At the end of Activity_Create you can add something like this

B4X:
    For Each v As View In Activity
        If v <> ToolBar Then
            v.Width = v.Width + 100dip
            v.Left = -50dip          
        End If
    Next

Maybe not 50dip, but less or more.
 
Upvote 0

monic

Active Member
Licensed User
Longtime User
The issue I find is that the view does move left but because of the space indents the header title goes off screen.
 
Upvote 0
Top