Make WordPress Core

Ticket #23790: 23790.diff

File 23790.diff, 1.9 KB (added by obenland, 12 years ago)
  • wp-content/themes/twentytwelve/inc/custom-header.php

     
    2121function twentytwelve_custom_header_setup() {
    2222        $args = array(
    2323                // Text color and image (empty to use none).
    24                 'default-text-color'     => '444',
     24                'default-text-color'     => '515151',
    2525                'default-image'          => '',
    2626
    2727                // Set height and width, with a maximum value for the width.
     
    4747add_action( 'after_setup_theme', 'twentytwelve_custom_header_setup' );
    4848
    4949/**
     50 * Loads our special font CSS file.
     51 *
     52 * @since Twenty Twelve 1.2
     53 *
     54 * @return void
     55 */
     56function twentytwelve_custom_header_fonts() {
     57        $fonts_url = twentytwelve_get_font_url();
     58        if ( ! empty( $fonts_url ) )
     59                wp_enqueue_style( 'twentytwelve-fonts', esc_url_raw( $fonts_url ), array(), null );
     60}
     61add_action( 'admin_print_styles-appearance_page_custom-header', 'twentytwelve_custom_header_fonts' );
     62
     63/**
    5064 * Styles the header text displayed on the blog.
    5165 *
    5266 * get_header_textcolor() options: 444 is default, hide text (returns 'blank'), or any hex value.
     
    96110        <style type="text/css">
    97111        .appearance_page_custom-header #headimg {
    98112                border: none;
     113                font-family: "Open Sans", ​Helvetica,​ Arial, ​sans-serif;
    99114        }
    100115        #headimg h1,
    101116        #headimg h2 {
    102                 line-height: 1.6;
     117                line-height: 1.84615;
    103118                margin: 0;
    104119                padding: 0;
    105120        }
    106121        #headimg h1 {
    107                 font-size: 30px;
     122                font-size: 26px;
    108123        }
    109124        #headimg h1 a {
    110125                color: #515151;
    111126                text-decoration: none;
    112127        }
    113128        #headimg h1 a:hover {
    114                 color: #21759b;
     129                color: #21759b !important; /* Has to override custom inline style. */
    115130        }
    116131        #headimg h2 {
    117132                color: #757575;
    118                 font: normal 13px/1.8 "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", sans-serif;
     133                font-size: 13px;
    119134                margin-bottom: 24px;
    120135        }
    121136        #headimg img {