Pregunta

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?

¿Fue útil?

Solución

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.

Otros consejos

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

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top