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 228890 - Extending the PHP Formatting options to enable multilevel indentation
Summary: Extending the PHP Formatting options to enable multilevel indentation
Status: NEW
Alias: None
Product: php
Classification: Unclassified
Component: Formatting & Indentation (show other bugs)
Version: 7.3
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: Ondrej Brejla
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-04-23 12:12 UTC by Rushleader
Modified: 2013-04-24 07:55 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rushleader 2013-04-23 12:12:09 UTC
Problem: Trying to nicely format a method call with new classes/method in the arguments is not completing/activating the indentation in php.

The current setting of creating my code would be something like this:

$this->addChild(
    $this->activeGroup = new GroupObject(),
    $this->inactiveGroup = new InactiveGroupObject(
        $this->inactiveLabel = new InactiveLabel("Inactive, this won't activate"),
        $this->activateGroupButton = new Button("Unless you press this button")
    )
);

This should be the formatting of the method call when calling with new inner classes, instead this happens

$this->addChild(
    $this->activeGroup(), $this->inactiveGroup = new InactiveGroupObject( $this->inactiveLabel = new InactiveLabel("Inactive, this won't activate"), $this->activateGroupButton = new Button("Unless you press this button")
    )
);

As you can see, this isn't the best formatting to work with.
I've tried changing my settings in Tools->options->editor->formatting but nothing would change for the better (some options would even put everything on a different line and not indent at all.
Maybe I've missed something in the options but i don't think so since the number formatting options for method arguments isn't that high.

This problem occured after updating to Netbeans 7.3 (Build 201302132200). Never happened on Netbeans 7.2.1
Comment 1 Rushleader 2013-04-24 07:55:57 UTC
Extra info: 

This programming style is used in a framework which simulates the dom tree. So constructing node within node is a often used command.