[TIMOB-19565] iOS: TableView header has wrong default height
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2015-09-22T22:51:31.000+0000 |
Affected Version/s | Release 5.0.0 |
Fix Version/s | Release 5.1.0 |
Components | iOS |
Labels | listview |
Reporter | Hans Knöchel |
Assignee | Hans Knöchel |
Created | 2015-09-22T04:15:40.000+0000 |
Updated | 2015-10-13T20:11:36.000+0000 |
Description
The default height of the UITableView section header is 29px, we currently use 20px. See the screenshot for comparison.
The fix is simple: Increase the value of the macro
DEFAULT_SECTION_HEADERFOOTER_HEIGHT
inside the TiUIListView.m from 20 to 29 and check the results.
*Demo code*:
var win = Titanium.UI.createWindow({
title : 'UITableView',
backgroundColor : '#fff'
});
var list = Ti.UI.createListView();
var sec = Ti.UI.createListSection({headerTitle: "Test"});
var item = {properties: {title: "Title"}};
sec.setItems([item,item,item]);
list.setSections([sec,sec]);
win.add(list);
win.open();
Attachments
File | Date | Size |
---|---|---|
UITableView.png | 2015-09-22T04:14:16.000+0000 | 36394 |
Comparison after adjusting the height: http://abload.de/img/uitableview-fixed9wuml.png
PR: https://github.com/appcelerator/titanium_mobile/pull/7221
APPROVED. PR merged.
Verified as fixed, am able to see the corrected default height on sim and device build. OSX El Capitan 10.11 Studio: 4.3.1.201509302304 Ti SDK: 5.2.0.v20151009071418 Appc NPM: 4.2.1-1 Appc CLI: 5.1.0-38