Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/purcell/ns-auto-titlebar
In Emacs, set the MacOS transparent titlebar to match the current theme
https://github.com/purcell/ns-auto-titlebar
Last synced: 3 days ago
JSON representation
In Emacs, set the MacOS transparent titlebar to match the current theme
- Host: GitHub
- URL: https://github.com/purcell/ns-auto-titlebar
- Owner: purcell
- Created: 2018-10-21T04:34:17.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-11-06T20:28:48.000Z (3 months ago)
- Last Synced: 2024-12-02T18:11:12.660Z (2 months ago)
- Language: Emacs Lisp
- Size: 5.86 KB
- Stars: 29
- Watchers: 4
- Forks: 6
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
[![Melpa Status](http://melpa.org/packages/ns-auto-titlebar-badge.svg)](http://melpa.org/#/ns-auto-titlebar)
[![Melpa Stable Status](http://stable.melpa.org/packages/ns-auto-titlebar-badge.svg)](http://stable.melpa.org/#/ns-auto-titlebar)ns-auto-titlebar.el
===================Recent builds of Emacs (27, 26?) support transparent titlebars on
MacOS via the `ns-transparent-titlebar` and `ns-appearance` frame
properties. The latter indicates whether the titlebar background
should be `dark` or `light`, and it is not set automatically by
Emacs. However, the text colour is always taken from the current
theme, which can lead to unreadable titlebar text if `ns-appearance`
is not set correctly.This Emacs package provides a global minor mode,
`ns-auto-titlebar-mode` which - when enabled - keeps the
"ns-appearance" frame parameter correctly set in GUI frames so that it
matches the currently-enabled theme, whether it is light or dark.For this package to work correctly, it is generally necessary that the
theme you use sets the `frame-background-mode` variable appropriately.
This can be set manually if necessary, but see the docs for that
variable.Installation
=============If you choose not to use one of the convenient
packages in [MELPA][melpa], you'll need to
add the directory containing `ns-auto-titlebar.el` to your `load-path`, and
then `(require 'ns-auto-titlebar)`.Usage
=====Enable `ns-auto-titlebar-mode` with `M-x customize`, or like this:
```elisp
(when (eq system-type 'darwin) (ns-auto-titlebar-mode))
```
Note that it is safe to omit the "when" condition if you prefer.[melpa]: http://melpa.org
[💝 Support this project and my other Open Source work](https://www.patreon.com/sanityinc)
[💼 LinkedIn profile](https://uk.linkedin.com/in/stevepurcell)
[✍ sanityinc.com](http://www.sanityinc.com/)