{ "id": "111200", "key": "TIMOB-13164", "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": { "id": "2", "description": "The problem described is an issue which will never be fixed.", "name": "Won't Fix" }, "resolutiondate": "2018-03-12T14:22:02.000+0000", "created": "2013-03-14T11:07:07.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [ "@font-face", "css", "css3", "fontfamily", "mobileweb" ], "versions": [], "issuelinks": [], "assignee": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "updated": "2018-04-04T23:20:29.000+0000", "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" } }, "components": [ { "id": "11500", "name": "MobileWeb", "description": "Mobile Web (HTML) Platform" } ], "description": "*When using a custom font, rendered CSS code is not valid.*\r\n\r\nh3. Steps to reproduce\r\n\r\n# create a new Titanium project (Single Window Application template)\r\n# _alloy new_ it\r\n# create assets/fonts directory and put any -- supported non-system -- font in there\r\n# change Label element style so it calls the mentioned font\r\n{code}\r\n\"Label\": {\r\n color: \"#000\",\r\n font: {\r\n fontFamily: \"Comic Zine OT\"\r\n }\r\n}\r\n{code}\r\n# see the font not being applied to the element\r\n\r\nh3. Analysis\r\n\r\nWhen opening the built mobileweb/titanium.css, our font declaration at the very end of the file is\r\n{code}\r\n@font-face {\r\n font-family: fonts/comic_zine_ot.otf;\r\n src: url(fonts/comic_zine_ot.otf);\r\n}\r\n{code}\r\n\r\nTo be usable by browser, it should be\r\n{code}\r\n@font-face {\r\n font-family: \"Some Font Name\";\r\n src: url(fonts/comic_zine_ot.otf);\r\n}\r\n{code}\r\n\r\nTo be working, \"Some Font Name\" should be a valid string and the same as in the defined _tss_ file.\r\n\r\nh3. Workaround\r\n\r\nI cannot see any workaround since the rendered _font-family_ is expecting a *user defined* font identifier.\r\nMay be adding a _font-face_ declaration could do the trick.", "attachment": [ { "id": "36560", "filename": "comic_zine_ot.otf", "author": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "created": "2013-03-22T09:47:20.000+0000", "size": 117384, "mimeType": "application/octet-stream" }, { "id": "36518", "filename": "titanium.css", "author": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "created": "2013-03-21T09:55:38.000+0000", "size": 37917, "mimeType": "text/css" } ], "flagged": false, "summary": "mobileweb rendered @font-face declaration is not valid", "creator": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "subtasks": [], "reporter": { "name": "clathrop", "key": "clathrop", "displayName": "Carter Lathrop", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "MacOS 10.7.5\r\nTitanium Studio 3.0.2", "closedSprints": [ { "id": 1008, "state": "closed", "name": "2018 Sprint 06 SDK", "startDate": "2018-03-11T22:18:04.396Z", "endDate": "2018-03-25T22:18:00.000Z", "completeDate": "2018-03-25T21:52:36.683Z", "originBoardId": 216 } ], "comment": { "comments": [ { "id": "243230", "author": { "name": "clathrop", "key": "clathrop", "displayName": "Carter Lathrop", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Hello Damien,\nWhen reporting an issue it is general good practice to provide a sample test case as well as the problem code to show the issue by just copy and pasting into an app.js and in this case running on mobile web. Would you mind providing such a test case so that this issue may get reviewed in a more timely manner? \nFor future reference: https://wiki.appcelerator.org/display/guides/How+to+Submit+a+Bug+Report\nThank you,\nCarter", "updateAuthor": { "name": "clathrop", "key": "clathrop", "displayName": "Carter Lathrop", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-20T19:26:53.000+0000", "updated": "2013-03-20T19:26:53.000+0000" }, { "id": "243371", "author": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "body": "Attached the rendered build/mobileweb/titanium.css file.", "updateAuthor": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "created": "2013-03-21T09:55:38.000+0000", "updated": "2013-03-21T09:56:32.000+0000" }, { "id": "243372", "author": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "body": "Hi Carter,\n\nI've added some more informations about the related problem in the description.\nSorry about the previous incomplete description.\n\nDamien\n", "updateAuthor": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "created": "2013-03-21T09:57:15.000+0000", "updated": "2013-03-21T09:57:15.000+0000" }, { "id": "243542", "author": { "name": "clathrop", "key": "clathrop", "displayName": "Carter Lathrop", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Thanks Damien, I reopened and am looking into this issue, if possible would you mind attaching the font .otf as well?\nThanks,\nCarter", "updateAuthor": { "name": "clathrop", "key": "clathrop", "displayName": "Carter Lathrop", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-21T21:38:43.000+0000", "updated": "2013-03-21T21:38:43.000+0000" }, { "id": "243544", "author": { "name": "clathrop", "key": "clathrop", "displayName": "Carter Lathrop", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Also, to clarify, is this issue only being seen in alloy?", "updateAuthor": { "name": "clathrop", "key": "clathrop", "displayName": "Carter Lathrop", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-21T21:42:15.000+0000", "updated": "2013-03-21T21:42:15.000+0000" }, { "id": "243659", "author": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "body": "I have added the font file used (it's the same file used in Kitchen Sink).\n\nI also tested rendering in a non-alloyed app, and the font-face declaration is not rendered properly either.\n\n{code:title=build/mobileweb/titanium.css}\n@font-face{font-family:fonts/comic_zine_ot.otf;src:url(fonts/comic_zine_ot.otf);\n{code}\n", "updateAuthor": { "name": "damiencaselli", "key": "damiencaselli", "displayName": "Damien Caselli", "active": true, "timeZone": "Europe/Paris" }, "created": "2013-03-22T10:05:07.000+0000", "updated": "2013-03-22T10:05:07.000+0000" }, { "id": "435486", "author": { "name": "topener", "key": "topener", "displayName": "Rene Pot", "active": true, "timeZone": "Europe/Berlin" }, "body": "Mobileweb was dropped. So no fix is required anymore", "updateAuthor": { "name": "topener", "key": "topener", "displayName": "Rene Pot", "active": true, "timeZone": "Europe/Berlin" }, "created": "2018-03-12T14:22:02.000+0000", "updated": "2018-03-12T14:22:02.000+0000" }, { "id": "436392", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Closing as will not fix.", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-04-04T23:20:29.000+0000", "updated": "2018-04-04T23:20:29.000+0000" } ], "maxResults": 8, "total": 8, "startAt": 0 } } }