###############################################################################
# STANDARD SKIN CONFIGURATION FILE                                            #
# Copyright (c) 2010-2021 Tom Keffer <tkeffer@gmail.com>                      #
# See the file LICENSE.txt for your rights.                                   #
###############################################################################

SKIN_NAME = Standard
SKIN_VERSION = 5.0.0b9

###############################################################################

# The following section is for any extra tags that you want to be available in the templates
[Extras]
    
    # This radar image would be available as $Extras.radar_img
    # radar_img = https://radblast.wunderground.com/cgi-bin/radar/WUNIDS_map?station=RTX&brand=wui&num=18&delay=15&type=N0R&frame=0&scale=1.000&noclutter=1&showlabels=1&severe=1
    # This URL will be used as the image hyperlink:
    # radar_url =	https://radar.weather.gov/?settings=v1_eyJhZ2VuZGEiOnsiaWQiOm51bGwsImNlbnRlciI6Wy0xMjEuOTE3LDQ1LjY2XSwiem9vbSI6OH0sImJhc2UiOiJzdGFuZGFyZCIsImNvdW50eSI6ZmFsc2UsImN3YSI6ZmFsc2UsInN0YXRlIjpmYWxzZSwibWVudSI6dHJ1ZSwic2hvcnRGdXNlZE9ubHkiOmZhbHNlfQ%3D%3D#/

    # If you have a Google Analytics ID, uncomment and edit the next line, and
    # the analytics code will be included in your generated HTML files:
    #googleAnalyticsId = UA-12345678-1
    
###############################################################################

# The CheetahGenerator creates files from templates.  This section
# specifies which files will be generated from which template.

[CheetahGenerator]

    # Possible encodings include 'html_entities', 'utf8', 'strict_ascii', or 'normalized_ascii',
    # as well as those listed in https://docs.python.org/3/library/codecs.html#standard-encodings
    encoding = html_entities

    [[SummaryByMonth]]
        # Reports that summarize "by month"
        [[[NOAA_month]]]
            encoding = normalized_ascii
            template = NOAA/NOAA-%Y-%m.txt.tmpl

    [[SummaryByYear]]
        # Reports that summarize "by year"
        [[[NOAA_year]]]
            encoding = normalized_ascii
            template = NOAA/NOAA-%Y.txt.tmpl
        
    [[ToDate]]
        # Reports that show statistics "to date", such as day-to-date,
        # week-to-date, month-to-date, etc.
        [[[day]]]
            template = index.html.tmpl
        
        [[[week]]]
            template = week.html.tmpl
        
        [[[month]]]
            template = month.html.tmpl
        
        [[[year]]]
            template = year.html.tmpl
            
        [[[RSS]]]
            template = RSS/weewx_rss.xml.tmpl
                
        [[[MobileSmartphone]]]
            template = smartphone/index.html.tmpl
            
        [[[MobileTempOutside]]]
            template = smartphone/temp_outside.html.tmpl

        [[[MobileRain]]]
            template = smartphone/rain.html.tmpl

        [[[MobileBarometer]]]
            template = smartphone/barometer.html.tmpl

        [[[MobileWind]]]
            template = smartphone/wind.html.tmpl
            
        [[[MobileRadar]]]
            template = smartphone/radar.html.tmpl
            
###############################################################################

[CopyGenerator]
    
    # This section is used by the generator CopyGenerator

    # List of files to be copied only the first time the generator runs
    copy_once = backgrounds/*, weewx.css, mobile.css, favicon.ico, smartphone/icons/*, smartphone/custom.js
    
    # List of files to be copied each time the generator runs
    # copy_always = 
        

###############################################################################

[ImageGenerator]
    
    # This section lists all the images to be generated, what SQL types are to be included in them,
    # along with many plotting options. There is a default for almost everything. Nevertheless,
    # values for most options are included to make it easy to see and understand the options.
    #
    # Fonts can be anything accepted by the Python Imaging Library (PIL), which includes truetype
    # (.ttf), or PIL's own font format (.pil). Note that "font size" is only used with truetype
    # (.ttf) fonts. For others, font size is determined by the bit-mapped size, usually encoded in
    # the file name (e.g., courB010.pil). A relative path for a font is relative to the SKIN_ROOT.
    # If a font cannot be found, then a default font will be used.
    #
    # Colors can be specified any of three ways:
    #   1. Notation 0xBBGGRR;
    #   2. Notation #RRGGBB; or
    #   3. Using an English name, such as 'yellow', or 'blue'.
    # So, 0xff0000, #0000ff, or 'blue' would all specify a pure blue color.
    
    image_width = 300
    image_height = 180
    image_background_color = "#f5f5f5"
    
    chart_background_color = "#d8d8d8"
    chart_gridline_color = "#a0a0a0"
    
    # Setting to 2 or more might give a sharper image with fewer jagged edges.
    anti_alias = 1
    
    top_label_font_path = font/DejaVuSansMono-Bold.ttf
    top_label_font_size = 10
    
    unit_label_font_path = font/DejaVuSansMono-Bold.ttf
    unit_label_font_size = 10
    unit_label_font_color = "#000000"
    
    bottom_label_font_path = font/DejaVuSansMono-Bold.ttf
    bottom_label_font_size = 12
    bottom_label_font_color = "#000000"
    bottom_label_offset = 3
    
    axis_label_font_path = font/DejaVuSansMono-Bold.ttf
    axis_label_font_size = 10
    axis_label_font_color = "#000000"
    
    # Options for the compass rose, used for progressive vector plots
    rose_label = N
    rose_label_font_path = font/DejaVuSansMono-Bold.ttf
    rose_label_font_size  = 10
    rose_label_font_color = "#000000"

    # Default colors for the plot lines. These can be overridden for
    # individual lines using option 'color'
    chart_line_colors = "#4282b4", "#b44242", "#42b442"
    
    # Type of line. Only 'solid' or 'none' is offered now
    line_type = 'solid'

    # Size of marker in pixels
    marker_size = 8
    # Type of marker. Pick one of 'cross', 'x', 'circle', 'box', or 'none'
    marker_type ='none'
    
    # Default fill colors for bar charts. These can be overridden for
    # individual bar plots using option 'fill_color'
    chart_fill_colors = "#72b2c4", "#c47272", "#72c472"
        
    # The following option merits an explanation. The y-axis scale used for
    # plotting can be controlled using option 'yscale'. It is a 3-way tuple,
    # with values (ylow, yhigh, min_interval). If set to "None", a parameter is
    # set automatically, otherwise the value is used. However, in the case of
    # min_interval, what is set is the *minimum* y-axis tick interval. 
    yscale = None, None, None

    # For progressive vector plots, you can choose to rotate the vectors.
    # Positive is clockwise.
    # For my area, westerlies overwhelmingly predominate, so by rotating
    # positive 90 degrees, the average vector will point straight up.
    vector_rotate = 90

    # This defines what fraction of the difference between maximum and minimum
    # horizontal chart bounds is considered a gap in the samples and should not
    # be plotted.
    line_gap_fraction = 0.05

    # This controls whether day/night bands will be shown. They only look good
    # on the day and week plots.
    show_daynight = true
    # These control the appearance of the bands if they are shown.
    # Here's a monochrome scheme:
    daynight_day_color   = "#dfdfdf"
    daynight_night_color = "#bbbbbb"
    daynight_edge_color  = "#d0d0d0"
    # Here's an alternative, using a blue/yellow tint:
    #daynight_day_color   = "#fffff8"
    #daynight_night_color = "#f8f8ff"
    #daynight_edge_color  = "#fff8f8"

    # Default will be a line plot of width 1, without aggregation.
    # Can get overridden at any level.
    plot_type = line
    width = 1
    aggregate_type = none
    time_length = 86400    # == 24 hours

    # What follows is a list of subsections, each specifying a time span, such as a day, week,
    # month, or year. There's nothing special about them or their names: it's just a convenient way
    # to group plots with a time span in common. You could add a time span [[biweek_images]] and
    # add the appropriate time length, aggregation strategy, etc., without changing any code.
    #
    # Within each time span, each sub-subsection is the name of a plot to be generated for that
    # time span. The generated plot will be stored using that name, in whatever directory was
    # specified by option 'HTML_ROOT' in weewx.conf.
    #
    # With one final nesting (four brackets!) is the sql type of each line to be included within
    # that plot.
    #
    # Unless overridden, leaf nodes inherit options from their parent.
    
    [[day_images]]
        x_label_format = %H:%M
        bottom_label_format = %x %X
        time_length = 27h
        
        [[[daybarometer]]]
            [[[[barometer]]]]
        
        [[[daytempdew]]]
            [[[[outTemp]]]]
            [[[[dewpoint]]]]
        
        [[[daytempchill]]]
            [[[[windchill]]]]
            [[[[heatindex]]]]

        [[[dayhumidity]]]
            [[[[outHumidity]]]]

        [[[dayrain]]]
            # Make sure the y-axis increment is at least 0.02 for the rain plot
            yscale = None, None, 0.02
            plot_type = bar
            [[[[rain]]]]
                aggregate_type = sum
                aggregate_interval = 1h
                label = Rain (hourly total)
                
        [[[dayrx]]]
            [[[[rxCheckPercent]]]]
        
        [[[daywind]]]
            [[[[windSpeed]]]]
            [[[[windGust]]]]
        
        [[[dayinside]]]
            [[[[inTemp]]]]
        
        [[[daywinddir]]]
            # Hardwire in the y-axis scale for wind direction
            yscale = 0.0, 360.0, 45.0
            [[[[windDir]]]]
    
        [[[daywindvec]]]
            [[[[windvec]]]]
                plot_type = vector

        [[[dayradiation]]]
            [[[[radiation]]]]
            [[[[radiation_max]]]]
                data_type = radiation
                aggregate_type = max
                aggregate_interval = 1h
                label = max

        [[[dayuv]]]
            yscale = 0, 16, 1
            [[[[UV]]]]
            [[[[UV_max]]]]
                data_type = UV
                aggregate_type = max
                aggregate_interval = 1h
                label = max
            
    [[week_images]]
        x_label_format = %d
        bottom_label_format = %x %X
        time_length = 1w
        aggregate_type = avg
        aggregate_interval = 1h
        
        [[[weekbarometer]]]
            [[[[barometer]]]]
        
        [[[weektempdew]]]
            [[[[outTemp]]]]
            [[[[dewpoint]]]]
        
        [[[weektempchill]]]
            [[[[windchill]]]]
            [[[[heatindex]]]]
        
        [[[weekhumidity]]]
            [[[[outHumidity]]]]

        [[[weekrain]]]
            yscale = None, None, 0.02
            plot_type = bar
            [[[[rain]]]]
                aggregate_type = sum
                aggregate_interval = 1d
                label = Rain (daily total)
        
        [[[weekrx]]]
            [[[[rxCheckPercent]]]]
        
        [[[weekwind]]]
            [[[[windSpeed]]]]
            [[[[windGust]]]]
                aggregate_type = max
        
        [[[weekinside]]]
            [[[[inTemp]]]]
        
        [[[weekwinddir]]]
            yscale = 0.0, 360.0, 45.0
            [[[[wind]]]]
                aggregate_type = vecdir
    
        [[[weekwindvec]]]
            [[[[windvec]]]]
                plot_type = vector

        [[[weekradiation]]]
            [[[[radiation]]]]
            [[[[radiation_max]]]]
                data_type = radiation
                aggregate_type = max
                label = max

        [[[weekuv]]]
            yscale = 0, 16, 1
            [[[[UV]]]]
            [[[[UV_max]]]]
                data_type = UV
                aggregate_type = max
                label = max

    [[month_images]]
        x_label_format = %d
        bottom_label_format = %x %X
        time_length = 30d
        aggregate_type = avg
        aggregate_interval = 3h
        show_daynight = false
        
        [[[monthbarometer]]]
            [[[[barometer]]]]
        
        [[[monthtempdew]]]
            [[[[outTemp]]]]
            [[[[dewpoint]]]]
        
        [[[monthtempchill]]]
            [[[[windchill]]]]
            [[[[heatindex]]]]
        
        [[[monthhumidity]]]
            [[[[outHumidity]]]]

        [[[monthrain]]]
            yscale = None, None, 0.02
            plot_type = bar
            [[[[rain]]]]
                aggregate_type = sum
                aggregate_interval = 1d
                label = Rain (daily total)
        
        [[[monthrx]]]
            [[[[rxCheckPercent]]]]
        
        [[[monthwind]]]
            [[[[windSpeed]]]]
            [[[[windGust]]]]
                aggregate_type = max
        
        [[[monthinside]]]
            [[[[inTemp]]]]
        
        [[[monthwinddir]]]
            yscale = 0.0, 360.0, 45.0
            [[[[wind]]]]
                aggregate_type = vecdir
    
        [[[monthwindvec]]]
            [[[[windvec]]]]
                plot_type = vector

        [[[monthradiation]]]
            [[[[radiation]]]]
            [[[[radiation_max]]]]
                data_type = radiation
                aggregate_type = max
                label = max

        [[[monthuv]]]
            yscale = 0, 16, 1
            [[[[UV]]]]
            [[[[UV_max]]]]
                data_type = UV
                aggregate_type = max
                label = max

    [[year_images]]
        x_label_format = %m/%d
        bottom_label_format = %x %X
        time_length = 365d
        aggregate_type = avg
        aggregate_interval = 1d
        show_daynight = false
        
        [[[yearbarometer]]]
            [[[[barometer]]]]
        
        
        [[[yeartempdew]]]
            [[[[outTemp]]]]
            [[[[dewpoint]]]]
        
        [[[yearhumidity]]]
            [[[[outHumidity]]]]

        # Daily high/lows:
        [[[yearhilow]]]
            [[[[hi]]]]
                data_type = outTemp
                aggregate_type = max
                label = High
            [[[[low]]]]
                data_type = outTemp
                aggregate_type = min
                label = Low Temperature
                
        [[[yearwind]]]
            [[[[windSpeed]]]]
            [[[[windGust]]]]
                aggregate_type = max
        
        [[[yeartempchill]]]
            [[[[windchill]]]]
            [[[[heatindex]]]]
        
        [[[yearrain]]]
            yscale = None, None, 0.02
            plot_type = bar
            [[[[rain]]]]
                aggregate_type = sum
                aggregate_interval = 1w
                label = Rain (weekly total)
        
        [[[yearrx]]]
            [[[[rxCheckPercent]]]]
        
        [[[yearinside]]]
            [[[[inTemp]]]]
        
        [[[yearwinddir]]]
            yscale = 0.0, 360.0, 45.0
            [[[[wind]]]]
                aggregate_type = vecdir

        [[[yearwindvec]]]
            [[[[windvec]]]]
                plot_type = vector

        [[[yearradiation]]]
            [[[[radiation]]]]
            [[[[radiation_max]]]]
                data_type = radiation
                aggregate_type = max
                label = max

        [[[yearuv]]]
            yscale = 0, 16, 1
            [[[[UV]]]]
            [[[[UV_max]]]]
                data_type = UV
                aggregate_type = max
                label = max

        # A progressive vector plot of daily gust vectors overlayed
        # with the daily wind average would look something like this:
#        [[[yeargustvec]]]
#            [[[[windvec]]]]
#                plot_type = vector
#                aggregate_type = avg
#            [[[[windgustvec]]]]
#                plot_type = vector
#                aggregate_type = max


###############################################################################

#
# The list of generators that are to be run:
#
[Generators]
        generator_list = weewx.cheetahgenerator.CheetahGenerator, weewx.imagegenerator.ImageGenerator, weewx.reportengine.CopyGenerator


