Bug 14716 - Code folding in editor
Summary: Code folding in editor
Status: UNCONFIRMED
Alias: None
Product: R
Classification: Unclassified
Component: Mac GUI / Mac specific (show other bugs)
Version: R 2.14.0
Hardware: All Mac OS X v10.7
: P5 enhancement
Assignee: Simon Urbanek
URL:
Depends on:
Blocks:
 
Reported: 2011-10-28 15:51 UTC by Timothy Paine
Modified: 2011-10-28 19:10 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Timothy Paine 2011-10-28 15:51:19 UTC
It would be a lovely, though minor, improvement to the editor to be able to fold a script based on function definitions, if statements or for loops (basically, anywhere that braces {} are used). Visibility of code within the braces would be toggled by clicking on a triangle (or other symbol), commonly located in the gutter at the left side of the editor window. 

Is this a difficult feature to add?

best-
tim
Comment 1 Simon Urbanek 2011-10-28 19:10:30 UTC
Unfortunately it is actually quite difficult. We are not aware of any classes we could use for this, so it would have to be done "by hand" which involves a lot of work since the NSTextView classes are not designed for this. If anyone knows about a better solution, we might reconsider.

Thanks,
Simon