It is currently March 28th, 2024, 4:25 pm

Help: Switching wallpapers with a button

Get help with creating, editing & fixing problems with skins
Mino_el_Nukenin
Posts: 231
Joined: April 24th, 2020, 7:39 pm
Location: France

Re: Help: Switching wallpapers with a button

Post by Mino_el_Nukenin »

balala wrote: June 8th, 2020, 7:53 pm There I see more problems:
  • There is a missing comma in the ActionList1 option of the [MeasureSlider] measure. You have this: ActionList1=Repeat SlideOutC,#SpeedC#,#RepeatC# | Wait #WaitP# | Repeat SlideOutP#SpeedP#,#RepeatP#, but a comma is needed between the SlideOutP and the #SpeedP# parameters: ActionList1=Repeat SlideOutC,#SpeedC#,#RepeatC# | Wait #WaitP# | Repeat SlideOutP,#SpeedP#,#RepeatP#.
Didn't see this one. The problem with copy-pasting from others skins.
[*]The two !CommandMeasure bangs used into the OnRefreshAction option of the [Rainmeter] section are contradicting each other. Makes not too much sense to start and stop one action in the same time. I suppose you wanted to put the [!Delay "500"] bang between the [!CommandMeasure MeasureSlider "Execute #StateP#"] and [!CommandMeasure MeasureSlider "Stop #StateP#"] bangs, but it's not there. And even if it would be, you still wouldn't get the proper execution of the appropriate actions, because all actions involved into the two action lists takes more then half a second (500 milliseconds), so there is no enough time to completely execute both action lists.
I've put both [Measure] since all my others skins that involve sliding have them both.
[*]The time is not enough for the [!Delay "3000"] bang of the SlideOutC option of the [MeasureSlider] measure. SlideOutC being the first action in the ActionList1 option, it waits more then 5 milliseconds (set for the WaitP variable, used between the SlideOutC and SlideOutP parameters), so finally SlideOutC is not executed at all.
[*]The values of different variables have to be adjusted a little bit. There are some inadvertences with more of them. For instance, I replaced the following two variables: RepeatC=270 and WaitP=100. I also rewrote the formulas used into the SlideOutC and SlideOutP options of the [MeasureSlider] measure, this way: [!SetVariable OffsetC "(Clamp((#OffsetC#-1),0,170))"] (SlideOutC), respectively [!SetVariable OffsetP "(Clamp((#OffsetP#-1),0,80))"] (SlideOutP).[/list]
Ok I got the skin working well, but I had to remove and re-change some things.
RepeatC=270 made the [Meter] going way to far to teh left so I put back 110.
the WaitP=100 do the same thing if it's 5, there is no difference.
I didn't understand why putting "Clamp" and all the rest in the [MeasureSlider] so I put back the initial [Measure] like in all my skins involving sliding. (I just removed the "clamp" and the numbers after the parenthesis.
User avatar
balala
Rainmeter Sage
Posts: 16110
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Help: Switching wallpapers with a button

Post by balala »

Mino_el_Nukenin wrote: June 8th, 2020, 10:23 pm Didn't see this one. The problem with copy-pasting from others skins.
Such mistakes are definitely not caused by copy-pasting problems, but this doesn't matter too much.
Mino_el_Nukenin wrote: June 8th, 2020, 10:23 pm I've put both [Measure] since all my others skins that involve sliding have them both.
Yes, but if you're using both, at a moment, the ActionTimer measure is started (by the bang using the Execute statement) and halted (by the bang using the Stop statement), not letting it top run.
Mino_el_Nukenin wrote: June 8th, 2020, 10:23 pm Ok I got the skin working well, but I had to remove and re-change some things.
RepeatC=270 made the [Meter] going way to far to teh left so I put back 110.
the WaitP=100 do the same thing if it's 5, there is no difference.
I didn't understand why putting "Clamp" and all the rest in the [MeasureSlider] so I put back the initial [Measure] like in all my skins involving sliding. (I just removed the "clamp" and the numbers after the parenthesis.
Ok, especially if you got it working as intended. Although I'd keep the Clamp functions, to keep the value of the variable between certain limits, but usually there is nothing wrong, even if you're renouncing to it.
Mino_el_Nukenin
Posts: 231
Joined: April 24th, 2020, 7:39 pm
Location: France

Re: Help: Switching wallpapers with a button

Post by Mino_el_Nukenin »

balala wrote: June 9th, 2020, 4:02 pm Such mistakes are definitely not caused by copy-pasting problems, but this doesn't matter too much.
In this case it is, because I'm copying stuffs, then changing the order then rechanging it.. so I probably erased by mistake or something like that.
Yes, but if you're using both, at a moment, the ActionTimer measure is started (by the bang using the Execute statement) and halted (by the bang using the Stop statement), not letting it top run.
I understand that they kinda opposed, but still all my others have it like that, and they are working perfectly. Don't know why to be honest.
Ok, especially if you got it working as intended. Although I'd keep the Clamp functions, to keep the value of the variable between certain limits, but usually there is nothing wrong, even if you're renouncing to it.
I this what Clamp does, but since I have a specific X and Y for both [Meter] and [Container] and a a variable that says "you have to move for that much X or Y", the job appears to be done without it.

Anyway thanks again for the help!
User avatar
balala
Rainmeter Sage
Posts: 16110
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Help: Switching wallpapers with a button

Post by balala »

Mino_el_Nukenin wrote: June 9th, 2020, 5:44 pm I understand that they kinda opposed, but still all my others have it like that, and they are working perfectly. Don't know why to be honest.
I'm surprised. Could you please post an example?
Mino_el_Nukenin wrote: June 9th, 2020, 5:44 pm I this what Clamp does, but since I have a specific X and Y for both [Meter] and [Container] and a a variable that says "you have to move for that much X or Y", the job appears to be done without it.
Alright, as you wish.
Mino_el_Nukenin wrote: June 9th, 2020, 5:44 pm Anyway thanks again for the help!
You're welcome. Glad if did help.
Mino_el_Nukenin
Posts: 231
Joined: April 24th, 2020, 7:39 pm
Location: France

Re: Help: Switching wallpapers with a button

Post by Mino_el_Nukenin »

balala wrote: June 9th, 2020, 6:00 pm I'm surprised. Could you please post an example?
Yeah sure here is a skin with various sliding.
Attachments
Skin_1.rmskin
(82.05 KiB) Downloaded 5 times
User avatar
balala
Rainmeter Sage
Posts: 16110
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Help: Switching wallpapers with a button

Post by balala »

Mino_el_Nukenin wrote: June 10th, 2020, 7:32 pm Yeah sure here is a skin with various sliding.
Yes, but there is a minor, but even more important difference: in the original code of Clock.ini, first you had the Execute operation and after this the Stop (OnRefreshAction = [!Delay "800"][!ShowMeter "MeterCircle"][!Delay "500"][!CommandMeasure MeasureSlider "Execute #StateP#"][!CommandMeasure MeasureSlider "Stop #StateP#"][!Delay "500"]). In the above posted skin, these are exactly opposite: first is posted the Stop and then the Execute operation (LeftMouseUpAction=[!CommandMeasure MeasureSlider "Stop #StateP#"][!CommandMeasure MeasureSlider "Execute #StateP#"][#MouseAction[#MyVar]][!SetVariable MyVar "(1-#MyVar#)"][!UpdateMeasure "MeasureMyVar"][!Redraw] - [MeterImage] meter). This makes a great difference and explains everything.
Mino_el_Nukenin
Posts: 231
Joined: April 24th, 2020, 7:39 pm
Location: France

Re: Help: Switching wallpapers with a button

Post by Mino_el_Nukenin »

balala wrote: June 10th, 2020, 8:05 pm Yes, but there is a minor, but even more important difference: in the original code of Clock.ini, first you had the Execute operation and after this the Stop (OnRefreshAction = [!Delay "800"][!ShowMeter "MeterCircle"][!Delay "500"][!CommandMeasure MeasureSlider "Execute #StateP#"][!CommandMeasure MeasureSlider "Stop #StateP#"][!Delay "500"]). In the above posted skin, these are exactly opposite: first is posted the Stop and then the Execute operation (LeftMouseUpAction=[!CommandMeasure MeasureSlider "Stop #StateP#"][!CommandMeasure MeasureSlider "Execute #StateP#"][#MouseAction[#MyVar]][!SetVariable MyVar "(1-#MyVar#)"][!UpdateMeasure "MeasureMyVar"][!Redraw] - [MeterImage] meter). This makes a great difference and explains everything.
Yes I see, actually i tried both order and it wasn't working either way (because some others modifications were needed at the time). So let it like that when I sent it to you. :Whistle
User avatar
balala
Rainmeter Sage
Posts: 16110
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Help: Switching wallpapers with a button

Post by balala »

Mino_el_Nukenin wrote: June 11th, 2020, 10:31 am So let it like that when I sent it to you. :Whistle
Obviously, it's your work, your skin, so it's up to you.
Mino_el_Nukenin
Posts: 231
Joined: April 24th, 2020, 7:39 pm
Location: France

Re: Help: Switching wallpapers with a button

Post by Mino_el_Nukenin »

balala wrote: June 11th, 2020, 10:55 am Obviously, it's your work, your skin, so it's up to you.
Yeah but now all working so it's good ;)

I have another doubt concerning the preivous skin you've helped me with. The skin with the 90° rotating circle and some sliding meters.

Well here is the thing :
I've added a clock with 2 strings meters but I would like it to be "attached" to a certain sliding meter, so it would look like it appears sliding with this sliding meter.
What should I add to the 2 strings meters to have the desired effect ?

Here is the part of code concerned :

Code: Select all

[MeterContainerP]
Meter=Image
ImageName=#@#\Images\Clock\ContainerP.png
X=618
Y=513
Antialias=1
DynamicVariables=1

[MeterSlidingPanel]
Container=MeterContainerP
Meter=Image
ImageName=#@#\Images\Clock\ClockPanel.png
X=(#OffsetP#)r
Y=r
DynamicVariables=1
AntiAlias=1

;--- Clock -------------------------------------------

[MeterText1]
Meter=String
MeasureName=Measure12HrTime
X=4r
Y=10r
FontColor=a2650c
FontSize=24
FontFace=OCR A Extended

[MeterText2]
Meter=String
MeasureName=Measure12HrTime2
X=-2R
Y=-10r
FontColor=a2650c
FontSize=20
FontFace=OCR A Extended
EDIT: nevermind, I had it working.
I've just added Container=MeterContainerP to each string.
And also [!UpdateMeter Text1][!UpdateMeter Text2] to the measure that does the sliding.
User avatar
balala
Rainmeter Sage
Posts: 16110
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Help: Switching wallpapers with a button

Post by balala »

Mino_el_Nukenin wrote: June 11th, 2020, 5:07 pm I've added a clock with 2 strings meters but I would like it to be "attached" to a certain sliding meter, so it would look like it appears sliding with this sliding meter.
What should I add to the 2 strings meters to have the desired effect ?
You probably should add a Group=SlidingPanel option to the [MeterText1] and [MeterText2] meters. But this solution works only if the [MeterSlidingPanel] meter still have a Group=SlidingPanel, as it had in the last code. Now I don't see this option in the last posted code piece.
So, is this Group option still there on the the [MeterSlidingPanel] meter?
Post Reply