2013-04-29 99 views
0

在NetBeans IDE 7.3 RC2中使用PHP插件v1.47.1。如何更改Netbeans PHP elseif自动格式化

我喜欢评论我,如果公司和elseifs如下:

/* 
* If this is the case, then do that. 
*/ 
if (*condition1*) { 
    // do some stuff. 
} 

/* 
* Otherwise, if this is the case, do the other thing. 
*/ 
elseif (*condition2*) { 
    // do some other stuff 
} 

/* 
* Finally, if neither of these is the case, then do something 
* totally different. 
*/ 
else { 
    // do something totally different. 
} 

但是,当我打 - 到自动套用,我得到如下:

/* 
* If this is the case, then do that. 
*/ 
if (*condition1*) { 
    // do some stuff. 
} 
/* 
* Otherwise, if this is the case, do the other thing. 
*/ elseif (*condition2*) { 
    // do some other stuff 
} 
/* 
* Finally, if neither of these is the case, then do something 
* totally different. 
*/ else { 
    // do something totally different. 
} 

我可以对付它,但我希望能够改变它。我查看了工具 - >选项 - >编辑 - >格式化,但没有看到关于在新行上添加“elseif”或“else”的任何信息。

回答

1

您可以更改与格式有关的非常有限数量的设置。

转到工具>选项 点击编辑按钮上的选项对话框 点击从语言选择框 格式化标签 选择PHP的左上角,然后你就可以看到所需要的设置,可以被改变

+0

谢谢 - 在我的帖子的底部,我提到我已经试过这个。 :)我不确定是否有可以编辑的XML文件。 – livefree75 2013-04-29 17:25:37