on 01-14-2016 12:43 PM
Hi Experts ,
I have a silly question .
I created a very simple form using Simple form layout . Below is the code .
<f:SimpleForm title="The Simpel form layout " maxContainerCols="2" editable="true">
<f:content>
<Label text="FirstName" textAlign="Left"></Label>
<Input type="Text" width="300px" ></Input>
<Label text="name" textAlign="Left"></Label>
<Input type="Text" width="300px" ></Input>
</f:content>
</f:SimpleForm>
Now I am able to get the out put as shown in the screen shot attached.
But its labels are right aligned . I want the labels to be left aligned . I already tried with textAligh = "Left" But no luck .
Can any one suggest here..
Thanks
Rizwan
Hi,
In general, I've always found form layouts to be a bit tricky to work with. In my experience they don't offer as much control as needed in certain situations. But my best guess would be that you should rather play around with the form's layout data instead of the Label's alignment. For example, you can set the layout of the form to layout: "ResponsiveGridLayout", and you should be able to see that the content is already aligned a bit more to the left. As in this jsbin example: JS Bin - Collaborative JavaScript Debugging (just make the output window a bit wider to see the effect)
I would suggest looking at JsDoc Report - SAP UI development Toolkit for HTML5 - API Reference - sap.ui.layout.form.SimpleForm to get an idea of what properties you can play around with in order to get the desired layout.
Unfortunately I'm not very familiar with form layouts so I can't give a lot more information, but I hope this gets you on the right track.I would also suggest using the UI5 chrome extension, since it can provide a much faster method of seeing what changing a property results in UI5 Inspector - Chrome Web Store
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Did you tried textAlign="Begin" ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Here you have all the options: JsDoc Report - SAP UI development Toolkit for HTML5 - API Reference - sap.ui.core.TextAlign
Kind regards,
Wouter
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.