Now i have the title, artist, and time/total time of the track. What do i have to add, an where, to also have something like 5/12 to indicate that track 5 of 12 ist currently paying (example)? I suppose, this should be possible.
I... don't think it's possible with native Rainmeter, since the NowPlaying plugin was made to fit as much as it can in common to all the player there, they either didn't find the right things or gave up. You can get the current track number in the playlist (PlayerType=Number) and that's all, I can't think of a way to get the total.
I've seen people with Spicetify do it using JavaScript, but that's a bit beside the point since WebNowPlaying isn't Rainmeter (yet... plz tj, plz jeff, plz plz webnowplaying4rainmeter)
Also a bit of suggestions on the code, you can remove AccurateText since you don't use Inline Strings. If you wanna keep AccurateText, you can have your stuff like
It simply uses a better method to "measuring" the dimensions of a drawn string when calculating the width and height the string. With it "off", the string meter will add small amounts of padding when rendering the string to the screen. You can easily see the difference if you include a background color to the meter with SolidColor.
Jeff wrote: ↑December 14th, 2018, 5:21 pm
Didn't AccurateText=0 use the same padding and character spacing as GDI+ and because of that the boundig box can't update?
Partially.
Didn't AccurateText=0 use the same padding and character spacing as GDI+ : Yes, AccurateText=0 does use a similar padding and character spacing as GDI+. We did this so that skins made before the change still "looked" and were spaced similarly to previous versions. When converting the String meter to DirectWrite/D2D, we noticed we could use a different method to get the exact "bounding box" of the string, which is why we have the option in the first place.
and because of that the boundig box can't update? : I am not sure what we mean by "can't update". The bounding box has always been updated (presuming no W or H is defined), when the string is updated. Could you explain?
AccurateText = 0 and 2 inline settings, the black box (that i call bounding box), which is SolidColor on the string, is big dum dum and dosen't change to the size of the actual real value of the text
With AccurateText = 1 that thing is fixed ofc but this is what I'm reffering to when I say the bounding box (original box lenght before inline options are applied) is not updated
So it's not possible? What does that code change? Does it look differently then? I'm not experienced with Rainmeter, so i do not want to mess up things.
@anbr07: Sorry to hijack your thread. Jeff is right, there is no way to get the exact information you are asking for. The only information available is the current track number (assuming it is included in the metadata of the music file currently being played). There is no option with the NowPlaying plugin to get the total amount of tracks on a playlist/album.
@Jeff: Congratulations, you found a bug. While most inline settings were not ignored by AccurateText=0, the CharacterSpacing inline setting was applied, then overwritten by the GDI+ emulation code we use to adjust the padding and spacing.
While the obvious solution is to swap that parts that set the character spacing, we will have to evaluate any side effects before doing so.