w0lfschild/winBuddy

Hide window title bar

Worie opened this issue Β· 15 comments

Worie commented

Hi, I use a lot of mySIMBL plugins made by you, great work, thanks!

I've got a feature request:
Recently I've encouraged a pretty uncommon case I guess, I'd like to hide window title bar ( https://i.stack.imgur.com/G3sRt.png ). Is that even possible and if so, is it worth an effort? What do you think?

Yeah that would probably be possible.

if you could make this happen i'd be eternally grateful. I've been looking for a way to do this for years.

<3

The problem with this is that then you can not really move the window around unless you're using a window manager.

Worie commented

For sure, but I feel like anybody who'd be interested in this would be the type of person to use a WM. Also I remember hearing people say the same thing when people were requesting a titlebar-less iTerm, but every build I've used of iTerm without a title bar is still able to be moved around with the mouse by clicking and dragging at an angle. Not sure if that would work with regular windows though.

termdrag

Okay build 0.3.4 is up : Download

Edit: 0.3.4 has fix for hiding titlebar on applications with a toolbar

Wow, didn't expect that so soon. Awesome.

I know this is your first build w/ this fix, and I'm not sure how much you care about that feature, but I figure I'll give you some feedback anyway.

This is my Finder window w/o the titlebar hidden:
screen shot 2017-05-30 at 7 41 43 pm 2

and this is it with it hidden:
screen shot 2017-05-30 at 7 41 56 pm 2

There really isn't much difference there, although definitely a step in the right direction. With most other apps I tried, it hides the titlebar perfectly, but is then impossible to resize the window. I can move it around with my window manager, but it won't resize it from when I checked the 'hide titlebar' setting.

I can't speak for @Worie but the effect I was hoping for was something like this:
edit

Not sure how possible that might be to accomplish, or if the window resizing issue is possible to fix, but either way, thanks a lot for your work. Winbuddy is essential to my setup.

Worie commented

0.3.4 works like a charm, thank you. I actually have toolbar enabled so it does not affect me that much, but it would probably make sense to hide it completely in that specific case.

Anyway, thank you very much for this feature :) Respect!

net commented

This seems to make a lot of windows unresizable. It gives me resizing issues with almost every non-native app.

net commented

Regarding dragging issues, on macOS you can move windows around without a titlebar by moving the cursor over the edge of the window so the resize arrow appears, then dragging perpendicular to the direction of the resize arrow. (For example, when hovering over the left or right edge, drag vertically instead of horizontally.)

(This is broken by the resizing issue above.)

net commented

A way to hide traffic lights would be nice, if possible.

Okay another update is up 0.3.5 : Download

Should fix not being able to drag windows and fully hiding the title in Finder.

All together it will never be ideal to hide the titlebar because a lot of different apps are going to behave differently with it hidden.

net commented

That fixed the resizing issue, but it restored the titlebar for most windows.

Perhaps the issue was caused by this?

A window that uses NSBorderlessWindowMask can’t become key or main, unless the value of canBecomeKeyWindow or canBecomeMainWindow is YES.

https://developer.apple.com/documentation/appkit/nsborderlesswindowmask

Also, I wonder how feasible it would be to make windows display as if they were in fullscreen mode (square corners, no traffic lights, whatever toolbar the application displays in fullscreen mode), although windowed in this case. That would be ideal for window managers.

net commented

The resizing issue can be fixed for 7e20d3f with NSWindowStyleMaskResizable.

self.styleMask = NSWindowStyleMaskBorderless | NSWindowStyleMaskResizable;

I'm running 0.3.5 right now, and hiding the title bar works for most of the apps for me. However, it does not work for the Terminal, which would be very nice to have! Do you think, you can have a look at that?