sindrets / atom-title-bar-replacer

Adds an alternative, theme-aware title bar and application menu that is more inline with Atom's UI design.
Other
85 stars 5 forks source link

Removing the Native Title Bar on Linux #52

Closed cysabi closed 3 years ago

cysabi commented 5 years ago

Specifically Fedora, how do I remove it?

sindrets commented 5 years ago

@LeptoSpira Depends on whether or not you are running the official binary, or built from source. Regardless you need to locate the source code on your machine. It's probably in /usr/local/share/atom or something similar. Now, if you are running the official binary, the app is probably archived in an asar under the name app.asar. You need to extract this using asar. If you are running a variant of atom that was built from source, then the source probably isn't archived. Locate app.asar/src/main-process/atom-window.js. Locate the window options, and set the frame property to false:

const options = {
      frame: false, // <<== ADD THIS
      show: false,
      title: 'Atom',
      tabbingIdentifier: 'atom',
      webPreferences: {
        // Prevent specs from throttling when the window is in the background:
        // this should result in faster CI builds, and an improvement in the
        // local development experience when running specs through the UI (which
        // now won't pause when e.g. minimizing the window).
        backgroundThrottling: !this.isSpec,
        // Disable the `auxclick` feature so that `click` events are triggered in
        // response to a middle-click.
        // (Ref: https://github.com/atom/atom/pull/12696#issuecomment-290496960)
        disableBlinkFeatures: 'Auxclick'
      }
    };

Now, again, if you are running the official binary you need to re-pack the modified source. This can be done using asar. That's it!

I'll leave this issue open as a feature request, but I don't maintain this plugin anymore, so I have no plans for implementing the window-frame-remover on linux for the time being. Also, if you care about title bar aesthetics on linux, I recommend you just use a desktop environment that allows you to customize window controls. I know both KDE and GNOME can do this, and probably many others.

cysabi commented 5 years ago

I ended up with this neat workaround:

Make sure to check the settings to show the title bar and such in fullscreen mode of course.

sindrets commented 3 years ago

As of Atom v1.53.0 the native title bar can be hidden on linux as well. Settings > Core > Title Bar > 'hidden'