{ "id": "170983", "key": "TIMOB-25754", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [], "resolution": null, "resolutiondate": null, "created": "2018-01-26T10:37:32.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [], "versions": [], "issuelinks": [ { "id": "58733", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "175489", "key": "TIMOB-28103", "fields": { "summary": "iOS: View shadow not working anymore if combined with border radius (9.1.0 regression)", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "Critical", "id": "1" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "jvennemann", "key": "jvennemann", "displayName": "Jan Vennemann", "active": true, "timeZone": "Europe/Berlin" }, "updated": "2020-10-07T17:21:06.000+0000", "status": { "description": "The issue is open and ready for the assignee to start work on it.", "name": "Open", "id": "1", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": " setting viewShadowColor on Button causes it to ignore borderRadius property.\r\n\r\n\r\ntestCase:\r\n\r\n\r\n{code:javascript}\r\nvar win = Titanium.UI.createWindow();\r\nvar btn = Titanium.UI.createButton({\r\n viewShadowColor: '#992E2E2E',\r\n\tviewShadowOffset: {\r\n\t\tx: 0,\r\n\t\ty: 3\r\n\t},\r\n\tviewShadowRadius: 3,\r\n borderRadius:20,\r\n width:200,\r\n height:40,\r\n title:\"test\"\r\n\r\n\r\n});\r\n\r\nwin.add(btn);\r\nwin.open();\r\n{code}", "attachment": [ { "id": "64757", "filename": "Captura de pantalla 2018-01-26 a las 11.33.33.png", "author": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-01-26T10:34:37.000+0000", "size": 9307, "mimeType": "image/png" }, { "id": "64758", "filename": "Captura de pantalla 2018-01-26 a las 11.34.17.png", "author": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-01-26T10:34:27.000+0000", "size": 8230, "mimeType": "image/png" } ], "flagged": false, "summary": "iOS: setting viewShadowColor on Button causes it to ignore borderRadius property", "creator": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "433732", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "Did this work in earlier versions of the SDK? Also, it seems to work for me unless I set a background-color:\r\n{code:js}\r\nvar win = Titanium.UI.createWindow({backgroundColor: '#fff'});\r\nvar btn = Titanium.UI.createButton({\r\n // backgroundColor: 'green',\r\n viewShadowColor: '#992E2E2E',\r\n\tviewShadowOffset: {\r\n\t\tx: 0,\r\n\t\ty: 3\r\n\t},\r\n\tviewShadowRadius: 3,\r\n borderRadius:20,\r\n width:200,\r\n height:40,\r\n title:\"test\"\r\n});\r\n \r\nwin.add(btn);\r\nwin.open();\r\n{code}", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2018-01-26T18:23:56.000+0000", "updated": "2018-01-26T18:23:56.000+0000" }, { "id": "433752", "author": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Just tested with the following SDK:\r\n\r\n||SDK||borderRadius applied to shadow||borderRadius applied to button||\r\n|6.1.2.GA|true|false|\r\n|6.2.0.GA|true|false|\r\n|6.2.2.GA|true|false|\r\n|6.3.0.GA|true|false|\r\n|7.0.0.GA|true|false|\r\n\r\nJust remember that could be related with this issue: [ImageView shadow|https://github.com/AndreaVitale/av.imageview/issues/24]", "updateAuthor": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-01-27T12:22:35.000+0000", "updated": "2018-01-27T12:22:35.000+0000" }, { "id": "433759", "author": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "body": "Hello, I tested the issue on previous version 7.0.0.GA, 6.3.0.GA, 6.2.2.Ga, I can see the border-radius does work with viewShadowColor. Also, as [~hknoechel], said with background-color this does not. So, the issue is with the background color. With background color, border-radius does not work, but viewShadowColor does. Thanks.", "updateAuthor": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "created": "2018-01-27T16:48:52.000+0000", "updated": "2018-01-27T16:52:00.000+0000" }, { "id": "436861", "author": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Any update on this?", "updateAuthor": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-04-13T10:34:22.000+0000", "updated": "2018-04-13T10:34:22.000+0000" }, { "id": "438455", "author": { "name": "mark.henderson@snagr.co.uk", "key": "mark.henderson@snagr.co.uk", "displayName": "Mark Henderson", "active": true, "timeZone": "Europe/London" }, "body": "Any update on this? Such a strange glitch.. ", "updateAuthor": { "name": "mark.henderson@snagr.co.uk", "key": "mark.henderson@snagr.co.uk", "displayName": "Mark Henderson", "active": true, "timeZone": "Europe/London" }, "created": "2018-06-17T02:26:27.000+0000", "updated": "2018-06-17T02:26:27.000+0000" }, { "id": "443252", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "Would be great to see in 8.0.0! I'll also try to hack on this.", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2018-11-03T17:24:23.000+0000", "updated": "2018-11-03T17:24:23.000+0000" }, { "id": "443276", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "It seems to be related to clashing view-layer properties and clipping / masking. [This|https://stackoverflow.com/a/25475536/5537752] should work, but I wasn't able to apply it to the SDK structure so far. Any help is appreciated.", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2018-11-05T08:25:20.000+0000", "updated": "2018-11-05T08:25:20.000+0000" }, { "id": "444965", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "Quick workaround: Create a view with a label instead of a button and / or place the button inside the shadowed view. ", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2019-01-03T15:29:32.000+0000", "updated": "2019-01-03T15:29:32.000+0000" }, { "id": "455666", "author": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Any news on this?", "updateAuthor": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-06-08T12:59:23.000+0000", "updated": "2020-06-08T12:59:23.000+0000" }, { "id": "457069", "author": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "body": "[~bgarcia] It should work in 9.2.0 with a minor change (Update \r\n{code:java}\r\nborderRadius: 20\r\n{code}\r\n to \r\n{code:java}\r\nborderRadius: '20 20'\r\n{code}\r\n). Reason is in case of multiple value of border radius, we use UIBezierPath and CAShapeLayer to create add corner radius. See following updated test case -\r\n\r\n\r\n{code:java}\r\nvar win = Titanium.UI.createWindow({\r\n\tbackgroundColor: 'white'\r\n});\r\nvar btn = Titanium.UI.createButton({\r\n viewShadowColor: 'red',\r\n\tviewShadowOffset: {\r\n\t\tx: 0,\r\n\t\ty: 3\r\n\t},\r\n\tviewShadowRadius: 3,\r\n\tbackgroundColor: 'green',\r\n borderRadius: '20 20',\r\n width:200,\r\n height:40,\r\n title:\"test\"\r\n});\r\n \r\nwin.add(btn);\r\nwin.open();\r\n{code}\r\n", "updateAuthor": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-09-28T23:13:16.000+0000", "updated": "2020-09-28T23:19:59.000+0000" }, { "id": "457090", "author": { "name": "Pietro", "key": "pietro", "displayName": "Pietro Granati", "active": true, "timeZone": "Europe/Rome" }, "body": "Same problem, confirm that the '20 20' solution works but sometimes render strangely with shadow over button", "updateAuthor": { "name": "Pietro", "key": "pietro", "displayName": "Pietro Granati", "active": true, "timeZone": "Europe/Rome" }, "created": "2020-09-30T11:10:28.000+0000", "updated": "2020-09-30T13:54:56.000+0000" }, { "id": "457186", "author": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I can confirm what Pietro reported. with the \"20 20\" the shadow works nice until you hide the button, in that case the shadow remains in screen and, in my case, it has a strange animation. I can share a video showcasing the issue in private", "updateAuthor": { "name": "bgarcia", "key": "bgarcia", "displayName": "Brian García", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-10-07T17:18:36.000+0000", "updated": "2020-10-07T17:21:06.000+0000" } ], "maxResults": 12, "total": 12, "startAt": 0 } } }