title: Eclipse formatter alternates format each time (and won't split a line)
body: <p>Eclipse is formatting code one way and then another, flipping particular bits of code backwards and forwards alternately each time it's used.</p>
  
  <p>What have I done wrong here? </p>
  
  <p>Here is the first state:</p>
  
  <pre><code>public static void main(final String[] args) {
      String dir = System.getenv(EtlConstants.ENVVAR_PROPERTIES_DIR);
      if (dir != null
          &amp;&amp; ("\\".equals(dir.charAt(dir.length() - 2)) || "/".equals(dir.charAt(dir.length() - 2)))) {
          dir = dir.substring(0, dir.length() - 1);
      }
  }
  </code></pre>
  
  <p>and this alternates with this:</p>
  
  <pre><code>public static void main(final String[] args) {
      String dir = System.getenv(EtlConstants.ENVVAR_PROPERTIES_DIR);
      if (dir != null
              &amp;&amp; ("\\".equals(dir.charAt(dir.length() - 2)) || "/".equals(dir.charAt(dir.length() - 2)))) {
          dir = dir.substring(0, dir.length() - 1);
      }
  }
  </code></pre>
  
  <p>The difference is the tab in the second line of the if statement.</p>
  
  <p>I am trying to get the formatter to wrap the same line at the <code>||</code> as well but I can't work out why it's flipping between these two states. It's obviously the interaction of two separate rules, but which?</p>
  
  <p>EDIT: This is with Eclipse Luna 4.4.0. </p>
  
  <p>EDIT 2: I am using <kbd>CTRL</kbd>+<kbd>s</kbd> because I have set Eclipse to do a format on save. It is obviously one of the other Save actions that is causing the format to change: </p>
  
  <ul>
  <li>format all lines</li>
  <li>organise imports</li>
  <li>convert control statement bodies to block</li>
  <li>add final modifier to private fields</li>
  <li>add final modifier to method parameters</li>
  <li>add missing '@Override' annotations</li>
  <li>add missing '@Override' annotations to implementations of interface methods</li>
  <li>add missing '@Deprecated' annotations</li>
  <li>remove unnecessary casts</li>
  <li>remove trailing white spaces on all lines</li>
  <li>correct indentation</li>
  </ul>
  
  <p>EDIT 3: I just removed the last Save action and it no longer causes that line to jump backwards and forwards. </p>
  
  <p>So thanks to all you people invoking the formatter with <kbd>CTRL</kbd>+<kbd>SHIFT</kbd>+<kbd>f</kbd> - that switched a light on because I realised I was using <kbd>CTRL</kbd>+<kbd>s</kbd> all the time. </p>