It is currently September 30th, 2024, 1:29 am
General topics related to Rainmeter.
LeftSide
Posts: 35 Joined: July 3rd, 2012, 6:16 pm
Post
by LeftSide » August 25th, 2012, 5:07 am
Code: Select all
[Variables]
PrimaryColorCpu1=0,0,0,0
PrimaryColorCpu1_Low=0,0,0,0
PrimaryColorCpu1_High=0,0,0,255
[MeasureCPUFast]
Measure=CPU
IfAboveValue=75
IfAboveAction=!RainmeterSetVariable PrimaryColorCpu1 PrimaryColorCpu1_High
IfBelowValue=75
fBelowAction=!RainmeterSetVariable PrimaryColorCpu1 PrimaryColorCpu1_Low
[CPUGraphFast]
Meter=HISTOGRAM
MeasureName=MeasureCPUFast
PrimaryColor=#PrimaryColorCpu1#
This doesn't work... the color of the graph doesn't change. But it works with a string.
Kaelri
Developer
Posts: 1721 Joined: July 25th, 2009, 4:47 am
Post
by Kaelri » August 25th, 2012, 5:17 am
You need to set
DynamicVariables=1 on [CPUGraphFast] to make it react when the variable changes.
Alternatively, if this is the only meter that is affected, you could use the
!SetOption bang to change the PrimaryColor option directly. This does
not require dynamic variables.
Code: Select all
[MeasureCPUFast]
Measure=CPU
IfAboveValue=75
IfAboveAction=!SetOption CPUGraphFast PrimaryColor "0,0,0,255"
IfBelowValue=75
fBelowAction=!SetOption CPUGraphFast PrimaryColor "0,0,0,0"
[CPUGraphFast]
Meter=HISTOGRAM
MeasureName=MeasureCPUFast
See more about:
-
Bangs
-
Dynamic Variables