DONE: Code folding #region in PHP
-
crtrubshaw
- Posts: 391
- Joined: 06 Jun 2012 11:08
DONE: Code folding #region in PHP
Hi Rickard, is it possible for TextEd to recognise "#region... #endregion" as a fold node in PHP? I think it might be possible by editing PHP.syx but can't figure it out.
Thank you.
Thank you.
Re: Code folding #region in PHP
Me neither; additionally //__START__ ... //__END__ doesn't work for me, either.
Alium tibi quaere fratrem; hic, quem tuum putas, meus est. Titus Flāvius Caesar Vespasiānus Augustus
- Rickard Johansson
- Site Admin
- Posts: 6900
- Joined: 19 Jul 2006 14:29
Re: Code folding #region in PHP
Fixed in next release (v16.37). Thanks!
-
crtrubshaw
- Posts: 391
- Joined: 06 Jun 2012 11:08
Re: DONE: Code folding #region in PHP
Hi Rickard, this appears to have stopped working (v16.55, 64-bit).
- Rickard Johansson
- Site Admin
- Posts: 6900
- Joined: 19 Jul 2006 14:29
Re: DONE: Code folding #region in PHP
Fixed in next version (v16.56). Thanks!
-
crtrubshaw
- Posts: 391
- Joined: 06 Jun 2012 11:08
Re: DONE: Code folding #region in PHP
Hello again, I have upgraded to v16.56 but it still doesn't create an automatic fold region, is there something I should check?
Thank you.
Thank you.
- Rickard Johansson
- Site Admin
- Posts: 6900
- Joined: 19 Jul 2006 14:29
Re: DONE: Code folding #region in PHP
Make sure the region labels are the first words found on the line (without spaces).
Code: Select all
//__START__
// Code here
if ( ) {
}
//__END__-
crtrubshaw
- Posts: 391
- Joined: 06 Jun 2012 11:08
Re: DONE: Code folding #region in PHP
Hi Rickard, I am using
Please include this syntax in the fix.
Thank you!
Code: Select all
#region
...
#endregion
Thank you!
- Rickard Johansson
- Site Admin
- Posts: 6900
- Joined: 19 Jul 2006 14:29
Re: DONE: Code folding #region in PHP
Until I implement a better solution you could replace
in PHP.syx with
Code: Select all
[Fold]
1_Id=^//__START__
1_Begin=
1_End=^//__END__
Code: Select all
[Fold]
1_Id=^#region
1_Begin=
1_End=^#endregion
-
crtrubshaw
- Posts: 391
- Joined: 06 Jun 2012 11:08
Re: DONE: Code folding #region in PHP
Thanks Rickard!
That does work, but it disables any fold regions in the region. It's not too serious at the moment because I typically want to collapse the region, but just saying, other fold regions don't do that.
That does work, but it disables any fold regions in the region. It's not too serious at the moment because I typically want to collapse the region, but just saying, other fold regions don't do that.
- Rickard Johansson
- Site Admin
- Posts: 6900
- Joined: 19 Jul 2006 14:29
Re: DONE: Code folding #region in PHP
This should work properly now in the next release (v16.57). Thanks!
