osx - How to repaint window after hide or show control -
i have nstextfield control on bottom of window. need show them or hide according condition.
in initial state control hidden. window shows blank space on control's position. when in runtime control should become visible
mptxtctrl.hidden = no;
it not happen.
the tasks:
1 display/hide control.
2 resize main window according control's state.
i can't find tutorials how manage layouts in cocoa. grateful help!
when in runtime control should become visible
mptxtctrl.hidden = no;
it not happen.
make sure connected mptxtctrl
outlet text field in nib. having forgotten connect outlet leading cause of nothing happening.
i can't find tutorials how manage layouts in cocoa.
switch file inspector while editing nib , turn “use auto layout” on. xcode create constraints whenever place views along aqua guides (the blue lines appear when place , size views correctly), , cocoa enforce these constraints sizes of views , window change.
more info:
- cocoa auto layout guide
- wwdc 2012 videos — include several sessions on auto layout
- os x human interface guidelines — aqua guide lines appear indicate conformance hig
Comments
Post a Comment