Hi, I am new to Rainmeter. I am making a skin for my personal use and I don't know how to deal with the following problem.
I have three variables, first one is named 'size', which changes dynamically by scrolling the mouse. I want to change the second (name: W) and third (name: Gap) variables with an if condition depending on the first variable. Changes should be done by following values:
Asper the image If 'size' is 5.5, 'W' should be 6 and 'Gap' should be 5 and if 'size' is 2, 'W' should be 2 and 'Gap' should be 2.
Please help with how to change the second and third variables if the first one changes.
Thanks in advance.
You do not have the required permissions to view the files attached to this post.
You might want to read the manual. To answer your questions, you'll want to read about IfConditions and the !SetVariable bang.
You'll need to use these in conjunction with some measure that will react to whatever you are doing. The IfCondition docs have an example that uses !SetOption bangs, so you would do something similar using !SetVariable bangs instead.
Tezz95 wrote: ↑April 19th, 2023, 2:37 pm
I want to change the second (name: W) and third (name: Gap) variables with an if condition depending on the first variable. Changes should be done by following values:
There is a small inconsistency in the provided data. What should you get for both functions, when size=1? Because both functions are shown should be 2 when size is 1 on the 10th column, but should be 1 on the 12th column. Plase let us (me) know what value should the function return for size=1, because it matters a lot.
There is a small inconsistency in the provided data. What should you get for both functions, when size=1? Because both functions are shown should be 2 when size is 1 on the 10th column, but should be 1 on the 12th column. Plase let us (me) know what value should the function return for size=1, because it matters a lot.
Please ignore the previous attached image. There are errors in the image and I am sorry for that.
Please check the new image.
Screenshot 2023-04-20 073832.png
Asper the image If 'size' is 5.5, 'W' should be 6 and 'Gap' should be 5 and if 'size' is 2, 'W' should be 2 and 'Gap' should be 2. Accordingly when size=1 'W' and 'Gap' both should be 1.
You do not have the required permissions to view the files attached to this post.
Tezz95 wrote: ↑April 20th, 2023, 2:25 am
Please ignore the previous attached image. There are errors in the image and I am sorry for that.
Please check the new image.Screenshot 2023-04-20 073832.png
Asper the image If 'size' is 5.5, 'W' should be 6 and 'Gap' should be 5 and if 'size' is 2, 'W' should be 2 and 'Gap' should be 2. Accordingly when size=1 'W' and 'Gap' both should be 1.
There is no need of conditions. This can be done easily using the Floor and Ceil functions. For instance: