It is currently April 25th, 2024, 8:00 am

Plugin measure Question

Get help with creating, editing & fixing problems with skins
SparkShredder
Posts: 50
Joined: November 17th, 2017, 12:00 pm

Plugin measure Question

Post by SparkShredder »

Okay, it is obvious that if you use Measure=Plugin , you can't change it with !Setoption bang
but, can Plugin=value be changed with !Setoption
I want to use this to make a music skin using depreciated Plugin=NowPlaying, and Plugin=WebNowPlaying, to make it support both players with single set of measure and meters, and toggle between both using !SetOtpion bang
If this is possible, this may won't create mess as both plugins use same options,values,and CommandMeasurebangs, a little bit of unsupported option is ignored by rainmeter anyway.
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Plugin measure Question

Post by balala »

No, I don't think it would be possible. But neither is it necessary. Create both sets of measures, disable all measures, then include them into two different groups, let's say a NowPlaying and a WebNowPlaying group. Finally you have to enable one group and disable the other, depending on which plugin would you like to use.
For more specific help, please post a code you have so far.
SparkShredder
Posts: 50
Joined: November 17th, 2017, 12:00 pm

Re: Plugin measure Question

Post by SparkShredder »

+ I guess a whole new set of meter would also be required
Or | Same meter be used with
MeasureName=NPMeasure
MeasureName2=WNPMeasure

!SetOptionGroup PlayerMeters Text "%1"
!SetOptionGroup PlayerMeters Text "%2"

------
Well No code I have:
I was "just thinking" :D :D
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Plugin measure Question

Post by balala »

SparkShredder wrote: December 31st, 2018, 11:08 am + I guess a whole new set of meter would also be required
Or | Same meter be used with
MeasureName=NPMeasure
MeasureName2=WNPMeasure

!SetOptionGroup PlayerMeters Text "%1"
!SetOptionGroup PlayerMeters Text "%2"
This would be one possibility, while the other is to leave the Text=%1 option unchanged and change the MeasureName option with a !SetOption bang:
[!SetOption PlayerMeters MeasureName "NPMeasure"][!UpdateMeter "PlayerMeters"][!Redraw]
[!SetOption PlayerMeters MeasureName "WNPMeasure"][!UpdateMeter "PlayerMeters"][!Redraw]
SparkShredder
Posts: 50
Joined: November 17th, 2017, 12:00 pm

Re: Plugin measure Question

Post by SparkShredder »

balala wrote: December 31st, 2018, 11:13 am This would be one possibility, while the other is to leave the Text=%1 option unchanged and change the MeasureName option with a !SetOption bang:
[!SetOption PlayerMeters MeasureName "NPMeasure"][!UpdateMeter "PlayerMeters"][!Redraw]
[!SetOption PlayerMeters MeasureName "WNPMeasure"][!UpdateMeter "PlayerMeters"][!Redraw]
With this possibility, There would require a separate bang for each meter
But it's easier with !SetOptionGroup
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Plugin measure Question

Post by balala »

SparkShredder wrote: December 31st, 2018, 12:05 pm With this possibility, There would require a separate bang for each meter
But it's easier with !SetOptionGroup
Yep, if you have more String meters and all of them should show the same thing. But this wouldn't have too much sense, I think. But can't say precisely, because you didn't post the code.
SparkShredder
Posts: 50
Joined: November 17th, 2017, 12:00 pm

Re: Plugin measure Question

Post by SparkShredder »

balala wrote: December 31st, 2018, 12:52 pm Yep, if you have more String meters and all of them should show the same thing. But this wouldn't have too much sense, I think. But can't say precisely, because you didn't post the code.
Who said it will make all meter show same thing?
Meter will show whatever the respective MeasureNames are assigned to them. %1 and %2 means the measure on the respective meter.
In case of %2, if no measurename2 is assigned, it will simply show "%2" , if one of meter is not string, Rainmeter will put a simple error in log file and move on.
Far I understand !SetOptionGroup will like:
1. Gather all meters respectively under the mentioned group
2. Apply said Options to each meter in separate thread, like multiple !Setoption bangs were used, one for each.
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Plugin measure Question

Post by balala »

Ok, as you wish...