Adjust discrepant indentation guides in code blocks (code fences)

What I’m trying to do

Inside code blocks, indentation guides do not match the setting Tab indent size in application settings. This is true in any theme. My Tab indent size is set to 4 but indentation guides are displaying as 2 spaces wide.

Things I have tried

  • Researched topic on this forum - recommendation has been to register bug with theme developer; but this discrepancy is noted in all themes tried (at least 5-6 themes.)
  • Internet search elsewhere

This “issue” is the default behavior. I’m also annoyed by it so I adjust the CSS a little to push back the indentation guide.

.markdown-source-view.mod-cm6 .HyperMD-codeblock-begin .cm-indent::before,
.markdown-source-view.mod-cm6 .cm-hmd-codeblock .cm-indent::before {
    transform: none;
}

Hope this helps.

That’s brilliant - thank you so much!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.