| Summary: | Python indentation problem: function definition inside class is automatically indented inside previous function | ||
|---|---|---|---|
| Product: | [Frameworks and Libraries] frameworks-ktexteditor | Reporter: | Lucas Pires Camargo <lucaspcamargo> |
| Component: | general | Assignee: | KWrite Developers <kwrite-bugs-null> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | |
| Priority: | NOR | ||
| Version First Reported In: | 5.38.0 | ||
| Target Milestone: | --- | ||
| Platform: | Other | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
Yes, this is a KTextEditor bug, in the Python indenter. I'll move it. This does not happen anymore in recent releases. This bug can be closed I guess. |
Whenever I have code like this: ''' class A: def a(self): print("a") def b(self): ''' Even if I have just pressed shift-Tab to go back an indentation level, as soon as I start writing the definition of function b, it gets indented to be inside function a. The same happens if I correct indentation afterwards, and then correct the line, its indentation level gets bumped up again. This is unbearably annoying. The menu Tools>Indentation is indeed in "Python" mode. So this might be a Kate bug, dunno.