Non-desctructive Scrollable interface in blender. [50$ reward]

Hello.

I’m offering 50$ for the one who can propose me a solution for my problem.

Problem example:

... ui code ...
box= layout.box()
for i in range(999) :
    box.label(text=str(i))

let say that i want my 99 lines of label inside of this box to be scrollable what am i supposed to do ?

The solution need to be non-destructive so that cases like the second example below can be resolved with the same kind of proceduralism within the code.

Problem example:

...ui code...
A = bpy.context.object
box= layout.box()
for m in A.modifiers:
    if m.type == 'DISPLACE':
         box.label(text=m.name)

in this example, it’s much more complex, as the assets present in the future scrollable list are constantly changing, either when the user add a modifier, remove one, or change the selection.

So in the case above using an UI list will be totally destructive to use because , as i understood, ui lists need Group Properties and Collection Properties, and those will need be constantly updated. needing handlers and timers for automatically updating the list every god dmn time.

imo this is a really bad solution, blender is forcing us to do an extra step which is this annoying Collection properties.

So here’s my question:
How to create a Non-desctructive Scrollable interface in blender

related :
https://blender.stackexchange.com/questions/158213/scrollable-interface

What kind of stuff do you need to put in your list??
Because your example with 1000 labels is not very illustrative. Also, layout.box() is for defining layouts, not functionality.

I think UILists is your best option… Even if you exagerate a bit about “updating the list every god dmn time”, which is not really the case; unless you’re using a very strange and mutable collection.

Some kind of screenshot would be helpful to see what you are trying to achieve with this.

As far as I understand there is nothing wrong with constantly updating a ui list, the whole ui system constantly updates anyway as long as the user interacts with it.