forked from tjhrulz/WebNowPlaying
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathExample.ini
More file actions
384 lines (347 loc) · 9.98 KB
/
Example.ini
File metadata and controls
384 lines (347 loc) · 9.98 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
[Rainmeter]
Update=100
BackgroundMode=2
[Metadata]
Name=WebNowPlaying Music Plugin Examples
Author=tjhrulz
Information="Various basic examples of how to use the WebNowPlaying"
Version=0.1.0
License=CC BY-NC-SA 4.0
;This is an example of how to use every info type and bang from version 1.0 or the WebNowPlaying
;Currently I have not setup support to get the rating of the current song this is planned for the next version
;After that if there is demand I may add the ability to get the upcoming songs info and/or the lyrics of the current song
[Variables]
Background=255,255,255
Color=0,0,0
Highlight=222,79,44
;This will get if there is any supported website open and connected
[MeasureStatus]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Status
;Example of how to get the title of the current song, if GPMDP has no song selected or it is closed it will be a blank string.
[MeasureTitle]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Title
UpdateDivider = 5
Substitute="":"N/A"
;Example of how to get the artist of the current song, if GPMDP has no song selected or it is closed it will be a blank string.
[MeasureArtist]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Artist
UpdateDivider = 5
Substitute="":"N/A"
;Example of how to get the album of the current song, if GPMDP has no song selected or it is closed it will be a blank string.
[MeasureAlbum]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Album
UpdateDivider = 5
Substitute="":"N/A"
;Example of how to get the album art of the current song, if GPMDP has no song selected or it is closed it will be a blank string.
;Note: You should not put and onChange event on this measure as it will change twice for each song instead use CoverWebAddress
[MeasureAlbumArt]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Cover
;This will be displayed when the album art is downloading, in this example I have downloaded from GPM the placeholder image but it could be any image
DefaultPath=#@#Images\nocover.png
;This is where the album art will be downloaded to, note if the album does not have album art set it will still download the GPM placeholder album art to here
CoverPath=#@#Images\cover.png
UpdateDivider = 5
;The URL of the currently displayed image
;Note this is updated once a PlayerType=Cover has updated so it is safe to assume that the image has been updated
;Note I am pretty sure if you have more than one PlayerType=Cover it will update when the first one is done, in the future I will try to have this accept a cover plugin and update once that cover plugin is done.
[MeasureAlbumArtAddress]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=CoverWebAddress
UpdateDivider = 5
;This gets how far into the song you are formated in MM:SS
[MeasurePosition]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Position
UpdateDivider = 5
Substitute="":"N/A"
;This gets how long the song is formated in MM:SS
[MeasureDuration]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Duration
UpdateDivider = 5
Substitute="":"N/A"
;This is what percent of the way through the song you are
[MeasureProgress]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Progress
Substitute="":"N/A"
;This is what percent of the way through the song you are
[MeasureVolume]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Volume
Substitute="":"N/A"
;The play state of the player
;0 is no song is selected, this will almost never happen as the plugin retains the last known song in the future I may change it so it clears when the websocket closes but I dont think I want to do that in the event the websocket closes unexpectedly you may want it to keep old data
;1 is playing
;2 is paused
[MeasurePlayPause]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=State
Substitute="0":"Play","1":"Pause","2":"Play","3":"Replay"
;The repeat state of the player
;0 repeat is off
;1 repeat is on repeat only one song
;2 repeat all songs
[MeasureRepeat]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Repeat
;An example of how to change and color the icon based on the repeat state
IfCondition=MeasureRepeat = 0
IfTrueAction=[!SetOption MeterRepeat ImageTint "#Color#"][!SetOption MeterRepeat ImageName "#@#Images\repeat.png"]
IfCondition2=MeasureRepeat = 1
IfTrueAction2=[!SetOption MeterRepeat ImageTint "#Highlight#"][!SetOption MeterRepeat ImageName "#@#Images\repeatOne.png"]
IfCondition3=MeasureRepeat = 2
IfTrueAction3=[!SetOption MeterRepeat ImageTint "#Highlight#"][!SetOption MeterRepeat ImageName "#@#Images\repeat.png"]
;The shuffle state of the player
;0 shuffle is off
;1 shuffle is on
[MeasureShuffle]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Shuffle
;An example of how to color the shuffle icon based on the shuffle state
IfCondition=MeasureShuffle = 0
IfTrueAction=[!SetOption MeterShuffle ImageTint "#Color#"]
IfCondition2=MeasureShuffle = 1
IfTrueAction2=[!SetOption MeterShuffle ImageTint "#Highlight#"]
;The rating of the current song
;-1 is thumbs down
;0 is no rating
;1 is thumbs up
[MeasureRating]
Measure=Plugin
Plugin=WebNowPlaying
PlayerType=Rating
;An example of how to color two rating icons based on the rating
IfCondition=(MeasureRating < 3) && (MeasureRating > 0)
IfTrueAction=[!SetOption MeterThumbsUp ImageTint "#Color#"][!SetOption MeterThumbsDown ImageTint "#Highlight#"]
IfCondition2=MeasureRating > 3
IfTrueAction2=[!SetOption MeterThumbsUp ImageTint "#Highlight#"][!SetOption MeterThumbsDown ImageTint "#Color#"]
IfCondition3=(MeasureRating = 0) || (MeasureRating = 3)
IfTrueAction3=[!SetOption MeterThumbsUp ImageTint "#Color#"][!SetOption MeterThumbsDown ImageTint "#Color#"]
[MeterBG]
Meter=Image
SolidColor=#CurrBG#
h=525
w=250
Group=DynamicColors
[MeterAlbumArt]
Meter=Image
h=250
w=250
MeasureName=MeasureAlbumArt
PreserveAspectRatio=1
;Example of how the bangs work, in this example clicking the album art will set the song to halfway through the song, the number after SetPosition is the percent through the song you want
;Note: the percent internally is an integer so it does not support decimals, same with the standard NowPlaying plugin. If people want it to I could make SetPosition support decimals however.
LeftMouseUpAction=[!CommandMeasure MeasureArtist "SetPosition 50"]
[MeterHeaderCurrent]
Meter=String
Text="Current Song:"
y=R
FontColor=#Color#,255
Group=DynamicColors
[MeterSongInfo]
Meter=String
y=R
h=15
w=250
FontColor=#Color#,255
Group=DynamicColors
MeasureName=MeasureTitle
ClipString=2
[MeterArtistInfo]
Meter=String
y=R
h=15
w=250
FontColor=#Color#,255
Group=DynamicColors
MeasureName=MeasureArtist
ClipString=2
[MeterAlbumInfo]
Meter=String
y=R
h=15
w=250
FontColor=#Color#,255
Group=DynamicColors
MeasureName=MeasureAlbum
ClipString=2
[MeterPrevious]
Meter=Image
ImageName=#@#Images\previous.png
ImageTint=#Color#
X=0
Y=R
W=48
H=48
Group=DynamicColors
;Example of the previous bang
;Note this will go to the begin of the song then go to the previous song
LeftMouseUpAction=[!CommandMeasure MeasurePlayPause "Previous"]
AntiAlias=1
[MeterPlayPause]
Meter=Image
ImageName=#@#images\[MeasurePlayPause].png
ImageTint=#Color#
X=R
Y=r
W=48
H=48
Group=DynamicColors
;Example of the playpause bang
;Note the plugin does not have support for a bang that only plays or only pauses and the standard GPMDP API, in the future if there is demand for them I can extra checks so that they can work
LeftMouseUpAction=[!CommandMeasure MeasurePlayPause "PlayPause"]
DynamicVariables=1
[MeterNext]
Meter=Image
ImageName=#@#Images\Next.png
ImageTint=#Color#
X=R
Y=r
W=48
H=48
Group=DynamicColors
;Example of the next bang, this skips to the next song
LeftMouseUpAction=[!CommandMeasure MeasurePlayPause "Next"]
AntiAlias=1
[MeterRepeat]
Meter=Image
ImageTint=#Color#
X=0
Y=R
W=48
H=48
Group=DynamicColors
;Example of the repeat bang, this toggles the repeat in the order of off -> on -> repeat one
LeftMouseUpAction=[!CommandMeasure MeasurePlayPause "Repeat"]
AntiAlias=1
[MeterShuffle]
Meter=Image
ImageName=#@#Images\shuffle.png
ImageTint=#Color#
X=R
Y=r
W=48
H=48
Group=DynamicColors
;Example of the repeat bang, this toggles the shuffle between off and on
LeftMouseUpAction=[!CommandMeasure MeasurePlayPause "Shuffle"]
AntiAlias=1
[MeterThumbsUp]
Meter=Image
ImageName=#@#Images\thumbsUp.png
ImageTint=#Color#
X=R
Y=r
W=48
H=48
Group=DynamicColors
;Example of the thumbs up bang, this toggles the thumbs up status of the song
LeftMouseDownAction=[!CommandMeasure MeasurePlayPause "ToggleThumbsUp"]
AntiAlias=1
[MeterThumbsDown]
Meter=Image
ImageName=#@#Images\thumbsDown.png
ImageTint=#Color#
X=R
Y=r
W=48
H=48
Group=DynamicColors
;Example of the thumbs down bang, this toggles the thumbs down status of the song
LeftMouseDownAction=[!CommandMeasure MeasurePlayPause "ToggleThumbsDown"]
AntiAlias=1
[MeterVolumeDown]
Meter=Image
ImageName=#@#Images\VolumeDown.png
ImageTint=#Color#
X=0
Y=R
W=48
H=48
Group=DynamicColors
;Example of the volume bang, this decreases the volume by 5%
LeftMouseDownAction=[!CommandMeasure MeasurePlayPause "SetVolume -5"]
AntiAlias=1
[MeterVolumeUp]
Meter=Image
ImageName=#@#Images\VolumeUp.png
ImageTint=#Color#
X=R
Y=r
W=48
H=48
Group=DynamicColors
;Example of the volume bang, this increases the volume by 5%
LeftMouseDownAction=[!CommandMeasure MeasurePlayPause "SetVolume +5"]
AntiAlias=1
[MeterPositionBack]
Meter=Image
ImageName=#@#Images\seekBack.png
ImageTint=#Color#
X=R
Y=r
W=48
H=48
Group=DynamicColors
;Example of the volume bang, this decreases the volume by 5%
LeftMouseDownAction=[!CommandMeasure MeasurePlayPause "SetPosition -5"]
AntiAlias=1
[MeterPositionForward]
Meter=Image
ImageName=#@#Images\seekForward.png
ImageTint=#Color#
X=R
Y=r
W=48
H=48
Group=DynamicColors
;Example of the volume bang, this increases the volume by 5%
LeftMouseDownAction=[!CommandMeasure MeasurePlayPause "SetPosition +5"]
AntiAlias=1
[MeterPositionInfo]
Meter=String
y=R
FontColor=#Color#,255
Group=DynamicColors
MeasureName=MeasurePosition
[MeterDurationInfo]
Meter=String
x=R
y=r
FontColor=#Color#,255
Group=DynamicColors
MeasureName=MeasureDuration
[MeterProgress]
Meter=String
y=R
Text=%1%
FontColor=#Color#,255
Group=DynamicColors
MeasureName=MeasureProgress
[MeterVolume]
Meter=String
x=R
y=r
Text=%1%
FontColor=#Color#,255
Group=DynamicColors
MeasureName=MeasureVolume