[TIMOB-19240] iOS: Change of fontWeight or fontFamily also changes fontSize
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | Medium |
| Status | Closed |
| Resolution | Duplicate |
| Resolution Date | 2017-07-08T22:18:19.000+0000 |
| Affected Version/s | n/a |
| Fix Version/s | n/a |
| Components | iOS |
| Labels | TCSupportTriage, font, fontFamily, fontSize, fontWeight, label |
| Reporter | Fokke Zandbergen |
| Assignee | Eric Merriman |
| Created | 2014-11-12T13:25:29.000+0000 |
| Updated | 2017-07-19T21:25:11.000+0000 |
Description
The following test case shows that on iOS changing only a Label's fontWeight or fontFamily will also change the fontSize. I'd expect the fontSize to stay the same, just like it does on Android.
Test case
var win = Titanium.UI.createWindow({
backgroundColor: '#ddd',
});
win.add(Ti.UI.createLabel({
top: 100,
text: 'No font property',
}));
win.add(Ti.UI.createLabel({
top: 200,
text: 'Font property for fontWeight only',
font: {
fontWeight: 'bold'
}
}));
win.add(Ti.UI.createLabel({
top: 300,
text: 'Font property for fontFamily only',
font: {
fontFamily: Ti.Platform.name === 'android' ? 'Roboto' : 'AmericanTypewriter'
}
}));
win.open();
Attachments
| File | Date | Size |
|---|---|---|
| Screen Shot 2014-11-12 at 14.24.32.png | 2014-11-12T13:25:29.000+0000 | 58979 |
| Screen Shot 2014-11-12 at 14.24.50.png | 2014-11-12T13:25:29.000+0000 | 33753 |
Uh... yes, that's not the issue. The issue is that the second label shows smaller while only the fontWeight is different from the first.
Fixed in 6.2.0!
Closing ticket as duplicate.