Formatting - Blocks of Assignments

As an offshoot to this discussion and this issue, I am exploring using the auto-formatting again. One reason I just won't use it, is how it (doesn't) line up assignments (=), like so....

Here is how I want this code to look:

  Input2::$sName         = "cboInterviewType";
  Input2::$sValue         = $cboInterviewType;
  Input2::$aOptions      = array("6M", "1Y");
  Input2::$bKeyIsVal    = true;
  Input2::$sOnChange  = "StoreValueInSessionJS(this.value, 'cboInterviewType');";
  Input2::Store(' Interview Type: ');

Those are tabs, FYI, but PHPStorm does this to it:

  Input2::$sName = "txtFromDate";
  Input2::$bCalendar = true;
  Input2::$sValue = Format::Date($txtFromDate, false);
  Input2::$sClass = "small";
  Input2::Store(" From (Date): ");

Is there no way to fix this (or at least have it not re-format it)?


this style is already implemented for 3.0. No way it will be included in 2.1.x though.


Oops, sorry, I just submitted the ticket. Can you mark it duplicate? I'll track the ticket that has this already requested.


Please sign in to leave a comment.