I am trying to find a way to change the look of my GUI...I noticed the standard background color of GUIs in JMP is GREY which is quite monocromatic...
How can I change
Curious to see how this can be done :)
This might get you started:
NamesDefaultToHere(1); nw = NewWindow("W", vlb = VListBox( bb = ButtonBox("Press Me"), sb = SpacerBox(Size(10, 100)) ); ); Wait(2); vlb << backgroundColor("Blue"); Wait(2); bb << backgroundColor("Red"); Wait(2); bb << setIcon("$SAMPLE_IMAGES/pi.gif"); bb << setIconLocation("Left");
You need to look in 'Help > Scripting Index' to see the different display boxes and the messages they respond to (but if you have written a GUI you will be somewhat familiar with this anyway). For images, search for 'PictureBox()'.
The << Background Color() message does not have an effect on the button box.
The only way that I see that you could color the background of a Button Box() is to create and image of the color background, and overlayed text, and then to specify it to the Button Box() as what to display. Below is a script using a builtin Icon, but the Set Icon() message can also point to an imate
Names Default To Here( 1 ); New Window( "Example", ex = Button Box( "" ) ); ex << Set Icon( "Go" );
Regarding the buttons, you can use Jim's approach:
Names Default To Here( 1 ); New Window( "Example", ex = Button Box( "", Beep() ) ); ex << Set Icon( "$DESKTOP/Screen Shot 2017-11-21 at 15.27.12.png" );
where I made the .png file by tacking a screenshot from a drawing package. This gives:
What I get by running the code is (I also placed a .png picture where it should be):
I am using JMP11. Could this be the problem ?