sizeThatFits vs Big Sur = regression

I'm currently using sizeThatFits to know the ideal dimensions for a NSPopUpButton (with no bezel).

In macOS Mojave and Catalina, the size I get is correct.

In macOS BS, the size is incorrect:
  • the width is not big enough to display the title.

  • the height is too small and the text is not vertically centered.

Questions:
  • is sizeThatFits a unreliable API?

  • if it is which one should be used? I don't want to use sizeToFit because I may need to resize the popup button once I know all the idea sizes.

Note:

I have absolutely no plans to use autolayout.
I met the same issue, sizeToFit also can't work on Big Sur.
sizeThatFits vs Big Sur = regression
 
 
Q