Then not this is the problem.prince1142003 wrote:Should've posted that. I'm using 4.1.0 beta r2824 64-bit (Jul 7 2017).
It is currently September 20th, 2024, 4:13 am
Thread for help with the Shape meter
-
- Rainmeter Sage
- Posts: 16564
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Thread for help with the new Shape meter
-
- Rainmeter Sage
- Posts: 5528
- Joined: April 12th, 2012, 9:40 pm
- Location: Cedar Point, Ohio, USA
Re: Thread for help with the new Shape meter
The radial gradient on your ellipse is behaving a bit strange, but by including the optional settings for offset and radius at zero levels, it seems to behave as expected. Try this code for the ellipse shapes; I modified the radial gradient definition and extended the 'black' out to 1.25 percent so the 'red' is the dominant color of the radial ring.prince1142003 wrote:I'm basically trying to achieve a shadow/glow effect around the circle.
I played with the stroke idea, but the problem is that the stroke is half inside the shape and half outside. If the interior of the shape is semitransparent, and the stroke is also semitransparent, they overlap in the interior region and it doesn't look good.
...
How do I fill the ring shape radially, fading from solid red at 92% to solid black at 100%?
Code: Select all
[BackgroundCircle]
Meter=Shape
Shape=Ellipse 100, 50, 46, 46 | Fill LinearGradient LinearGrad | StrokeWidth 0
Shape2=Ellipse 100, 50, 50, 50 | Fill RadialGradient ShadowGrad | StrokeWidth 0
Shape3=Ellipse 100, 50, 46, 46 | Fill Color 0,0,0,0 | StrokeWidth 0
Shape4=Combine Shape2 | Exclude Shape3
LinearGrad=0 | 0,0,255,128 ; 0 | 0,255,0,128 ; 1
ShadowGrad=100, 50, 0, 0, 0, 0 | 0,0,0,0 ; 0.0 | 0,0,0,0 ; 0.91 | 255,0,0,255 ; 0.92 | 0,0,0,64 ; 1.25
DynamicVariables=1
UpdateDivider=-1
Group=PanelBG
Code: Select all
[BackgroundCircle]
Meter=Shape
Shape=Rectangle 52, 0, 100, 100, 50 | Fill RadialGradient ShadowGrad | StrokeWidth 0
Shape2=Rectangle 54, 4, 92, 92, 46 | Fill LinearGradient1 LinearGrad | StrokeWidth 0
LinearGrad=0 | 0,0,255,128 ; 0 | 0,255,0,128 ; 1
ShadowGrad=100,50 | 0,0,0,0 ; 0.0 | 0,0,0,0 ; 0.91 | 255,0,0,255 ; 0.92 | 0,0,0,64 ; 1.25
DynamicVariables=1
UpdateDivider=-1
Group=PanelBG
Hope this helps.
:: My DA Gallery :: Rainmeter DA Gallery :: Rainmeter Workshops :: Rainmeter Documentation :: BBCode Guide ::
-
- Posts: 919
- Joined: January 30th, 2017, 2:01 am
- Location: Greece
Re: Thread for help with the new Shape meter
Pretty basic question. I wanna make a line that goes from fully transparent to white and fully transparent again.
I'm trying this but I don't think the syntax is correct. I searched in the docs for gradients in the line shape but I didn't find anything.
Also, is it possible to add a gradient in an image meter? If so, what would the syntax be again?
Code: Select all
[MeterLine]
Meter=Shape
Shape=Line 50,0,50,420 | StrokeWidth 2 | Fill LinearGradient1 LinearGrad
LinearGrad=0 | 0,0,255,128 ; 0 | 0,255,0,128 ; 1
Also, is it possible to add a gradient in an image meter? If so, what would the syntax be again?
Code: Select all
[MeterLine2]
Meter=Image
SolidColor=255,255,255,200
W=2
H=420
-
- Rainmeter Sage
- Posts: 16564
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Thread for help with the new Shape meter
EDIT: Sorry if you've read my reply, I just realized I've misunderstood your question: what you've tried to do, I think is not possible. The gradient aren't related to the stroke, but to the fill color. But a Line shape doesn't has a fill color, just a Stroke color.kyriakos876 wrote:I wanna make a line that goes from fully transparent to white and fully transparent again.
-
- Rainmeter Sage
- Posts: 16564
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Thread for help with the new Shape meter
But you can simulate something similar: create a Rectangle shape, instead of a Line one, without a Stroke and use the gradient on its Fill Color option:
I've replaced the first value of the LinearGrad option with 90, because with 0 (as you had it) on the 2 pixels wide "line" (rectangle) shape, the gradient wouldn't be properly visible.
Code: Select all
[MeterLine]
Meter=Shape
Shape=Rectangle 50,0,2,420 | StrokeWidth 0 | Fill LinearGradient LinearGrad
LinearGrad=90 | 0,0,255,128 ; 0 | 0,255,0,128 ; 1
-
- Posts: 919
- Joined: January 30th, 2017, 2:01 am
- Location: Greece
Re: Thread for help with the new Shape meter
Never read your answer so I don't know what you said, but this is correct Thanks.balala wrote:But you can simulate something similar: create a Rectangle shape, instead of a Line one, without a Stroke and use the gradient on its Fill Color option:I've replaced the first value of the LinearGrad option with 90, because with 0 (as you had it) on the 2 pixels wide "line" (rectangle) shape, the gradient wouldn't be properly visible.Code: Select all
[MeterLine] Meter=Shape Shape=Rectangle 50,0,2,420 | StrokeWidth 0 | Fill LinearGradient LinearGrad LinearGrad=90 | 0,0,255,128 ; 0 | 0,255,0,128 ; 1
Final code:
Code: Select all
[MeterLine]
Meter=Shape
Shape=Rectangle 50,0,2,420 | StrokeWidth 0 | Fill LinearGradient LinearGrad
LinearGrad=90 | 255,255,255,0 ; 0 | 255,255,255,255 ; 0.5 | 255,255,255,0 ; 1
-
- Rainmeter Sage
- Posts: 16564
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Thread for help with the new Shape meter
That's good, because as I said, initially I've strongly misunderstood your request. I'm glad if it's working well.kyriakos876 wrote:Never read your answer
-
- Rainmeter Sage
- Posts: 5528
- Joined: April 12th, 2012, 9:40 pm
- Location: Cedar Point, Ohio, USA
Re: Thread for help with the new Shape meter
@ balalabalala wrote:EDIT: Sorry if you've read my reply, I just realized I've misunderstood your question: what you've tried to do, I think is not possible. The gradient aren't related to the stroke, but to the fill color. But a Line shape doesn't has a fill color, just a Stroke color.
I think you overlooked that the Stroke parameter in any shape CAN use a defined gradient as the stroke parameter.
Here is code for what kyriakos876 requested.
Code: Select all
[MeterShapeLine]
Meter=Shape
X=0
Y=0
MyGrad=90 | 0,0,0,1 ; 0.0 | 255,255,255,255 ; 0.5 | 0,0,0,1 ; 1.0
; Shape=Line StartX, StartY, EndX, EndY
Shape=Line 50,0,50,420 | StrokeWidth 2 | Stroke LinearGradient MyGrad
You do not have the required permissions to view the files attached to this post.
:: My DA Gallery :: Rainmeter DA Gallery :: Rainmeter Workshops :: Rainmeter Documentation :: BBCode Guide ::
-
- Rainmeter Sage
- Posts: 16564
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Thread for help with the new Shape meter
Yeah, you're right (again!). I didn't think to this possibility.eclectic-tech wrote:@ balala
I think you overlooked that the Stroke parameter in any shape CAN use a defined gradient as the stroke parameter.
-
- Rainmeter Sage
- Posts: 5528
- Joined: April 12th, 2012, 9:40 pm
- Location: Cedar Point, Ohio, USA
Re: Thread for help with the new Shape meter
It is easy to understand how this could be overlooked... the Shape meter is, by far, the most complicated and powerful meter in Rainmeter.balala wrote:Yeah, you're right (again!). I didn't think to this possibility.
I am still discovering new possibilities a year after it's introduction.
:: My DA Gallery :: Rainmeter DA Gallery :: Rainmeter Workshops :: Rainmeter Documentation :: BBCode Guide ::