-
April 11th, 2018, 14:40 #11
-
April 11th, 2018, 15:36 #12
<windowcontrol>.setFrame
https://www.fantasygrounds.com/refdo...l.xcp#setFramePrivate Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!
-
April 11th, 2018, 15:39 #13
A couple of entries above that one is one I hadnt seen before...
setBackColor
function setBackColor( color )
Set the color to be used to fill the background of the control before drawing the contents. If no backcolor specified (i.e. nil), then no fill will be done (i.e. transparent).
Parameters
color (string)
The color specified as a HTML compatible string representing an RGB color with an alpha (transparency) value. The format of the string is 'aarrggbb', and each component is presented as a hexadecimal value from 00 to FF. If alpha is zero or not defined, FF is assumed.
-
April 11th, 2018, 15:48 #14Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!
-
April 11th, 2018, 16:05 #15
Thanks guys I will play with it and see what happens.
Discord User : Samarex#0318
Ultimate License
Starfinder Society ID#:274538
Lets Play a RPG
-
April 12th, 2018, 13:33 #16
It works great.
Just put in a handler to watch skill ranks. When on changes it does the check and changes the backgound back an forth.
Thanks alot
Code:local sLabel = w.label.getValue(); local rSkill = DataCommon.skilldata[sLabel]; local bTrainedOnly = (rSkill and rSkill.trainedonly); local nRanks = w.ranks.getValue(); if nRanks ~= 0 then --w.total.setColor(nil); w.total.setBackColor(nil); end if bTrainedOnly and nRanks == 0 then --w.total.setColor("BB0000"); w.total.setBackColor("BB0000"); end
Last edited by Samarex; April 12th, 2018 at 13:35.
Discord User : Samarex#0318
Ultimate License
Starfinder Society ID#:274538
Lets Play a RPG
-
April 12th, 2018, 13:46 #17Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!
-
April 15th, 2018, 15:35 #18
Archangel
- Join Date
- Apr 2008
- Location
- Virginia Beach
- Posts
- 3,096
Samarex, what did you do about the frame? Did this override that as well?
-
April 15th, 2018, 15:41 #19Discord User : Samarex#0318
Ultimate License
Starfinder Society ID#:274538
Lets Play a RPG
-
April 15th, 2018, 16:28 #20
Here is the Function
w.total.setBackColor(nil);
total being the Total field control on the skills tab.
Code:function update() local bEditMode = (window.skills_iedit.getValue() == 1); window.idelete_header.setVisible(bEditMode); for _,w in ipairs(getWindows()) do local bAllowDelete = w.isCustom(); if not bAllowDelete then local sLabel = w.label.getValue(); local rSkill = DataCommon.skilldata[sLabel]; if rSkill and rSkill.sublabeling then bAllowDelete = true; end end if bAllowDelete then w.idelete_spacer.setVisible(false); w.idelete.setVisibility(bEditMode); else w.idelete_spacer.setVisible(bEditMode); w.idelete.setVisibility(false); end local sLabel = w.label.getValue(); local rSkill = DataCommon.skilldata[sLabel]; local bTrainedOnly = (rSkill and rSkill.trainedonly); local nRanks = w.ranks.getValue(); if nRanks ~= 0 then --w.total.setColor(nil); w.total.setBackColor(nil); end if bTrainedOnly and nRanks == 0 then --w.total.setColor("BB0000"); w.total.setBackColor("ffcccc"); end end end
Discord User : Samarex#0318
Ultimate License
Starfinder Society ID#:274538
Lets Play a RPG
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks