OOLOI.ORG
Menu

OOLOI

OVERVIEW

FAQ

DOCUMENTATION

NEWSLETTER

The First Bar of the System

18/10/2026

2 Comments

 
An accidental, a grace note, a clef change and a repeat barline walk into a bar. It’s the first bar of a system, so it’s already crowded.

The clef change says, ‘Don’t worry, I sent word ahead’, and points to the courtesy clef waiting at the end of the previous system.

The repeat barline says, ‘I’ve been here before’.

The grace note says, ‘I can’t stay long’.

The accidental just nods at the notehead and says, ‘I’m with him’.

Most bartenders sigh and reach for the special-case drawer. Ooloi’s hands each of them a spring (‘boinggg’) and goes back to polishing glasses.
Picture
​A postscript, since the joke is less of one than it looks.

I’ve dreaded this part for two years. Casting off and spacing are where the Minotaur lives: the centre of the labyrinth, where the model finally has to become a page. I assumed I’d have to go in and wrestle it, and I spent the pipeline years arming myself.

I knew what the fight would look like. In a conventional architecture, each kind of object that needs room at a system start has a formatter of its own: one for accidentals, one for grace notes, one for clefs, one for barlines. Each is reasonable in isolation. The trouble is that they’re independent, so they needs must negotiate. The accidental takes its room, the grace note needs some of it back, the courtesy clef changes what’s left over, and every pair that meets needs an agreement. Too many of those agreements end up as correction passes, and correction passes are the bane of notation programs, and their elephant graveyard: it’s where Finale finally went, after more than three decades. The agreements grow with the combinations, not with the objects. It isn’t one hard problem; it’s herding cats, each one patched where it was caught, until adding one more kind of object costs more than the program can bear.

Instead the Minotaur stretched out a hand: ‘Pleased to meet you, Peter. Let’s get to work, shall we?’

There were no cats to herd. There was only one Master Ring, if I may mix my metaphors further. Information in Ooloi’s pipeline flows one way, and every horizontal rule has to take one of four forms before breaking begins. By the time the accidental, the grace note, the clef and the barline reach the breaker, they’re all springs, combined the same way every time. The problem I met wasn’t the one I’d prepared for. I’d expected a fight with chaos. What I got was a choice between two pieces of mathematics, and the only question was which one was right. The chaos had been dealt with upstream, years earlier, without my quite realising that this was what I was doing.

I’m increasingly convinced this is also why Hegazy and Gourlay’s method hasn't been used in interactive programs. The usual explanation is that optimal breaking is too slow to recompute after every edit. It isn’t. It hasn’t been for decades. What it needs is width data that’s settled before breaking begins and stays put while the breaker works. An army of negotiating formatters can’t supply that, because in such an architecture widths are what layout produces, not what it starts from. Speed was never the obstacle; the cats were.
​
​The single model also makes the rest of the formatting much, much more straightforward to implement. Every rule that remains has one thing to become and one place to go, and none of them has to know about the others. Foundation work succeeds by disappearing, and this is what it looks like when it does: you walk into the room where the monster is supposed to be, and find a bartender polishing glasses.
2 Comments
Roland Gurt
18/10/2026 19:26:14

Congratulations on yet another productive and intriguing series of posts!

You write in the last post about the purity of the spacing system.

I would view the totality of music engraving as a quite messy system with at least as many exceptions as there are rules; also a very human and organic system. (Not without reason does one speak of the "warmth" of a page when talking about a traditional engraving – as opposed to a coldly perceived digital layout.)

If the software is pure and "immovable", I can completely rely on the aspects of work that it claims to perform, for example: laying out the music in a relatively optimal way and being absolutely reliable and predictable about that, as well as preventing any bad collisions (not counting, of course, the slight overlapping of items commonly found in expert engravings, going even as far as putting dynamics inside the stave for dense scores which optimize for the greater good of a compact engraving with consistent blackness.)

If the software can prevent everything that would be absolutely prohibited in a professional score, like a wildly uneven black-white-balance or the mentioned types of collisions, I can have a much greater peace of mind and focus on my work.

I don't know if any engraving software has yet achieved this ideal of "simply" laying out every element on the page in a correct way (except perhaps for Lilypond). Even Dorico has some classes of items that still cannot be handled in a proper way, for example, combinations of octave lines with other markings such as harmonics.

A completely immovable page architecture that never unexpectedly jumps and transforms would then be a first in real-time interactive scoring applications. (And don't even get me started on the viewport jumping and twitching that is going on in Dorico.)

Cheers and here's to further inspiring work!

Reply
Peter Bengtson
19/10/2026 07:03:40

Roland, thank you. It’s a real pleasure to hear from you, and on exactly the questions that matter.

You’re right that engraving is messy, human and organic, and I’d be the last to pretend otherwise. The purity isn’t meant to abolish the mess. It’s meant to put it in the right place. Here, though, I need to separate two kinds of stability, because they pull in different directions.

The first is determinism: the same score always produces the same page, with no hidden state and no correction passes that behave differently depending on what happened before. That the architecture guarantees.

The second is calm under editing: the page not rearranging itself when you touch it. Here optimal breaking is, paradoxically, less stable than the greedy kind. Hegazy and Gourlay optimise the whole flow at once, so a change in bar 40 can legitimately move a break back in bar 12 if the result is better overall. The page is never wrong, but it isn’t inert. That has to be handled with care, and in the right places. The interface should make rebreaks legible rather than startling, and keep the viewport anchored to what you’re working on. You should be able to lock breaks you’ve settled on. Locked breaks work precisely because they’re part of the score: explicit decisions you’ve made, not hidden memory in the breaker. The breaker itself must never remember its previous answer. Same score, same page, always.

On black/white balance, I think we’re in complete agreement, and the mathematics is on our side. Minimising spacing deviation across every system at once is, in effect, a balance optimiser in the horizontal dimension. It’s what prevents one loose system turning up after three tight ones. A calm page is the intention.

Horizontally there is also one absolute guarantee: no collisions, ever. That isn’t a rule anyone has to remember to enforce. It follows from the model.

Vertically it’s a different world, and rightly so. Your own examples prove it. The slight overlaps, dynamics tucked inside the staff in a dense score, harmonics negotiating with octave lines: these are deliberate transgressions that good engravers commit for the greater good of the page. So the vertical stage can’t simply forbid contact. It needs a model of permitted intrusion, of working with negative space. I have a research paper on the techniques Ooloi can use there, and it will eventually become an ADR. That is where the organic part lives, and the reason I can afford to let it be organic is that everything upstream of it is settled.

Purity upstream, so that we can afford to be messy downstream, and messy on purpose.

Here’s to more of these conversations.

Peter

Reply



Leave a Reply.

    Author

    Peter Bengtson –
    Cloud architect, Clojure advocate, concert organist, opera composer. Craft over commodity. Still windsurfing through parentheses.

    Search

    Archives

    November 2026
    October 2026
    September 2026
    August 2026
    July 2026
    June 2026
    May 2026
    April 2026
    March 2026
    February 2026
    January 2026
    December 2025
    November 2025
    October 2025
    September 2025
    August 2025
    July 2025
    June 2025
    April 2025
    March 2025
    September 2024
    August 2024
    July 2024

    Categories

    All
    Accidentals
    Alfred Korzybski
    Architecture
    Backend
    Beaming
    Benchmarks
    Casting Off
    Clefs
    Clojure
    CLOS
    Common Lisp
    DDD
    Death Of Igor Engraver
    Documentation
    Donald E Knuth
    Dorico
    Dynamic Programming
    Finale
    Fonts
    FrankenScore
    Franz Kafka
    Frontend
    Functional Programming
    Generative AI
    GRPC
    Hegazy Gourlay
    Hegazy-Gourlay
    Igor Engraver
    Ingmar Bergman
    Instruments
    Jacques Derrida
    JVM
    Knuth Plass
    Knuth-Plass
    License
    LilyPond
    Lisp
    Localisation
    MIDI
    MPL 2.0
    MuseScore
    MusicXML
    Ooloi
    Ortography
    Pitches
    Platforms
    Playback
    Plugins
    Python
    QuickDraw GX
    Rendering
    Rhythm
    Rich Hickey
    Road Map
    Scheme
    Semiotics
    Sibelius
    Silicon Valley
    Site
    Skia
    Sponsorship
    Testing
    Transposition
    UI
    Umberto Eco
    Vertigo
    VST/AU
    Wednesday Addams

    RSS Feed

Home
​Overview
Documentation
About
Contact
Newsletter
Ooloi is an open-source desktop music notation system for musicians who need stable, precise engraving and the freedom to notate complex music without workarounds. Scores and parts are handled consistently, remain responsive at scale, and support collaborative work without semantic compromise. They are not tied to proprietary formats or licensing.
​
Ooloi is currently under development. No release date has been announced.


  • Home
  • Overview
    • Background and History
    • Project Goals
    • Introduction for Musicians
    • Introduction for Programmers
    • Technical Comparison
  • FAQ
  • Documentation
  • About
  • Contact
  • Workbench
  • Home
  • Overview
    • Background and History
    • Project Goals
    • Introduction for Musicians
    • Introduction for Programmers
    • Technical Comparison
  • FAQ
  • Documentation
  • About
  • Contact
  • Workbench