It is currently March 28th, 2024, 8:48 am

Some issues with !Refresh

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

Re: Some issues with !Refresh

Post by balala »

Yincognito wrote: March 1st, 2020, 8:05 pm it just can't parse the UpdateDivider line because of a previous non Key=Value line.
Not sure this is (or why is it) normal. But it seems it indeed is...
User avatar
jsmorley
Developer
Posts: 22628
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Some issues with !Refresh

Post by jsmorley »

Yes, if you do this:

Code: Select all

[MeasureOne]
Measure=Calc
Formula=(MeasureOne + 1) % 10
[!Log "Hello"][!Log "Goodbye"]
UpdateDivider=-1
Then the invalid line with just the two "actions" and no "option" breaks the parser for this measure, it is entirely invalid INI format, much less Rainmeter, and the UpdateDivider=-1 is never read. Don't do that...
User avatar
Yincognito
Rainmeter Sage
Posts: 7017
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Some issues with !Refresh

Post by Yincognito »

balala wrote: March 1st, 2020, 8:08 pm Not sure this is (or why is it) normal. But it seems it indeed is...
After further thinking, I think it has to do with how Rainmeter parses code (i.e. looking for [Sections]). When it encounters the faulty line, it assumes the current section (i.e. [SomeTest]) has ended, and the following lines until a new [Section] begins are to be ignored as "comments".
User avatar
jsmorley
Developer
Posts: 22628
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Some issues with !Refresh

Post by jsmorley »

Yincognito wrote: March 1st, 2020, 8:15 pm After further thinking, I think it has to do with how Rainmeter parses code (i.e. looking for [Sections]). When it encounters the faulty line, it assumes the current section (i.e. [SomeTest]) has ended, and the following lines until a new [Section] begins are to be ignored as "comments".
Almost correct. It sees the [Action] without any option as an entirely new [SectionName]. Since there is no Measure= or Meter= "type" on it, it will be treated as a MeterStyle.
User avatar
Yincognito
Rainmeter Sage
Posts: 7017
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Some issues with !Refresh

Post by Yincognito »

jsmorley wrote: March 1st, 2020, 8:16 pm Correct. It sees the [Action] without any option as an entirely new [SectionName]
Yes. Forgot the bangs have the same [syntax] as [sections] (i.e. enclosed in square brackets).
User avatar
jsmorley
Developer
Posts: 22628
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Some issues with !Refresh

Post by jsmorley »

Yincognito wrote: March 1st, 2020, 8:18 pm Yes. Forgot the bangs have the same [syntax] as [sections] (i.e. enclosed in square brackets).
Yes. He has inadvertently created a MeterStyle.
User avatar
Yincognito
Rainmeter Sage
Posts: 7017
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Some issues with !Refresh

Post by Yincognito »

jsmorley wrote: March 1st, 2020, 8:19 pm Yes. He has inadvertently created a MeterStyle.
Indeed.
User avatar
jsmorley
Developer
Posts: 22628
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Some issues with !Refresh

Post by jsmorley »

Code: Select all

[Rainmeter]
Update=1000
DynamicWindowSize=1
AccurateText=1

[MeasureOne]
Measure=Calc
Formula=(MeasureOne + 1) %11
[!Log "Hello"]
FontSize=30

[MeterOne]
Meter=String
MeterStyle=!Log "Hello"
FontWeight=400
FontColor=255,255,255,255
SolidColor=47,47,47,255
Padding=5,5,5,5
AntiAlias=1
Text=Hello World
User avatar
balala
Rainmeter Sage
Posts: 16109
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Some issues with !Refresh

Post by balala »

jsmorley wrote: March 1st, 2020, 8:16 pm Almost correct. It sees the [Action] without any option as an entirely new [SectionName]. Since there is no Measure= or Meter= "type" on it, it will be treated as a MeterStyle.
Stupid me. Didn't figure this out, but it's perfectly logic and explains what is going on.
User avatar
Yincognito
Rainmeter Sage
Posts: 7017
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Some issues with !Refresh

Post by Yincognito »

balala wrote: March 1st, 2020, 8:27 pm Stupid me. Didn't figure this out, but it's perfectly logic and explains what is going on.
Nah, don't worry. Neither of us truly figured this out since the first post. That's why some are actual developers and others are ... erm ... trying very hard to be (yeah, myself included - although I have no clue what I'm trying to "develop" here). :lol:
Last edited by Yincognito on March 1st, 2020, 8:31 pm, edited 1 time in total.
Post Reply