{"action":"created","issue":{"url":"https://api.github.com/repos/prawnpdf/prawn/issues/894","labels_url":"https://api.github.com/repos/prawnpdf/prawn/issues/894/labels{/name}","comments_url":"https://api.github.com/repos/prawnpdf/prawn/issues/894/comments","events_url":"https://api.github.com/repos/prawnpdf/prawn/issues/894/events","html_url":"https://github.com/prawnpdf/prawn/pull/894","id":95899789,"number":894,"title":"Track transformations and apply to gradients' matrices","user":{"login":"mogest","id":23133,"avatar_url":"https://avatars.githubusercontent.com/u/23133?v=3","gravatar_id":"","url":"https://api.github.com/users/mogest","html_url":"https://github.com/mogest","followers_url":"https://api.github.com/users/mogest/followers","following_url":"https://api.github.com/users/mogest/following{/other_user}","gists_url":"https://api.github.com/users/mogest/gists{/gist_id}","starred_url":"https://api.github.com/users/mogest/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mogest/subscriptions","organizations_url":"https://api.github.com/users/mogest/orgs","repos_url":"https://api.github.com/users/mogest/repos","events_url":"https://api.github.com/users/mogest/events{/privacy}","received_events_url":"https://api.github.com/users/mogest/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2015-07-19T09:00:04Z","updated_at":"2015-07-29T20:57:58Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/prawnpdf/prawn/pulls/894","html_url":"https://github.com/prawnpdf/prawn/pull/894","diff_url":"https://github.com/prawnpdf/prawn/pull/894.diff","patch_url":"https://github.com/prawnpdf/prawn/pull/894.patch"},"body":"PDF gradients/patterns take coordinates in the coordinate space of the\r\ndocument, not the \"user space\", so if you perform a scale/rotate/translate\r\nand then paint a gradient inside, it doesn't render correctly.\r\n\r\nThis commit tracks transformations applied to the document, and multiplies\r\nthe gradient matrix with this tracked transformation matrix so that the\r\ngradient appears in the correct place in the document.\r\n\r\nThis has been created in response to issue #891."},"comment":{"url":"https://api.github.com/repos/prawnpdf/prawn/issues/comments/126093958","html_url":"https://github.com/prawnpdf/prawn/pull/894#issuecomment-126093958","issue_url":"https://api.github.com/repos/prawnpdf/prawn/issues/894","id":126093958,"user":{"login":"cheba","id":7405,"avatar_url":"https://avatars.githubusercontent.com/u/7405?v=3","gravatar_id":"","url":"https://api.github.com/users/cheba","html_url":"https://github.com/cheba","followers_url":"https://api.github.com/users/cheba/followers","following_url":"https://api.github.com/users/cheba/following{/other_user}","gists_url":"https://api.github.com/users/cheba/gists{/gist_id}","starred_url":"https://api.github.com/users/cheba/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cheba/subscriptions","organizations_url":"https://api.github.com/users/cheba/orgs","repos_url":"https://api.github.com/users/cheba/repos","events_url":"https://api.github.com/users/cheba/events{/privacy}","received_events_url":"https://api.github.com/users/cheba/received_events","type":"User","site_admin":false},"created_at":"2015-07-29T20:57:58Z","updated_at":"2015-07-29T20:57:58Z","body":"I use both prawn-svg and gradients in my documents. But I don't use transformations.\r\n\r\nI don't think changing core behaviour in prawn-svg is a nice thing to do. Probably, we can create a new gem for this very specific thing. Warn in Prawn when gradients used with transformations that it's going to change in 3.0 and that there's this one gem you should use to get correct behaviour. prawn-svg can warn users too when incorrect behaviour is evoked (but prawn would probably detect it anyway)."}}