문제

I have in my settings bundle of my application two text fields , where the user can give latitude and longitude values.

The bundle settings look like this :

enter image description here

As you see the values (43.46 and -3.81) are left aligned.

Is there a way to right align them so it looks better?

도움이 되었습니까?

해결책

It seems the only answer to this question is to add spaces on the title of the text field , till your values move to the left side.

Is not very delicate , but looks better than this.

다른 팁

This worked for me in in-app settings view. I have not tried it with settings.

Open property list file as a source and paste the following to the for each entry you want right-aligned:

        <key>IASKTextAlignment</key>
        <string>IASKUITextAlignmentCenter</string>

Or do the same through the plist editor.

You can do that in different way. You have to add a Title preference item. and add titles and values inside that. I have a screenshot here,

Settings bundle plist file

And the resulting settings screen will look like this,

enter image description here

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top