Make sure the played song has MP3 tags present. If it doesn't it won't display any title or artist. Also, what player are you using?Crash wrote: ↑April 5th, 2020, 8:18 pm I tried this out but I can't seem to get the artist or music name to show up at all, I tried messing with the Container but I can't seem to get it to show up at all, the settings on the side do seem to work and so do the play, pause, and next buttons with Itunes...
It is currently June 17th, 2024, 9:16 am
Scrolling text
-
- Rainmeter Sage
- Posts: 7439
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Scrolling text
-
- Rainmeter Sage
- Posts: 16307
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Scrolling text
He is using iTunes:
Although iTunes is not completely supported, the title and the artist are returned and he had these before applying my last code.
-
- Rainmeter Sage
- Posts: 7439
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Scrolling text
Yeah, I saw that he was mentioning iTunes, I just thought that he was using it as an alternative player (in which he managed to make
work). Must have misunderstood the meaning of the mention - my bad.
-
- Posts: 47
- Joined: February 12th, 2020, 1:53 am
Re: Scrolling text
Ahh I found the issue, it's just not setup with using the "Now playing" alligned to the right(Which I can probably setup myself) Overall this looks pretty good imo, but sometimes it seems to make a "Jump" rather than hiding or removing each character, huge thanks btw sorry for any trouble I may have caused at the beginning
-
- Rainmeter Sage
- Posts: 16307
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Scrolling text
Well, I think that's a much harder thing. For now yes, when the scrolling arrives to the end of the artist / title it jumps. Yet I have no idea how to make that "hiding or removing each character". Will try it, let's see...
No trouble at all, don't worry.
-
- Posts: 47
- Joined: February 12th, 2020, 1:53 am
Re: Scrolling text
Code: Select all
[Variables]
ContainerWidth=169
TextWidth=0
ScrollingStep=10
SlidingStep=1
CurrentStep=(#SlidingStep#)
SlidingUpdate=24
EatCharUpdate=150
Text="SOUL'd OUT - ALIVE"
[Rainmeter]
AccurateText=1
Update=#SlidingUpdate#
---Measures---
[MeasureEatChars]
Disabled=1
Measure=String
String=""
UpdateDivider=(#EatCharUpdate#/#SlidingUpdate#)
RegExpSubstitute=1
Substitute="^.{1}(.*)$":"\1","^\\1$":""
IfMatch=^$
IfMatchAction=[!SetOption MeterText Text ""][!UpdateMeter "MeterText"][!DisableMeasure "MeasureEatChars"][!UpdateMeasure "MeasureEatChars"]
IfNotMatchAction=[!SetOption MeasureEatChars String "[MeasureEatChars]"][!SetOption MeterText Text "[MeasureEatChars]"][!UpdateMeter "MeterText"]
IfMatchMode=1
DynamicVariables=1
[MeasureCounter]
Group=CounterGroup
Disabled=1
Measure=Calc
Formula=((MeasureCounter<0)?(#ContainerWidth#):((MeasureCounter>=(#TextWidth#))?(#TextWidth#):(MeasureCounter+#CurrentStep#)))
OnUpdateAction=[!SetOption MeterText X (#ContainerWidth#-[MeasureCounter])][!UpdateMeter *][!Redraw]
IfCondition=(MeasureCounter<0)
IfTrueAction=[!UpdateMeter *][!UpdateMeasure "MeasureCounter"]
IfCondition2=(MeasureCounter>=(#TextWidth#)) && (#TextWidth#<>0)
IfTrueAction2=[!EnableMeasure "MeasureEatChars"]
IfConditionMode=1
DynamicVariables=1
---Meters---
[MeterBackground]
Meter=Shape
Shape=Rectangle 0,0,169,13 | StrokeWidth 0.5 | Stroke Color 255,64,32 | Fill Color 32,32,32,128
UpdateDivider=-1
[MeterContainer]
Meter=Shape
X=0
Y=0
Shape=Rectangle 0,0,169,13 | Fill Color 0,0,0,255 | StrokeWidth 0
UpdateDivider=-1
MouseOverAction=[!PauseMeasure "MeasureCounter"]
MouseLeaveAction=[!UnpauseMeasure "MeasureCounter"]
MouseScrollUpAction=[!SetVariable CurrentStep (-#ScrollingStep#)][!UnpauseMeasure "MeasureCounter"][!UpdateMeasure "MeasureCounter"][!PauseMeasure "MeasureCounter"][!SetVariable CurrentStep (#SlidingStep#)]
MouseScrollDownAction=[!SetVariable CurrentStep (#ScrollingStep#)][!UnpauseMeasure "MeasureCounter"][!UpdateMeasure "MeasureCounter"][!PauseMeasure "MeasureCounter"][!SetVariable CurrentStep (#SlidingStep#)]
LeftMouseUpAction=[!DisableMeasure "MeasureEatChars"][!SetOption MeasureEatChars String "#Text#"][!UpdateMeasure "MeasureEatChars"][!SetOption MeterText Text "#Text#"][!UpdateMeter "MeterText"][!UnpauseMeasure "MeasureCounter"][!UpdateMeasure "MeasureCounter"][!DisableMeasure "MeasureCounter"][!UpdateMeasure "MeasureCounter"][!EnableMeasure "MeasureCounter"][!UpdateMeasure "MeasureCounter"][!PauseMeasure "MeasureCounter"]
DynamicVariables=1
[MeterText]
Meter=String
Container=MeterContainer
FontFace=Tahoma
FontSize=7
FontWeight=400
FontColor=255,255,255,255
FontEffectColor=0,0,0,255
StringEffect=Shadow
Antialias=1
ClipString=0
X=(#ContainerWidth#)
Y=0
Text=#Text#
UpdateDivider=-1
OnUpdateAction=[!SetVariable TextWidth [MeterText:W]]
DynamicVariables=1
-
- Rainmeter Sage
- Posts: 7439
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Scrolling text
Not necessarily.
Crash is right:
This (initially disabled) measure is doing the job, basically "eating" the first character from itself (since it's a String measure, and the initial value of its String option is the #Text# variable). Then, it updates the (previously scrolled) meter text every 150 ms until its string value is empty (""). The scrolling process (which happens in this case in the Counter measure, but is obviously another measure in your case) never stops actually, it's just that after scrolling out of the viewport (i.e. container or such), it continues to "scroll" on the same position as before while "eating out" character after character. In the end, it will become the empty string "scrolling" on the same position.Crash wrote: ↑April 6th, 2020, 11:01 am[MeasureEatChars]
Disabled=1
Measure=String
String=""
UpdateDivider=(#EatCharUpdate#/#SlidingUpdate#)
RegExpSubstitute=1
Substitute="^.{1}(.*)$":"\1","^\\1$":""
IfMatch=^$
IfMatchAction=[!SetOption MeterText Text ""][!UpdateMeter "MeterText"][!DisableMeasure "MeasureEatChars"][!UpdateMeasure "MeasureEatChars"]
IfNotMatchAction=[!SetOption MeasureEatChars String "[MeasureEatChars]"][!SetOption MeterText Text "[MeasureEatChars]"][!UpdateMeter "MeterText"]
IfMatchMode=1
DynamicVariables=1
I guess the Substitute can be simplified to not use captures, by setting it to "^.":"". Didn't thought to do that at the time of writing. Also, aligning the string to the right (this requires some changes in formulas, I think) can help in keeping making the text being "eaten" much more stable in terms of positioning (as it is right now, it looks like slightly moving to the left/right by 1px or so, while it's repositioning itself in the process).
I can try to do add it as well (working on your version of the code, obviously), if it helps...
-
- Posts: 47
- Joined: February 12th, 2020, 1:53 am
Re: Scrolling text
That would be very helpfull, I don't mind manually editing the stuff over to the right side btw, since I don't intend to keep the settings tab really, no use once this is all setup. The way it gets "eaten" looks fine to me and is relativley smooth, I gather that using the method balala had with the bounding box that has the with of 300 to keep it from going too far would work fine aswellYincognito wrote: ↑April 6th, 2020, 3:37 pm Not necessarily.
Crash is right:
This (initially disabled) measure is doing the job, basically "eating" the first character from itself (since it's a String measure, and the initial value of its String option is the #Text# variable). Then, it updates the (previously scrolled) meter text every 150 ms until its string value is empty (""). The scrolling process (which happens in this case in the Counter measure, but is obviously another measure in your case) never stops actually, it's just that after scrolling out of the viewport (i.e. container or such), it continues to "scroll" on the same position as before while "eating out" character after character. In the end, it will become the empty string "scrolling" on the same position.
I guess the Substitute can be simplified to not use captures, by setting it to "^.":"". Didn't thought to do that at the time of writing. Also, aligning the string to the right (this requires some changes in formulas, I think) can help in keeping making the text being "eaten" much more stable in terms of positioning (as it is right now, it looks like slightly moving to the left/right by 1px or so, while it's repositioning itself in the process).
I can try to do add it as well (working on your version of the code, obviously), if it helps...
-
- Rainmeter Sage
- Posts: 7439
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Scrolling text
So you're currently using this version, right?Crash wrote: ↑April 6th, 2020, 3:54 pm That would be very helpfull, I don't mind manually editing the stuff over to the right side btw, since I don't intend to keep the settings tab really, no use once this is all setup. The way it gets "eaten" looks fine to me and is relativley smooth, I gather that using the method balala had with the bounding box that has the with of 300 to keep it from going too far would work fine aswell
-
- Posts: 47
- Joined: February 12th, 2020, 1:53 am