Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

box size is wrong in layer creation sample #80

Open
DianaProbst opened this issue Sep 8, 2022 · 1 comment
Open

box size is wrong in layer creation sample #80

DianaProbst opened this issue Sep 8, 2022 · 1 comment

Comments

@DianaProbst
Copy link

https://github.com/AdobeDocs/uxp-photoshop-plugin-samples/blob/main/layer-creation-js-sample/index.js has, as part of the batchplay,
"bounds": { "_obj": "rectangle", "top": 100, "left": 100, "bottom": 400, "right": 500 }
gives me a box 1667 pixels wide and 1250 tall. I've screenshotted it next to the rulers.

image

If I change the top and left to 0.0, the box gets bigger. It's now 2083 x 1667, which given that's one of the same numbers as before, says there is a scaling issue somewhere.

image

I found this out when I was attempting to produce and centre other boxes on defined points, so it is just possible I did something to my instance of Photoshop, such as over-writing the anchor points, that has made this happen. I recorded the orginal change as an action and exported JavaScript to use. However, I've closed and re-opened Photoshop, to no avail. In either case, I think it should not be happening. I'm afraid I can't test it in a pre-Action-copy-and-paste state.

@DianaProbst
Copy link
Author

Looking at the relative sizes, it seems to be an issue with 300ppi vs 72ppi. The docs say that everything should be in 300 ppi, but I suspect that somewhere is a conversion to 72 which is not fully converted back.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant