Use extra constants and keywords from Web Mode if available

Web Mode allows users to define a custom list of additional PHP
constants and keywords.  This patch incorporates those lists into
their PHP Mode counterparts.  However, in PHP Mode we create the lists
as constants at compile-time.  That means users who reconfigure those
lists in Web Mode will not see the changes automatically propagate to
PHP Mode.
README: Replace ‘php-mode’ with ‘PHP Mode’ for consistency

For some months now I have been writing ‘PHP Mode’ for the name of the
project and so I wanted to update the README accordingly.
README: Update the ‘Status’ section
README: Use the spelling ‘GitHub’ consistently

I realize how marginal of a detail this is, but that is the correct
way to spell it.  Patches like these are a clear sign that I’m
avoiding legitimately important issues.
README: Add installation instructions
Address the compiler warning regarding `c-syntactic-context'
GitHub-Issue: 102 (Unit Test)
Fix indentation error involving magic constants

Consider the following code from the test case in this patch:

    $x = some_function(__FILE__) . '';
    $broken = true;

PHP Mode will indent the second line far to the right, aligning the
start of the line with the concatenation operator from the line
above it.  CC Mode (which handles our indentation) indents the second
line according to the settings for `knr-argdecl'.  None of the
indentation styles we provide give any value to this.

This patch modifies all of the PHP Mode indentation styles so that
`knr-argdecl' has the value of a vector with one element: the number
zero.  This tells Emacs to always position the line in the first
column so that we get the actual indentation in the example above.

This approach is not bullet-proof.  If we write the same two lines of
code inside of a function then CC Mode indents the second line using
something besides `knr-argdecl'.  However, that does not mean there
are not other situations where it may meaningfully use `knr-argdecl'
in a situation where we do not want to start a line in the first
column of the screen.  This patch fixes the specific problem of the
bug report referenced below, but there may still be corner-cases where
indentation surrounding magic constants unexpectedly breaks.

GitHub-Issue: 102
Merge branch 'ejmr/issue-102'

* ejmr/issue-102:
  Fix indentation error involving magic constants
  GitHub-Issue: 102 (Unit Test)
Stop marching indentation for try-catch blocks

This patch not only fixes the issue but also includes a test case
which has a lot of commentary explaining how CC Mode tries to indent
try-case blocks and the potential problems therein.  Our specific fix
in this patch is to add the keyword `catch' to the constant list
`php-block-stmt-2-kwds'.  The result is that it adds the keyword to
the CC Mode list `c-block-stmt-2-key' and that automatically takes
care of indenting try-catch blocks in situations where we put the
keywords and braces on the same lines together.

GitHub-Issue: 68
GitHub-Issue: 100 (Unit Test)
Fix two errors with the regex for matching namespace imports

1. We need to escape all backslashes.  Specifically we need to write
‘\\s-’ instead of ‘\s-’ for matching whitespace.

2. We want to match zero or more whitespace characters, not just one
optional character.

GitHub-Issue: 100
GitHub-Issue: 115 (Unit Test)

We expect this test to fail because of a current limitation in the
test suite.  In order to test for indentation we use ‘magic comments’
and describe the correct, expected offset for indentation that we want
to see when running the tests.  The test for issue 115 has this:

    // ###php-mode-test### ((indent c-lineup-cascaded-calls))

The test suite code will fail on this magic comment because it tries
to treat `c-lineup-cascaded-calls' like a variable that we can compare
to the indentation.  The problem is that `c-lineup-cascaded-calls' is
a function, and we need to apply it to the correct ‘language element’
in order to get an indentation we can compare against.

Until the test suite supports this behavior we will expect the test
for issue 115 to always fail.
Use the PEAR indentation style by default for unit tests

We can tell the `with-php-mode-test' macro to use an explicit
indentation style if necessary.  However, we rarely do so, meaning
that the temporary buffers we create for testing indentation take on
the user’s preferred default indentation style, e.g. `gnu' or `linux'.
We only ensure correct indentation for the styles that PHP Mode
explicitly provides to users.  So this patch changes the behavior of
the macro to use the PEAR style of indentation by default, that way we
can be sure we are testing indentation with a style we support.

This patch also modifies the macro so that it enables PHP Mode before
selecting any style, as the original order of trying to select the
style first can cause errors.

This change relates to the issue below, as its unit test would no
longer pass since I was not using one of PHP Mode’s specific styles.

GitHub-Issue: 29
Align chained method calls inside of arrays

This patch modifies the four PHP Mode specific indentation styles so
that method calls in arrays align like so:

    $x = ["x" => $this->foo()
                      ->bar()
                      ->baz()];

Admittedly this may introduce unexpected indentation in some
circumstances, particularly with the Drupal style, as it was the only
style that defined `arglist-cont-nonempty'.  We do not have any tests
which use that cc-mode syntactic symbol in other contexts.  So this
patch implements the indentation above but because our test suite does
not thoroughly examine `arglist-cont-nonempty' this patch should be
first on our list of ‘things to check’ and possibly revert if we
receive any bug reports related to `arglist-cont-nonempty'.

GitHub-Issue: 115
Update php-mode-modified
Merge branch 'ejmr/align-method-calls-in-arrays'

* ejmr/align-method-calls-in-arrays:
  Update php-mode-modified
  Align chained method calls inside of arrays
  Use the PEAR indentation style by default for unit tests
  GitHub-Issue: 115 (Unit Test)
Add (require 'speedbar) as functions are used.

Fixes byte-compiler warning of the form:

Warning: the following functions are not known to be
    defined: speedbar-add-supported-extension

Speedbar has been a part of GNU Emacs since version 23.2, so it should
be safe to require.

Signed-off-by: Eric James Michael Ritz <lobbyjones@gmail.com>
Remove eval-when-compile.

Fixes byte-compiler error of the form:

Error: Symbol's value as variable is void: php-extra-constants

Signed-off-by: Eric James Michael Ritz <lobbyjones@gmail.com>
Add (require 'etags) as etag functions are used.

Fixes byte-compiler warnings:

Warning: the following functions are not known to be
    defined: tags-verify-table, etags-tags-completion-table

etags.el is part of GNU Emacs so should be safe to include.

Signed-off-by: Eric James Michael Ritz <lobbyjones@gmail.com>