ejmr/php-mode — pull request #159 by jdufresne (2014-07-21 23:11:24+00:00)
Title: Do not override variable tab-width when indenting with spaces.

The number of spaces to indent is controlled by the correctly set
variable c-offset-width. The value of tab-width does not influence
this. When indent-tabs-mode is nil, indentation is always acheived
using spaces, not tabs. The various modes set this correctly. However,
the modes that indent using spaces also override tab-width which might
undo a user's set value.

As an example, a user may prefer a literal tab (not code indentation)
be rendered as 8 spaces. And so this user would set tab-width to 8 in
init.el. All PHP modes override this value even when not using tabs
for indentation. This mean's the user's preferred tab width is altered
for no gain.

I prefer using tab-width 8 so I can quickly see when code is
incorrectly indented with tabs instead of spaces. The overriding of
this value breaks this for me. Of course, I workaround this by
re-setting tab-width in hooks, but why put the user through this in
the first place.

Coding styles that indent using tab (such as wordpress) remain
unaltered.