95b5b26d |
1 | <?php |
d88b6310 |
2 | |
3 | /** |
4 | * dompie_theme.php |
5 | * Name: Greenhouse Effect |
6 | * Author: Joey Bump |
7 | * Date: October 20, 2001 |
8 | * Comment: This theme generates random colors, featuring a |
9 | * light greenish background. |
10 | * |
11 | * Copyright (c) 2000-2002 The SquirrelMail Project Team |
12 | * Licensed under the GNU GPL. For full terms see the file COPYING. |
13 | * |
14 | * $Id$ |
15 | */ |
16 | |
17 | /** seed the random number generator **/ |
18 | sq_mt_randomize(); |
19 | |
ecf5c1bd |
20 | for ($i = 0; $i <= 15; $i++) { |
d88b6310 |
21 | /* background/foreground toggle **/ |
22 | if (($i == 0) || ($i == 3) || ($i == 4) || ($i == 5) |
23 | || ($i == 9) || ($i == 10) || ($i == 12)) { |
24 | /* background */ |
25 | $g = mt_rand(248,255); |
26 | $r = mt_rand(110,248); |
27 | $b = mt_rand(109,$r); |
28 | } else { |
29 | /* text */ |
30 | $cmin = 0; |
31 | $cmax = 96; |
32 | |
33 | /** generate random color **/ |
34 | $b = mt_rand($cmin,$cmax); |
35 | $g = mt_rand($cmin,$cmax); |
36 | $r = mt_rand($cmin,$cmax); |
37 | } |
38 | |
39 | /** set array element as hex string with hashmark (for HTML output) **/ |
1681f4d9 |
40 | $color[$i] = sprintf('#%02X%02X%02X',$r,$g,$b); |
ecf5c1bd |
41 | } |
d88b6310 |
42 | |
43 | |
44 | |
45 | /** |
46 | * Reference from http://www.squirrelmail.org/wiki/CreatingThemes |
47 | * $color[0] = '#xxxxxx'; // Title bar at the top of the page header |
48 | * $color[1] = '#xxxxxx'; // Not currently used |
49 | * $color[2] = '#xxxxxx'; // Error messages (usually red) |
50 | * $color[3] = '#xxxxxx'; // Left folder list background color |
51 | * $color[4] = '#xxxxxx'; // Normal background color |
52 | * $color[5] = '#xxxxxx'; // Header of the message indexi |
53 | * // (From, Date,Subject) |
54 | * $color[6] = '#xxxxxx'; // Normal text on the left folder list |
55 | * $color[7] = '#xxxxxx'; // Links in the right frame |
56 | * $color[8] = '#xxxxxx'; // Normal text (usually black) |
57 | * $color[9] = '#xxxxxx'; // Darker version of #0 |
58 | * $color[10] = '#xxxxxx'; // Darker version of #9 |
59 | * $color[11] = '#xxxxxx'; // Special folders color (INBOX, Trash, Sent) |
60 | * $color[12] = '#xxxxxx'; // Alternate color for message list |
61 | * // Alters between #4 and this one |
62 | * $color[13] = '#xxxxxx'; // Color for quoted text -- > 1 quote |
63 | * $color[14] = '#xxxxxx'; // Color for quoted text -- >> 2 or more |
64 | **/ |
95b5b26d |
65 | |
66 | ?> |