Figma Support Forum

Boolean operations glitchy/broken?

I’m having an issue with a semi-complex shape that is composed out of various sub-shapes that are combined together using union and subtract boolean operations. The various sub-shapes are anchored in various ways to emulate nine-slicing so that as I resize the shape without distorting the edges and corners. Here’s what the shape (correctly) looks like at its original size:

However, if I make the shape smaller than a certain size, suddenly parts of it start disappearing. Here’s an example:

Here’s a link to a simple Figma file that demonstrates the issue: https://www.figma.com/file/TROU3GCQqhpfDj2VSQbipR/Boolean-Operation-Test?node-id=0%3A1

I’m pretty sure this is an actual bug with Figma, but does anyone know how to work around it?

Hello, I got good news because it’s not a bug!

I’ve played with your file and found that the object breaks below 200px vertically - which is half of the component vertically. I’ve checked the ‘Left Edge’ layer’s frame settings and noticed vertical constraints are mixed. I’ve changed it to scale and now it resizes as you intended to.

Screenshot 2021-04-20 at 09.06.58

Screenshot 2021-04-20 at 09.07.39

Detective work :female_detective:

By the way, I would suggest to keep your booleans way simpler. It would greatly improve the load performance (and developers sanity) to implement something that is drawn with a couple of layers instead 100 booleans operations. If that image is going to live on web, it is going to be a pain to implement those boolean operations.

Thanks for taking the time to investigate! Unfortunately, setting the left (or any) edge to ‘Scale’ does NOT do what I want. I want the thickness of the edges and size of the corners to remain constant regardless of the size of the instance’s frame. (I’m basically trying to emulate traditional nine-slicing as found in tools like Illustrator and commonly implemented in games.) Setting the edge constraints to ‘Scale’ causes the edges to, well, scale, which is not what I want. This is why I have the constraints setup the way that I do and why there are so many individual shapes.

(FWIW, this is not for a web page/app. These assets get exported as PNG image files for use in a game, where the complexity of the original Figma files doesn’t matter.)

Yes there are some glitches with them, I don’t think there is a way to fix them, but you can report a bug to Figma support team via the bug report form.

I filed a bug report, thanks for the link.

In my particular case I was able to work around the bug by shrinking the base component, which then fixed the instance of it.