It is currently April 23rd, 2024, 1:40 pm

First Skin Opinions

Get help with creating, editing & fixing problems with skins
User avatar
paulsim
Posts: 9
Joined: December 19th, 2018, 10:14 am
Location: Houston, Texas

First Skin Opinions

Post by paulsim »

This is my first skin which is a basic launcher. Hopefully the attached jpg will help what I have going on... "Gaming" and "Audio/Video" are headers that when moused over will drop down applications (Dopamine, Netflix, WinTV) that will launch with a left click. It's working as intended so far but before I keep adding more categories and applications I wanted to get more experienced eyes on the code to see if I have any extraneous lines or maybe a way to tighten things up. Most of this stuff I just copied from the manual and tweaked not really knowing a lot of what was going on. Just charging ahead to see what happens. It always surprised me when things actually worked as expected upon updating! Anyhow... thanks for any tips, pointers, or advice!

Oh... and yes... you can see the Monstercat visualiser in the shot too. Obviously, not my creation.

Code: Select all

[Rainmeter]
Update=200
MouseLeaveAction=[!HideMeterGroup HoverGroup1][!HideMeterGroup HoverGroup2]

[Metadata]
Name=Drop Pop
Author=PJSimmons
Information=Launcher for applications in a hidden dropdown style.

[MyTextStyle]
FontFace=SF Fourche
FontColor=125,125,125
FontSize=20
AntiAlias=1
H=45
SolidColor=0,0,0,1

;------------------------------Background------------------------
[Background]
Meter=Shape
Shape=Rectangle 0,0,2200,36 | Fill Color 50,50,50,100 | Stroke Color 0,0,0

;------------------------------Title1---------------------------
[Title1]
Meter=STRING
MeterStyle=MyTextStyle
Text=Gaming
MouseOverAction=[!ShowMeterGroup HoverGroup1][!Redraw]

;------------------------------GamingHovers--------------------------

[HoverArma]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup1
x=25
y=45r
Text=ARMA
LeftMouseUpAction=["M:\Steam Installation\steamapps\common\Arma 3\arma3launcher.exe"]
MouseOverAction=[!ShowMeterGroup HoverGroup1][!Redraw]

[HoverTeamspeak]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup1
x=0r
y=45r
Text=TeamSpeak
LeftMouseUpAction=["C:\Program Files\TeamSpeak 3 Client\ts3client_win64.exe"]
MouseOverAction=[!ShowMeterGroup HoverGroup1][!Redraw]

;--------------------------------Title2----------------------
[Title2]
Meter=STRING
MeterStyle=MyTextStyle
x=200
Text=Audio/Video
MouseOverAction=[!ShowMeterGroup HoverGroup2][!Redraw]

;------------------------------Audio/VideoHovers--------------------------

[HoverDopamine]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup2
x=25r
y=45r
Text=Dopamine
LeftMouseUpAction=["C:\Program Files (x86)\Dopamine\Dopamine.exe"]
MouseOverAction=[!ShowMeterGroup HoverGroup2][!Redraw]

[HoverNetflix]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup2
x=0r
y=45r
Text=Netflix
LeftMouseUpAction=["Netflix:"]
MouseOverAction=[!ShowMeterGroup HoverGroup2][!Redraw]

[HoverWinTV]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup2
x=0r
y=45r
Text=WinTV
LeftMouseUpAction=["C:\Program Files (x86)\WinTV\WinTV8\WinTV8.exe"]
MouseOverAction=[!ShowMeterGroup HoverGroup2][!Redraw]
You do not have the required permissions to view the files attached to this post.
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5406
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: First Skin Opinions

Post by eclectic-tech »

Nice work! 8-)

A few suggestions:

You do not need to [!Redraw] after show/hide; so you can remove those bangs.
You do not need the MouseOverAction in the drop down sections (I commented out those bangs).

Drop down items stay visible when changing to the next top category... just my preference would be to only show items in the currently hovered top category.

To dynamically hide old drop down items and only show the current group, add all drop down sections to a second group (let's call it "Items") and hide that group when you hover over a new top category, and then only show the drop down items related to the currently hovered top category.

The MouseLeaveAction in the [Rainmeter] section will hide all drop down items when you move off the skin.

The only other suggestion would be to change the [Background] shape parameters; since the stroke is 2 pixels by default, half the border is off the screen unless you set X & Y to 1. Also change the shape width to (#ScreenAreaWidth#-2) so the bar fills the users screen and draws the right border.

As I said, just my suggestions... you are the author and have final say on how things work :great:

Here is modified code with those changes.

Code: Select all

[Rainmeter]
Update=200
MouseLeaveAction=[!HideMeterGroup Items]

[Metadata]
Name=Drop Pop
Author=PJSimmons
Information=Launcher for applications in a hidden dropdown style.

[MyTextStyle]
FontFace=SF Fourche
FontColor=125,125,125
FontSize=20
AntiAlias=1
H=45
SolidColor=0,0,0,1

;------------------------------Background------------------------
[Background]
Meter=Shape
X=1
Y=1
Shape=Rectangle 0,0,(#ScreenAreaWidth#-2),36 | Fill Color 50,50,50,100 | Stroke Color 0,0,0

;------------------------------Title1---------------------------
[Title1]
Meter=STRING
MeterStyle=MyTextStyle
Text=Gaming
MouseOverAction=[!HideMeterGroup Items][!ShowMeterGroup HoverGroup1]

;------------------------------GamingHovers--------------------------

[HoverArma]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup1 | Items
x=25
y=45r
Text=ARMA
LeftMouseUpAction=["M:\Steam Installation\steamapps\common\Arma 3\arma3launcher.exe"]
;MouseOverAction=[!ShowMeterGroup HoverGroup1]

[HoverTeamspeak]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup1 | Items
x=0r
y=45r
Text=TeamSpeak
LeftMouseUpAction=["C:\Program Files\TeamSpeak 3 Client\ts3client_win64.exe"]
;MouseOverAction=[!ShowMeterGroup HoverGroup1]

;--------------------------------Title2----------------------
[Title2]
Meter=STRING
MeterStyle=MyTextStyle
x=200
Text=Audio/Video
MouseOverAction=[!HideMeterGroup Items][!ShowMeterGroup HoverGroup2]

;------------------------------Audio/VideoHovers--------------------------

[HoverDopamine]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup2 | Items
x=25r
y=45r
Text=Dopamine
LeftMouseUpAction=["C:\Program Files (x86)\Dopamine\Dopamine.exe"]
;MouseOverAction=[!ShowMeterGroup HoverGroup2]

[HoverNetflix]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup2 | Items
x=0r
y=45r
Text=Netflix
LeftMouseUpAction=["Netflix:"]
;MouseOverAction=[!ShowMeterGroup HoverGroup2]

[HoverWinTV]
Meter=STRING
Hidden=1
MeterStyle=MyTextStyle
Group=HoverGroup2 | Items
x=0r
y=45r
Text=WinTV
LeftMouseUpAction=["C:\Program Files (x86)\WinTV\WinTV8\WinTV8.exe"]
;MouseOverAction=[!ShowMeterGroup HoverGroup2]
User avatar
balala
Rainmeter Sage
Posts: 16162
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: First Skin Opinions

Post by balala »

eclectic-tech wrote: December 19th, 2018, 11:56 am You do not need to [!Redraw] after show/hide; so you can remove those bangs.
Well, yes and no: when a meter is shown / hidden, the skin can be redrawn. It makes sense. Not mandatory, but nor a useless movement isn't. I use it many times.
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5406
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: First Skin Opinions

Post by eclectic-tech »

balala wrote: December 19th, 2018, 1:31 pm Well, yes and no: when a meter is shown / hidden, the skin can be redrawn. It makes sense. Not mandatory, but nor a useless movement isn't. I use it many times.
I'd agree with you, but then we'd both be wrong. ;-)

Sorry, but the bang to show/hide meters or groups does not modify any meter or measure values, so having !Redraw after those bangs is useless; you are redrawing a meter that is currently showing and has not been updated with any changes.

Manual:
"Since by itself !Redraw accomplishes nothing useful, this bang will always be used in conjunction with bangs that update specific things before redrawing the skin. Depending on the case, this might be with !UpdateMeasure bangs to immediately update measure values, and certainly !UpdateMeter bangs to update meter values and options."
User avatar
paulsim
Posts: 9
Joined: December 19th, 2018, 10:14 am
Location: Houston, Texas

Re: First Skin Opinions

Post by paulsim »

Thank you for looking at it. I'll play around with those changes. I want to understand commands more than just make some change and not realise its implications.

The background is probably not done well. It was just a quick idea that turned out to be what I was after. I'll upload a full desktop screen shot this evening. 12 hours from now. I am running three monitors and using Display Fusion. Maybe tonight after I upload a pic of the entire desktop, I can get some help achieving what i am after in a better way.

Thanks again!
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5406
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: First Skin Opinions

Post by eclectic-tech »

paulsim wrote: December 19th, 2018, 2:05 pm Thank you for looking at it. I'll play around with those changes. I want to understand commands more than just make some change and not realise its implications.

The background is probably not done well. It was just a quick idea that turned out to be what I was after. I'll upload a full desktop screen shot this evening. 12 hours from now. I am running three monitors and using Display Fusion. Maybe tonight after I upload a pic of the entire desktop, I can get some help achieving what i am after in a better way.

Thanks again!
Sounds good!

You will find there are many methods to achieve similar results; understanding the reason for each is important so you can decide which to use.

I look forward to seeing your update. :thumbup:
User avatar
balala
Rainmeter Sage
Posts: 16162
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: First Skin Opinions

Post by balala »

eclectic-tech wrote: December 19th, 2018, 1:48 pm I'd agree with you, but then we'd both be wrong. ;-)

Sorry, but the bang to show/hide meters or groups does not modify any meter or measure values, so having !Redraw after those bangs is useless; you are redrawing a meter that is currently showing and has not been updated with any changes.

Manual:
"Since by itself !Redraw accomplishes nothing useful, this bang will always be used in conjunction with bangs that update specific things before redrawing the skin. Depending on the case, this might be with !UpdateMeasure bangs to immediately update measure values, and certainly !UpdateMeter bangs to update meter values and options."
No, !Redraw doesn't redraws a meter or group of meters, but the skin itself. When a meter is shown / hidden (with a !ShowMeter / !HideMeter bang) a redraw could be done to immediately see the change (the appearance / disappearance of meter), without having to wait for the next update cycle, when the redraw is automatically made.
And I didn't notice before, but there is a small inadvertence in the help. The !Redraw doesn't make too much sense with !UpdateMeasure. With !UpdateMeter yes, but with !UpdateMeasure not too much, because updating a measure usually doesn't have a visible effect.
User avatar
jsmorley
Developer
Posts: 22629
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: First Skin Opinions

Post by jsmorley »

balala wrote: December 19th, 2018, 2:46 pm No, !Redraw doesn't redraws a meter or group of meters, but the skin itself. When a meter is shown / hidden (with a !ShowMeter / !HideMeter bang) a redraw could be done to immediately see the change (the appearance / disappearance of meter), without having to wait for the next update cycle, when the redraw is automatically made.
And I didn't notice before, but there is a small inadvertence in the help. The !Redraw doesn't make too much sense with !UpdateMeasure. With !UpdateMeter yes, but with !UpdateMeasure not too much, because updating a measure usually doesn't have a visible effect.
The implication in the manual page is that you might want to first !UpdateMeasure to have them get the latest values, then !UpdateMeter to have them get current, then !Redraw to redraw the skin. !UpdateMeasure alone with !Redraw certainly doesn't do much, but the point is that sometimes you need all three, sometimes just !UpdateMeter and !Redraw, but !Redraw alone does nothing useful.

If I'm missing something and there is some error or confusion in the docs, can you link to it and point out the issue?
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5406
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: First Skin Opinions

Post by eclectic-tech »

This skin uses a fairly fast update rate of 200 milliseconds, so my point was that the !Redraw was not really needed.

My question would be: "Do the bangs to !HideMeter or !ShowMeter do that immediately, or only on the next skin update?"

If it takes a skin update to accomplish the bang, and the skin has the default update rate (1000 milliseconds), then !Redraw could be needed. :???:
User avatar
jsmorley
Developer
Posts: 22629
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: First Skin Opinions

Post by jsmorley »

eclectic-tech wrote: December 19th, 2018, 3:15 pm This skin uses a fairly fast update rate of 200 milliseconds, so my point was that the !Redraw was not really needed.

My question would be: "Do the bangs to !HideMeter or !ShowMeter do that immediately, or only on the next skin update?"

If it takes a skin update to accomplish the bang, and the skin has the default update rate (1000 milliseconds), then !Redraw could be needed. :???:
!HideMeter and !ShowMeter take effect on the next regular skin update. However, they do not require an !UpdateMeter if nothing but the visible state has changed, just !Redraw.

LeftMouseUpAction=[!HideMeter MeterOne][!Redraw]