Problem description
Ti.UI.Label's are being cut of on the bottom in layout vertical when top is specified.
Test case
var w = Ti.UI.createWindow({
backgroundColor:"white"
});
var container = Ti.UI.createView({
width:500,
height:250,
borderColor:"blue",
layout:"vertical"
});
var textLabel1 = Ti.UI.createLabel({
width:Ti.UI.FILL,
height:Ti.UI.SIZE,
// bottom:10,
text:"Vestibulum id ligula porta felis euismod semper.",
font: {
fontSize:24,
fontWeight:"bold"
}
});
var textLabel2 = Ti.UI.createLabel({
// top:10,
width:Ti.UI.FILL,
height:Ti.UI.FILL,
text:"Duis mollis, est non commodo luctus, nisi erat porttitor ligula, eget lacinia odio sem nec elit. Aenean lacinia bibendum nulla sed consectetur. Nullam quis risus eget urna mollis ornare vel eu leo. Donec sed odio dui. Integer posuere erat a ante venenatis dapibus posuere velit aliquet. Etiam porta sem malesuada magna mollis euismod. Donec sed odio dui. Aenean lacinia bibendum nulla sed consectetur. Maecenas sed diam eget risus varius blandit sit amet non magna. Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Maecenas sed diam eget risus varius blandit sit amet non magna. Sed posuere consectetur est at lobortis."
});
container.add(textLabel1);
container.add(textLabel2);
w.add(container);
w.open();
If you toggle the top:10 in textLabel2 on and off you see that the label is cut off and half a line is shown.
If you give textLabel1 a bottom instead of textLabel2 a top it looks as expected.
If you don't use vertical layout it works as expected.
Expected
Labels should truncate the labels text and add ...'s.
Different issue, same cause.
Duplicates TIMOB-10856
This is actually not a duplicate, and not fixed... (now also tested on SDK 3.0.0.GA, and in Alloy)
Closing ticket as duplicate of the ticket that is mentioned above and has since been closed.
Closed, not fixed...