I have a bar that convets metric to farenheir and the reverse.
It works but there is something wrong. Sometimes the British/Metric button needs to be clicked from then back to the desired system.
Everything seems to work after that. I am hoiping someone knows a way to remove that unnecessary mouse action.
Here is the file:
Thanks for any help.
Cheers.
It is currently October 4th, 2023, 12:58 pm
Weird BEhavior - Or so it seems
-
- Posts: 1270
- Joined: September 7th, 2020, 2:24 pm
- Location: QLD, Australia
Weird BEhavior - Or so it seems
You do not have the required permissions to view the files attached to this post.
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
-
- Rainmeter Sage
- Posts: 15689
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Weird BEhavior - Or so it seems
Sorry, but me at least can't even figure out what the skin should do. If I click the first button (there is written Enter), I can enter a numerical value from the keyboard. When I hit Enter, nothing is done, nothing happens. If I click the second button (Metric or British), the Metric and / or British string switches, but nothing else is changing. Finally, I can click the last button (Output) as well, but such in a case, I get the last string (Output) replaced by a 0 and this is all. Nothing else.
So a description of what should we do or expect to happen would be nice...
So a description of what should we do or expect to happen would be nice...
-
- Posts: 1270
- Joined: September 7th, 2020, 2:24 pm
- Location: QLD, Australia
Re: Weird BEhavior - Or so it seems
Ok everything actually does work, but with bugs. clicking on the box allows you to enter a value for several measurement systems - scrolling the top box allows you to choose which conversion you want. Then click the last button a numeric value equivalent to the conversion the metric or British button is to toggle what you want to convert to.
But sometimes the metric and British button needs to be toggled twice one then back to the original system then finally clicking the last button should reveal your converted measurement.
But sometimes the metric and British button needs to be toggled twice one then back to the original system then finally clicking the last button should reveal your converted measurement.
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
-
- Posts: 1270
- Joined: September 7th, 2020, 2:24 pm
- Location: QLD, Australia
Re: Weird BEhavior - Or so it seems
In hindsight I would have known more details would have helped.
But I seem to found a solution - buy putting magic quotes around the conversions equations.
I think it is necessary when multiple outcomes use the same meter for display.
I chime back in if I find ANY NEW bugs. sry caps.
lika dis:
But I seem to found a solution - buy putting magic quotes around the conversions equations.
I think it is necessary when multiple outcomes use the same meter for display.
I chime back in if I find ANY NEW bugs. sry caps.

lika dis:
Code: Select all
[MeasureOfUnits]
Measure=Calc
Formula=0
IfCondition=(#Mode# = 1) && (#UnitSystem# = 1)
IfTrueAction=[!SetOption MeasureOfUnits Formula """#Var# * 0.914"""][!Update]
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
-
- Posts: 1270
- Joined: September 7th, 2020, 2:24 pm
- Location: QLD, Australia
Re: Weird BEhavior - Or so it seems
looks like the magic quotes dont really work consistently.
If anyone has a solution please post it. Thanks.
If anyone has a solution please post it. Thanks.
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
-
- Rainmeter Sage
- Posts: 15689
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Weird BEhavior - Or so it seems
To be honest I don't see this could help. Doesn't for me (and yep, I saw you posted the same thing in meantime).
However what am I not sure about is what do you mean by "multiple outcomes use the same meter for display". What do you mean?
Yep, I think there is one. Namely in the IfTrueAction6 option of the [MeasureOfUnits] measure. This is what you have used there:
IfTrueAction6=[!SetOption MeasureOfUnits Formula "#*Var*# -32 * .5556"][!Update]. But note that Rainmeter is not happy at all when the integer part of a number is 0 and this is not explicitly specified. So add the not-used zero: IfTrueAction6=[!SetOption MeasureOfUnits Formula "#*Var*# -32 * 0.5556"][!Update]
-
- Posts: 180
- Joined: May 6th, 2021, 2:57 pm
Re: Weird BEhavior - Or so it seems
these changes works for me.
Code: Select all
[MeterInput]
Meter=String
X=55
Y=54
W=98
H=24
FontSize=15
FontColor=#IconTint#
SolidColor=15,15,15
AntiAlias=1
FontFace=Tele-Marines
;-----
Text=#Var#
DynamicVariables=1
;-----
[MeasureInput]
Measure=Plugin
Plugin=InputText
X=55
Y=54
W=98
H=23
FontSize=15
FontColor=#EdgeColor#
SolidColor=15,15,15
FontFace=Tele-Marines
;------
DefaultValue=#Var#
;------
InputNumber=1
AntiAlias=1
InputLimit=6
Command1=[!SetVariable Var "$UserInput$"][!WriteKeyValue Variables Var "[#var]" "#@#_ExtendPrefs.inc"][!Update]
-
- Posts: 1270
- Joined: September 7th, 2020, 2:24 pm
- Location: QLD, Australia
Re: Weird BEhavior - Or so it seems
I mean that for each system the output should reflecr the correct conversion, using the same text meter.
Cool. That was one of the bugs - and I do actually 9or should) know that decimal fractions of 1 cannot have a zero.balala wrote: ↑September 13th, 2022, 7:07 pm Yep, I think there is one. Namely in the IfTrueAction6 option of the [MeasureOfUnits] measure. This is what you have used there:
IfTrueAction6=[!SetOption MeasureOfUnits Formula "#*Var*# -32 * .5556"][!Update]. But note that Rainmeter is not happy at all when the integer part of a number is 0 and this is not explicitly specified. So add the not-used zero: IfTrueAction6=[!SetOption MeasureOfUnits Formula "#*Var*# -32 * 0.5556"][!Update]
I continue to errors sometimes and they are inconsistent. sometimes the value is correct - testing by 1 for each system. This is driving me more crazy than I already am. lol
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.
-
- Rainmeter Sage
- Posts: 15689
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Weird BEhavior - Or so it seems
Could you please trying to described when exactly the errors are occurring? Because I can't find any (however didn't test extremely deeply). I mean you should describe which conversion do you choose, what do you enter and so on.
-
- Posts: 1270
- Joined: September 7th, 2020, 2:24 pm
- Location: QLD, Australia
Re: Weird BEhavior - Or so it seems
Funny you should ask, I was just going to post this part of theconverter:
Code: Select all
IfCondition5=(#Mode# = 1) && (#UnitSystem# = 3)
IfTrueAction5=[!SetOption MeasureOfUnits Formula "((#Var# * 1.8) + 32)"][!Update]
IfCondition6=(#Mode# = 0) && (#UnitSystem# = 3)
IfTrueAction6=[!SetOption MeasureOfUnits Formula "((#Var# -32) / 1.8)"][!Update]
I dont want to jinx it, but other than that, everything seems to be working as hoped.
thanks guys for helping out.
ƈǟռ'ȶ ʄɨӼ ɨȶ ɨʄ ɨȶ ǟɨռ'ȶ ɮʀօӄɛ - ʊռʟɛֆֆ ɨȶ ɨֆ ɨռ ƈօɖɛ.