-
Notifications
You must be signed in to change notification settings - Fork 20
/
themes.txt
executable file
·474 lines (376 loc) · 15.6 KB
/
themes.txt
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
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
HOW TO MAKE YOUR OWN THEMES:
Pesterchum 3.14 themes are very flexible and allow you to create
almost any kind of main window you can imagine (notable exception
being animation). This document should help you make your own themes
or make adjustments to existing themes!
Try following along with existing themes -- it'll make this document
much less confusing!
A note on editing existing themes: Don't edit current themes! If you
make changes in the existing themes directory, they *will* be
overwritten when you install any updates.
CREATING A THEME
----------------
Every theme is just a separate directory in the "themes"
directory. That directory contains all the images used in that theme
as well as a "style.js" file which is the configuration file for the
theme.
FORMAT
------
The theme file is unlike most configuration files. It uses a format
called JSON, which at its core looks like this:
{"option": "value", "option2": 5, "category": {"option1": [10, 50] } }
The idea is that it's basically a list of: "name": "value"
separated by commas, inside brackets. So to give another example:
{"color": "red", "size": 50 }
means "color" is "red, and "size" is 50. Note that strings should have
quotes around them and numbers should not. You can also make certain
values into categories by making the value a bracketed list, like so:
{"memos": {"color": "red", "size": 50}, "convos": {"color": "green", "size": 50 } }
This creates two categories: memos and convos, each with their own
color and size value. Also note that spaces don't really matter. It
helps to indent each category:
{"memos": {"color": "red", "size": 50"},
"convos": {"color": "green", "size": 50" }
}
or even
{"memos": {"color": "red",
"size": 50" },
"convos": {"color": "green",
"size": 50" }
}
SETTINGS
--------
INHERITS: You can make writing themes easier on yourself by using the
"inherits" setting. This sets all the settings to be the same as the
inherited theme unless you change it. So you only need to set the
settings you want to change!
When specifying file locations, you use the term "$path" to represent
the path to the current theme. The program will automatically
subtitute the correct location.
A note about styles:
PC3.14 uses Qt's Stylesheets. That means that there are several
options in the style file that use CSS-like options. Most CSS options
are actually available in these settings. See this page for details
about Qt's stylesheets:
http://doc.qt.nokia.com/latest/stylesheet.html
and here for how CSS works:
http://www.w3schools.com/css/default.asp
If you know CSS, note that there is no cascading or need to type in
tag names. The program does this for you.
CSS values are like this:
background:#000000; font: bold;
with name:value; separated by ";".
NOTE that if you change a style from a theme you inherited, you MUST
put in all the options the old style had if you want to keep them!
I'll go over some of the most commonly used options in styles:
background-color: Self-explanatory. A note, though: colors can be
color names ("black"), standard HTML colors ("#000000") or rgba
(red, green, blue, alpha) values ("rgba(0, 34, 151, 75%)").
background-image: Sets the background image to be this image. You
specify the location of the image by using "url(location)". So it
could be: "url($path/background.png)".
background-repeat: Sets how the background should repeat if the area
is larger than the image. Values are repeat-x, repeat-y, repeat, and
no-repeat.
border: Sets the border of the item. Should be in the form "Xpx style
color". Example: "border: 2px solid black;" See reference for styles.
border-top/right/left/bottom: You can specify values for individual
borders the same way by using these. Example: "border-right: 1px solid
#ffff00;"
border-image: This one is complicated. Basically it's a good way of
having a resizable image with borders. See this page for a good
tutorial: http://www.lrbabe.com/sdoms/borderImage/
border-radius: Set this to a certain pixel length to get a rounded
border. Example: "border-radius: 4px;"
color: The color to make text. Example: "color: #ff0000;"
font: A shortcut. You can specify most different font properties from
this setting. Read on...
font-family: A string representing the font name. Be careful as
everyone's computer may not have the same fonts! Popular fonts like
"Arial" are fine. Example: "font-family: 'Arial';" Don't forget the
quotes!
font-size: A font's size in pixels. Example: "font-size: 12px;"
font-style: Basically italic or not. Example: "font-style: italic;"
font-weight: Basically bold or not. Example: "font-weight: bold;"
margin: Sets the amount of space between this object and other
objects. This is really only useful in memo and conversation
settings. You can set individual margins for right/left/top/bottom
by margin-top/left/right/bottom. Examples: "margin-top: 15px;" "margin:
5px;"
max/min-height/width: Sets the maximum/minimum height/width for something.
padding: Same thing as margin, kinda... basically this sets the space
between the outside of the box and the stuff inside it. See
http://doc.qt.nokia.com/latest/stylesheet-customizing.html#the-box-model
for more detail.
selection-color: The color of the text when an item is
selected. Example: "selection-color: black;"
selection-background-color: The color of the background of an item
when it is selected. Example: "selection-background-color: white;"
text-align: Centers, left-justifies, and right-justifies
text. Example: "text-align: center;"
--------
A note about sizes and coordinates:
Wherever it says "size", Pesterchum expects a value of the form [width,
height], where width and height are NUMBERS. No quotes should be
involved. Example:
"size": [232,280]
Same with coordinates, and with coordinates, they are always the
distance away from the top left corner. So [50, 60] would be 50 pixels
to the right and 60 pixels down.
OK, onto the main event:
MAIN
----
"main": { .... }
This is the section that controls the main chum window.
"style": Sets the style of the main window (as above). This value will
affect other parts of the window. DO NOT put a background image
here. You must set that separately; this is necessary to support
themes that are not square (e.g. gold xl).
"background-image": Sets the background image. This will define the
shape of your pesterchum! This is your canvas! See the included themes
for examples of what background images look like.
"size": The size of the window. Usually this is the same as the size
of your background image.
"icon": The file name of the image you want to appear in the tray and
your taskbar. Example: "icon": "$path/trayicon.png"
"newmsgicon": The file name of the image that will appear in the tray
when you have a new message.
"windowtitle": The title of the window.
"close": Category:
"image": Location of the image of the "X" button.
"loc": The coordinates of the "X" button.
Example:
"close": {"image": "$path/x.png", "loc": [210,2]}
"minimize": Category. Same as "close" but for the minimize button.
"menubar": Category. Contains one element:
"style": Style of the main menubar.
"menu": Category.
"style": Style of each individual menu.
"menuitem": Affects each menu item on the main menu. Usually used
for spacing.
"selected": Style information for when you hover over a menu option.
"loc": Location of the main menubar.
"sounds": Category.
"alertsound": Path to the alert sound. Should be a wav.
"ceasesound": Path to the sound when people cease pestering.
"menus": Category. This is where you change the text of the menus.
"client": Category. The client menu.
"_name": The text for the client menu header.
(These are self explanatory:)
"options"
"memos"
"userlist"
"import"
"reconnect"
"idle"
"exit"
"profile": Category. Profile menu.
"_name": Text of the profile menu header.
"switch"
"color"
"theme"
"block"
"quirks"
"help": Category. Help menu.
"_name": Text of the help menu header
"about"
"rclickchumlist": Category. Text for right click menus.
"pester"
"removechum"
"blockchum"
"addchum"
"unblockchum"
"banuser"
"opuser"
"quirksoff"
"chums": Category. Creates your chumroll, where all the users are. All
of them.
"style": Style for the chumroll
"loc": Location of the chumroll
"size": Size of the chumroll
"userlistcolor": Default text color of the users
"moods": Category. Contains a list of mood icons and colors; when a
user has that mood, their handle will appear with that icon and text
color. Basically follows the form "mood": { "icon": "$path/file.png", "color": "colorname" }
Moods are:
"chummy", "rancorous", "offline", "pleasant", "distraught",
"pranky", "smooth", "mystified", "amazed", "insolent", "bemused",
"ecstatic", "relaxed", "discontent", "devious", "sleek",
"detestful", "mirthful", "manipulative", "vigorous", "perky",
"acceptant", "protective", "blocked"
(Note: blocked is not technically a "mood", but the icon is used
when you block someone.)
"trollslum": Category. The settings for the trollslum.
"style": Style for the trollslum.
"size": Size of the window.
"label": Category. Sets the label of the trollslum.
"style": Style of the label.
"text": The text displayed.
"chumroll": Category.
"style": Sets the style for the list of users.
"mychumhandle": Category. Settings for the text label, the user's
current handle, and color swatch.
"label": Category.
"text": Text of label indicating chumhandle.
"loc": Location of label.
"style": Style of label.
"handle": Category. User's current handle.
"style": Style of handle.
"loc": Location of handle.
"size": Size of handle.
"colorswatch": Category. Color swatch.
"loc": Location of swatch.
"size": Size of swatch.
"text": Text displayed inside swatch.
"currentmood": Location of icon of user's current mood.
"defaultwindow": Category.
"style": Style of the default window. (Quirks, profile changer,
etc)
"addchum": Category. Add chum button.
"style": Style of button.
"pressed": Style of button when pressed down.
"loc": Location of button.
"size": Size of button.
"text": Text of button.
The same attributes apply for these categories:
"pester": Button to pester selected user.
"block": Button to block selected user.
"defaultmood": Default mood of this theme.
"moodlabel": Category. Text label indicating mood buttons.
"style": Style of label.
"loc": Location of label.
"text": Text of label.
"moods": OK this can get complicated. Basically this is a list of
categories, one for each mood button present in the interface. You
make a list like this example:
"moods": [{"style": "", "option": "value"}, {"style": "", "option": "value"}]
The square brackets are important!
Anyway, for each mood, here are the possible settings:
"style": Style of the mood button.
"selected": Style of the mood button when selected.
"loc": Location of the mood button.
"size": Size of the mood button.
"text": Text displayed on the mood button.
"icon": Path to icon displayed on the mood button.
"mood": Mood # of the button. See mood numbers -> mood names index
at the end of this document.
CONVO SECTION
-------------
{"main": { ... },
"convo": { ... }
This controls the conversation windows.
"style": Style of the conversation window. Only affects the main
window; does not cascade to the other parts.
"scrollbar": Category. This item is OPTIONAL. It can be a little
complicated: if you add this item, you MUST specify ALL of the
settings yourself. If you don't add this item, it will use default
system scrollbars. If you are inheriting a theme that does have
scrollbar customization and you want to remove it, enter "scrollbar: null".
Anyway, onto the scrollbar options:
"style": General style of whole scrollbar.
"handle": Style for the handle of the scrollbar.
"downarrow": Style for the down arrow.
"darrowstyle": Generally this is where you set the image of the
down arrow with "image:url($path/downarrow.png)".
"uparrow": Same as down arrow.
"uarrowstyle": Same as darrowstyle but for up arrow.
"margins": Category. Sets the margins around the contents of the
conversation window.
"top": Top margin
"bottom", "left", "right"
"size": Initial size of the conversation window.
"chumlabel": Category. The part that says who youre chatting with.
"style": Style for the chumlabel.
"align": Category.
"h": Horizontal alignment
"v": Vertical alignment
"minheight": The minimum height the chum label can be.
"maxheight": The tallest the chum label can be.
"text": The text of the label. Use $handle to represent the name
of the person you're talking to. Example: ":: $handle ::"
"textarea": Category. The window with the pesterlog in it.
"style": Style of the window.
"input": Category. The place where you type.
"style": Style of the input area.
"tabwindow": Category. The window that holds the tabs.
"style": Style of the window.
"tabs": Category. Style of the tabs in tabbed conversation.
"style": Style of the tabs.
"selectedstyle": Style of the currently selected tabs.
"newmsgcolor": The color the text should turn when you get a new
msg.
"tabstyle": Usually 0. See the Qt Stylesheets for more
information.
"text": Category. Flavor text for system messages. In the following
examples, the text in all caps will be replaced with these values:
"beganpester": "<user> BEGAN PESTERING <you> at <time>"
"ceasepester": "<user> CEASED PESTERING <you> at <time>"
"blocked": "<user> BLOCKED <user>"
"unblocked": "<user> UNBLOCKED <user>"
"blockedmsg": "<user> DID NOT RECEIVE MESSAGE FROM <you>"
"openmemo": "<user> OPENED MEMO ON BOARD <memo>"
"joinmemo": "<user> RESPONDED TO MEMO <memo>"
"closememo": "<user> CEASED RESPONDING TO MEMO"
"kickedmemo": "YOU HAVE BEEN BANNED FROM THIS MEMO!"
"idle": "<user> IS NOW AN IDLE CHUM!"
"systemMsgColor": The color of system messages.
MEMOS SECTION
------------
{"main": { .... }
"convo": { .... }
"memos": { .... }
This controls the memos. It is almost identical to conversations,
with a few additions.
"style": Same as convos.
"size": Same as convos.
"tabs": Same as convos.
"scrollbar": Same as convos.
"label": Same as convos.
"input": Same as convos.
"textarea": Same as convos.
"margins": Same as convos.
"userlist": Category. The list of users currently in the memo.
"width": Width.
"style": Style of the userlist.
"time": Category. The time slider area.
"text": Category.
"width": Width of time text.
"style": Style of time text.
"slider": Category. Time slider.
"style": Style of slider.
"groove": Style of the groove of the slider.
"handle": Style of the handle of the slider.
"buttons": Category. Controls the time buttons.
"style": Style of the buttons.
"arrows": Category. Controls the time arrows.
"left": Path to image of left arrow.
"right" Path to image of right arrow.
"style": Style of arrow boxes.
"systemMsgColor": Color of system messges.
"op": Category.
"icon": Icon that is shown next to the ops of the memo in the userlist.
Number -> Mood List
-------------------
0: "chummy"
1: "rancorous"
2: "offline"
3: "pleasant"
4: "distraught"
5: "pranky"
6: "smooth"
7: "ecstatic"
8: "relaxed"
9: "discontent"
10: "devious"
11: "sleek"
12: "detestful"
13: "mirthful"
14: "manipulative"
15: "vigorous"
16: "perky"
17: "acceptant"
18: "protective"
19: "mystified"
20: "amazed"
21: "insolent"
22: "bemused"