It is currently April 28th, 2024, 6:40 am

Improve Meter Styles.

Report bugs with the Rainmeter application and suggest features.
User avatar
lysy1993lbn
Posts: 291
Joined: July 25th, 2011, 9:53 am
Location: Lublin, Poland

Improve Meter Styles.

Post by lysy1993lbn »

I'm just wondering is possible to improve meter styles to use several in one meter / string..

For example to use like in html, in that way:

Code: Select all

[Meter]
Meter=String
MeasureName=mCPU
MeterStyle=Style
MeterStyle2=Style2
Text=<s1>CPU</s1><s2>%1%</s2>
To get for example "CPU 22%"

I really miss something like that in Rainmeter, and I think that I'm not only one..
"Never argue with an idiot, he will drag you down to his level and beat you with experience."
my deviantART | Alternative Rainmeter tray icons
User avatar
jsmorley
Developer
Posts: 22631
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Sugestion • Improve Meter Styles.

Post by jsmorley »

In the current environment, "inline" formatting is just not possible. The output of a meter is not some stream of characters rendered a character at a time as it is displayed, but really a graphical "object" built all at once and displayed more or less as an image.

It would take an entirely different approach to how Rainmeter works to accomplish HTML/CSS type formatting. You never know though.. ;-)
User avatar
lysy1993lbn
Posts: 291
Joined: July 25th, 2011, 9:53 am
Location: Lublin, Poland

Re: Sugestion • Improve Meter Styles.

Post by lysy1993lbn »

Really pity.. it seems to be really basic, to make even bold text next to normal..

Looking forward for changes / improvements to make it possible..
"Never argue with an idiot, he will drag you down to his level and beat you with experience."
my deviantART | Alternative Rainmeter tray icons
r0k
Posts: 78
Joined: March 9th, 2012, 10:06 am

Re: Sugestion • Improve Meter Styles.

Post by r0k »

Using two meters with the second one's position relative to the first would do the trick for fixed width strings such as this example (length of text wouldn't change much)

Code: Select all

[Meter]
Meter=String
MeasureName=mCPU
MeterStyle=Style1
Text=CPU

[Meter2]
Meter=String
x=R
MeterStyle=Style2
Text=%
For variable lenght text you might use a fixed width font and measure the legnth with a lua script. This becomes more of hassle.

Maybe if it's possible, having some sort of auto-resizing of string meters based on actual (pixel) size of the text would help work around this limitation.
User avatar
lysy1993lbn
Posts: 291
Joined: July 25th, 2011, 9:53 am
Location: Lublin, Poland

Re: Sugestion • Improve Meter Styles.

Post by lysy1993lbn »

I know actual text formatting methods.. Is simply not good enough in some cases..
"Never argue with an idiot, he will drag you down to his level and beat you with experience."
my deviantART | Alternative Rainmeter tray icons