[TIMOB-10166] Android: BorderRadius on TableView doesn't clip content on Android, Ti 2.1.0
GitHub Issue | n/a |
Type | Bug |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2012-09-19T17:01:13.000+0000 |
Affected Version/s | Release 2.1.0 |
Fix Version/s | Release 2.1.3, Release 3.0.0, Sprint 2012-19 Core, 2012 Sprint 19 |
Components | Android |
Labels | SupportTeam, community, core, module_tableview, parity, qe-testadded |
Reporter | Quang Pham |
Assignee | Allen Yeung |
Created | 2012-07-13T03:11:21.000+0000 |
Updated | 2013-09-26T11:03:04.000+0000 |
Description
Steps to Reproduce
Titanium.UI.setBackgroundColor('#000');
var win = Titanium.UI.createWindow({
title:'Tab 1',
backgroundColor:'#fff'
});
var rows = [];
for (var i=0; i < 5; i++) {
var row = Ti.UI.createTableViewRow({});
row.add(Ti.UI.createView({ width: 100, height: 50, left: 0, backgroundColor: 'blue', borderWidth: 1, borderColor: '#000' }));
rows.push(row);
};
var table = Ti.UI.createTableView({ data: rows, borderWidth: 1, borderRadius: 10, borderColor: 'blue', backgroundColor: '#fff', rowHeight: 50, top: 100, left: 100, right: 100, height: Ti.UI.SIZE });
win.add(table);
win.open();
Actual Result
overflow content is not clipping, override borderRadius
Expected Result
overflow content is clipping
Attachments
Same issue here. Android 2.1 and 2.2, with Titanium SDK 2.1.0 and 2.1.1
Possible workaround is to embed table view into generic view with border radius set.
Note to self: Must investigate feasibility of doing such and get back to Alan by the 28th.
Talked with other Allen. He implemented something for views, and it wasn't inherited by TableView, but he sees no reason why it couldn't be done. Schedule for next sprint.
Now that feasibility is known, returning it to Neeraj to be dispatched.
PR Ready: https://github.com/appcelerator/titanium_mobile/pull/2980
Please test this against the most recent PR. It seems to work for me, as in the image shows up.
Backport for 2_1_X: https://github.com/appcelerator/titanium_mobile/pull/3006
my app is working again with ayeung:timob-10166-2_1_X, thanks!
Verified fix with: osx Mountain Lion 10.8.1 Titanium Studio, build: 2.1.2.201208301612 Titanium SDK: 2.1.3.v20120920154617 Titanium SDK: 3.0.0.v20120921144915 Device: Nexus S3 4.0.4