+1 vote

I'm new to Godot, but I'm having some issues finding the settings of the built-in text editor. In particular, I'm trying to change the current behaviour, which is that 4 whitespaces get converted into 1 tab whenever one saves. I would actually like to:

  1. Have eventually the opposite conversion, so saving converts tabs into spaces;
  2. Have an indentation setting that allowed me to set n (e.g. 4) whitespaces as indentation and then that pressing TAB actually inserts such n spaces instead of a \t.

Does exist anything like that?
Do I need to open an issue on GH to propose that?

P.S. I think this is a standard of modern code editors, including VS Code and PyCharm

Godot version 3.3.1.stable.mono
in Engine by (24 points)
edited by

If you've figured out the solution to your problem, then reply to your question with the answer.

Comment Deleted

1 Answer

+2 votes
Best answer

I just realised how to achieve that!
From the top menu, find and press on Editor -> Editor Settings.

Menu that appears when clicking "Editor" from the top menu, showing "Editor Settings"

It will open a new window and you will find on the left, the item Text Editor with subitem Indentation. There, you can change Type from Tabs to Spaces. I recommend you leave Size to 4 and that you enable Draw Spaces.

image "Indentation"">

by (24 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.