What I want is a solid bar, but with the text being see-though, as in creating a hole the bar, so to say. In addition, when the text is longer than the bar, the text becomes "visible" again. It's hard to explain, so I included some images, hope they do better (Please note, they are just examples I made in Paint.NET):
It is currently May 9th, 2024, 4:21 pm
Can I make text displace or see trough objects?
-
- Posts: 6
- Joined: July 23rd, 2012, 11:30 pm
Can I make text displace or see trough objects?
Last edited by smurfier on July 25th, 2012, 6:17 pm, edited 1 time in total.
Reason: Changed to use hsimg tags.
Reason: Changed to use hsimg tags.
-
- Moderator
- Posts: 1931
- Joined: January 29th, 2010, 1:43 am
- Location: Willmar, MN
Re: Can I make text displace or see trough objects?
What you ask is not currently possible with Rainmeter. You would need to create the static text as an image that way using the .png format.
GitHub | DeviantArt | Tumblr
This is the song that never ends. It just goes on and on my friends. Some people started singing it not knowing what it was, and they'll continue singing it forever just because . . .
This is the song that never ends. It just goes on and on my friends. Some people started singing it not knowing what it was, and they'll continue singing it forever just because . . .
-
- Posts: 6
- Joined: July 23rd, 2012, 11:30 pm
Re: Can I make text displace or see trough objects?
So if I remove the "%" part, I should be good? But what then? How can I make the bar-image displace the background image?smurfier wrote:What you ask is not currently possible with Rainmeter. You would need to create the static text as an image that way using the .png format.
-
- Developer
- Posts: 22632
- Joined: April 19th, 2009, 11:02 pm
- Location: Fort Hunt, Virginia, USA
Re: Can I make text displace or see trough objects?
There really is not. While you can have transparent text, there is no way to have that text be a "mask" to cause transparency on an underlying meter (bar, image or otherwise).
In addition, there is no easy way to have part of a string meter have different attributes than any other part of the meter. There is only one FontColor, FontSize, etc allowed per meter.
Sometimes you can do some clever stuff with multiple meters that are positioned in a relative way to give the appearance of a single meter with "inline" formatting, but this is both reasonably tricky to pull off in a dynamic measure-driven way, and won't help much with your situation as the overall effect you are going for is just not possible.
About the only thing you could do is create 100 images with the bar, the transparent text and the solid text all incorporated into the image.
In addition, there is no easy way to have part of a string meter have different attributes than any other part of the meter. There is only one FontColor, FontSize, etc allowed per meter.
Sometimes you can do some clever stuff with multiple meters that are positioned in a relative way to give the appearance of a single meter with "inline" formatting, but this is both reasonably tricky to pull off in a dynamic measure-driven way, and won't help much with your situation as the overall effect you are going for is just not possible.
About the only thing you could do is create 100 images with the bar, the transparent text and the solid text all incorporated into the image.
-
- Developer
- Posts: 1721
- Joined: July 25th, 2009, 4:47 am
Re: Can I make text displace or see trough objects?
Rainmeter supports transparent PNGs, so if you only need the "CPU:" part to be see-through (like your second example), all you have to do is cut those letters out of a white rectangle in Paint.NET.804R wrote: So if I remove the "%" part, I should be good? But what then? How can I make the bar-image displace the background image?
-
- Developer
- Posts: 22632
- Joined: April 19th, 2009, 11:02 pm
- Location: Fort Hunt, Virginia, USA
Re: Can I make text displace or see trough objects?
Understand of course that that "white rectangle" won't have anything to do with being a "bar" that reacts to a measure. It will just be a static white box with "CPU" cut out of it, and I'm not sure that is where you are trying to go.Kaelri wrote: Rainmeter supports transparent PNGs, so if you only need the "CPU:" part to be see-through (like your second example), all you have to do is cut those letters out of a white rectangle in Paint.NET.
-
- Posts: 6
- Joined: July 23rd, 2012, 11:30 pm
Re: Can I make text displace or see trough objects?
But what if the bar is "bellow" the CPU text? Can I have white text appear when the bar is too short to outline the transparent text?Kaelri wrote: Rainmeter supports transparent PNGs, so if you only need the "CPU:" part to be see-through, all you have to do is cut those letters out of a white rectangle in Paint.NET (or your image editor of choice).
-
- Developer
- Posts: 22632
- Joined: April 19th, 2009, 11:02 pm
- Location: Fort Hunt, Virginia, USA
Re: Can I make text displace or see trough objects?
No, not really. I theory you could have two meters, one the image and another the solid text. Then you would have to make a determination of some percentages involved, use ImageCrop http://rainmeter.net/cms/Meters-Image_beta on the image-based first meter to only display some part of it, then use relative positioning to have the second measure-driven text be right next to it.804R wrote: But what if the bar is "bellow" the CPU text? Can I have white text appear when the bar is too short to outline the transparent text?
The problem is that you would still need a large amount of images to account for any value where any part of the value text needs to be "cut out" as the bar is long enough to include it, and there would be no way at all to have a bar that is at for instance 37% go half-way though some text. So accuracy of the bar becomes an issue.
I would be tempted to compromise. Have an image with just CPU: cut out of a white background. Then have the bar meter be a matching white and start exactly at the end of the CPU: image. Then have the "value" be some interesting color that works nicely when it is on top of the white bar meter or just on the desktop.
-
- Posts: 6
- Joined: July 23rd, 2012, 11:30 pm
Re: Can I make text displace or see trough objects?
I'm considering that compromise of yours, otherwise I'll just take a shortcut and cut out parts of my static wallpaper and use that for text. It'll be a hassle when I want to change my wallpaper, but whatever.jsmorley wrote: No, not really. I theory you could have two meters, one the image and another the solid text. Then you would have to make a determination of some percentages involved, use ImageCrop http://rainmeter.net/cms/Meters-Image_beta on the image-based first meter to only display some part of it, then use relative positioning to have the second measure-driven text be right next to it.
The problem is that you would still need a large amount of images to account for any value where any part of the value text needs to be "cut out" as the bar is long enough to include it, and there would be no way at all to have a bar that is at for instance 37% go half-way though some text. So accuracy of the bar becomes an issue.
I would be tempted to compromise. Have an image with just CPU: cut out of a white background. Then have the bar meter be a matching white and start exactly at the end of the CPU: image. Then have the "value" be some interesting color that works nicely when it is on top of the white bar meter or just on the desktop.
Thanks a lot for your help, all!
-
- Developer
- Posts: 22632
- Joined: April 19th, 2009, 11:02 pm
- Location: Fort Hunt, Virginia, USA
Re: Can I make text displace or see trough objects?
Glad to help.