Comments (17)
Yes, this is a known issue. org-indent-mode is currently incompatible with org-modern-mode. This is wontfix for now since org-indent-mode adjusts the line-prefix text properties which are also used by org-modern-mode. Not sure if it is possible to make this work. To be honest, I consider org-indent-mode a waste of space and not modern at all. ;)
EDIT: The issue has been fixed in e13be0f.
from org-modern.
how org lives in the dark ages without org-indent-mode: syl20bnr/spacemacs#2732
I actually had to begrudingly choose org-indent-mode over org-modern-mode just now for this incompatibility. I'll have to try @jdtsmith's package later and evaluate if I'm okay with no line-spacing everywhere.
Dark ages might be a little much, but the hierarchy that org-indent-mode adds is probably one of the things that makes org-mode most understandable to me.
from org-modern.
Perhaps if org-modern-mode implemented its own visual solution to level indentation? The reason I'd ask for this is because the indentation level is how I easily appreciate how many levels deep I actually am.
I don't have to think about what symbol precedes the text, or what color that headline is and try to remember 6 variations thereof and eventually surrender to un-hiding the leading asterisks.
from org-modern.
The indentation does exist, but there is still a problem with the indentation at the body (compare org-super-star).
See level 1, level 2, level 3 in the screenshot, they should be aligned with the heading.
from org-modern.
- Good point, I hadn't thought of line spacing. Some fonts have more vertical breathing room, so that could be a workaround.
That's not a good workaround. We shouldn't restrict ourselves to only such fonts. As I wrote, the only proper solution is to use display trickery. But it is a pain, in particular the corners.
2.This is definitely only for users of org-indent. Without indent enabled, the fringe solution already in modern is clearly superior (and saves space).
Sure. My second point only explains why I use the fringe. I had tried inserting characters as alternative and I didn't like it because of the indentation. However I think the fringe solution only looks nice if you use large frame borders and window dividers as in Nicolas Rougier's Nano themes.
Anyway, if we figure out a proper solution for 1. we can add this to org-modern itself, such that org-modern is more compatible with org-indent. It would be nice if we can achieve consistent looks for both cases (fringe vs non-fringe).
from org-modern.
same question
from org-modern.
block's indent guide line also didn't show in org-indent-mode, I choose disable org-indent-mode.
from org-modern.
@404CN Yes, org-indent-mode is quite problematic. It is an intrusive mode which breaks all kinds of other modes. I never used org-indent-mode since it always felt a bit unpredictable. Therefore it is okay if org-modern cannot be made to work with it. I will still keep this issue open in case someone finds a solution. But for example the nice org-modern source blocks use the fringe. If you indent the block, it won't look good.
In case someone wants to debug this:
- Go to the org-modern customization
- Turn off all options
- Enable the org modern styling one by one to figure out the style elements which are problematic with org-indent-mode.
- Maybe it is possible to figure out a solution on a case by case basis.
from org-modern.
For reference, here is a heated discussion on how horrible org-indent-mode is and how org lives in the dark ages without org-indent-mode: syl20bnr/spacemacs#2732 😆
from org-modern.
I fiddled a bit around and made org-modern-mode
slightly less intrusive. But it seems impossible to make these modes cooperate nicely in all scenarios, since org-indent-mode
is quite a bulldozer. I recommend to turn of org-indent-mode
if you want to use org-modern-mode
.
from org-modern.
appreciate the effort.
do you think it is possible to build something like a modern org-indent-mode?
from org-modern.
I think it should be possible to make org-modern-mode more compatible with org-indent-mode by not using the fringe for source blocks. It needs a bit of work. Currently org-modern-mode doesn't aim for full compatibility. You can use some of the org-modern style elements with org-indent-mode without issues, but not all of them.
from org-modern.
I quite like org-modern, and I quite like org-indent. So I co-opted the latter's use of line-prefix
and wrap-prefix
to approximate the block-styling of the former:
https://github.com/jdtsmith/org-modern-indent/
Works well for me; happy for any feedback. I'm not a deep org user, so I'm not sure what else org-indent-mode currently breaks in org-modern, with the recent workarounds @minad implemented.
from org-modern.
@jdtsmith The kind of cooperation you implemented between indent mode and modern mode is nice. There are two downsides of your approach:
- It does not handle line-spacing>0 well. I usually increase line-spacing since I like if Emacs doesn't look so dense. It should be possible to fix this with some display/image trickery instead of box drawing characters.
- Using prefix characters (line prefixes) indents the source blocks by one character. For non-indent users this is not so nice since everything appears shifted. By using the fringe, this problem doesn't occur. For org-indent-mode users this is of course not an issue.
For these two reasons I went with the current fringe solution.
from org-modern.
Thanks @minad.
- Good point, I hadn't thought of line spacing. Some fonts have more vertical breathing room, so that could be a workaround.
- This is definitely only for users of org-indent. Without indent enabled, the fringe solution already in modern is clearly superior (and saves space).
from org-modern.
Just FYI, strangely, I cannot reproduce this issue. The indentation is kept when using org-modern
.
My (non minimal) org config:
(use-package org
:defer t
:custom
(org-startup-indented t)
(org-confirm-babel-evaluate nil)
(org-special-ctrl-a/e t)
(org-hide-emphasis-markers t)
(org-pretty-entities t)
(org-ellipsis "…"))
(use-package org-modern
:init
(add-hook 'org-mode-hook #'org-modern-mode))
Emacs and org versions:
GNU Emacs 29.0.50 (build 1, x86_64-apple-darwin19.6.0, NS appkit-1894.60 Version 10.15.7 (Build 19H2)) of 2022-07-24
Org mode version 9.5.4 (release_9.5.4-3-g6dc785 @ /usr/local/Cellar/emacs-plus@29/29.0.50/share/emacs/29.0.50/lisp/org/)
from org-modern.
Got it. Indeed, it's misaligned here too. I hadn't noticed because it was less apparent on the other file I was working on.
from org-modern.
Related Issues (20)
- Top 2 level default fold glyphs not support by many fonts HOT 8
- New folding indicators do not render well in doom Emacs HOT 2
- Second level folding indicator showing wrong state after folding top level heading
- org-modern-tag-faces does not work as expected HOT 1
- Opt-out for fold indicators? HOT 1
- Can this package work with `visual-fill-column-center-text' set to t?
- fold-stars doesn't work well when org-cycle twice on header HOT 1
- readme screenshot image no longer visible on github
- Org agenda tags go outside the buffer
- Have fringe around dynamics block, like the one around source block.
- org-modern todo stopped working on custom agenda views
- Wrong bullet character HOT 1
- Clock and [%] headlines not aligning properly
- Org-table alignment (divider rows)
- org-modern breaks on blocks that are rendered later
- Timestamps in buffer settings HOT 1
- static-if not available in emacs 29.4 HOT 1
- New invalid-function error with static-if HOT 3
- Triggers (invalid-function static-if) constantly HOT 3
- Change to compat v30 breaks installation on debian systems HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from org-modern.