Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to choose spaces instead of tab #668

Open
titanomachy opened this issue Nov 24, 2024 · 1 comment
Open

Option to choose spaces instead of tab #668

titanomachy opened this issue Nov 24, 2024 · 1 comment

Comments

@titanomachy
Copy link

Description

Currently the tab button returns a literal tab character. In most editors there is an option to convert a tab in to a number of spaces. White space indenting is important for e.g. Python, Nim, Haskell etc. Having to type 4 spaces is cumbersome, but I could not find an option to change it.

Describe the solution you'd like

Solution

  • An option for choosing the indentation character: Tab or Space
  • An option for setting the amount of spaces when indenting with the Tab key

Scintilla
The documentation for the Scintilla editor for indentation are here: https://www.scintilla.org/ScintillaDox.html#TabsAndIndentationGuides

SciTE
In SciTE you can change the SciTEUser.properties file and insert:

tabsize=4         # Sets the width of a tab character to 4 spaces
indent.size=4     # Sets the indentation size to 4 spaces
use.tabs=0        # Ensures that pressing the Tab key inserts spaces instead of tab characters

Language specific settings, e.g. for Python, are set in a python.properties file.

file.patterns.py=*.py
tab.size=4
indent.size=4
use.tabs=0

NotepadNext
For NotepadNext in src/scintilla/.editorconfig is set on line 4: indent_style = tab

I don't know how NotepadNext handles and stores preferences under "setting > preferences".

Notepad++
This is the Notepad++ setting for indentation:
tab-indentation

Describe alternatives you've considered

Macro feature, but that does not work sufficiently.

@titanomachy
Copy link
Author

In SciTE setting indentation via SHIFT+CTRL+I or menu Options > Change Indentation Settings is also possible.

SciTE-indentation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant