Hi! Can somebody explain why with “snap to pixel grid” function on in Figma, the coordinates of files are still can be fractional? It fixes when you move them, but the question is still here why it is happening? And maybe there are some ways to prevent this or fix all frames coordinates in file altogether?
Hey Polina, thank you for reaching out! When you enable this functionality Figma will align objects to the underlying grid when placing or moving them. This can help to prevent mis-aligned pixel errors when exporting elements. More info here: https://help.figma.com/hc/en-us/articles/360041065034-Adjust-your-zoom-and-view-options#pixel-grid.
Could you show me at what times coordinated are still fractional? Could you share a brief video recording of this issue so that I have a better understanding of which actions you’re taking?
Thank you for answering!
For a faster answer, I share a screenshot of the situation. The new Figma file is created with the Snap to pixel grid function switched on, during work I need to copy some of the frames and place them in my own Figma file from another ones, so when I do it this frame might still have fractional coordinates, even when it is moving from file that was snapped to pixel grid too. I can move this one frame in my file to get rid of the problem with coordinates, but there are many frames I need to work with and it gets difficult to control all of them and not to miss any little frame during exporting a lot of resized banners.
To sum up, Figma file has snap to pixel grid, but it still can paste a copied frames with fractional coordinates inside. Can I fix it somehow?
Got it @Polina3, I can totally understand your frustration. I’ve shared your feedback internally and asked for a workaround here. I’ll give you an update soon! Appreciate your patience.
Apologies @Polina3 for asking you to clarify your issue again. I’ve raised this with an engineer and got the response that the behavior regarding pasting from fractional spaces into pixel grid spaces is intentional. We preserve the coordinates instead of changing them.
However this could be a bug though if the coordinates of that layer are not fractional.
so when I do it this frame might still have fractional coordinates, even when it is moving from file that was snapped to pixel grid too
Could you confirm me again if you’re experiencing this? I would appreciate if you can share a screen recording so that I can share this internally and investigate further.
No problem, @Gayani_S! Here is a screen recording of the situation I struggle with.
Copied frames are saving their fractional coordinates indeed, but it becomes a problem further, because while working with big massive of files to miss one with fractionals is so easy. How can I fix them without moving each of them in file?
And the main question is that why I am pasting fractional frames from snapped to snapped spaces? All files have this function switched on.
Hey, apologies for the delayed response! So this looks like it’s an intended behaviour, I was able to reproduce this on my end. However, I want to double check this internally to see if there are any workarounds to copy & paste the frames without moving them. I’ll update you soon. Appreciate your patience!
@Polina3 I got the confirmation this is intended and unfortunately there are no workarounds at this moment. However, I am able to change the category of this post to “Share an Idea”. I can change the title to: Enabling “Snap to Pixel” instantly modifies the fractional coordinates of the frames in the file.
This helps us roadmap future updates. Community members who would like to see your suggestion implemented can vote on it. Let me know if you approve this as well.
I am totally agree with your suggestion to change category of my question, hope that other users will help me to promote this idea as a new function update!
Thank you, @Gayani_S, for all of your efforts to solve my problem!
No worries at all @Polina3, happy to help! I’ve changed the category now, feel free to upvote this post.
Thanks,
Gayani.
I’m struggling with the same issue and it’s really annoying. I hope there’s a fix for this soon like some keyboard trick where I can hold down the option key to make sure the paste command pastes the content snapping to a pixel grid, not fractional XY coordinates which screws up everything inside the frame as all elements then have fractional measurements in the XY coordinates and spacing things out is a giant pain from then on.
Also have struggle with this - we’re always copy > pasting things and they get further and further bested into auto-layouts which I suspect also ends up fractionalizing pixels, making it impossible to undo one layer at a time. Figma should create an option to auto-snap all layers to full pixels, allow user to exclude things like icons, and show a window that explains which layers were not able to be changed to full pixels (but still move all the eligible layers).
@Cori_Leste2 @Miklos_Philips thanks for your support! We are in the same boat, so I’ll appreciate if you promote this topic so we can get more votes to fix this annoying problem finally!
I’m also have issue with this and hope the solution will find very soon!
+1, i need an option where Figma forces frames to whole pixel values, as exported assets with fractional positioning will have a thin white edge and will not be the expected dimensions (+/-1 pixel)
I am also experiencing this issue and its super frustrating to deal with.
Our team is having a terrible time with exported assets having a thin white edge. We all have Snap to Pixel Grid turned on and we’re still getting all kinda of fractional positions.
There’s a “Snap to Pixel” plugin that removes unwanted decimals but we shouldn’t be having to run this across everything. Can we PLEASE get a “Make All Frames Round Values” preference?
I am coming form sketch which has a Round to Pixel action in the task bar. This works regardless grid or not. I am running into the same issue and find myself having to so it by hand which is time consuming.
Hi,
We are also struggling with this.
Besides the of pasting from another file, elements also don’t snap to grid when pasted components or elements are scaled up or down. We know that scaling components is an unusual user case, but it’s part of our workflow with a specific client. Having to go over all file layers to fix positions and dimensions every single time sucks the life of us. We’d rather let Figma snap everything automatically and we manually deal with the few exceptions when something doesn’t look right.
If Figma would copy paste sources with fractions into other positions when copying from file to file, it could potentially mess up the integrity of the design, so I understand Figma’s decision to not do this.
Sketch’s “Round to pixel” option on the toolbar was mentioned before.
I wanted to get opinions from people about the Snap to Pixel plugin. Do you use this plugin to fix frames that sit on fractional values, or do you fix it manually using the numbers in the right side panel? Or do you have another solution?
https://www.figma.com/community/plugin/1219661857469864621/snap-to-pixel
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.