You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 3, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Mar 3, 2023. It is now read-only.
While digging into scoping editor.softTabs in #3718, it's pretty clear that the setting has very little influence on the actual value chosen. It's effectively the worst-case fallback: it only works on an empty file.
I propose doing a couple things:
adding a new editor.tabType setting that accepts 3 values: Auto, Hard, Soft. With the default being auto. Then in the scoped settings for each language, they can set it to whatever they want.
Changing TextEditor::setSoftTabs to being a settings override accepting 4 values: unset / use-the-settings, Auto, Hard, Soft
Reading the settings on each time we need to get the tab type. Something like (pseudo code):
All the +1's only add noise at this point, so I'm locking this issue until someone begins working on it. At that point we may re-open it for discussion purposes.
The big issue as reported is the inaccurate "guessing" combined with the inability for an editor-wide setting (and not per-file setting). It may be that several preferences may be required instead of having one monolithic setting which is clearly causing unhappiness:
Default for all files (y/n)
Default for certain files (by file extension)
Setting on per file basis
The idea would be to be able to re-order these in terms of priority, based on the needs of the user.
Reacted by Álex C., Ricardo Graça, Marc Jordan, Asbjørn Ulsberg, Roy Revelt and Zennii
I'm with @jeffmcneill on this one; it's still a problem in Atom 1.16.0 and the current settings just doesn't work. The editor-settings package outlines a lot of the functionality I would like to see in Atom wrt. whitespace handling, but it also does not work correctly as it seems to be fighting with Atom on what tab type should be used. Couple that with the whitespace package and you have complete chaos.
I would love to see the current settings, packages and everything related to whitespace wiped from the face of the earth, because it's bug-ridden junk that Just Doesn't Work. Then, I would like to see something implemented along these lines:
A base setting for tab preference that did not try to be smart in any way. Just a clear "hard tab" or "spaces" (the phrase "soft tab" is just confusing; please get rid of it) that perhaps can have a checkbox for "change existing whitespace on save".
A way à la editor-settings to configure tab preference for every language (and/or file type). This should override the previous setting.
Support for EditorConfig. If there's an .editorconfig file in the project file hierarchy that is an ancestor or sibling to the current file, use that to adjust the tab setting of the file. This should override previous settings.
With these three levels all supported within Atom without any packages, I believe it's possible to reach sanity and get rid of a lot of bug-ridden, "intelligent" code that obviously doesn't work and also serve the needs of most people.
Reacted by Benjamin Staneck, Jeff McNeill, Roy Revelt, SirPavlova, John Shammas, kylegoetz, Benjamin Gray, Zennii and Guy Bolton King
This issue has been automatically locked since there has not been any recent activity after it was closed. If you can still reproduce this issue in Safe Mode then please open a new issue and fill out the entire issue template to ensure that we have enough information to address your issue. Thanks!
Activity
lee-dohm commentedon Oct 4, 2014
Discuss Topics:
Issues:
If I find more, I'll edit this comment.
benogle commentedon Oct 8, 2014
Thanks @lee-dohm that's exactly what I was looking for.
benogle commentedon Oct 8, 2014
Removing from the API freeze roadmap as it is not necessary for the api freeze. Will happen shortly after.
ilanbiala commentedon Dec 24, 2014
Also please add support for per language soft tabs support somehow.
10 remaining items
xaviergmail commentedon Jun 28, 2015
👍 I find myself having to replace all tabs with spaces and re-open a file to get tab to insert spaces properly, which isn't very intuitive.
JeffreyVdb commentedon Jun 29, 2015
This should be made possible language specifically. Most languages have their own coding conventions. This is a critical bug if you ask me.
pbhogan commentedon Jun 29, 2015
👍 Can't even think of switching to Atom for actual work until this is fixed.
fedorov commentedon Jun 29, 2015
+1
unRob commentedon Jun 30, 2015
+1
thomasjo commentedon Jun 30, 2015
All the +1's only add noise at this point, so I'm locking this issue until someone begins working on it. At that point we may re-open it for discussion purposes.
Add tabType config-item related functions as softTabs backend.
jeffmcneill commentedon Jun 13, 2016
Most reports of issues seem to be closed without resolving the underlying problem. There is only one open I could find (on cursory clicking):
Closed
Open
The big issue as reported is the inaccurate "guessing" combined with the inability for an editor-wide setting (and not per-file setting). It may be that several preferences may be required instead of having one monolithic setting which is clearly causing unhappiness:
The idea would be to be able to re-order these in terms of priority, based on the needs of the user.
asbjornu commentedon May 7, 2017
I'm with @jeffmcneill on this one; it's still a problem in Atom 1.16.0 and the current settings just doesn't work. The editor-settings package outlines a lot of the functionality I would like to see in Atom wrt. whitespace handling, but it also does not work correctly as it seems to be fighting with Atom on what tab type should be used. Couple that with the whitespace package and you have complete chaos.
I would love to see the current settings, packages and everything related to whitespace wiped from the face of the earth, because it's bug-ridden junk that Just Doesn't Work. Then, I would like to see something implemented along these lines:
.editorconfigfile in the project file hierarchy that is an ancestor or sibling to the current file, use that to adjust the tab setting of the file. This should override previous settings.With these three levels all supported within Atom without any packages, I believe it's possible to reach sanity and get rid of a lot of bug-ridden, "intelligent" code that obviously doesn't work and also serve the needs of most people.
lock commentedon Apr 2, 2018
This issue has been automatically locked since there has not been any recent activity after it was closed. If you can still reproduce this issue in Safe Mode then please open a new issue and fill out the entire issue template to ensure that we have enough information to address your issue. Thanks!