Fix for browsers not understanding some commands

I found that IE9 does not handle commands with parameters such as "fontSize 3".

This fix strips off parameters if they are present and additionally does a check to make sure the browser supports the command before trying to query the state of the command.

This is similar to other fixes in the issue queue (most are fixes for specific commands), but this is more generic.