PHPStorm 的 Ctrl + / 的单行注释,只能顶头加嘛?

2021-05-07 14:08:24 +08:00
 dzdh
function x()
{
// < 直接顶这里了    $ctrl+/注释
    // $ctrl+/注释  <-怎么在缩进内进行注释
}
1514 次点击
所在节点    PHP
3 条回复
dzdh
2021-05-07 14:17:49 +08:00
自问自答:

安装中文语言包后。

设置->编辑器->代码样式->PHP->代码生成->注释的代码。取消勾选。
Rache1
2021-05-08 10:34:30 +08:00
File | Settings | Editor | Code Style | PHP

Code Generation | Comment Code

取消这两个的勾选,先写内容再按快捷键注释
Rache1
2021-05-08 10:37:12 +08:00
File | Settings | Editor | Code Style | PHP

Wrapping and Braces | Keep when reformatting | Comment at first column
取消勾选

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/775422

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX