]> git.mxchange.org Git - friendica.git/blob - view/theme/quattro/style.php
Merge remote-tracking branch 'upstream/develop' into develop
[friendica.git] / view / theme / quattro / style.php
1 <?php
2         $uid = get_theme_uid();
3
4         $color=false;
5         $quattro_align=false;
6         $site_color = get_config("quattro","color");
7         $site_quattro_align = get_config("quattro", "align" );
8         
9         if ($uid) {
10                 $color = get_pconfig( $uid, "quattro","color");
11                 $quattro_align = get_pconfig( $uid, 'quattro', 'align' );
12         }
13         
14         if ($color===false) $color=$site_color;
15         if ($color===false) $color="dark";
16         if ($quattro_align===false) $quattro_align=$site_quattro_align;
17         
18                 
19         if (file_exists("$THEMEPATH/$color/style.css")){
20                 echo file_get_contents("$THEMEPATH/$color/style.css");
21         }
22
23
24         if($quattro_align=="center"){
25                 echo "
26                         html { width: 100%; margin:0px; padding:0px; }
27                         body {
28                                 margin: 50px auto;
29                                 width: 900px;
30                         }
31                 ";
32         }
33
34     
35
36     $textarea_font_size = false;
37     $post_font_size = false;
38     
39     $site_textarea_font_size = get_config("quattro","tfs");
40     $site_post_font_size = get_config("quattro","pfs");
41     if ($site_textarea_font_size===false) $site_textarea_font_size="20";
42     if ($site_post_font_size===false) $site_post_font_size="12";
43     
44         if ($uid) {
45         $textarea_font_size = get_pconfig( $uid, "quattro","tfs");
46         $post_font_size = get_pconfig( $uid, "quattro","pfs");    
47         } 
48     
49     if ($textarea_font_size===false) $textarea_font_size = $site_textarea_font_size;
50     if ($post_font_size===false) $post_font_size = $site_post_font_size;
51
52     echo "
53         textarea { font-size: ${textarea_font_size}px; }
54         .wall-item-comment-wrapper .comment-edit-text-full { font-size: ${textarea_font_size}px; }
55         #jot .profile-jot-text:focus { font-size: ${textarea_font_size}px; }
56         .wall-item-container .wall-item-content  { font-size: ${post_font_size}px; }
57     ";