Round to Pixel command
XD could really use a Round to Pixel command. Yes, I'm pulling this straight from Sketch, but it's awfully useful. The command simply rounds every anchor point to the nearest whole-pixel value, eliminating fractional pixels.
This feature has been added in our November update (version 0.6.2): choose Object > Align to Pixel Grid to tweak the X/Y/W/H so the object(s) are crisply aligned with the pixel grid. You can use this command with a multiple selection or with groups selected to align multiple objects at once.
Note: aligning to pixel grid does not always mean the X/Y/W/H won’t have fractions. For center-stroked shapes (lines and Pen tool, mostly), sometimes the X/Y need to end in .5 to keep the stroke crisply aligned on-pixel.
I see some people in the discussion thread here are asking for snap to pixel “by default.” Adobe XD should already do that, with very few exceptions (see https://adobexd.uservoice.com/forums/353010/suggestions/16962847-resizing-multiple-selection-or-group-loses-pixel-alignment). If you’re encountering other situations where objects you created in XD are not pixel aligned by default, please file a new bug here in UserVoice.
Thanks everyone for all your feedback and votes on this feature!
-
Harper Lieblich commented
This is a big one for me. Today, I was trying to create an icon with widths that where 1.5px (or 3px @2x) and it was a real pain to have to manually add '.5' to my dimensions in the attributes panel.
-
frshnss commented
Who is using sub-pixels? Seriously. Round to Pixel should be by default not an option.
-
Alan Valek commented
Daniel, elements still render better if designed on a pixel grid.
It seems like XD is snapping to grid by default? Everything should snap to pixel grid by default and you should tell it that you want a specific element to go sub-pixel.
-
Robert H Paige commented
God please.
-
Kidhack commented
Yes please!
-
christian.moore@mi9.com.au commented
Please make this happen! At least have it as an option in preferences.
-
Daniel Keller commented
I thought about that, although I'm not entirely sure it's still relevant today.. the web is vector based now, logos and icons usually are in the svg format!