It is currently April 18th, 2024, 10:53 pm

Need help with Greeting Format!

Get help with creating, editing & fixing problems with skins
Mel21
Posts: 2
Joined: October 20th, 2020, 11:17 am

Need help with Greeting Format!

Post by Mel21 »

Hi. So I'm quite new to Rainmeter and cant figure out how to get the greeting text into one line. Currently, the greeting is "Good Afternoon" and then my username in the next line below it. I want it in the same line, i.e. Good Afternoon, (username)!

I'm using the ClockWorld Skin by Evans (https://github.com/ervans589/ClockWorld-for-Rainmeter/releases). This is the code for the same

Code: Select all

[Rainmeter]
Update=-1
OnWakeAction=[!Refresh]

[Metadata]
Author=Evans Stenakis
License=Creative Commons Attribution - Non - Commercial - Share Alike 3.0
Version=Final
Information=ClockWorld Profile

[Variables]
@include=#@#Variables.inc
S=100
Font=Beckman Free

;;-------------------------------------------

[BG]
Meter=Image
ImageName=#UserImagePath#
MaskImageName=#@#Particles\User\Circle.png
W=#S#
H=#S#
X=((#SCREENAREAWIDTH# / 2) - 50)
Y=(#WORKAREAY# + 40)

;;-------------------------------------------

[MeterMessage]
Meter=String
Text="%1"
FontFace=Tropical Asian Demo
InlineSetting=CharacterSpacing | 1 | 1
AntiAlias=1
FontColor=255,255,255
FontSize=100
StringAlign=Center
StringCase=Upper
X=(#SCREENAREAWIDTH# / 2)
Y=(#WORKAREAY# + 150)
ClipString=1
W=(#SCREENAREAWIDTH#)
AntiAlias=1


[MeasureTime]
Measure=Time
Format=%H

[MeasureText]
Measure=Calc
Formula=MeasureTime
IfCondition=(MeasureTIME >= #MorningHour#) && (MeasureTIME < #NoonHour#)
IfTrueAction=[!SetOption MeterMessage Text "#Morning#"]
IfCondition2=(MeasureTIME >= #NoonHour#) && (MeasureTIME < #AfternoonHour#)
IfTrueAction2=[!SetOption MeterMessage Text "#Noon#"]
IfCondition3=(MeasureTIME >= #AfternoonHour#) && (MeasureTIME < #EveningHour#)
IfTrueAction3=[!SetOption MeterMessage Text "#Afternoon#"]
IfCondition4=(MeasureTIME >= #EveningHour#) && (MeasureTIME < #NightHour#)
IfTrueAction4=[!SetOption MeterMessage Text "#Evening#"]
IfCondition5=(MeasureTIME >= #NightHour#) || (MeasureTIME < #MorningHour#)
IfTrueAction5=[!SetOption MeterMessage Text "#Night#"]

[UserName]
Meter=String
AntiAlias=1
Text=#UserName#
FontColor=255,255,255
FontSize=25
FontWeight=600
FontFace=#Font#
StringAlign=Center
StringCase=Upper
X=(#SCREENAREAWIDTH# / 2)
Y=(#WORKAREAY# + 225)
InlineSetting=CharacterSpacing | 1 | 1
SolidColor=0,0,0,1


[SettingsIcon]
Meter=Image
ImageName=#@#Particles\User\settings1.png
X=((#SCREENAREAWIDTH# / 2) - 12)
Y=(#WORKAREAY# + 125)
W=25
H=25
ImageTint=#Accent#
SolidColor=0,0,0,1
LeftMouseUpAction=[!ActivateConfig "ClockWorld\Settings" "Settings.ini"]

Can someone help me with this please? Thanks a lot in advance!!!
User avatar
SilverAzide
Rainmeter Sage
Posts: 2603
Joined: March 23rd, 2015, 5:26 pm

Re: Need help with Greeting Format!

Post by SilverAzide »

You didn't include the Variables.inc file, which is where the greeting text is located.

To make the change you want, comment out all the lines for the meter [UserName] since you don't want this. Next, open the Variables.inc file and find the "Quotes" section with all the greetings. Change the lines to this:

Code: Select all

Morning=Good Morning, #UserName#!
Noon=Good Noon, #UserName#!
Afternoon=Good Afternoon, #UserName#!
Evening=Good Evening, #UserName#!
Night=Good Night, #UserName#!
Save all the changes and refresh the skin.

P.S.: In this skin, #UserName# (a Rainmeter variable) and %username% (the Windows environment variable) are the same thing, so they are interchangeable. If you want your name to be more formal/formatted, change the line UserName=%username% to something like UserName=Fred Flintstone.
Gadgets Wiki GitHub More Gadgets...
Mel21
Posts: 2
Joined: October 20th, 2020, 11:17 am

Re: Need help with Greeting Format!

Post by Mel21 »

Thank you so much! It works flawlessly. :D
User avatar
balala
Rainmeter Sage
Posts: 16144
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Need help with Greeting Format!

Post by balala »

Mel21 wrote: October 20th, 2020, 4:25 pm Thank you so much! It works flawlessly. :D
SilverAzide's solution probably does, however because your initial skin has the Update option of the [Rainmeter] section set to Update=-1 (which means the skin is not updated), once you get a daytime (morning, for instance) on the skin, this never changes. Recommend to change this option to the default Update=1000. Skins which has to act according to the time of day, are not alright to be set to Update=-1, the default Update being the best idea for these skins.
User avatar
ervans589
Posts: 3
Joined: August 14th, 2020, 10:20 am

Re: Need help with Greeting Format!

Post by ervans589 »

Hello there,
Evans (the developer) here. The Update value is -1 because there is another skin "Wallpapers.ini" which triggers an update command for every timestamp. When the Afternoon for example "time" sets, it will automatically update all .inis