9

Can I correct the indention of selected code (not my whole page) with BBEdit?

So if I had this:

<div><div><div>
<div><div><div><div>
</div>
</div></div></div></div></div></div> 

It colud become this:

<div>
  <div>
    <div>
      <div>
       <div>
        <div>
        </div>
      </div>
    </div>
  </div>
</div>

Evanss
  • 1,358

1 Answers1

12

I know the question is older but wanted to let it be known that this is indeed possible.

It is easy to indent just a selection of markup.

  1. Select the text
  2. Go to Menu item Markup > Utilities > Format
  3. Check the "Selection Only" option

The keyboard shortcut for the command is Cmd + Shft + Opt + F.

Phoenix
  • 834
ryentzer
  • 146