开发者

Code complete styling for overridden and implemented methods in Netbeans

Does anyone know how t开发者_JAVA技巧o change the autocomplete PHP styling for Overridden/Implemented Methods in Netbeans 6.9.1

I would like to drop the opening curly bracket to the next line. eg

public function overriddenMethod()
{

}


When creating methods using alt + insert Netbeans respects the language specific formating you set in:

Tools -> Options -> Formatting Tab 

Change the Languagedropdown php and after that the Category dropdown to braces.

Now you can set new line for Method deceleration and it will create the methods like you want it to.

For me having "method" at "same line" produced this output:

public function __get($name) {

}

and after changing it do: "next line" it generated:

public function __get($name)
{

}

As an added bonus (just in case you didn't know about that:

Using alt + shift + f format all existing code according to those rules.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜