SNRHUDKit icon indicating copy to clipboard operation
SNRHUDKit copied to clipboard

Resize window

Open kgn opened this issue 13 years ago • 1 comments

It would be great if the window could be resized

kgn avatar Jan 24 '12 08:01 kgn

You could make it resizable by changing the style mask from NSBorderlessWindowMask to NSResizableWindowMask in the file SNRHUDWindow.m.

Example:

- (id)initWithContentRect:(NSRect)contentRect styleMask:(NSUInteger)windowStyle backing:(NSBackingStoreType)bufferingType defer:(BOOL)deferCreation
{
    if ((self = [super initWithContentRect:contentRect styleMask:NSResizableWindowMask backing:bufferingType defer:deferCreation])) {
        [self setOpaque:NO];
        [self setBackgroundColor:[NSColor clearColor]];
        [self setMovableByWindowBackground:YES];
        [self setLevel:NSFloatingWindowLevel];
    }
    return self;
}

nicu avatar Jan 24 '14 23:01 nicu