It's MeterStyle=, StringStyle= is used for Bold, Italic and the like.sl23 wrote:Actually I used @Resources\Marquee.lua instead of #@#Marquee.lua, now I switched to the latter, it works now I've rearranged the code a little. I can't get the font style to work though?
Here's the latest version.
It is currently March 28th, 2024, 10:18 am
[Script] Lua Marquee
Re: [Script] Lua Marquee
Re: [Script] Lua Marquee
That's the thing, I've used this to specify the details:
[StringMeter1]
StringStyle=styleLeftText
Here's the code now:
[StringMeter1]
StringStyle=styleLeftText
Here's the code now:
Code: Select all
[mMedia1]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mPlayer]
PlayerType=Artist
[mLua1]
Measure=Script
ScriptFile=#@#Marquee.lua
Width=20
MeasureName=mMedia1
Delimiter=" | "
[StringMeter1]
Meter=String
MeasureName=mLua1
StringStyle=styleLeftText
X=120
Y=18
W=120
H=16
[mMedia2]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mPlayer]
PlayerType=Title
[mLua2]
Measure=Script
ScriptFile=#@#Marquee.lua
Width=20
MeasureName=mMedia2
Delimiter=" | "
[StringMeter2]
Meter=String
MeasureName=mLua2
StringStyle=styleLeftText
FontColor=128,255,0,255
X=r
Y=15r
W=120
H=16
[mMedia3]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mPlayer]
PlayerType=Album
[mLua3]
Measure=Script
ScriptFile=#@#Marquee.lua
Width=20
MeasureName=mMedia3
Delimiter=" | "
[StringMeter3]
Meter=String
MeasureName=mLua3
StringStyle=styleLeftText
X=r
Y=15r
W=120
H=16
Re: [Script] Lua Marquee
MeterStyle=styleLeftText
Re: [Script] Lua Marquee
Oh?! Now I'm confused! Why not StringStyle? That works elsewhere.
Yay! Sorted, thanks for your help smurfier
Yay! Sorted, thanks for your help smurfier
Re: [Script] Lua Marquee
Because StringStyle is exclusively used for StringStyle=Bold and the like.sl23 wrote:Oh?! Now I'm confused! Why not StringStyle? That works elsewhere.
Yay! Sorted, thanks for your help smurfier
What you are doing is using a MeterStyle.
Re: [Script] Lua Marquee
Er... Ok! How come this works elsewhere though? Does it depend where it's used I suppose?
Re: [Script] Lua Marquee
It shouldn't work anywhere else. StringStyle is only for use on strings and applies Bold, Italic, or BoldItalic to a string. MeterStyle applies to all Meters and adds the options from the defined styles to that meter. A MeterStyle can be a section containing options or be another meter itself.sl23 wrote:Er... Ok! How come this works elsewhere though? Does it depend where it's used I suppose?
Re: [Script] Lua Marquee
My mistake I saw StringStyle and mistook it for the MeterStyle!!!
Re: [Script] Lua Marquee
The Marquee seems to work but have minor problems. The skin is laid out like this:
Artist - Never seen scrolling yet
Track - Always scrolls if longer than visible size
Album - sometimes scrolls, sometimes not
I've set the length to 20 characters. Basically I have 3 marquees one for each and they're all the same so how come Artist doesn't scroll and Album sometimes scrolls but not always, both should ALWAYS scroll when more than 20 characters shouldn't they?
EDIT: Think I've solved this, it was due to 20 chars being longer than W=120!
Marquee Code...
I also can't get the scroll on MouseOver to work:
MouseOverAction=!CommandMeasure Lua Pause=1
MouseLeaveAction=!CommandMeasure Lua Pause,Timer=0,0
I copied this from the first post. As I have used these commands in the [Rainmeter] section, and I'd prefer a general MouseOver command, I put them in there with the other stuff. Am I doing something wrong?
I changed the Pause=0 and Position=Left in the LUA.
EDIT: I've figured out the cause. Basically as I'd renamed MeterLua and now have 3 of these, I needed 3 !CommandMeasure mLua1(and 2 and 3). As detailed below:
Artist - Never seen scrolling yet
Track - Always scrolls if longer than visible size
Album - sometimes scrolls, sometimes not
I've set the length to 20 characters. Basically I have 3 marquees one for each and they're all the same so how come Artist doesn't scroll and Album sometimes scrolls but not always, both should ALWAYS scroll when more than 20 characters shouldn't they?
EDIT: Think I've solved this, it was due to 20 chars being longer than W=120!
Marquee Code...
MouseOverAction=!CommandMeasure Lua Pause=1
MouseLeaveAction=!CommandMeasure Lua Pause,Timer=0,0
I copied this from the first post. As I have used these commands in the [Rainmeter] section, and I'd prefer a general MouseOver command, I put them in there with the other stuff. Am I doing something wrong?
I changed the Pause=0 and Position=Left in the LUA.
Re: [Script] Lua Marquee
Version 6.2 is rounding numbers, eg if a calc returns 15.8 it displays 16. How do I change this behaviour?
Further to that, the figure above is RAM, and Autoscale does not seem to be supported so I am using a calc:
and I want to append GB. e.g 15.85 GB or whatever.
MeasureName=MeasureTime|MeasureDate|PhysMemTotalCalc GB|PhysMemUsedCalc|PhysMemFreeCalc
If I pop a GB after PhysMemTotalCalc the meter is not displayed at all, so what is the method to achieve this please?
Further to that, the figure above is RAM, and Autoscale does not seem to be supported so I am using a calc:
Code: Select all
[PhysMemTotalCalc]
Measure=Calc
Formula=ROUND((MeasurePhysMemTotal/1024/1024/1024),#Accuracy#)
MeasureName=MeasureTime|MeasureDate|PhysMemTotalCalc GB|PhysMemUsedCalc|PhysMemFreeCalc
If I pop a GB after PhysMemTotalCalc the meter is not displayed at all, so what is the method to achieve this please?