It is currently April 25th, 2024, 5:28 am

Nesting square brackets in actions

Get help with creating, editing & fixing problems with skins
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Nesting square brackets in actions

Post by balala »

:17what :17what
Honimoura wrote:

Code: Select all

OnUpdateAction = [! SetOptionGroup Pictures "Hidden = 0"]
OnUpdateAction = [! SetOptionGroup Pictures "Hidden [color=#FF0000]=[/color] 0"] - This is almost good, just remove the equal sign: OnUpdateAction = [! SetOptionGroup Pictures Hidden "0"].
Honimoura wrote:

Code: Select all

[Light]
Meter=Shape
Shape=Rectangle 7,0,193.5,62.5,5 | StrokeWidth 6 | Stroke Color 0,200,0,100 | Fill Color 47,47,47,0

[Effect]
OnUpdateAction=[!SetOption Light][!Show Light]| Wait 5 |[!Hide Light][!Show Light][!Hide Light][!Show Light][!Update Light]
This option has a lot of issues: first replace the red part of the following option with a !Delay bang: OnUpdateAction=[!SetOption Light][!Show Light][color=#FF0000]| Wait 5 |[/color][!Hide Light][!Show Light][!Hide Light][!Show Light][!Update Light]. Correctly (only from this point of view): OnUpdateAction=[!SetOption Light][!Show Light][color=#009900]| Wait 5 |[/color][!Hide Light][!Show Light][!Hide Light][!Show Light][!Update Light]. The number used under the !Delay bang is expressed in milliseconds. But there are missing a lot of parameters, quotation marks and so on. Can't see what you would like... In plus, adding more !ShowMeter / HideMeter bangs related to the same meter, has no visible effect, those bangs are executed simultaneously, you won't see anything.
Honimoura wrote:

Code: Select all

OnUpdateAction=[!SetOption Light [!Show Light | Wait 5 | !Hide Light]]
Again I'm not sure what you would like to achieve with the above option, but it definitely won't work, because there are too much spaces and too less parameters. The !SetOption bang needs at least three parameters: the first would be the name of the section which you'd like to modify through the bang. This is what I suppose to be missing above. There also would be required quotations. The set option contains spaces, so the quotations are absolutely required, without them the bang won't work: [!SetOption [color=#FF0000]NAME-OF-SECTION[/color] Light [color=#FF0000]"[/color][!Show Light | Wait 5 | !Hide Light][color=#FF0000]"[/color]].
Honimoura wrote:

Code: Select all

OnUpdateAction=[ActionList=[[!Show Light][!Hide Light][!Show Light]] | Wait 2000 | Repeat [[!Hide Light][!Show Light][!Hide Light]],10,3][!Redraw]
On this point I definitely don't understand what you would like to do. Probably again a !SetOption would be required, but...
:17oops :17oops
Honimoura
Posts: 94
Joined: April 3rd, 2018, 11:15 am

Re: Nesting square brackets in actions

Post by Honimoura »

Forget all this for a moment, I'm on the ActionMeter plugin tutorial and I see that I made a code that does not look like anything: s
Honimoura
Posts: 94
Joined: April 3rd, 2018, 11:15 am

Re: Nesting square brackets in actions

Post by Honimoura »

Sorry my code is so wrong !!!

But after reading the tutorial it would look more like at :

Code: Select all

[Light]
Meter=Shape
Shape=Rectangle 7,0,193.5,62.5,5 | StrokeWidth 6 | Stroke Color 0,200,0,100 | Fill Color 47,47,47,0

[Effect]
Measure=Plugin
Plugin=ActionTimer
ActionList=DoThat| Wait 1000 | Dothis
DoThat=[!Hide Light][!UpdateMeter Effect][!Redraw]
DoThis=[!Show Light][!UpdateMeter Effect][!Redraw]

But I continue the tutorial, I showed you just to reassure you about my unskill in this plugin. :D
Honimoura
Posts: 94
Joined: April 3rd, 2018, 11:15 am

Re: Nesting square brackets in actions

Post by Honimoura »

the same problem ... "! hide" works for a skin and not for a measure ... need to do with "hidden =" i think
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Nesting square brackets in actions

Post by balala »

Honimoura wrote:

Code: Select all

[Light]
Meter=Shape
Shape=Rectangle 7,0,193.5,62.5,5 | StrokeWidth 6 | Stroke Color 0,200,0,100 | Fill Color 47,47,47,0

[Effect]
Measure=Plugin
Plugin=ActionTimer
ActionList=DoThat| Wait 1000 | Dothis
DoThat=[!Hide Light][!UpdateMeter Effect][!Redraw]
DoThis=[!Show Light][!UpdateMeter Effect][!Redraw]
From what I understood you'd like to do there's no need of an ActionTimer plugin measure. Simply, instead of the measure execution (activation) option (probably something like LeftMouseUpAction=[!CommandMeasure "Effect" "Execute 1"]), you could use this: LeftMouseUpAction=[!Hide Light][!Delay "1000"][!Show Light].
Last edited by balala on April 4th, 2018, 8:19 pm, edited 1 time in total.
Honimoura
Posts: 94
Joined: April 3rd, 2018, 11:15 am

Re: Nesting square brackets in actions

Post by Honimoura »

It is, I think, not possible because it would be necessary that "Light" is part of another skin not?
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Nesting square brackets in actions

Post by balala »

Honimoura wrote:the same problem ... "! hide" works for a skin and not for a measure ... need to do with "hidden =" i think
A measure can't be hidden or shown, because it isn't something visual, you can't see it. Instead it can be disabled or enabled. The !Hide (!Show and !Toggle, along with !HideFade / !ShoFade / !ToggleFade) are used to hide / show loaded skins, they don't have effect neither on meters. For meters you have to use the !HideMeter / !ShowMeter / !ToggleMeter bangs. The Hidden option is again related to meters, has no effect nor on measures, nor on skins (in the Help it is in the General Meter Options section).
I think you have to clarify some notions...
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Nesting square brackets in actions

Post by balala »

Honimoura wrote:It is, I think, not possible because it would be necessary that "Light" is part of another skin not?
Sorry, what isn't possible?
Honimoura
Posts: 94
Joined: April 3rd, 2018, 11:15 am

Re: Nesting square brackets in actions

Post by Honimoura »

ho !! okay !!! I did not know the "! hidemeter".
I try to hide a "Sharpe" so it's visual.
In cheating I managed with a:

Code: Select all

[Light]
Meter=Shape
Shape=Rectangle 7,0,193.5,62.5,5 | StrokeWidth 6 | Stroke Color 0,200,0,100 | Fill Color 47,47,47,0

[bg]
Meter=Image
Imagename=MP.png
X=0
Y=0
OnUpdateAction=[!SetOption Light Hidden "1"][!Delay "1000"][!SetOption Light Hidden "0"]
DynamicVariables=1
So where do I loop this or use "hideMeter", which is the cleanest? The least greedy?
balala wrote:Sorry, what isn't possible?
"!hide" for a measure in the same skin
User avatar
balala
Rainmeter Sage
Posts: 16168
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Nesting square brackets in actions

Post by balala »

Honimoura wrote:ho !! okay !!! I did not know the "! hidemeter".
I try to hide a "Sharpe" so it's visual.
In cheating I managed with a:

Code: Select all

[Light]
Meter=Shape
Shape=Rectangle 7,0,193.5,62.5,5 | StrokeWidth 6 | Stroke Color 0,200,0,100 | Fill Color 47,47,47,0

[bg]
Meter=Image
Imagename=MP.png
X=0
Y=0
OnUpdateAction=[!SetOption Light Hidden "1"][!Delay "1000"][!SetOption Light Hidden "0"]
DynamicVariables=1
So where do I loop this or use "hideMeter", which is the cleanest? The least greedy?
OnUpdateAction=[!HideMeter "Light"][!Delay "1000"][!ShowMeter "Light"]
Setting the Hidden option (as you did) also works, but this solution is much more clearer (at least for me it definitely is).
Honimoura wrote:"!hide" for a measure in the same skin
https://forum.rainmeter.net/viewtopic.php?p=146924#p146924