Jump to content

Using Tidy with other editors


Danp2
 Share

Recommended Posts

I've notices a few oddities when trying to use Tidy v23.402.1150.0 with VSCode --

  • Error message near the end that states "Unable to restore Folds and Boomarks due to Sessionfile not found:C:\Users\xxx\AppData\Local\Temp\tidyscite.session". When using /SCI=9, I see a message stating "Disable SciTE folds !", so it seems like it shouldn't be attempting to restore the folds / bookmarks.
     
  • I have a section of code that looks like this --
     
    #Tidy_ILC_Pos=42
    Global Enum _                            ; https://www.w3schools.com/jsref/prop_doc_readystate.asp
            $_WD_READYSTATE_Uninitialized, _ ; Has not started loading
            $_WD_READYSTATE_Loading, _       ; Is loading
            $_WD_READYSTATE_Loaded, _        ; Has been loaded
            $_WD_READYSTATE_Interactive, _   ; Has loaded enough to interact with
            $_WD_READYSTATE_Complete, _      ; Fully loaded
            $_WD_READYSTATE__COUNTER
    #Tidy_ILC_Pos=0

    Running Tidy from VSCode works correctly on this code as long as an instance of Scite exists. When I run Tidy without Scite being open, then the indentation looks like this --

    #Tidy_ILC_Pos=42
    Global Enum _                            ; https://www.w3schools.com/jsref/prop_doc_readystate.asp
            $_WD_READYSTATE_Uninitialized, _         ; Has not started loading
            $_WD_READYSTATE_Loading, _               ; Is loading
            $_WD_READYSTATE_Loaded, _                ; Has been loaded
            $_WD_READYSTATE_Interactive, _           ; Has loaded enough to interact with
            $_WD_READYSTATE_Complete, _              ; Fully loaded
            $_WD_READYSTATE__COUNTER
    #Tidy_ILC_Pos=0

@Jos Any ideas?

Link to comment
Share on other sites

  • Developers
9 hours ago, Danp2 said:

Error message near the end that states "Unable to restore Folds

That was a wrong test whether tidy was started by SciTE or not. Should be fixed in the current Beta.

9 hours ago, Danp2 said:

Running Tidy from VSCode works correctly on this code as long as an instance of Scite exists.

Yea....  it does try to get the tabsize from SciTE and uses that to calculate the number of spaces to use.
In case SciTE isn't running then tabsize=x needs to be set on either the #Tidy_Parameters= /tabsize=4  (/ts=4 ) or  define in tidy.ini the field  tabsize=4 under [ProgramSettings] to set it as default.
I have made some changes in the last Beta version to make this work properly and also set the default to 4 when not defined.

Let me know when you find other issues when ran outside of SciTE as that is not much tested by me! ;) 

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.
  :)

Link to comment
Share on other sites

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
 Share

  • Recently Browsing   0 members

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