Shortcut and/or button to toggle readable line length

Hotkeys++ plugin has it!! GitHub - argenos/hotkeysplus-obsidian: Adds hotkeys to toggle todos, ordered/unordered lists and blockquotes in Obsidian

3 Likes

“Smarter Markdown Hotkeys” plugin adds in Obsidian Hotkeys window the option “Toggle Readable Line Length”…

and much more hotkeys…

2 Likes

+1 for this. We would like it available natively please :slight_smile:

1 Like

For better table editing they already introduced GUI-table-editing. For viewing code there is this file-based readable line length customization.

I am very glad that editing tables is natively easier now.

However, I still can’t see all of my table without scrolling horizontally. I use tables mainly for weekly/monthly calendars, but simply having 8-9 columns for the names of the weekdays doesn’t even fit without scrolling, much less with any content longer than the shorter day names like “Friday.”

It’s just annoying to have 2" of extra space around a table that makes me scroll to see what’s going on this weekend, and then have to scroll back to see what time that would be.

Plus, I like to embed those notes on my “Hello” canvas so I can see schedule, meal planning, etc. at a glance, together. Scrolling is defies the objective of “at a glance.”

So perhaps, I’d rather have an option to disable readable line length for entire folders. Then, I could set all of my calendars to look right with one fell swoop - and not have to worry about toggling.

Do I need to make a separate feature request for this variant of a solution to the same problem?

Hi @JVSKGardening . Your idea for folder‑based readable line length setting is good — however other settings as well could be tied to different folders. This could be a feature in Workspaces. See my comment in other thread:

You could also use xlsx. file links inside your notes. When clicked you would be directed to Excel etc. Creating file‑links is documented at Internal links - Obsidian Help. You can also create file:/// links that doesn’t import the file to your vault. Creating file:/// links is documented in Drag and drop - Obsidian Help. By default Obsidian doesn’t support all file extensions but you can toggle
Settings →Files and links → Detect all file extensions

1 Like

Use case or problem

I make heavy use of tables thanks to the amazing community plugin “Advanced Tables”

I find myself having to turn off

settings > Editor > “Readable line lenght”

many times a day, for editing tables with more space.

But for notes where I don’t edit tables I like keeping “Readable line lenght” on.

Proposed solution

What I’d like to ask it to be able to toggle this function on and off, from hotkeys.

I make heavy use of hotkeys and vim mode. And even thought the settings for Readable line lenght can be quickly accessed, it is still not as comfortable having to use the mouse every time for it.

Would really appreaciate being able to map a hotkey to it.

Thanks a lot!

PS: I couldn’t find other mentions of this request, feel free to let me know if this already exists somewhere, thanks!

36 Likes

That exact thing, for editing tables, was on my list of things to file. Thanks.

3 Likes

awesome, happy to know I’m not the only one @elmsfeuer

2 Likes

It would be great to have it. Sometimes I need to see everything on full width and now I need to change it on the config pane.

2 Likes

exactly, a hotkey would be extremly useful!

1 Like

I’d like to bump this one up. I keep running into it and it would be great to have a hot key for this

3 Likes

Recently I faced the same problem and I was thinking about a hotkey solution to it. +1 for this. Another more general solution for this could be creating hotkeys for toggling css snippets

1 Like

If anyone is using auto hot key in windows you can write a script to toggle the readable line length setting. I’ve shared mine. The only challenge is, you’d need to use window spy to edit the numbers

; Readable line toggle for ctrl+shift+L
#IfWinActive ahk_exe Obsidian.exe
^+l::
WinGetPos, , , CurrentWinWidth
CoordMode Mouse, Screen
MouseGetPos MouseXBefore, MouseYBefore
; make the window full screen if it isn't
; do this by checking if the width matches full screen width
If (CurrentWinWidth < 2560) {
    Send {F11}
}
Sleep 100
; open settings
Send ^,
; Click on "Editor"
MouseClick, Left, 324, 309, 1
Sleep 100
; Click on the readable line length toggle
MouseClick, Left, 2186, 368, 1
; Close settings
Send {Esc}
; If the window was not full screen before escape from full screen
If (CurrentWinWidth < 2560) {
    Send {F11}
}
; Move the mouse back to where it was before
MouseMove, %MouseXBefore%, %MouseYBefore%
return
3 Likes

Are you sure that this can work for everyone? I guess the placement of buttons is affected by theme and css that one uses

This is important!

1 Like

You are correct that the placement of buttons will be affected. Which is why Window Spy is needed to figure out what numbers to insert into the mouse click locations and window size parameters

1 Like

interesting, I have never used this feature of AHK, because I though it is going be very finicky for this reason, maybe I should look into it again

+1 for this feature. I end up needing to turn on/off the reading line length multiple times per day (mostly for editing tables). Having a hotkey for this would be super helpful!!! Please prioritize, thanks! :slight_smile:

2 Likes

definitely happy to see you agree!