Jump to content

Recommended Posts

Posted

Using your's testing script.

 

OLD version

image.thumb.png.64dd215106a7fedf8b503f758471bd84.png

NEW version

image.png.10028cbedfd487612e94fac229ba2fb1.png

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted
  On 3/16/2022 at 10:12 AM, mLipok said:
But also would like to have this behavior:
image.png.990102c01efe44746cddb6406b76c317.png
 
for :
#Au3Stripper_Ignore_Funcs=
#Au3Stripper_Ignore_Errors_in_Funcs=
#Au3Stripper_Ignore_Variables=
Expand  

also for:

#Au3Stripper_Ignore_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Errors_in_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Variables=$SOMEVALUE, $SOMEVALUE2
#ignorefunc _Example, _Example_1, _Example_2, _Example_3
#forcedef $SOMEVALUE, $SOMEVALUE2
#forceref $sTest, $SOMEVALUE, $SOMEVALUE

 

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted (edited)

I would also ask about such feature:

#TODO TASK 1 ; Description
#TODO TASK 2 ; Description
#REMARK ; any remark

#TODO TASK 1 ; Description
#TODO TASK 2 ; Description

#REMARK ; any remark
 

currently it looks like:

image.png.8d6d3a336c6288c142bafb9dd5dbc357.png

REMARK:
I use foreground color (because it is easy to show the concept) but for green color I was thinking about background color.

Something like:

image.png.76a180cb720bb77a73d1ff17cbf5aed0.png

 

Edited by mLipok

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted (edited)

I also combine all scripts into one full/combined testing script:

Global $Variable

; Comment block
#cs Level1
If 1 = 2 Then ;test
    ConsoleWrite("Yea right") ;test
EndIf
;~  #cs Level2
;~  ; multilevel directive is shown as comment
;~  #ce Level2
#ce Level1
#comments-start Level1
    ; comments
#comments-end   Level1

; Special
#AutoIt3Wrapper_Run_Au3Check=n
#Au3Stripper_AlwaysStrip_Off=1
#AutoIt3Wrapper_UseX64=N
#AutoIt3Wrapper_Run_AU3Check=Y
#AutoIt3Wrapper_AU3Check_Stop_OnWarning=y
#AutoIt3Wrapper_AU3Check_Parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6 -w 7
#AutoIt3Wrapper_Run_Au3Stripper=y
#Au3Stripper_Parameters=/MO /RSLN /DEBUG /TL /SCI=9
#Au3Stripper_Off
#Au3Stripper_On
#Au3Stripper_AlwaysStrip_Off
#Au3Stripper_AlwaysStrip_On
#Au3Stripper_Ignore_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Errors_in_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Variables=$SOMEVALUE, $SOMEVALUE2
#Tidy_ILC_Pos=120
#Tidy_Parameters=/sort_funcs /reel
#Tidy_Off
#Tidy_On
#ignorefunc _Example, _Example_1, _Example_2, _Example_3

#Region - User's functions
#EndRegion - User's functions

; preprocessor
#RequireAdminaaa  #cs #ce ; This script requires full Administrative rights
#RequireAdmin ; This script requires full Administrative rights
#RequireAdminxxthe rest is considered a comment
#RequireAdmin  the rest is considered a comment
#include-once  the rest is considered a comment
#include <Array.au3>
#NoTrayIcon  the rest is considered a comment
#OnAutoItStartRegister "Example"
; Any Unknown preprocessor
#whatever directive you use
; Lexing bug
#RequireAdmin #cs  Admin #ce ; <=====  Causing the rest of the code to be wrongly colored
If 1 = 2 Then ;test
    ConsoleWrite("Yea right") ;test
EndIf

#ce ; redundant #ce

#comments-start
#comments-end

#comments-start

#comments-end

#cs
#ce

#cs documentation
#CE documentation
#CS documentation
some text
some text
#CE documentation


#TODO TASK 1 ; Description
#TODO TASK 2 ; Description
#REMARK ; any remark

_Example()
Func _Example($sTest = '(Empty string :)')
    #forcedef $SOMEVALUE, $SOMEVALUE2
    #forceref $sTest, $SOMEVALUE, $SOMEVALUE
    $sTest = "SOME TEST"
    Return SetError(@error, @extended, ($sTest))

EndFunc

_Example_1()
_Example_2()
_Example_3()

Func _Example_1(ByRef $sTest)

EndFunc

Func _Example_2($sTest = "(Empty string :)")
EndFunc

Func _Example_3()
    For $i = 1 To UBound() -1
        While 1
            ConsoleWrite("! " & @CRLF)
            #cs
            ; test
            #ce
        WEnd

    Next
EndFunc

 

Edited by mLipok

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

  • Developers
Posted
  On 3/16/2022 at 1:00 PM, mLipok said:

Using your's testing script.

Expand  

Showing me an image in dark mode of something I already have without any definition of it being right/wrong and details doesn't tell me anything! ;) 

So what about you stop posting all these details for a moment and we take it one step at the time ( as discussed before) .... :) 

I have found the issue with #region and have that fixed....  and am now looking at the CommentBlock folding which clearly is due to me changing the Color for the initial statement, so need to think about how that all was working again as it has been a long time ago i last touched that part of the code.   

  On 3/16/2022 at 1:24 PM, mLipok said:

I also combine all scripts into one full/combined testing script:

Expand  

Fine ....but again don't see any comments in there where things go wrong in your mind.... but as stated, let me first tackle the #region and Commentblock folding and then we test again and tackle any remaining issue.

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Posted
  On 3/16/2022 at 1:36 PM, Jos said:

So what about you stop posting all these details for a moment and we take it one step at the time ( as discussed before) .

Expand  

I already stoped as I posted all what I had to post ;)

 

  On 3/16/2022 at 1:36 PM, Jos said:

Fine ....but again don't see any comments in there where things go wrong in your mind

Expand  

All comments was in posts. Script is only a combination of all testing script to have possibility to check all issues/feature request, at once.

  On 3/16/2022 at 1:36 PM, Jos said:

Let me first tackle the #region and Commentblock folding and then we test again and tackle any remaining issue.

Expand  

Perfectly fine, as for me.

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

  • Developers
Posted

Please try the current Beta with the following changes:

  • #Region & #EndRegion will have the LineComment color for everything behind the directive (style.au3.1)
  • #Comment block folding fix (i hope)
  • #SPECIALS will have the LineComment color for everything behind the directive (so style.au3.1 in stead of style.au3.12)

This should be the first 3 items in the list. :) 

 

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

  • Developers
Posted (edited)

 

 

  On 3/16/2022 at 1:23 PM, mLipok said:

#TODO TASK 1 ; Description
#TODO TASK 2 ; Description

#REMARK ; any remark

Expand  

Uploaded new Beta which will change the color from Pre-Processor style.au3.11  to Line Comment style.au3.1 when an ";" is encountered.

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

  • Developers
Posted (edited)

Next Beta available... the testcode now look like this:

  Quote

Global $Variable

; Comment block
#cs Level1
    If 1 = 2 Then ;test
        ConsoleWrite("Yea right") ;test
    EndIf
    #cs Level2
    ; multilevel directive is shown as comment
    #ce Level2
#ce Level1
#comments-start Level1
    ; comments
#comments-end   Level1

; Special
#AutoIt3Wrapper_Run_Au3Check=n
#Au3Stripper_AlwaysStrip_Off=1
#AutoIt3Wrapper_UseX64=N
#AutoIt3Wrapper_Run_AU3Check=Y
#AutoIt3Wrapper_AU3Check_Stop_OnWarning=y
#AutoIt3Wrapper_AU3Check_Parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6 -w 7
#AutoIt3Wrapper_Run_Au3Stripper=y
#Au3Stripper_Parameters=/MO /RSLN /DEBUG /TL /SCI=9
#Au3Stripper_Off
#Au3Stripper_On
#Au3Stripper_AlwaysStrip_Off
#Au3Stripper_AlwaysStrip_On
#Au3Stripper_Ignore_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Errors_in_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Errors_in_Func=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Variables=$SOMEVALUE, $SOMEVALUE2
#Tidy_ILC_Pos=120
#Tidy_Parameters=/sort_funcs /reel
#Tidy_Off
#Tidy_On
#ignorefunc _Example, _Example_1, _Example_2, _Example_3

#Region - User's functions
#EndRegion - User's functions

; preprocessor
#RequireAdminaaa  #cs #ce ; This script requires full Administrative rights
#RequireAdmin ; This script requires full Administrative rights
#RequireAdminxxthe rest is considered a comment
#RequireAdmin  the rest is considered a comment
#include-once  the rest is considered a comment
#include <Array.au3>
#NoTrayIcon  the rest is considered a comment
#OnAutoItStartRegister "Example"
; Any Unknown preprocessor
#whatever directive you use
; Lexing bug
#RequireAdmin #cs  Admin #ce ;
If 1 = 2 Then ;test
    ConsoleWrite("Yea right") ;test
EndIf

;#ce ; redundant #ce

#comments-start
#comments-end

#comments-start

#comments-end

#cs
#ce

#cs documentation
#CE documentation
#CS documentation
some text
some text
#CE documentation


#TODO TASK 1 ; Description
#TODO TASK 2 ; Description
#REMARK; any remark
#REMARK=any remark  ( you can use either ; or = to change the lexer color to commentline.)

_Example()
Func _Example($sTest = '(Empty string :)')
    #forcedef $SOMEVALUE, $SOMEVALUE2
    #forceref $sTest, $SOMEVALUE, $SOMEVALUE
    $sTest = "SOME TEST"
    Return SetError(@error, @extended, ($sTest))

EndFunc

_Example_1()
_Example_2()
_Example_3()

Func _Example_1(ByRef $sTest)

EndFunc

Func _Example_2($sTest = "(Empty string :)")
EndFunc

Func _Example_3()
    For $i = 1 To UBound() -1
        While 1
            ConsoleWrite("! " & @CRLF)
            #cs
            ; test
            #ce
        WEnd

    Next
EndFunc

Expand  

 

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Posted (edited)

Highlighiting is awesome, almost perfectly.

I notice issue is related to red color of #Au3Stripper_Ignore_Errors_in_Funcs

image.png.27b3803c4b58cde9ba7123fb050854bd.png


And I have one feature request for the following:

#Au3Stripper_Ignore_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Errors_in_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Variables=$SOMEVALUE, $SOMEVALUE2
#ignorefunc _Example, _Example_1, _Example_2, _Example_3

Could they have similar way fo highlighting like:

#OnAutoItStartRegister "_Example"
#OnAutoItStartRegister _Example

This following screenshot shows how it would look like (showing concept)

image.png.0978890c1c2cc2ca80757a1cf58dc3dc.png

 

EDIT:
The same:

image.png.00a1e29f0d2b0db3a81f7107d9ae708b.png

 

Edited by mLipok

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

  • Developers
Posted (edited)
  On 3/17/2022 at 8:17 AM, mLipok said:

I notice issue is related to red color of #Au3Stripper_Ignore_Errors_in_Funcs

Expand  

That highlights fine as directive as that in NOT an au3Stripper directive hence the different color. The correct directive is:

#Au3Stripper_Ignore_Errors_in_Func

;)

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Posted (edited)

And main issue folding lines are broken

 

for #cs.....#ce

image.png.df897a1cb11ec8d5f083fbeb9ffa30fa.png

 

and for Func...EndFunc

image.png.44b52d6a67c8bc279edc15109d5022ae.png

 

image.png.80167cee96cd52a6b2e84a38312d3653.png

Edited by mLipok

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted
  On 3/17/2022 at 8:26 AM, Jos said:

That highlights fine as directive as that in NOT an au3Stripper directive hence the different color. The correct directive is:

#Au3Stripper_Ignore_Errors_in_Func

;)

Expand  

It was copied from SciTE4AutoIt3.chm there is wrong name used.

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

  • Developers
Posted (edited)

The commentblock folding work fine for me , so post example source. This will happen when there is un issue before these statements.

I don't understand the second and third one...  what is wrong there? ...  (and post the source to test with.)

  On 3/17/2022 at 8:28 AM, mLipok said:

It was copied from SciTE4AutoIt3.chm there is wrong name used.

Expand  

Will change it for the next version. :) 

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Posted
  On 3/17/2022 at 8:37 AM, Jos said:

The commentblock folding work fine for me , so post example source.

Expand  

This is my current testing script:

; TESTING: GLOBALS
Global $Variable
Global Enum _
        $enum1, _
        $enum2
Global Const $const




; TESTING: COMMENT BLOCK
#cs Level1
If 1 = 2 Then ;test
    ConsoleWrite("Yea right") ;test
EndIf
;~  #cs Level2
;~  ; multilevel directive is shown as comment
;~  #ce Level2
#ce Level1
#comments-start Level1
    ; comments
#comments-end   Level1

#ce

#comments-start
#comments-end

#comments-start

#comments-end

#cs
#ce

#cs documentation
#CE documentation
#CS documentation
some text
some text
#CE documentation





; TESTING: COMMENTS
;~ few
;~ lines
;~ of
;~ comments





; TESTING: SPECIAL 1
#AutoIt3Wrapper_Run_Au3Check=n
#Au3Stripper_AlwaysStrip_Off=1
#AutoIt3Wrapper_UseX64=N
#AutoIt3Wrapper_Run_AU3Check=Y
#AutoIt3Wrapper_AU3Check_Stop_OnWarning=y
#AutoIt3Wrapper_AU3Check_Parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6 -w 7
#AutoIt3Wrapper_Run_Au3Stripper=y
#Au3Stripper_Parameters=/MO /RSLN /DEBUG /TL /SCI=9
#Au3Stripper_Off
#Au3Stripper_On
#Au3Stripper_AlwaysStrip_Off
#Au3Stripper_AlwaysStrip_On
#Tidy_ILC_Pos=50
#Tidy_Parameters=/sort_funcs
#Tidy_Off
#Tidy_On




; TESTING: SPECIAL 2
#Au3Stripper_Ignore_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Errors_in_Func=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Variables=$SOMEVALUE, $SOMEVALUE2
#ignorefunc _Example, _Example_1, _Example_2, _Example_3
#OnAutoItStartRegister "_Example"
#OnAutoItStartRegister _Example




; TESTING: REGIONS
#Region - User's functions
#EndRegion - User's functions

#Region - User's functions
Func _Test()
    ; some test
EndFunc   ;==>_Test
#EndRegion - User's functions




; TESTING: PREPROCESSOR
#RequireAdminaaa  #cs #ce                        ; ILC This script requires full Administrative rights
#RequireAdmin                                    ; ILC This script requires full Administrative rights
#RequireAdminxxthe rest is considered a comment
#RequireAdmin  the rest is considered a comment
#include-once  the rest is considered a comment
#include <Array.au3>
#NoTrayIcon  the rest is considered a comment




; TESTING: ANY UNKNOWN PREPROCESSOR
#whatever directive you use
#TODO TASK 1 ; Description
#TODO TASK 2 ; Description
#REMARK ; any remark





; TESTING: LEXING BUG
#RequireAdmin #cs  Admin #ce                     ; ILC <=====  Causing the rest of the code to be wrongly colored





; TESTING: CODE AND FUNCTIONS
If 1 = 2 Then                                    ;ILC test
    ConsoleWrite("Yea right")                    ;ILC test
EndIf

_Example()
Func _Example($sTest = '(Empty string :)')
    #forcedef $SOMEVALUE, $SOMEVALUE2
    #forceref $sTest, $SOMEVALUE, $SOMEVALUE
    $sTest = "SOME TEST"
    Return SetError(@error, @extended, ($sTest))

EndFunc   ;==>_Example

_Example_1()
_Example_2()
_Example_3()

Func _Example_1(ByRef $sTest)

EndFunc   ;==>_Example_1

Func _Example_2($sTest = "(Empty string :)")
    Local Enum _
            $enum1, _
            $enum2
    Local Static $static
    Local Const $const
EndFunc   ;==>_Example_2

Func _Example_3()
    For $i = 1 To UBound() -1
        While 1
            ConsoleWrite("! " & @CRLF)
            #cs
            ; test
            #ce
        WEnd

    Next
EndFunc   ;==>_Example_3

 

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

  • Developers
Posted
  On 3/17/2022 at 8:37 AM, Jos said:

The commentblock folding work fine for me , so post example source. This will happen when there is un issue before these statements.

I don't understand the second and third one...  what is wrong there? ...  (and post the source to test with.)

Will change it for the next version. :) 

Expand  

I actually made the change in au3stripper as that is more consistent the the directive can contain multiple func names. API  and properties are also updated in Beta. 

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

  • Developers
Posted (edited)
  On 3/17/2022 at 8:40 AM, mLipok said:

This is my current testing script:

Expand  

There is a #ce too many in there causing the folding to break the folding after that.

"D:\Development\AutoIt3\programs\test\test.au3"(24) : ### Tidy Error: "#ce" is likely missing it's opening statement. next line creates a negative tablevel.

 

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Posted
  On 3/17/2022 at 8:37 AM, Jos said:

I don't understand the second and third one...  what is wrong there? ...  (and post the source to test with.)

Expand  

This is how it looks now:

image.png.5c57b79eadab6796a8bbf3ab19db8c2f.png

I propose to change highlighting in this way:

image.png.7e56fb6be48c93a58c7d53b36720ad30.png

 

It will be very handy for reading code but alos for using "Search only in this style" feature:

image.png.a1376b8e66239d2d1c88347c60647ce9.png

 

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted (edited)
  On 3/17/2022 at 8:49 AM, Jos said:

There is a #ce too many in there causing the folding to break the folding after that.

Expand  

Yeah. There is redundant #ce I put them there intentionally to check what happens, and it seams that he is the reason of issue with folding lines in relation to #cs....#ce blocks.

But even if I comment them the issue is persistent.

Check current testing script:
 

; TESTING: GLOBALS
Global $Variable
Global Enum _
        $enum1, _
        $enum2
Global Const $const




; TESTING: COMMENT BLOCK
#cs Level1
If 1 = 2 Then ;test
    ConsoleWrite("Yea right") ;test
EndIf
;~  #cs Level2
;~  ; multilevel directive is shown as comment
;~  #ce Level2
#ce Level1
#comments-start Level1
    ; comments
#comments-end   Level1

; redundant #ce
;~ #ce

#comments-start
#comments-end

#comments-start

#comments-end

#cs
#ce

#cs documentation
#CE documentation
#CS documentation
some text
some text
#CE documentation





; TESTING: COMMENTS
;~ few
;~ lines
;~ of
;~ comments





; TESTING: SPECIAL 1
#AutoIt3Wrapper_Run_Au3Check=n
#Au3Stripper_AlwaysStrip_Off=1
#AutoIt3Wrapper_UseX64=N
#AutoIt3Wrapper_Run_AU3Check=Y
#AutoIt3Wrapper_AU3Check_Stop_OnWarning=y
#AutoIt3Wrapper_AU3Check_Parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6 -w 7
#AutoIt3Wrapper_Run_Au3Stripper=y
#Au3Stripper_Parameters=/MO /RSLN /DEBUG /TL /SCI=9
#Au3Stripper_Off
#Au3Stripper_On
#Au3Stripper_AlwaysStrip_Off
#Au3Stripper_AlwaysStrip_On
#Tidy_ILC_Pos=50
#Tidy_Parameters=/sort_funcs
#Tidy_Off
#Tidy_On




; TESTING: SPECIAL 2
#Au3Stripper_Ignore_Variables=$SOMEVALUE, $SOMEVALUE2
#Au3Stripper_Ignore_Funcs=_Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Errors_in_Func=_Example, _Example_1, _Example_2, _Example_3
#ignorefunc _Example, _Example_1, _Example_2, _Example_3
#OnAutoItStartRegister _Example, _Example_1, _Example_2, _Example_3
#OnAutoItStartRegister "_Example"

; TESTING: SPECIAL 2
#Au3Stripper_Ignore_Variables=$SOMEVALUE, $SOMEVALUE2
#Au3Stripper_Ignore_Funcs=                _Example, _Example_1, _Example_2, _Example_3
#Au3Stripper_Ignore_Errors_in_Func=        _Example, _Example_1, _Example_2, _Example_3
#ignorefunc                                _Example, _Example_1, _Example_2, _Example_3
#OnAutoItStartRegister                     _Example, _Example_1, _Example_2, _Example_3
#OnAutoItStartRegister "_Example"




; TESTING: REGIONS
#Region - User's functions
#EndRegion - User's functions

#Region - User's functions
Func _Test()
    ; some test
EndFunc   ;==>_Test
#EndRegion - User's functions




; TESTING: PREPROCESSOR
#RequireAdminaaa  #cs #ce                        ; ILC This script requires full Administrative rights
#RequireAdmin                                    ; ILC This script requires full Administrative rights
#RequireAdminxxthe rest is considered a comment
#RequireAdmin  the rest is considered a comment
#include-once  the rest is considered a comment
#include <Array.au3>
#NoTrayIcon  the rest is considered a comment




; TESTING: ANY UNKNOWN PREPROCESSOR
#whatever directive you use
#TODO TASK 1 ; Description
#TODO TASK 2 ; Description
#REMARK ; any remark





; TESTING: LEXING BUG
#RequireAdmin #cs  Admin #ce                     ; ILC <=====  Causing the rest of the code to be wrongly colored





; TESTING: CODE AND FUNCTIONS
If 1 = 2 Then                                    ;ILC test
    ConsoleWrite("Yea right")                    ;ILC test
EndIf

_Example()
Func _Example($sTest = '(Empty string :)')
    #forcedef $SOMEVALUE, $SOMEVALUE2
    #forceref $sTest, $SOMEVALUE, $SOMEVALUE
    $sTest = "SOME TEST"
    Return SetError(@error, @extended, ($sTest))

EndFunc   ;==>_Example

_Example_1()
_Example_2()
_Example_3()

Func _Example_1(ByRef $sTest)

EndFunc   ;==>_Example_1

Func _Example_2($sTest = "(Empty string :)")
    Local Enum _
            $enum1, _
            $enum2
    Local Static $static
    Local Const $const
EndFunc   ;==>_Example_2

Func _Example_3()
    For $i = 1 To UBound() -1
        While 1
            ConsoleWrite("! " & @CRLF)
            #cs
            ; test
            #ce
        WEnd

    Next
EndFunc   ;==>_Example_3

 

Edited by mLipok

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

  • Developers
Posted (edited)
  On 3/17/2022 at 8:55 AM, mLipok said:

I propose to change highlighting in this way:

Expand  

Understand, but that would require all kinds of hardcoding in the lexer. The lexer basically finds and known "Special Keyword" defined in the properties file and everything behind the keyword is considered a line comment. 

 

  On 3/17/2022 at 8:59 AM, mLipok said:

But even if I comment them the issue is persistent.

Expand  

Not for me...  it work right away when I add a ; to the start of the line.
EDIT: But i do see something strange happening ...so let me check!!

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...