Jump to content

Recommended Posts

Posted (edited)
Today I had a problem with TIDY
cause my script turns off TIIDY.
 
After analyzing the problem solved here is the summary:
 
 

This is a reproduction script.

#Tidy_Parameters=/sort_funcs
Func _test()
    Select
        Case 1
                if $test = True
                    $string = ""
                Then
        EndSelect

EndFunc

i know there is a issue

if $test = True
                    $string = ""
                Then

it must be that

#Tidy_Parameters=/sort_funcs
Func _test()
    Select
        Case 1
                if $test = True then
                    $string = ""
                Endif
        EndSelect

EndFunc

but please try to TIDY this one:

#Tidy_Parameters=/sort_funcs
Func _test()
    Select
        Case 1
                if $test = True
                    $string = ""
                Then
        EndSelect

EndFunc

now comment TIDY sorting and run TIDY again

;~ #Tidy_Parameters=/sort_funcs
Func _test()
    Select
        Case 1
                if $test = True
                    $string = ""
                Then
        EndSelect

EndFunc

EDIT:

I know this is not nearly as important as TIDY correctly points out errors through appropriate messages on the console.
But however you may be interested.
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

The parameter is /sf not /sort_func, and your example is written wrong, and /sf sorts your functions in your script alphabetically. No clue what you're attempting.

If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.
Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag Gude
How to ask questions the smart way!

  Reveal hidden contents

I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from.

Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays.  -  ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script.  -  Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label.  -  _FileGetProperty - Retrieve the properties of a file  -  SciTE Toolbar - A toolbar demo for use with the SciTE editor  -  GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI.  -   Latin Square password generator

Posted
  On 9/17/2013 at 11:58 PM, mlipok said:

 

Today I had a problem with TIDY
 

but please try to TIDY this one:

#Tidy_Parameters=/sort_funcs
Func _test()
    Select
        Case 1
                if $test = True
                    $string = ""
                Then
        EndSelect

EndFunc

now comment TIDY sorting and run TIDY again

;~ #Tidy_Parameters=/sort_funcs
Func _test()
    Select
        Case 1
                if $test = True
                    $string = ""
                Then
        EndSelect

EndFunc

EDIT:

I know this is not nearly as important as TIDY correctly points out errors through appropriate messages on the console.
But however you may be interested.

 

 In fact I cannot reproduce  but I get a crash with the latest Tidy (2013/9/01) with the latest Scite beta download  using the aupit3Wrapper (2013/09/08)

the main point is your last script still have errors

it should be

#Tidy_Parameters=/sort_funcs
Func _test()
    Select
        Case 1
            If $test = True Then
                $string = ""
            EndIf
    EndSelect

EndFunc   ;==>_test

so perhaps after that the /sort_funcs will be correct if suitable

Posted

maybe I in OP using wrong wording

...

I know that all, 

I havent problem with that scirpt, this is only repro.

I had a case of for a few minutes. but deal with it immediately.

this is not my working script

I exactly reproduce "TIDY crash"

to show you the fact "TIDY crash"

and to show you when TIDY may crash.

To give you the opportunity to correct TIDY.

Because IMHO any program should not end his work by accident.

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

ok

#2479

best regards

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

Fixed in the current Beta v2.3.0.20. I am now skipping the SortFunc in case there are Tidy errors as it isn't really safe to perform that option in case of Tidy errors.

 

  On 9/18/2013 at 12:14 AM, BrewManNH said:

The parameter is /sf not /sort_func,.....

Either /sf or /sort_funcs will perform the Sort Func option. :)

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)

Thanks Jos

br,

mlipok

EDIT:

confirm FIXED

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 9/18/2013 at 5:46 PM, Jos said:

Fixed in the current Beta v2.3.0.20. I am now skipping the SortFunc in case there are Tidy errors as it isn't really safe to perform that option in case of Tidy errors.

 

Either /sf or /sort_funcs will perform the Sort Func option. :)

Jos

Really? Is that documented somewhere? I go by the parameters listed in AutoIt3Wrapper, and it's not listed in there.

If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.
Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag Gude
How to ask questions the smart way!

  Reveal hidden contents

I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from.

Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays.  -  ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script.  -  Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label.  -  _FileGetProperty - Retrieve the properties of a file  -  SciTE Toolbar - A toolbar demo for use with the SciTE editor  -  GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI.  -   Latin Square password generator

Posted

in HelpFile

SciTE MENU:    HELP / SciTE HELP

section Extra Utilities / Tidy

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 9/18/2013 at 7:27 PM, mlipok said:

in HelpFile

SciTE MENU:    HELP / SciTE HELP

section Extra Utilities / Tidy

Confirmed as documentation for Tidy being found there as well as here >> http://www.autoitscript.com/autoit3/scite/docs/Tidy.html

UDF List:

  Reveal hidden contents

Updated: 22/04/2018

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
×
×
  • Create New...