boolean (Insets insets) { if (insets instanceof JBInsets jbInsets && jbInsets.unscaledSupplier != null) { return false; // Even if these are zero now, they can be non-zero later (e.g. if the theme is changed or compact mode toggled). } // Scaling doesn't matter here, as zero is zero regardless of scaling: return insets.top == 0 && insets.left == 0 && insets.bottom == 0 && insets.right == 0; }