Color Type and visibility

Christie Widget Designer Version 6 - Q&A

Moderator: Moderator Group

Forum rules
When asking make sure to include the operating system and the revision of Widget Designer you are using.

Color Type and visibility

Postby maccalder » Mon Jan 09, 2017 10:49 pm

Hi All

Got a couple of questions. .FillColor - if I am trying to assign a new fill color to an item, how does it expect the RGB value to be represented? If I set it to automatically apply changes in the properties panel and change the value, I can see the original value represented as 'rrr, ggg, bbb' which I tried - I also tried "0,255,0", "#00FF00", "00FF00" to no avail - I also tried dumping an existing fill color to a variable but got type-mismatch errors.

Also .Visible - toggling between 0 and 1 works fine on shapes, but does not seem to work on custom script buttons, drop down boxes, XY boxes etc? DOes not seem to work toggling it in the properties window either.

Regards

-Mac

PC: Xeon E3-1225 @ 3.3GHz, 8gb RAM, Windows 10 Enterprise LTSB, WD6 4242-RC
WD PC: Xeon E3-1225 @ 3.3GHz, 8gb RAM, Windows 10 Enterprise LTSB, WD6 Unlimited 4242-RC
PB PC: Xeon E3-1220 @ 3.5GHz, 8gb RAM,Gigabyte GeForce GTX 1050 Ti OC 4G, Windows 10 Enterprise LTSB
maccalder
 
Posts: 13
Joined: Wed Nov 04, 2009 10:22 am
Location: Melbourne, Australia

Re: Color Type and visibility

Postby Janina Baltaziewicz » Thu Feb 09, 2017 1:48 pm

Hi,

Sorry for the late reply.

Boolean data types require the value "true" or "false", 0 and 1 are not supposed to work properly here and also didn't work when I tested the ".Visible" member for some widgets, Shape included.
I also can't reproduce the issue with the check box in the item properties dialog, they all seem to work well despite the widget used.


There also is an new data type, called "Color", it has its own structure like a string or a double.
It is not yet fully implemented in revision 4242 but will be in the next release candidate. You will then also be able to create color-type global variables, editable via hex code.
There are several object properties that already use this data type, like .FillColor, .ForeColor, .LineColor, etc.
So if you want to have a look at this feature, try e.g. a ColorPicker and use the ColorPicker1.SelectedColor for a color value:

Shape1.FillColor = ColorPicker1.SelectedColor


Lokal variables also already support this type:

var x = ColorPicker1.SelectedColor
Shape1.FillColor = x


You can also use additional color members:
Shape1.FillColor.SetRGB(128,0,255)


Also (just one more), will the string members be updated in future, so that you can use something like this:
Shape1.FillColor = "#00FF00".ToColor
Janina Baltaziewicz
Customer Service Engineer
User avatar
Janina Baltaziewicz
 
Posts: 53
Joined: Tue Jun 14, 2016 2:08 pm


Return to Widget Designer V6

Who is online

Users browsing this forum: No registered users and 13 guests