Search code examples
phpstormphpcodesniffer

Where can I edit the background color of php_codesniffer errors?


Working with PhpStorm 2021, I use squizlabs/php_codesniffer 3.7 and want to change back phpcs warning background color.

phpcs has level ="warning"—I suppose that is some common option for all warnings, but where can I edit background color?


Solution

  • https://www.jetbrains.com/help/phpstorm/configuring-colors-and-fonts.html#customize-color-scheme

    • Settings/Preferences on macOS | Editor | Color Scheme | General
    • Errors and Warnings | Warning (or whatever error level you want to change)

    enter image description here


    You may also check out the PHP_Codesniffer inspection settings -- you should be able to change what actual style to use there etc.: Settings/Preferences | Editor | Inspections | PHP | Quality tools | PHP_CodeSniffer validation

    enter image description here

    P.S. All screenshots are made in the latest stable PhpStorm 2022.2.3