#Tidy_ILC_Pos=-1 ; strip space between "code end" and "comment start" to single space (old behavior) - this mean move dynamicaly "InLineComment_Pos" starting in line at "comment start" to nearest "code end" column position #Tidy_ILC_Pos=0 ; save my (user) manually set "InLineComment_Pos" (do not move them) - THIS IS DEFAULT NEW CURRENT BEHAVIOR #Tidy_ILC_Pos=50 ; preset "InLineComment_Pos" to column #50 #CS ; comment for #CE Func _CommentedFunction() For $i =1 To 10 ; some comment ; REMARK 1: #Tidy_ILC_Pos start acting from next line ; REMARK 2: #Tidy_ILC_Pos does not apply to lines wiht #Region and #EndRegion directives Next EndFunc ;==>_CommentedFunction #CE ; comment for #CE ; REMARK 3: #Tidy_ILC_Pos does not act on line without code Global Enum _ $UDFNAME_ERR_SUCCESS, _              ; No Error $UDFNAME_ERR_GENERAL, _              ; General - some Error - Not classified type of error $UDFNAME_ERR_ENUMCOUNTER              ; just for testing #Tidy_ILC_Pos=40 Global Const $UDFNAME_EXT_DEFAULT =0     ; default Extended Value Global Const $UDFNAME_EXT_PARAM1 =1 ; Error Occurs in Parameter #1 Global Const $UDFNAME_EXT_PARAM2 =2             ; Error Occurs in Parameter #2 Global Const $UDFNAME_EXT_PARAM3 =3             ; Error Occurs in Parameter #3 #Tidy_ILC_Pos=0 ; do not change user ILC_Pos _Example_1() Func _Example_1() ; user manually set InLineComment_Pos as column #25 - will not be moved as #Tidy_ILC_Pos=0           While        1 ; user manually set InLineComment_Pos as column #35 - will not be moved as #Tidy_ILC_Pos=0 WEnd #Tidy_ILC_Pos=55 For $i = 1      To      10 ; For             ; some important Loop Next ; next ; important Loop ending For $i = 1      To $aFileList[0] ; For ; $aFileList: - HEADER ; some processing ; some processing ; some processing SomeFunction1() ; Looping $aFileList: Warning .... this is important part .... ; some processing ; some processing ; some processing SomeFunction2() ; Looping $aFileList: !!! do not delete this line. It's prventing ERROR on ..... ; some processing ; some processing ; some processing SomeFunction3() ; Looping $aFileList: CleanUp for GPDR ! Next ; Next ; $aFileList: - END Looping #Tidy_ILC_Pos=80         MsgBox(      0    ,      '              '        ,       1)               ; SOME DISTANT COMMENT AT 99 COLUMN EndFunc #Tidy_ILC_Pos=45 Func _Example2() ; STEP BY STEP FUNCTION While 1 Switch GUIGetMsg() Case $1; STEP 1 Return Case $1; STEP 2 MsgBox(0, '', 1) Case $GUI_EVENT_CLOSE ExitLoop Case $1; STEP 3 Return EndSwitch WEnd EndFunc #Region - Any             description1 ; comment #1          #EndRegion #Region - Any             description2 ; comment #2          #EndRegion #Region - Any             dscription ; comment #3          #EndRegion #Region - Any             dscription ; comment #4          #EndRegion #Tidy_ILC_Pos=-1 ; strip space between "code end" and "comment" to single space (old behavior) Func SomeFunction1() ; TEST 1 EndFunc Func SomeFunction2() ; TEST 2 EndFunc Func SomeFunction3()      ; TEST 3 EndFunc