This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 199885 - Code folding when editing YAML is over-eager.
Summary: Code folding when editing YAML is over-eager.
Status: RESOLVED FIXED
Alias: None
Product: web
Classification: Unclassified
Component: YAML (show other bugs)
Version: 7.0
Hardware: All All
: P3 normal with 1 vote (vote)
Assignee: Ondrej Brejla
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-04 20:30 UTC by contrebis
Modified: 2012-05-05 10:22 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description contrebis 2011-07-04 20:30:26 UTC
Code folding when editing a YAML file is over-eager.

From the

    Tools / Options / Editor / General

screen, tick

    Code folding / Collapse by default: Methods

Create a file of type "YAML File" and type some YAML code into the editor panel.

For any text that is indented, the yaml editor will fold the code as you type it.

Expected that the code will remained unfolded until asked and I wouldn't expect the code to fold by default (yaml keys/values aren't methods).

The only workaround I have found is to disable the above option, but this disables across all file types.

This happens consistently.

As a side/personal note I find the behaviour a little over-eager when editing PHP methods as well - I would only expect the default folding to happen on page load.


Product Version: NetBeans IDE 7.0 (Build 201104080000)
Java: 1.6.0_23; Java HotSpot(TM) 64-Bit Server VM 19.0-b09
System: Windows 7 version 6.1 running on amd64; Cp1252; en_GB (nb)
Comment 1 Ondrej Brejla 2011-09-01 14:57:33 UTC
Reassigning
Comment 2 Ondrej Brejla 2012-05-04 13:04:00 UTC
It could be better to use another ption then "Method"...e.g. "Tags and another code blocks". But all other things are not yaml connected...yaml support just provides offset ranges to fold, nothing else. That problems, you describe, are problem of folding infrastructure from CSL, or from some higher infrastructure.
Comment 3 Ondrej Brejla 2012-05-04 13:15:02 UTC
So folding is now nmanaged by "Tags and other code blocks" option.

Fixed in web-main #caf5ebbe67e0
Comment 4 Quality Engineering 2012-05-05 10:22:01 UTC
Integrated into 'main-golden', will be available in build *201205050400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/caf5ebbe67e0
User: Ondrej Brejla <obrejla@netbeans.org>
Log: #199885 - Code folding when editing YAML is over-eager.