dbriemann
2020-6-20 12:43:31

Can the scrollbar on a list-box% be hidden if there is nothing to scroll?


dbriemann
2020-6-20 14:17:43

Or even more important.. can a message% receive events like a mouse click?


samth
2020-6-20 14:23:13

@dbriemann I think there’s not auto-hiding but you can turn them on and off when the size changes


dbriemann
2020-6-20 14:28:41

I realized that I have to create my own list here anyways. What I want are items that look similar to this


dbriemann
2020-6-20 14:30:07

I managed to do the layout for this item now by using a mix of horizontal-containers, vertical-containers and messages. Now I need to figure out how to listen for clicks on these components.


mflatt
2020-6-20 14:32:55

You may be able to detect clicks via on-subbwindow-event, but I forget the detail or how much variation there is across platforms.


mflatt
2020-6-20 14:34:18

There’s also mrlib/hierlist, which has an 'auto-vscroll style. It works in the snip world, so probably better for cases where you want to customize the way items behave.


dbriemann
2020-6-20 17:02:20

Am I correct that I cannot register callbacks for events on message%s? Do I have to derive a class from message% and override the callback functions? Also is there a way to change e.g. the background color of a panel% or message%


mflatt
2020-6-20 17:09:31

That right - you’d have to derive a class and override. There is no way to change the background color (because GUI toolkits don’t uniformly provide that option). When you want that level of control, a canvas or editor canvas is the way to go, and that’s how hierlist works.


dbriemann
2020-6-20 17:55:21

ok thanks for all the information. have to think about that now and try things :slightly_smiling_face: