PxPlus User Forum

Twitter Twitter Twitter

Author Topic: Themes and Panel Background Colours/Colors  (Read 956 times)

bbssupport

  • Silver Member
  • ***
  • Posts: 34
    • View Profile
Themes and Panel Background Colours/Colors
« on: November 22, 2020, 11:12:03 PM »
Hi All,

I'm stuggling to implement themes and visual classes in my application in the effort to improve the look and feel of our applications. We are using v16 of PxPlus, NOMADS for all panels (except the odd old CBI screen we still have) and have previously simply defined a Black-on-Light Grey colour scheme in the library defaults for each of our libraries and then just adjusted the colour, size, font etc on individual controls as needed.

The first thing I need to be able to achieeve is to set the panel background colours from a startup program so I can control which systems have which background colour. I've tried setting the library defaults to Default-on-Default and then setting the %NOMAD_Pnl_Def_Colour$="RGB: 217,235,247" variable but it doesn't seem to work. I have had some success with PRINT '_COLOUR'("LIGHT GREEN"),'DF', however that causes my character based panels to also turn light green. Trying to control and change the '_COLOUR' option between the CBI and GUI panels is very difficult as CBI screens (which are 'BLUE' by default) often open up GUI screens (which need to vary in colour depending on our needs).

I have attempted to start using themes and visual classes to accomplish this as well, however there doesn't appear to be an option in either to set the panel background colour ONLY. I can set the default background colour....but then list boxes, multi_lines etc all change as well. If i then start defining themes for each control type, i then have to create 100 different visual classes to accomidate all the minor colour/font size changes that appear on multi_lines and list_boses on panels throughout our system.

So in short, how do I set the global panel background colour for all our nomads panels without affecting other controls? Is the only way to set them in the library defaults and then have no runtime control over the colour?

bbssupport

  • Silver Member
  • ***
  • Posts: 34
    • View Profile
Re: Themes and Panel Background Colours/Colors
« Reply #1 on: November 22, 2020, 11:59:22 PM »
I found the solution! I'll note it for anyone else that may stumble across this thread, but would also still like to know if this can be accomplished using Themes.

I found that if I issue a PRINT 'OPTION'("Colour16","RGB: 217,235,247"), in my start up program (where i can define it to be any colour), and then add 'Colour16' as an expression for the user defined background colour in the library defaults, it works perfectly.