openframeworks / openFrameworks

openFrameworks is a community-developed cross platform toolkit for creative coding in C++.
http://openframeworks.cc
Other
9.97k stars 2.55k forks source link

ofSystemAlertDialog throws "missing constraints" warning on console #5494

Open datishans opened 7 years ago

datishans commented 7 years ago

ofSystemAlertDialog() will throw a warning on the console about missing constraints.

2017-03-16 08:58:53.308164 mySketchDebug[63175:5835999] [Layout] Detected missing constraints for <NSTextField: 0x101f088c0>. It cannot be placed because there are not enough constraints to fully define the size and origin. Add the missing constraints, or set translatesAutoresizingMaskIntoConstraints=YES and constraints will be generated for you. If this view is laid out manually on macOS 10.12 and later, you may choose to not call [super layout] from your override. Set a breakpoint on DETECTED_MISSING_CONSTRAINTS to debug. This error will only be logged once.

My setup: macOS Sierra (10.12.3) oF: of_v0.9.8_osx_release Xcode 8.2.1

bakercp commented 7 years ago

I'm on macOS Sierra (10.12.5), oF master branch, Xcode 8.3.1 and not seeing this error.

bakercp commented 7 years ago

Can you provide some test code to reproduce?

datishans commented 7 years ago

Have reproduced it using the following setup:

macOS Sierra (10.12.5) oF: of_v0.9.8_osx_release (-> not main branch, this could be the diff?) Xcode 8.3.1

I've stripped my current project to a minimum, so here you go:

warning-test-#5494.zip result

igiso commented 6 years ago

probably This is an apple related issue, https://openradar.appspot.com/28700495

I've no idea how it is really caused, I can repeat it consistently but i cannot debug it.. I've tried putting a DETECTED_MISSING_CONSTRAINTS flag on the debugger it stops somewhere inside NSView:

screen shot 2018-04-30 at 13 45 36