Вопрос

In Xcode I can put some controls on the window's contentView and they get default spacing according to some unknown rules. This depends on control types that are constrained. For example, two NSButtons of regular type are separated by 12 points, but regular button and gradient button only by 8.

Also, vertical space depends too. Regular spacing is 8, but for two NSTextFields the spacing is 10, and for button below them even 20.

What are the rules and/or constants?

Это было полезно?

Решение

Can't find it in the docs right now but it was mentioned in the various WWDC videos covering this topic -

default should refer to the various suggested defaults in the Human Interface Guidelines, i.e. using default will apply Apple's suggested settings.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top