Finding related If EndIf / Repeat Until etc. by keypress

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
high key
User
User
Posts: 23
Joined: Sun Jun 08, 2003 8:07 pm

Finding related If EndIf / Repeat Until etc. by keypress

Post by high key »

Would be a nice feature to just press Ctrl Pageup, when the cursor is in a Endif-line to get to the related If-line. My If/Endifs are often quite far away (many hundred lines), so it's often very frustrating finding them. And yes, I do the indents very carefully, but if only one if or endif is at the wrong place, all hope is lost :?

I don't know, if any programming editor has such a feature?
freak
PureBasic Team
PureBasic Team
Posts: 5940
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Re: Finding related If EndIf / Repeat Until etc. by keypress

Post by freak »

Place the cursor on the keyword itself and press Ctrl+K.
quidquid Latine dictum sit altum videtur
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: Finding related If EndIf / Repeat Until etc. by keypress

Post by PB »

Nice! I wasn't even aware of this. :)
I compile using 5.31 (x86) on Win 7 Ultimate (64-bit).
"PureBasic won't be object oriented, period" - Fred.
high key
User
User
Posts: 23
Joined: Sun Jun 08, 2003 8:07 pm

Re: Finding related If EndIf / Repeat Until etc. by keypress

Post by high key »

@freak wow, that's exactly, what I was looking for! Thanks a lot!
davido
Addict
Addict
Posts: 1890
Joined: Fri Nov 09, 2012 11:04 pm
Location: Uttoxeter, UK

Re: Finding related If EndIf / Repeat Until etc. by keypress

Post by davido »

Thanks freak, didn't know that. :D
Should have, though, as it is in the manual. :oops:

A little research shows that it is in the drop-down menu from Edit, but not in the right-click menu. Shouldn't both menues be the same?
I always use the right-click menu. So my wish is that it should be there, too.
DE AA EB
Post Reply