Page 1 of 1

Indentation, Default.

Posted: Sun Apr 03, 2022 7:10 pm
by Flinx
Hello,

Two (or three) small flaws:

Code: Select all

If a
	If b
		If c

		EndIf
	EndIf
EndIf

	Switch (t)
	Case 1:
	default:
	EndSwitch
If you put the cursor behind the first EndIf and press Enter, the indentation of this line changes. The same happens with Case and default.
Furthermore the IDE does not know the keyword "default".

Ralf

Re: Indentation, Default.

Posted: Thu Apr 07, 2022 5:52 pm
by airsoftsoftwair
Well, the de-indentation on "EndIf", "Case" etc. is actually a feature. The IDE will always remove one tab in lines that contain one of the block closures like "EndIf", "Wend", "Next" etc. Fixing this to be sensitive to the current block is too much work because it would have to scan (potentially many) previous lines to find out which block is about to be closed.

The fact that "Default:" wasn't highlighted correctly has been fixed now, though.

Code: Select all

- Fix [IDE]: The "Default" keyword wasn't highlighted when followed by a colon

Re: Indentation, Default.

Posted: Fri Apr 08, 2022 2:25 pm
by Flinx
Sorry, regarding the de-indentation I should have seen that. I had an irritating effect whith copy and paste and wanted to provide a simple example, but that went wrong. Maybe I can find and try it again.