{"action":"created","issue":{"url":"https://api.github.com/repos/itext/itextpdf/issues/9","labels_url":"https://api.github.com/repos/itext/itextpdf/issues/9/labels{/name}","comments_url":"https://api.github.com/repos/itext/itextpdf/issues/9/comments","events_url":"https://api.github.com/repos/itext/itextpdf/issues/9/events","html_url":"https://github.com/itext/itextpdf/pull/9","id":112919831,"number":9,"title":"change PdfPageLabels.getPageLabels() to scope prefixes to the range","user":{"login":"Palmr","id":360183,"avatar_url":"https://avatars.githubusercontent.com/u/360183?v=3","gravatar_id":"","url":"https://api.github.com/users/Palmr","html_url":"https://github.com/Palmr","followers_url":"https://api.github.com/users/Palmr/followers","following_url":"https://api.github.com/users/Palmr/following{/other_user}","gists_url":"https://api.github.com/users/Palmr/gists{/gist_id}","starred_url":"https://api.github.com/users/Palmr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Palmr/subscriptions","organizations_url":"https://api.github.com/users/Palmr/orgs","repos_url":"https://api.github.com/users/Palmr/repos","events_url":"https://api.github.com/users/Palmr/events{/privacy}","received_events_url":"https://api.github.com/users/Palmr/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-10-23T00:47:21Z","updated_at":"2015-11-03T10:10:56Z","closed_at":"2015-11-02T20:48:07Z","pull_request":{"url":"https://api.github.com/repos/itext/itextpdf/pulls/9","html_url":"https://github.com/itext/itextpdf/pull/9","diff_url":"https://github.com/itext/itextpdf/pull/9.diff","patch_url":"https://github.com/itext/itextpdf/pull/9.patch"},"body":"they are defined for\r\n\r\nWhile reading a PDF generated by Adobe InDesign CS6 using the Adobe\r\nPDF Library 10.0.1 which included several page label sections I\r\nnoticed iText was keeping the prefix applied to subsequent sections\r\nin the values return by PdfPageLabels.getPageLabels(), even when the\r\nkey was omitted in the following page label dictionary entries.\r\nAccording to the PDF Reference 1.7, Table 8.10 says that /P is an\r\noptional label prefix for page labels in this range. PDF Readers I\r\nhave installed scope the prfix only to the range it is specified.\r\nThis change empties out the prefix field to give behaviour I think\r\naligns with the reference and my experience of other PDF readers.\r\nI also reformatted the function as previously it was a mix of tab &\r\nspace indenting.\r\n\r\nI am not aware of any potential regression issues introduced by this\r\nchange, existing page label dictionaries created by iText set /P to\r\nan empty string so this will only affect reading PDFs with partially\r\nprefixed page label ranges as far as I know."},"comment":{"url":"https://api.github.com/repos/itext/itextpdf/issues/comments/153305945","html_url":"https://github.com/itext/itextpdf/pull/9#issuecomment-153305945","issue_url":"https://api.github.com/repos/itext/itextpdf/issues/9","id":153305945,"user":{"login":"amedee","id":463961,"avatar_url":"https://avatars.githubusercontent.com/u/463961?v=3","gravatar_id":"","url":"https://api.github.com/users/amedee","html_url":"https://github.com/amedee","followers_url":"https://api.github.com/users/amedee/followers","following_url":"https://api.github.com/users/amedee/following{/other_user}","gists_url":"https://api.github.com/users/amedee/gists{/gist_id}","starred_url":"https://api.github.com/users/amedee/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amedee/subscriptions","organizations_url":"https://api.github.com/users/amedee/orgs","repos_url":"https://api.github.com/users/amedee/repos","events_url":"https://api.github.com/users/amedee/events{/privacy}","received_events_url":"https://api.github.com/users/amedee/received_events","type":"User","site_admin":false},"created_at":"2015-11-03T10:10:56Z","updated_at":"2015-11-03T10:10:56Z","body":"Thank you for your contribution, as you can see we have merged in your pull request."}}