Code-folding. The only thing TP needs to be PERFECT !!!

Ideas for new features

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
egodoyc
Posts: 7
Joined: Tue Jul 26, 2005 11:03 pm

Code-folding. The only thing TP needs to be PERFECT !!!

Post by egodoyc »

All modern developer environments must have code-folding.

This would enable the user to selectively hide and display modules, classes or functions of the currently edited file with source code.

Usually, to fold or display a piece of code, the user should click the - or + icon to the left of the code.

This is the only thing that TextPad needs to be PERFECT.
dougcrews
Posts: 9
Joined: Mon Nov 29, 2004 8:39 pm
Contact:

Concur.

Post by dougcrews »

I love TextPad but I really miss this brace highlighting/code folding feature that most other code editors seem to have:

Code: Select all

    method()
(-) {
    |   loop()
(-) |   {
    |   |   blah
    |   |   blah
    |   }
    |
    |   // This loop is folded up and hidden temporarily
    |   loop()...
(+) |   {...}
    }
Add those and I'd gladly pay the registration fee over again.
dtoader
Posts: 15
Joined: Thu Feb 22, 2007 9:50 pm

Just because it is new, it is not better

Post by dtoader »

Code folding is a bad idea:
I need to go through another step to see inside nested code blocks.
Why should I do that?

All of the "modern" text editors have this "feature".

If any feature should be added to Textpad, I'd go old school
and recommend ctags-like keyword hyper-linking.

Ctags is a program that generates an index (or tag) file of names found
in source and header files of various programming languages. Depending
on the language, functions, variables, class members, macros and so on
may be indexed. These tags allow definitions to be quickly and easily
located by a text editor or other utility. Alternatively, there is also an
output mode that generates a cross reference file, listing information
about various names found in a set of language files in human-readable
form.

The original Ctags was introduced in BSD Unix and was written by Ken
Arnold, with Fortran support by Jim Kleckner and Pascal support by Bill
Joy.

It's a feature I love in vim/vi and I miss in Textpad.

Textpad happens to have another old-school feature that vi/vim has:
Split Edit Window

This is an old-school feature that many "modern" text editors lack.
With Split Edit Window, I can see a relevant code section
while editing another section of code simultaneously.

Just my 2 cents.
aka_bigred
Posts: 6
Joined: Wed Nov 04, 2009 3:37 pm

Post by aka_bigred »

I'd echo the request for code folding or at least some sort of block highlighting if not folding.

I really miss it in Textpad, but textpad is the all-around best fitting editor I've found.
aka_bigred
Posts: 6
Joined: Wed Nov 04, 2009 3:37 pm

Re: Just because it is new, it is not better

Post by aka_bigred »

dtoader wrote:Code folding is a bad idea:
I need to go through another step to see inside nested code blocks.
Why should I do that?
If you don't want to fold the code, then you wouldn't turn on code folding. At least let the people that want it have it.

I agree there's times where it's simply an extra step, but when you have massive code files, it can be a life/eye saver!
jtonathiu
Posts: 1
Joined: Fri Nov 06, 2009 2:51 am

Code folding

Post by jtonathiu »

I completey agree. I miss it too.

This would be the perfect TextPad editor
Old Hack
Posts: 1
Joined: Fri Nov 06, 2009 10:02 am

Post by Old Hack »

I would also like to see code folding as an option. It would certainly help to navigate around complex coding - especially when you have had to break off writing the code for a few days.

But I also like the advantages os split-screen mode. Going back more than 20 years, with Xedit you could split the screen into up to 8 horizontal panes to simultaneously view different parts of the same file. So, more advanced split-screen options would be handy too. :idea:
qkz73
Posts: 33
Joined: Thu Jul 22, 2004 9:15 pm

a convert

Post by qkz73 »

I've said before I wouldn't really use this. But I take that back. Having used Zend studio for a while (for PHP), I decided I really like it. It helps out most when managing large files. That coupled with a Class Explorer would be quite powerful. I know everyone is using different languages, but there's probably a way to make it work. (UE has it, right?)

Mostly, I see this as beneficial for classes and functions.. not really necessary at all for all the rest of the blocks like if/while/etc. A custom thing like the #region in VS/C# would be cool, I use those quite a bit for b-i-g classes to silo off blocks of similar methods, etc.

P.S. Many (if not most?) of us code the RIGHT way and don't utterly waste vertical space with open-braces on their own lonely line, so this feature would need to support:

Code: Select all

function whatever() {
    if() {
        /// do something
    } else {
        /// do something different
    }
}
- QKZ -
egodoyc
Posts: 7
Joined: Tue Jul 26, 2005 11:03 pm

This is heading to make other editors to be better accepted

Post by egodoyc »

This is heading to make other editors to be better accepted.


I have seen code-folding in many other Text editors, like UltraEdit, NotePad++, gEdit and EditPlus. Some of them distributed under GNU licence.

And I really love TextPad, but the lack of this feature makes difficult to edit large code files.

http://lifehacker.com/385929/best-text-editors
Post Reply