Giter Club home page Giter Club logo

tab-bar-notch's Introduction

Logo
tab-bar-notch

Adjust tab-bar height for MacBook Pro notch.

GitHub tag (latest SemVer) MELPA Stable MELPA GitHub issues GitHub pull requests License Status

When using the non-native fullscreen mode of Emacs on modern MacBook Pro machines, it ends up rendering buffer content behind the camera notch. This package attempts to solve this by way of resizing the tab-bar to fill the vertical space taken up by the camera notch.

Obviously tab-bar-mode must be enabled with the tab-bar visible at the top of the frame for this package to be able to function.

Non-Native Fullscreen?

The default native fullscreen implementation on macOS can be rather annoying, as it moves applications over to their own separate desktop Space. This prevents you from layering windows from other applications on top it, among other things.

Emacs supports both native and non-native fullscreen modes. In the non-native mode, Emacs just acts like any other window, but stretches itself to cover the whole screen, and hides the menu bar and dock. Non-native fullscreen is enabled with:

(setq ns-use-native-fullscreen nil)

In the non-native fullscreen mode, Emacs is not aware of the physical camera notch however, so it does not know to avoid rendering things behind it.

Installation

tab-bar-notch is available via MELPA.

use-package

(use-package tab-bar-notch)

Manual

Place tab-bar-notch.el somewhere in your load-path and require it. For example ~/.emacs.d/vendor:

(add-to-list 'load-path "~/.emacs.d/vendor")
(require 'tab-bar-notch)

Usage

You must be using tab-bar-mode, with the tab-bar visible at the top of the frame above all buffers.

Then simply add tab-bar-notch-spacer to the tab-bar-format variable, for example:

(setq tab-bar-format '(tab-bar-format-history
                       tab-bar-format-tabs
                       tab-bar-separator
                       tab-bar-format-add-tab
                       tab-bar-notch-spacer))

To disable the package, simply remove tab-bar-notch-spacer, and it will unregister itself from window resizing hooks.

tab-bar-notch's People

Contributors

github-actions[bot] avatar jimeh avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

tab-bar-notch's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.