Is it possible to change the default OP size?

I’d like to have CHOPs smaller by default, as I use them a lot and things can get busy.
I know I can make containers but when working with reactivity I like to overview moving parameters fast.

Any solution?

That is not currently available as a setting

I see, thanks for the clarification.
I’ve seen automation of OPs position and size. Could it be scripted as a function affecting all CHOPs on the same container?
Any chance it could be added to the roadmap?

You can script it with op(“yourNode”).nodeHeight and nodeWidth

Smth like

for n in op("someContainer").children:
    n.nodeHeight == 100
1 Like

To determine if it’s a CHOP you can use

if n.isCHOP:

You can also automate this check and size change using OP Execute DAT’s onNumChildrenChange callback.

So, yeah you can kind of roll your own version of this feature!

1 Like

Thanks @Achim, @Ivan!
Script and Execute DATs are way out of my confort zone. Let’s see where ChatGPT can take me.

So far so good. I realized too late I can skip the script DAT entirely and run it on the execute. Works great! I now want to make it a custom container with params to set height and width but that may be too much already, no idea how to recall an UI parameter value inside the script.

Additionally it only works on the first monitored OP even if I add several ones to monitor (also adjusting the script to affect those). I’d like it to be global, even for newly created containers. ChatGPT hinted some ways, but since monitoring several OPs doesn’t work as expected I’ll stick with what I have.

Here’s the thing

df

def onNumChildrenChange(changeOp):
    container = op('/project1')  # Replace with your actual container path
    exclude = ['select','1']  # list of characters contained on the OPs name to be excluded
    
    if container:
        for n in container.children:
            if all(excluded_name not in n.name for excluded_name in exclude) and all(excluded not in n.name for excluded in exclude):
                if n.isCHOP:
                    n.nodeWidth = 60 
                    n.nodeHeight = 40

    return

Edited to add exceptions to the resizing depending on the OP name.