org-modern
- Description
- Modern looks for Org
- Latest
- org-modern-1.5.0.20241022.103450.tar (.sig), 2024-Oct-22, 80.0 KiB
- Maintainer
- Daniel Mendler <mail@daniel-mendler.de>
- Website
- https://github.com/minad/org-modern
- Browse ELPA's repository
- CGit or Gitweb
- Badge
- Manual
- org-modern
To install this package from Emacs, use package-install
or list-packages
.
Full description
1. Introduction
This package implements a modern style for your Org buffers using font locking
and text properties. The package styles headlines, keywords, tables and source
blocks. The styling is configurable, you can enable, disable or modify the style
of each syntax element individually via the org-modern
customization group.
The screenshots shows example.org with org-modern-mode
turned on and off. The
elegant theme featured in the screenshot is modus-operandi.
Since this package adjusts text styling, it depends on your font settings. You
should ensure that your variable-pitch
and fixed-pitch
fonts combine
harmonically and have approximately the same height. As default font, I
recommend variants of the Iosevka font, e.g., Iosevka Term Curly.
org-modern-mode
tries to adjust the tag label display based on the value of
line-spacing
. This looks best if line-spacing
has a value between 0.1 and 0.4 in
the Org buffer.
2. Configuration
The package is available on GNU ELPA and MELPA. You can install the package with
package-install
. Then org-modern
can be enabled manually in an Org buffer by
invoking M-x org-modern-mode
. In order to enable org-modern
for all your Org
buffers, add org-modern-mode
to the Org mode hooks.
;; Option 1: Per buffer (add-hook 'org-mode-hook #'org-modern-mode) (add-hook 'org-agenda-finalize-hook #'org-modern-agenda) ;; Option 2: Globally (with-eval-after-load 'org (global-org-modern-mode))
Try the following more extensive setup in emacs -Q
to reproduce the looks of the
screenshot above.
;; Minimal UI (package-initialize) (menu-bar-mode -1) (tool-bar-mode -1) (scroll-bar-mode -1) (modus-themes-load-operandi) ;; Choose some fonts ;; (set-face-attribute 'default nil :family "Iosevka") ;; (set-face-attribute 'variable-pitch nil :family "Iosevka Aile") ;; (set-face-attribute 'org-modern-symbol nil :family "Iosevka") ;; Add frame borders and window dividers (modify-all-frames-parameters '((right-divider-width . 40) (internal-border-width . 40))) (dolist (face '(window-divider window-divider-first-pixel window-divider-last-pixel)) (face-spec-reset-face face) (set-face-foreground face (face-attribute 'default :background))) (set-face-background 'fringe (face-attribute 'default :background)) (setq ;; Edit settings org-auto-align-tags nil org-tags-column 0 org-catch-invisible-edits 'show-and-error org-special-ctrl-a/e t org-insert-heading-respect-content t ;; Org styling, hide markup etc. org-hide-emphasis-markers t org-pretty-entities t ;; Agenda styling org-agenda-tags-column 0 org-agenda-block-separator ?─ org-agenda-time-grid '((daily today require-timed) (800 1000 1200 1400 1600 1800 2000) " ┄┄┄┄┄ " "┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄") org-agenda-current-time-string "◀── now ─────────────────────────────────────────────────") ;; Ellipsis styling (setq org-ellipsis "…") (set-face-attribute 'org-ellipsis nil :inherit 'default :box nil) (global-org-modern-mode)
3. Incompatibilities
org-indent-mode
is not compatible with the block prettification in the fringe. Iforg-indent-mode
is enabled,org-modern
will disable the block prettification.org-num-mode
interferes with theorg-modern
prettification of TODO keywords.visual-wrap-prefix-mode
relies on thewrap-prefix
text property which is also used byorg-modern
.
4. Alternatives
The tag style of org-modern
is inspired by Nicholas Rougier's svg-tag-mode. In
contrast to svg-tag-mode
, the package org-modern
avoids images and uses more
efficient Emacs box text properties. By only styling the text via text
properties, the styled text, e.g., dates or tags stay editable and are easy to
interact with.
The approach used here restricts the flexibility (e.g., no rounded corners) and
creates dependence on the size and alignment of the font. Combining
org-modern-mode
with svg-tag-mode
is possible. You can use SVG tags and use the
table and block styling from org-modern
. If you are interested in further
tweaks, Emacs comes with the builtin prettify-symbols-mode
which can be used for
individual styling of custom keywords.
Alternatives are the older org-superstar
and org-bullets
packages, which are
more limited and mainly adjust headlines and lists. org-superstar
relies on
character composition, while org-modern
uses text properties, which are
considered more future-proof. Note that org-modern
is a full replacement for
both org-superstar
and org-bullets
. You can disable styling of certain elements,
e.g., org-modern-timestamp
, if you only want to use the subset of org-modern
equivalent to org-superstar
.
5. Contributions
Since this package is part of GNU ELPA contributions require a copyright assignment to the FSF.
Old versions
org-modern-1.5.0.20240926.92259.tar.lz | 2024-Sep-26 | 14.3 KiB |
org-modern-1.5.0.20240914.202549.tar.lz | 2024-Sep-15 | 14.3 KiB |
org-modern-1.5.0.20240910.145422.tar.lz | 2024-Sep-10 | 14.3 KiB |
org-modern-1.5.0.20240803.195206.tar.lz | 2024-Aug-03 | 14.3 KiB |
org-modern-1.4.0.20240726.173421.tar.lz | 2024-Jul-26 | 14.3 KiB |
org-modern-1.3.0.20240722.83058.tar.lz | 2024-Jul-22 | 14.4 KiB |
org-modern-1.1.0.20240308.144842.tar.lz | 2024-Mar-08 | 13.4 KiB |
org-modern-0.10.0.20231019.184309.tar.lz | 2023-Oct-19 | 13.2 KiB |
org-modern-0.9.0.20230614.170049.tar.lz | 2023-Jun-14 | 13.1 KiB |
org-modern-0.2.0.20220307.175543.tar.lz | 2022-Mar-07 | 18.1 KiB |
News
1. Development
- Require Emacs 28.1.
2. Version 1.5 (2024-08-03)
- Bugfixes.
3. Version 1.4 (2024-07-25)
- Fix date formatting after #+date keyword.
- Fix table divider line scaling.
- Fix TODO state formatting in custom agendas.
- Bump Compat dependency to Compat 30.
4. Version 1.3 (2024-06-02)
- Add support for heading folding indicators. The option
org-modern-star
has been changed to accept the valuesfold
,replace
andnil
. Setorg-modern-star
toreplace
to go back to the old default behavior. - Add new customization options
org-modern-replace-stars
andorg-modern-fold-stars
. - Add
org-modern-tag-faces
. - Add colored coded progress bars. The variable
org-modern-progress
specifies the width of the bars.
5. Version 1.2 (2024-03-16)
org-modern-star
,org-modern-hide-stars
,org-modern-progress
: Support string values.
6. Version 1.1 (2023-12-01)
- Bugfix: Do not use zero line width for box face attribute. Zero line widths are disallowed in Emacs 30.
7. Version 1.0 (2023-12-01)
- Bugfix: Remove line/wrap-prefix if fringe is enabled
8. Version 0.10 (2023-07-02)
- Bugfixes.
- Fix star prettification if
org-indent-mode
is enabled. - Prettify
filetags
.
9. Version 0.9 (2023-03-12)
- Improve prettification of stars, such that line movement commands are not affected negatively.
- Use
natnum
custom types. - Depend on the Compat library.
10. Version 0.8 (2023-02-15)
- Start of changelog.