equal
deleted
inserted
replaced
739 len(section['lines'][1].lstrip(' ')) |
739 len(section['lines'][1].lstrip(' ')) |
740 if bindent >= sindent: |
740 if bindent >= sindent: |
741 break |
741 break |
742 pointer += 1 |
742 pointer += 1 |
743 if pointer > 1: |
743 if pointer > 1: |
744 secs.append(('', secs[-pointer][1] + 1, [])) |
744 blevel = secs[-pointer][1] |
|
745 if section['type'] != b['type']: |
|
746 blevel += 1 |
|
747 secs.append(('', blevel, [])) |
745 secs[-1][2].append(b) |
748 secs[-1][2].append(b) |
746 return secs |
749 return secs |
747 |
750 |
748 def decorateblocks(blocks, width): |
751 def decorateblocks(blocks, width): |
749 '''generate a list of (section name, line text) pairs for search''' |
752 '''generate a list of (section name, line text) pairs for search''' |