BarNumberInterface — Abjad v1.1.1 documentation

### Navigation

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

# BarNumberInterface

class `abjad.barnumber.interface.` `BarNumberInterface`(_client)

  Bases: `abjad.core.interface._Interface`, `abjad.core.grobhandler._GrobHandler`, `abjad.core.settinghandler._ContextSettingHandler`

  Manage bar number attributes.

  - Handle LilyPond `BarNumber` grob.
  - Manage LilyPond `currentBarNumber` context setting.

      abjad> t = RigidMeasure((2, 8), construct.scale(2))
      abjad> t.barnumber
      <BarNumberInterface>

  `current`

    Read / write LilyPond `currentBarNumber` context setting.

    - Default value: `None`.
    - All values: integer, `None`.

        abjad> t = RigidMeasure((2, 8), construct.scale(2))
        abjad> t[0]
        abjad> t[0].barnumber.current = 22
        abjad> t[0].barnumber.current
        22

  `promote`(setting, context)
    Promote `setting` to LilyPond `context`.
  `settings`

    Read-only list of LilyPond context settings picked up at format-time.

    - Derived from `BarNumberInterface.current`.

        abjad> t = RigidMeasure((2, 8), construct.scale(2))
        abjad> t[0]
        abjad> t[0].barnumber.current = 22
        abjad> print t.format
                \time 2/8
                \set currentBarNumber = #22
                c'8
                d'8

### Navigation

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