Jump to content
Sign in to follow this  
chronicsilence

Setting listbox item background

Recommended Posts

If you create a listbox control (type 5), it looks something like this right:

 

WuChaoRen_ctListBox.png

 

I'm looking for a way to set it so that the list items have backgrounds. Note, I'm not trying to set a background color for the entire control like you could do with the colorBackground attribute, but just for each list item. So it would look something like this, from the inventory screen (which uses listbox controls):

 

5noi7SA.png

 

Any ideas how to do this? I've been reading through the DialogControls-ListBoxes page and I can't see a way to do it, but it looks like it must be possible.

Share this post


Link to post
Share on other sites

In the configs, the default inventory ListBox uses the itemBackground[] and itemSpacing properties. However, when the ListBox is populated with the lbAdd command, it doesn't utilise those properties. This leads me to believe that Bohemia do not use a publicly available command to create their inventory menu.

  • Like 1

Share this post


Link to post
Share on other sites

I don't think this is possible using RscListBox. You can create your own custom UI using RscControlsGroup though and add a scrollbar.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×