Im trying to create a view that has 2 labels in it, with auto layout enabled. Upon running of the app, it adjusts the size of the screen as it would if it had content yet nothing shows up. This is without setting any text programmatically.
This is my view:
This is what happens when I run the app:
If I go ahead and add more text to the multiline label above 'Date':
It is reacting to the text changes, but not displaying anything.
Here's my very, very short and simply ViewController code:
TodayViewController.h:
#import <Cocoa/Cocoa.h>
@interface TodayViewController : NSViewController
@property (weak) IBOutlet NSTextField *multiLine;
@property (weak) IBOutlet NSTextField *theDate;
@end
TodayViewController.m:
#import "TodayViewController.h"
#import <NotificationCenter/NotificationCenter.h>
@interface TodayViewController () <NCWidgetProviding>
@end
@implementation TodayViewController
@synthesize multiLine, theDate;
- (void)viewDidLoad {
[super viewDidLoad];
//Weather I programmatically set text or not doesn't change anything.
}
- (void)widgetPerformUpdateWithCompletionHandler:(void (^)(NCUpdateResult result))completionHandler {
completionHandler(NCUpdateResultNoData);
}
@end