jrsconfitto / language-powershell

PowerShell language support for the Atom editor
https://atom.io/packages/language-powershell
Other
44 stars 17 forks source link

Fold Regions #42

Open hillbear opened 9 years ago

hillbear commented 9 years ago

Whenever I wrap a block of code within a region, the plugin does not parse it as code that can be folded.

Can this ability be added to the script, or is this something I can force in Atom configuration?

jrsconfitto commented 9 years ago

Thanks for letting me know. i’ll take a look and see what we can do to support it.

hillbear commented 9 years ago

Thanks! Just for example purposes, this is what I am referring to: ISE 3 Regions

jrsconfitto commented 9 years ago

i think i've got an idea of how to make this work, but i need to try it. i think related information can be found in the textmate manual section on folding.

jrsconfitto commented 9 years ago

Nevermind that earlier idea. Looks like Atom doesn't respect the foldingStartMarker and foldingStopMarker in a grammar, but instead is indentation based, which may make regions difficult? Ref: https://github.com/atom/first-mate/issues/48#issuecomment-114044244.