iterate.chained_contents — Abjad v1.1.1 documentation

### Navigation

- index
- modules |
- next |
- previous |
- Project Abjad »
- Abjad v1.1.1 documentation »
- Abjad API »

# iterate.chained_contents

`abjad.tools.iterate.` `chained_contents`(expr)

  Yield the left-to-right, top-level contents of expr with chain-wrapped leaves.

      t = Staff(construct.notes(0, [(5, 32)] * 4))
      t.insert(4, FixedDurationTuplet((2, 8), construct.run(3)))
      pitchtools.diatonicize(t)
      abjad> print t.format
      \new Staff {
         c'8 ~
         c'32
         \times 2/3 {
            d'8
            e'8
            f'8
         }
         g'8 ~
         g'32
         a'8 ~
         a'32
         b'8 ~
         b'32
      }

      abjad> for x in iterate.chained_contents(t):
      ...     x
      ...
      (Note(c', 8), Note(c', 32))
      (Note(d', 8), Note(d', 32))
      FixedDurationTuplet(1/4, [e'8, f'8, g'8])
      (Note(a', 8), Note(a', 32))
      (Note(b', 8), Note(b', 32))

  Crossing ties raise `TieChainError`.

### Navigation

- index
- modules |
- next |
- previous |
- Project Abjad »
- Abjad v1.1.1 documentation »
- Abjad API »