So, I’m not quite certain if this is Csound in origin, or if this is unique to Cabbage, but I have never seen any function call like…
colour:0("red")
Not that I am an expert in language syntax, but I have never seen anything like the “:” used with a function name. And yes, I know they are called “identifiers”, but when they execute, they are functions… (Just an opinion. It may very well be a concept that I just have to accept, but I’ve never seen anything like this, so this is me trying to understand…)
Nothing to do with Csound at all. And perhaps not the finest syntactical decision I ever made! At the time I thought fontcolour:0() and colour:1() were simpler than fontcolouron() and colouroff().
I might overhaul this at some point. With camel case fontColourOn()/colourOn() isn’t so bad.
They are not really functions at all. They are just a construct for the parser. Deep within the Cabbage code base are they actual setColour() functions, or setText(), etc.
Yeah, I’m starting to think the same. And it would make life a lot easier in terms of parsing because I don’t have to think about the :1, :0. If I did this I think I would go all in, which would result in a breaking change - if you tried to compile older .csd files with the new version. Your plugins would of course still function the exact same, as they shipped with the older version…
Oh yeah, I’m currently upgrading Cabbage to use JUCE 6, I think the writing is on the wall for the CabbageLite, but I will pour more time into the standalone builds before I pull the trigger!