{"action":"created","issue":{"url":"https://api.github.com/repos/simonbengtsson/jsPDF-AutoTable/issues/363","repository_url":"https://api.github.com/repos/simonbengtsson/jsPDF-AutoTable","labels_url":"https://api.github.com/repos/simonbengtsson/jsPDF-AutoTable/issues/363/labels{/name}","comments_url":"https://api.github.com/repos/simonbengtsson/jsPDF-AutoTable/issues/363/comments","events_url":"https://api.github.com/repos/simonbengtsson/jsPDF-AutoTable/issues/363/events","html_url":"https://github.com/simonbengtsson/jsPDF-AutoTable/issues/363","id":331002015,"node_id":"MDU6SXNzdWUzMzEwMDIwMTU=","number":363,"title":"Incorrect headerStyles with custom fonts in jspdf 1.4.0","user":{"login":"alexbazilev","id":2733010,"node_id":"MDQ6VXNlcjI3MzMwMTA=","avatar_url":"https://avatars0.githubusercontent.com/u/2733010?v=4","gravatar_id":"","url":"https://api.github.com/users/alexbazilev","html_url":"https://github.com/alexbazilev","followers_url":"https://api.github.com/users/alexbazilev/followers","following_url":"https://api.github.com/users/alexbazilev/following{/other_user}","gists_url":"https://api.github.com/users/alexbazilev/gists{/gist_id}","starred_url":"https://api.github.com/users/alexbazilev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexbazilev/subscriptions","organizations_url":"https://api.github.com/users/alexbazilev/orgs","repos_url":"https://api.github.com/users/alexbazilev/repos","events_url":"https://api.github.com/users/alexbazilev/events{/privacy}","received_events_url":"https://api.github.com/users/alexbazilev/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-06-10T20:59:37Z","updated_at":"2018-11-10T12:59:10Z","closed_at":"2018-06-10T21:04:52Z","author_association":"NONE","body":"Custom fonts support was added into jspdf 1.4.0. Here is the code from their example:\r\n```\r\nconst doc = new jsPDF('p', 'pt');\r\nconst PTSans = \"AAEAAAAUAQAAB...\"; \r\n// according to jspdf, PTSans must be base64 font, full string is on jsPDF/examples/js/basic.js\r\ndoc.addFileToVFS(\"PTSans.ttf\", PTSans);\r\n\r\ndoc.addFont('PTSans.ttf', 'PTSans', 'normal');\r\n```\r\nNow let's try to apply this custom font to table body and table headers:\r\n\r\n```\r\ndoc.autoTable(columns, rows, {\r\n...\r\n    styles: {\r\n        fontSize: 6,\r\n        font: 'PTSans'\r\n    },\r\n    headerStyles: {\r\n        fontSize: 6,\r\n        font: 'PTSans'\r\n    }\r\n...\r\n});\r\n```\r\n\r\nCustom font from \"styles\" is correctly applied to table body, but not applied for headers through \"headerStyles\".\r\n\r\nHere is another issue about custom fonts: https://github.com/simonbengtsson/jsPDF-AutoTable/issues/357 , but this is different."},"comment":{"url":"https://api.github.com/repos/simonbengtsson/jsPDF-AutoTable/issues/comments/437582183","html_url":"https://github.com/simonbengtsson/jsPDF-AutoTable/issues/363#issuecomment-437582183","issue_url":"https://api.github.com/repos/simonbengtsson/jsPDF-AutoTable/issues/363","id":437582183,"node_id":"MDEyOklzc3VlQ29tbWVudDQzNzU4MjE4Mw==","user":{"login":"iamkarthikselvaraj","id":26427259,"node_id":"MDQ6VXNlcjI2NDI3MjU5","avatar_url":"https://avatars2.githubusercontent.com/u/26427259?v=4","gravatar_id":"","url":"https://api.github.com/users/iamkarthikselvaraj","html_url":"https://github.com/iamkarthikselvaraj","followers_url":"https://api.github.com/users/iamkarthikselvaraj/followers","following_url":"https://api.github.com/users/iamkarthikselvaraj/following{/other_user}","gists_url":"https://api.github.com/users/iamkarthikselvaraj/gists{/gist_id}","starred_url":"https://api.github.com/users/iamkarthikselvaraj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iamkarthikselvaraj/subscriptions","organizations_url":"https://api.github.com/users/iamkarthikselvaraj/orgs","repos_url":"https://api.github.com/users/iamkarthikselvaraj/repos","events_url":"https://api.github.com/users/iamkarthikselvaraj/events{/privacy}","received_events_url":"https://api.github.com/users/iamkarthikselvaraj/received_events","type":"User","site_admin":false},"created_at":"2018-11-10T12:59:10Z","updated_at":"2018-11-10T12:59:10Z","author_association":"NONE","body":"> My mistake :)\r\n> jspdf-autotable is awesome!\r\n\r\nhow did you fix that?"}}
{"actor":{"display_login":"iamkarthikselvaraj"}}