Actions
Defect #33707
closedHighlighted code with 'diff' format converts tabs to spaces, which breaks IDEs
Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Text formatting
Target version:
-
Start date:
Due date:
% Done:
0%
Estimated time:
Resolution:
Duplicate
Affected version:
Description
If I paste some code like a diff
(patch format), then tabs are replaced by 4 spaces:
Index: web/SomeJs.js
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- web/SomeJs.js (revision a772b73079dfedeaafa2a941b33b4bb03fc77b2a)
+++ web/SomeJs.js (date 1593706024927)
@@ -7,13 +7,33 @@
};
SomeJs.prototype.isMobile = function () {
- return /Foo/.test("a");
Please compare with raw format, where I got some <TAB>
chars originally (edit the description to see that the tabs are still there):
Index: web/SomeJs.js IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== --- web/SomeJs.js<TAB>(revision a772b73079dfedeaafa2a941b33b4bb03fc77b2a) +++ web/SomeJs.js<TAB>(date 1593706024927) @@ -7,13 +7,33 @@ }; SomeJs.prototype.isMobile = function () { -<TAB>return /Foo/.test("a");
This is annoying cause copying the diff
from the visual view does not work. I have to copy from the Edit
view and apply the patch in my IDE this way.
Related issues
Updated by Go MAEDA over 4 years ago
- Is duplicate of Defect #28793: Redmine replaces tabs with spaces in code blocks added
Updated by Go MAEDA over 4 years ago
- Status changed from Confirmed to Closed
- Resolution set to Duplicate
I found that the same problem has already been reported as #28793. Closing this issue as a duplicate of it.
Thank you for reporting this issue.
Actions