12
10

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

【PhpStorm】PhpStormでコメントアウトの位置を設定する【PHP】

Posted at

PhpStorm導入直後でPhpStorm初心者です

やりたいこと

PhpStormで Command + / でコメントアウトができるが、初期設定だと最左位置に // が入るためこれをもとのソースの位置にしたい
image.png

環境

端末 MacBook Pro (13-inch, 2017, Two Thunderbolt 3 ports)
OS macOS Mojave 10.14.2
PhpStorm 2018.3.2

調べる

「phpstorm comment out position」でググって記事(stackoverflow)を発見。

設定方法

Preferences -> Code Style -> PHP を選択
SchemaをProjectに変更して(Defaultだと変更しても保存されなかった)
"Code Generation" タブで "Line comment at first colum" のチェックを外す
// のあとにスペースがほしかったので
"Add a space at comment start" にチェックを入れる
image.png

12
10
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
12
10

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?