Sign in to follow this  
Followers 0
LongBowNZ

Tidy Region within Region problem

9 posts in this topic




I didn't want to bump the thread but its on the second page so

*bump*

Share this post


Link to post
Share on other sites

#Region - 1
#Region - 2
#EndRegion - 2
#EndRegion - 1

When I Tidy the above code it changes to the below code.

#Region - 1
#Region - 2
#EndRegion - 2
#EndRegion - 2
Well, #Region tags are not meant to be nested at all. It is not doing any math with your numbers, just substituting the string. Everything after "#Region" is considered a comment, and Tidy is just making the comments match. Similar to to putting the function name after EndFunc. Try this to see the effect:
#Region One

#Region Two

#EndRegion Two

#Region Three

#EndRegion Three

#EndRegion One

:)


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

Yeah I thought it wasn't supposed to be nested but I also thought maybe noone had tried it before because I searched the forums and noone mentioned it.

Thats also why the topic description is "Bug?" because I was hoping nesting could be implemented if possible.

Share this post


Link to post
Share on other sites

Yeah I thought it wasn't supposed to be nested but I also thought maybe noone had tried it before because I searched the forums and noone mentioned it.

Thats also why the topic description is "Bug?" because I was hoping nesting could be implemented if possible.

It's not a bug, because it works as intended. But you could put it in as a Feature Request to Jos via Bug Trac.

:)


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

@Feature Request

Done Thanks :)

Share this post


Link to post
Share on other sites

I have never considered the #region - #endRegion nesting when copying the Comment from the #region statement.

I will follow it up when time permits and report back in the feature request.

Jos :)


Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

#8 ·  Posted (edited)

Uploaded Tidy v 2.0.23.16 to the Beta area, which now supports nested #region statements for its comment copy options.

Jos

Edited by Jos

Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

I have never considered the #region - #endRegion nesting when copying the Comment

Exactly why I decided to make the topic :)

Uploaded Tidy v 2.0.23.16 to the Beta area, which now supports nested #region statements for its comment copy options.

Thank you :P, I'll check it out

Share this post


Link to post
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
Sign in to follow this  
Followers 0