text:
<!doctype html>

<meta charset="utf-8">
<meta name="author" content="">
<meta name="keywords" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Funky Tunes | Documentation</title>

<link href="../funky-tunes-css/css/bootstrap.css" media="screen" rel="stylesheet">
<link href="../funky-tunes-css/style.css" media="screen" rel="stylesheet">

<link href="../funky-tunes-css/css/prettyPhoto.css" rel="stylesheet">

<link href="../funky-tunes-css/css/video-js.css" rel="stylesheet">

<link href="../funky-tunes-css/css/jplayer.css" rel="stylesheet">

<link href="css/prettify.css" rel="stylesheet">

<link href="css/docs.css" media="screen" rel="stylesheet">

Funky Tunes UI Kit

                        Version: 1.0
                        Last update: 04.02.2014

What is Funky Tunes

What is included

Browser support

Getting Started

Basic Template

Typography

                            Components

                                    Buttons

Simple Buttons

Transparent Buttons

Different sizes

Shaped Buttons

Buttons with Icons

Buttoned Input

Rating Stars

Scroll Bars

Navigation

Tabs

                            Widgets

Post Tabs

                                    Pricing Items

Pricing style 3

Content Box

Video Player

                                    Audio Players

Circle Player

User Profile

Statistics

Schedule

                                    Charts

Top 3 chart

What is Funky Tunes UI Kit

Funky Tunes UI Kit is a number of useful user interface components built on Bootstrap 3 framework. We did not modify any line of Bootstrap, so you can safely use Funky Tunes UI Kit in your ongoing project.

What is included

Once purchased, unzip the compressed folder to see the directory structure of Funky Tunes UI Kit. You'll see something like this:

funky-tunes
├───docs
│   ├───css
│   ├───images
│   └───js
├───funky-tunes-css
│   ├───css
│   ├───fonts
│   │   └───video-js
│   │   └───icons-small
│   ├───images
│   │   ├───icons
│   │   ├───prettyPhoto
│   │   └───temp
│   └───js
│       └───libs
│       └───jplayer
└───funky-tunes-less
    ├───fonts
    │   └───video-js
    │   └───icons-small
    ├───images
    │   ├───icons
    │   ├───prettyPhoto
    │   └───temp
    ├───js
    │   └───libs
    │   └───jplayer
    └───less
        └───bootstrap

docs/

contains this documentation.

funky-tunes-css/

contains Funky Tunes UI Kit in simple CSS format. Use it to easily start your project.

css/

contains all the stylesheets for CSS version of the kit.

fonts/

contains Bootstrap Glyphicons for CSS version of the kit.

fonts/video-js/

contains Video Player icons for CSS version of the kit.

fonts/icons-small/

contains Font icons for CSS version of the kit.

images/

contains all the images for CSS version of the kit.

images/icons/

contains all the icons for CSS version of the kit.

images/temp/

contains all the temporary images for CSS version of the kit.

js/

contains all the JS files for CSS version of the kit.

funky-tunes-less/

contains Funky Tunes UI Kit in LESS format. Use it to modify this kit in your project.

fonts/

contains Bootstrap Glyphicons for LESS version of the kit.

fonts/video-js/

contains Video Player icons for LESS version of the kit.

fonts/icons-small/

contains Font icons for LESS version of the kit.

images/

contains all the images for LESS version of the kit.

images/icons/

contains all the icons for LESS version of the kit.

images/temp/

contains all the temporary images for LESS version of the kit.

js/

contains all the JS files for LESS version of the kit.

less/

contains all the stylesheets for LESS version of the kit.

Note: The folders funky-tunes-css and funky-tunes-less is fully independent from each other, including all the images and JS files. You can use the version you prefer without pulling images or JS files from the other version of the kit.

Browser support

Since Funky Tunes UI Kit is built on Bootstrap 3 framework, it supports the same browsers as Bootstrap.

Getting Started

To start working with Funky Tunes UI Kit you can use a basic template.html, or take the completely functional pages included in this package. Since it is built on Bootstrap, you can also use it on your project with Bootstrap 3.

                                We provide you both CSS and LESS standalone versions which are completely identical in design and functions.

                                CSS Version: You can use CSS version by dropping contents of funky-tunes-css folder to your project folder and including style.css file in your HTML page: <link href="style.css" media="screen" rel="stylesheet">

                                LESS Version: You can find it in funky-tunes-less folder. Use LESS if you want to modify Funky Tunes UI Kit. We built it Bootstrap way so you won't find big difference. Use less/variables.less to modify different styles, use style.less to remove needless components.

                                If you want to start from scratch, the best way is to use our template where all startup files are already included and ready to be used. You can find template.html file both for CSS and LESS version in their respective folders.

Basic Template

You can use a basic HTML template to write your code, or take completely functional pages included in this package. Basic template as well as completely functional pages are available both for CSS and LESS versions of the Funky Tunes UI Kit.

<!doctype html>
<!--[if lt IE 8 ]><html lang="en" class="ie7"> <![endif]-->
<!--[if IE 8 ]><html lang="en" class="ie8"> <![endif]-->
<!--[if IE 9 ]><html lang="en" class="ie9"> <![endif]-->
<!--[if (gt IE 9)|!(IE)]><!--><html lang="en"> <!--<![endif]-->
    <head>
        <meta charset="utf-8">
        <meta name="author" content="">
        <meta name="keywords" content="">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <title>Funky Tunes | Template</title>

        <!-- main JS libs  -->
        <script src="js/libs/jquery-1.11.0.min.js"></script>
        <script src="js/libs/jquery-ui.min.js"></script>
        <script src="js/libs/bootstrap.min.js"></script>

        <!-- Style CSS -->
        <link href="css/bootstrap.css" media="screen" rel="stylesheet">
        <link href="style.css" media="screen" rel="stylesheet">

        <!-- General Scripts -->
        <script src="js/general.js"></script>

        <!--[if lt IE 9]>
        <script src="js/libs/html5shiv.js"></script>
        <script src="js/libs/respond.min.js"></script>
        <![endif]-->
    </head>

    <body>
        <div class="body-wrap">
            <!-- container-->
            <div class="container">
                Start Your Work Here

            </div>
            <!--/ container-->
        </div>
    </body>
</html>

Typography

                                Funky Tunes UI Kit uses free Open Sans, Allerta and Montserrat webfonts available at the Google Fonts. The global default font-size is 14px, this is applied to the <body>. In addition, all <p> (paragraphs) receive a line height of 24px and bottom margin of 25px.

                                Also, all headings, <h1> through <h6> are available.

Example

Example (h1)

Example (h2)

Example (h3)

Example (h4)

Example (h5)

Example (h6)

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam in dui mauris. Vivamus hendrerit arcu sed erat molestie vehicula. Sed auctor neque eu tellus rhoncus ut eleifend nibh porttitor.

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam in dui mauris. Vivamus hendrerit arcu sed erat molestie vehicula. Sed auctor neque eu tellus rhoncus ut eleifend nibh porttitor. Ut in nulla enim. Phasellus molestie magna non est bibendum non venenatis nisl tempor. Suspendisse dictum feugiat nisl ut dapibus.

<h1>Example (h1)</h1>
<h2>Example (h2)</h2>
<h3>Example (h3)</h3>
<h4>Example (h4)</h4>
<h5>Example (h5)</h5>
<h6>Example (h6)</h6>
<p>Lorem ipsum dolor sit amet.</p>
<p>Lorem ipsum dolor sit amet.</p>

Buttons

Simple Buttons

Use any of the available button classes to quickly create a simple button.

Example

                                Default
                                Green
                                Red
                                All Capitals

<a href="#" class="btn"><span>Default</span></a>
<a href="#" class="btn btn-white"><span>White</span></a>
<a href="#" class="btn btn-gray"><span>Gray</span></a>
<a href="#" class="btn btn-round"><span>Rounded</span></a>
<a href="#" class="btn btn-caps"><span>All Capitals</span></a>

Transparent Buttons

Example

                                Prev
                                Download all files
                                Next

<a href="#" class="btn btn-left btn-transparent"><span>Prev</span></a>
<a href="#" class="btn btn-transparent"><span>Download all files</span></a>
<a href="#" class="btn btn-right btn-transparent"><span>Next</span></a>

Buttons with Different Sizes

Two button sizes available.

Example

                                Default Button
                                Large Button

<a href="#" class="btn"><span>Default Button</span></a>
<a href="#" class="btn btn-large"><span>Large Button</span></a>

Shaped Buttons

Buttons with left and right pointers.

Example

                                Prev
                                Download all files
                                Next

                                Prev
                                Download all files
                                Next

                                Prev
                                Download all files
                                Next

<a href="#" class="btn btn-left"><span>Prev</span></a>
<a href="#" class="btn"><span>Download all files</span></a>
<a href="#" class="btn btn-right"><span>Next</span></a>

<a href="#" class="btn btn-left btn-red"><span>Prev</span></a>
<a href="#" class="btn btn-red"><span>Download all files</span></a>
<a href="#" class="btn btn-right btn-red"><span>Next</span></a>

<a href="#" class="btn btn-left btn-green"><span>Prev</span></a>
<a href="#" class="btn btn-green"><span>Download all files</span></a>
<a href="#" class="btn btn-right btn-green"><span>Next</span></a>

Buttons with Icons

Example

                                Buy Now!
                                Download

<a href="#" class="btn btn-red">
    <span><i class="glyphicon glyphicon-shopping-cart"></i>Buy Now!</span>
</a>

<a href="#" class="btn btn-green">
    <span><i class="glyphicon glyphicon-download-alt"></i>Download</span>
</a>

Buttoned Input

Wrap input type="submit" into span and use available button classes to create a styled Input.

Example

                                <input type="submit" value="Send Message" />

<span class="btn"><input type="submit" value="Send Message" /></span>

Rating Stars

Use rating stars for voting.

Example

<div class="rating clearfix">
    <span class="star voted" rel="1"></span>
    <span class="star voted" rel="2"></span>
    <span class="star voted" rel="3"></span>
    <span class="star voted" rel="4"></span>
    <span class="star" rel="5"></span>
</div>

<div class="rating rating-large clearfix">
    <span class="star voted" rel="1"></span>
    <span class="star voted" rel="2"></span>
    <span class="star voted" rel="3"></span>
    <span class="star" rel="4"></span>
    <span class="star" rel="5"></span>
</div>

Scroll Bars

Create a styled Scroll Bar for your site.

Element specific usage

Styled Scroll Bar require next files to be included into <head> section of the page:

<script src="js/jquery.mousewheel.js"></script>
<script src="js/jquery.jscrollpane.min.js"></script>

Example

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.

<div class="scrollbar">
    ...Content...
</div>

<div class="scrollbar style2">
    ...Content...
</div>

Enable Scroll Bars via JS:

<script>
    jQuery(function() {
        jQuery('.scrollbar').jScrollPane({
            autoReinitialise: true,
            verticalGutter: 0
        });
    });
</script>

Navigation

Website menu with dropdown submenu.

Example

Home

                                        Online Radio

Katy Perry

Miley Cyrus

Selena Gomez

                                        Top 25

Miley Cyrus

Katy Perry

Lene Marlin

                                        TV show

                                                Katy Perry

Album 1

Album 2

Album 3

                                                Miley Cyrus

Album 1

Album 2

Album 3

                                                Selena Gomez

Album 1

Album 2

Album 3

News

Contact Us

<ul class="menu boxed clearfix bg-image-home">
    <li><a href="#"><i class="menu-icon menu-icon-1"></i>Home</a></li>
    <li>
        <a href="#"><i class="menu-icon menu-icon-2"></i>Online Radio</a>
        <ul>
            <li><a href="#">Katy Perry</a></li>
            <li><a href="#">Miley Cyrus</a></li>
            <li><a href="#">Selena Gomez</a></li>
        </ul>
    </li>
    <li>
        <a href="#"><i class="menu-icon menu-icon-3"></i>Top 25</a>
        <ul>
            <li><a href="#">Miley Cyrus</a></li>
            <li><a href="#">Katy Perry</a></li>
            <li><a href="#">Lene Marlin</a></li>
        </ul>
    </li>
    <li>
        <a href="#"><i class="menu-icon menu-icon-4"></i>TV show</a>
        <ul>
            <li>
                <a href="#">Katy Perry</a>
                <ul>
                    <li><a href="#">Album 1</a></li>
                    <li><a href="#">Album 2</a></li>
                    <li><a href="#">Album 3</a></li>
                </ul>
            </li>
            <li>
                <a href="#">Miley Cyrus</a>
                <ul>
                    <li><a href="#">Album 1</a></li>
                    <li><a href="#">Album 2</a></li>
                    <li><a href="#">Album 3</a></li>
                </ul>
            </li>
            <li>
                <a href="#">Selena Gomez</a>
                <ul>
                    <li><a href="#">Album 1</a></li>
                    <li><a href="#">Album 2</a></li>
                    <li><a href="#">Album 3</a></li>
                </ul>
            </li>
        </ul>
    </li>
    <li><a href="#"><i class="menu-icon menu-icon-5"></i>News</a></li>
    <li><a href="#"><i class="menu-icon menu-icon-8"></i>Contact Us</a></li>
</ul>

Tabs

Add quick, dynamic tab functionality to transition through panes of local content.

Example

Photos

Profile

Music

Comments

                                                            Miley Cyrus
                                                            ARTIST PROFILE

7 034

12 980

9 156

                                                            Anna Maria Jopek
                                                            ARTIST PROFILE

7 034

12 980

9 156

                                                            Katy Perry
                                                            ARTIST PROFILE

7 034

12 980

9 156

                                                            Madonna
                                                            ARTIST PROFILE

7 034

12 980

9 156

<div class="tabs-framed tabs-framed-right boxed">
    <ul class="tabs clearfix">
        <li><a href="#profile1" data-toggle="tab"><i class="icon-tab-4"></i>Photos</a></li>
        <li class="active"><a href="#profile2" data-toggle="tab"><i class="icon-tab-5"></i>Profile</a></li>
        <li><a href="#profile3" data-toggle="tab"><i class="icon-tab-6"></i>Music</a></li>
    </ul>
    <div class="tab-content">
        <div class="tab-pane fade" id="profile1">
            ...Content...
        </div>

        <div class="tab-pane fade in active" id="profile2">
            ...Content...
        </div>

        <div class="tab-pane fade" id="profile3">
            ...Content...
        </div>
    </div>
</div>

Tabbed Post Items

Example

Lil Wayne

Bruno mars

Niki Minaj

Selena Gomez

Tim McGraw

Deep Purple

Katy Perry

Miley Cyrus

Christina

Lil Wayne

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Bruno mars

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Niki Minaj

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Selena Gomez

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Tim McGraw

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Deep Purple

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Katy Perry

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Miley Cyrus

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Christina

ARTISTs OF THE WEEK

Praesent magna nunc, tincidunt pretium consequat dapibus, mollis nec odio. Nunc feugiat molestie orci.

Read more

Pricing

Use pricing items to announce prices for your services.

Pricing Items style 3

Example

Full acc

For music lovers

50 000 songs

All profiles

Exclusive

Hot news

                                                    $9
                                                    per month

                                                Buy!

<div class="price-list style3">
    <div class="price-item boxed">
        <div class="price-content bg-image-note4">
            <h3 class="price-title">Full acc</h3>
            <h6 class="price-subtitle">For music lovers</h6>
            <ul>
                <li>50 000 songs</li>
                <li>All profiles</li>
                <li>Exclusive stories</li>
                <li>Hot news</li>
            </ul>
        </div>
        <div class="price">
            <strong><sub>$</sub>9</strong>
            <span>per month</span>
        </div>
        <a href="#" class="btn btn-full btn-large">
            <span><i class="glyphicon glyphicon-shopping-cart"></i>Buy!</span>
        </a>
    </div>
</div>

Content Box

Use titled box to display different content.

Example

Title

SubTitle

<div class="widget-container boxed">
    <div class="inner">
        <h3 class="widget-title">Widget Title</h3>
        <!-- place your content here -->
    </div>
</div>

Video Player

Use Video.js player to play video content.

Element specific usage

Video Player require next files to be included into <head> section of the page:

<link href="css/video-js.css" rel="stylesheet">
<script src="js/video.js"></script>

Example

                                            <video id="video1" controls preload="auto" poster="../funky-tunes-css/images/temp/vjs-poster-4.jpg" class="video-js vjs-styled-skin">
                                                <source src="http://vjs.zencdn.net/v/oceans.mp4" type="video/mp4">
                                                <source src="http://vjs.zencdn.net/v/oceans.webm" type="video/webm">
                                            </video>

<div class="widget-container widget-video boxed">
    <video id="video1" controls preload="auto" poster="images/temp/vjs-poster-4.jpg" class="video-js vjs-styled-skin">
        <source src="http://vjs.zencdn.net/v/oceans.mp4" type="video/mp4">
        <source src="http://vjs.zencdn.net/v/oceans.webm" type="video/webm">
    </video>
</div>

Enable Video Player via JS:

<script>
    videojs("video1", {
        "height": "auto",
        "width": "auto"
    }).ready(function() {
        var myPlayer = this; // Store the video object
        var aspectRatio = 342 / 536; // Make up an aspect ratio
        function resizeVideoJS() {
            // Get the parent element's actual width
            var width = document.getElementById(myPlayer.id()).parentElement.offsetWidth;
            // Set width to fill parent element, Set height
            myPlayer.width(width).height(width * aspectRatio);
        }
        resizeVideoJS(); // Initialize the function
        window.addEventListener("resize", resizeVideoJS, false); // Call the function on resize
    });
</script>

Audio Players

Circle Audio Player

Element specific usage

Circle Audio Player require next files to be included into <head> section of the page:

<link href="css/jplayer.css" rel="stylesheet">
<script src="js/jplayer/jquery.jplayer.min.js"></script>
<script src="js/jplayer/jquery.transform2d.js"></script>
<script src="js/jplayer/jquery.grab.js"></script>
<script src="js/jplayer/mod.csstransforms.min.js"></script>
<script src="js/jplayer/circle.player.js"></script>

Example

play

pause

Picasso Baby

jay-z

                                                mute
                                                unmute

                                                Update Required
                                                Flash plugin

<div id="jquery_jplayer_1" class="jp-jplayer"></div>
<div id="cp_container_1" class="cp-container clearfix">
    <div class="cp-wrap">
        <div class="cp-progress-holder">
            <div class="cp-progress-1"></div>
            <div class="cp-progress-2"></div>
        </div>
        <div class="cp-circle-control"></div>
        <ul class="cp-controls">
            <li><a class="cp-play" tabindex="1">play</a></li>
            <li><a class="cp-pause" style="display:none;" tabindex="1">pause</a></li>
        </ul>
        <div class="jp-current-time"></div>
    </div>
    <div class="jp-controls jp-buttons">
        <div class="song-title">
            <div class="item-song">Picasso Baby</div>
            <div class="item-artist">jay-z</div>
        </div>
        <a href="javascript:;" class="jp-mute" tabindex="1" title="mute">mute</a>
        <a href="javascript:;" class="jp-unmute" tabindex="1" title="unmute">unmute</a>
        <div class="jp-volume-bar"><div class="jp-volume-bar-value"></div></div>
    </div>
    <div class="jp-no-solution">
        <span>Update Required</span>
        <a href="http://get.adobe.com/flashplayer/" target="_blank">Flash plugin</a>
    </div>
</div>

Enable Circle Audio Player via JS:

<script>
    //<![CDATA[
    $(document).ready(function(){

        new CirclePlayer(
            "#jquery_jplayer_1",
            {
                mp3:"http://www.jplayer.org/audio/mp3/Miaow-07-Bubble.mp3",
                oga:"http://www.jplayer.org/audio/ogg/Miaow-07-Bubble.ogg"
            },
            {
                cssSelectorAncestor: "#cp_container_1",
                swfPath: "js/jplayer",
                supplied: "oga, mp3",
                wmode: "window",
                smoothPlayBar: false,
                keyEnabled: false,
                preload: "auto"
            }
        );
    });
    //]]>
</script>

User Profile

Display information about user in a styled box.

Example

Photos

Profile

Music

Comments

                                                            Miley Cyrus
                                                            ARTIST PROFILE

7 034

12 980

9 156

                                                            Anna Maria Jopek
                                                            ARTIST PROFILE

7 034

12 980

9 156

                                                            Katy Perry
                                                            ARTIST PROFILE

7 034

12 980

9 156

                                                            Madonna
                                                            ARTIST PROFILE

7 034

12 980

9 156

<div class="tabs-framed tabs-framed-right boxed widget-container widget-profile">
    <ul class="tabs clearfix">
        <li>
            <a href="#profile5" data-toggle="tab"><i class="icon-tab-4"></i>Photos</a>
        </li>
        <li class="active">
            <a href="#profile6" data-toggle="tab"><i class="icon-tab-5"></i>Profile</a>
        </li>
        <li>
            <a href="#profile7" data-toggle="tab"><i class="icon-tab-6"></i>Music</a>
        </li>
        <li>
            <a href="#profile8" data-toggle="tab"><i class="icon-tab-7"></i>Comments</a>
        </li>
    </ul>

    <div class="tab-content">
        <div class="tab-pane fade" id="profile5">
            <div class="profile-social">
                <a href="#"><span class="icon-small-pinterest"></span></a>
                <a href="#"><span class="icon-small-twitter"></span></a>
                <a href="#"><span class="icon-small-facebook"></span></a>
            </div>
            <div class="profile-image">
                <img src="images/temp/profile-1.jpg" alt="" />
            </div>
            <div class="bottom">
                <div class="profile-desc">
                    <a href="#" class="profile-title">Miley Cyrus</a>
                    <span class="profile-subtitle">ARTIST PROFILE</span>
                </div>
                <ul class="profile-links clearfix">
                    <li class="profile-views">
                        <a href="#"><i class="icon-small-author"></i>7 034</a>
                    </li>
                    <li class="profile-likes">
                        <a href="#"><i class="icon-small-like"></i>12 980</a>
                    </li>
                    <li class="profile-comments">
                        <a href="#"><i class="icon-small-comment"></i>9 156</a>
                    </li>
                </ul>
            </div>
        </div>

        <div class="tab-pane fade in active" id="profile6">
            <div class="profile-social">
                <a href="#"><span class="icon-small-pinterest"></span></a>
                <a href="#"><span class="icon-small-twitter"></span></a>
                <a href="#"><span class="icon-small-facebook"></span></a>
            </div>
            <div class="profile-image">
                <img src="images/temp/profile-2.jpg" alt="" />
            </div>
            <div class="bottom">
                <div class="profile-desc">
                    <a href="#" class="profile-title">Anna Maria Jopek</a>
                    <span class="profile-subtitle">ARTIST PROFILE</span>
                </div>
                <ul class="profile-links clearfix">
                    <li class="profile-views">
                        <a href="#"><i class="icon-small-author"></i>7 034</a>
                    </li>
                    <li class="profile-likes">
                        <a href="#"><i class="icon-small-like"></i>12 980</a>
                    </li>
                    <li class="profile-comments">
                        <a href="#"><i class="icon-small-comment"></i>9 156</a>
                    </li>
                </ul>
            </div>
        </div>

        <div class="tab-pane fade" id="profile7">
            <div class="profile-social">
                <a href="#"><span class="icon-small-pinterest"></span></a>
                <a href="#"><span class="icon-small-twitter"></span></a>
                <a href="#"><span class="icon-small-facebook"></span></a>
            </div>
            <div class="profile-image">
                <img src="images/temp/profile-3.jpg" alt="" />
            </div>
            <div class="bottom">
                <div class="profile-desc">
                    <a href="#" class="profile-title">Katy Perry</a>
                    <span class="profile-subtitle">ARTIST PROFILE</span>
                </div>
                <ul class="profile-links clearfix">
                    <li class="profile-views">
                        <a href="#"><i class="icon-small-author"></i>7 034</a>
                    </li>
                    <li class="profile-likes">
                        <a href="#"><i class="icon-small-like"></i>12 980</a>
                    </li>
                    <li class="profile-comments">
                        <a href="#"><i class="icon-small-comment"></i>9 156</a>
                    </li>
                </ul>
            </div>
        </div>

        <div class="tab-pane fade" id="profile8">
            <div class="profile-social">
                <a href="#"><span class="icon-small-pinterest"></span></a>
                <a href="#"><span class="icon-small-twitter"></span></a>
                <a href="#"><span class="icon-small-facebook"></span></a>
            </div>
            <div class="profile-image">
                <img src="images/temp/profile-4.jpg" alt="" />
            </div>
            <div class="bottom">
                <div class="profile-desc">
                    <a href="#" class="profile-title">Madonna</a>
                    <span class="profile-subtitle">ARTIST PROFILE</span>
                </div>
                <ul class="profile-links clearfix">
                    <li class="profile-views">
                        <a href="#"><i class="icon-small-author"></i>7 034</a>
                    </li>
                    <li class="profile-likes">
                        <a href="#"><i class="icon-small-like"></i>12 980</a>
                    </li>
                    <li class="profile-comments">
                        <a href="#"><i class="icon-small-comment"></i>9 156</a>
                    </li>
                </ul>
            </div>
        </div>
    </div>
</div>

Statistical Data

Statistics widget is based on Google Charts.

Element specific usage

Google Charts require next file to be included into <head> section of the page:

<script src="https://www.google.com/jsapi"></script>

Example

Chart positions

2013

                                                                Passenger
                                                                1sttop
position

                                                                Miley Cyrus
                                                                2dtop
position

                                                                Katy Perry
                                                                3rdtop
position

<div class="widget-container widget-stats boxed boxed-transparent">
    <div class="stats-top">
        <h6 class="widget-title">Chart positions</h6>
        <div class="widget-subtitle">2013</div>
    </div>
    <div class="stats-content fade-effect">
        <div id="stats" class="carousel slide" data-interval="20000">
            <!-- Carousel items -->
            <div class="carousel-inner">

                <div class="item">
                    <div id="graph-1" class="graph"></div>
                    <script type="text/javascript">
                        google.load("visualization", "1", {packages:["corechart"]});
                        google.setOnLoadCallback(drawChart);
                        function drawChart() {
                            var data = google.visualization.arrayToDataTable([
                                ['Month', 'Place', {type: 'string', role: 'tooltip', p: {html:true}}],
                                ['Jan',  3, '<strong>3</strong><span>place</span>'],
                                ['Feb',  1, '<strong>1</strong><span>place</span>'],
                                ['Mar',  5, '<strong>5</strong><span>place</span>'],
                                ['Apr',  8, '<strong>8</strong><span>place</span>'],
                                ['May',  9, '<strong>9</strong><span>place</span>'],
                                ['Jun',  6, '<strong>6</strong><span>place</span>'],
                                ['Jul',  3, '<strong>3</strong><span>place</span>'],
                                ['Aug',  8, '<strong>8</strong><span>place</span>'],
                                ['Sep',  4, '<strong>4</strong><span>place</span>'],
                                ['Oct',  2, '<strong>2</strong><span>place</span>'],
                                ['Nov',  6, '<strong>6</strong><span>place</span>'],
                                ['Dec',  9, '<strong>9</strong><span>place</span>']
                            ]);

                            var options = {
                                curveType: 'function',
                                chartArea:{left:0, top:10, width:"100%"},
                                hAxis: {textStyle: {color: 'transparent', fontSize: 0}},
                                vAxis: {direction: -1, gridlines: {color: 'transparent', count: 0}, baselineColor: 'transparent'},
                                tooltip: {isHtml: true},
                                backgroundColor:{fill: 'transparent'},
                                series: [{
                                    color: '#fff',
                                    visibleInLegend: false,
                                    pointSize: 4,
                                    lineWidth: 3,
                                    areaOpacity: .1
                                }]
                            };

                            var chart = new google.visualization.LineChart(document.getElementById('graph-1'));
                            chart.draw(data, options);

                            $(window).resize(function() {
                                chart.clearChart();
                                chart.draw(data, options);
                            });
                            $('#stats').on('slid.bs.carousel', function () {
                                chart.clearChart();
                                chart.draw(data, options);
                            })
                        }
                    </script>
                    <div class="stats-tab-bottom clearfix">
                        <span class="artist">Passenger</span>
                        <span class="position"><strong>1</strong>st<em>top<br>position</em></span>
                    </div>
                </div>
                ...
                ...
                ...

            </div>
            <!-- Carousel nav -->
            <a class="carousel-control left" href="#stats" data-slide="prev"></a>
            <a class="carousel-control right" href="#stats" data-slide="next"></a>
        </div>
    </div>
</div>

Tour Calendar

Element specific usage

Widget Schedule require next files to be included into <head> section of the page:

<script src="js/jquery.carouFredSel-6.2.1-packed.js"></script>
<script src="js/jquery.touchSwipe.min.js"></script>

Example

Calendar

Kyle
Minouge

january 25th

                                                                Details
                                                                Add to list

Selena
Gomez

MARCH 18th

                                                                Details
                                                                Add to list

Maria
Jopek

MARCH 12th

                                                                Details
                                                                Add to list

                                                ‹
                                                ›

<div class="widget-container widget-schedule clearfix">
    <h2 class="widget-title"><i></i>Calendar</h2>
    <div class="carousel">
        <ul id="schedule">

            <li class="schedule-item clearfix">
                <div class="schedule-left">
                    <div class="schedule-name">Kyle<br />Minouge</div>
                    <div class="schedule-date">january 25th</div>
                    <div class="rating clearfix">
                        <span class="star voted" rel="1"></span>
                        <span class="star voted" rel="2"></span>
                        <span class="star voted" rel="3"></span>
                        <span class="star" rel="4"></span>
                        <span class="star" rel="5"></span>
                    </div>
                </div>
                <div class="schedule-right">
                    <div class="schedule-avatar">
                        <a href="#"><img src="images/temp/schedule-avatar-2.jpg" alt="" /></a>
                    </div>
                    <div class="schedule-links">
                        <a class="schedule-details" href="#"><i class="icon-small-info"></i>Details</a>
                        <a class="schedule-add" href="#"><i class="icon-small-star"></i>Add to list</a>
                    </div>
                </div>
            </li>
            ...
            ...
            ...

        </ul>
        <a class="prev" id="schedule-prev" href="#">‹</a>
        <a class="next" id="schedule-next" href="#">›</a>
    </div>
</div>

Enable Schedule via JS:

<script>
    jQuery(document).ready(function ($) {

        function scheduleInit() {
            $('#schedule').carouFredSel({
                swipe : {
                    onTouch: true
                },
                prev: '#schedule-prev',
                next: "#schedule-next",
                auto: {
                    play: true,
                    timeoutDuration: 16000
                },
                scroll: {
                    pauseOnHover: true,
                    items: 1,
                    duration: 500,
                    easing: 'swing'
                }
            });
        }

        scheduleInit();

        $(window).resize(function() {
            scheduleInit();
        });
    });
</script>

Music Charts

Top 3 Chart

Top 3 songs and video clips.

Example

                                                    1

                                                    Wide AwakeMiley Cyrus
                                                    246

                                                    2

                                                    Bullet proofMadonna
                                                    984

                                                    3

                                                    She WolfRihanna
                                                    896

                                                    1

                                                    She WolfShakira
                                                    593

                                                    2

                                                    Wide AwakeKaty Perry
                                                    412

                                                    3

                                                    Bullet proofBruno Mars
                                                    360

Top3

Music

Videos

<div class="widget-container widget-top3chart boxed">
    <ul class="chart-tab music">
        <li class="clearfix">
            <span class="position">1</span>
            <div class="chart-avatar"><img src="images/temp/thumb-4.jpg" alt="" /></div>
            <a href="#" class="chart-title"><strong>Wide Awake</strong>Miley Cyrus</a>
            <a href="#" class="chart-like">246<i class="icon-small-like"></i></a>
        </li>
        <li class="clearfix">
            <span class="position">2</span>
            <div class="chart-avatar"><img src="images/temp/thumb-6.jpg" alt="" /></div>
            <a href="#" class="chart-title"><strong>Bullet proof</strong>Madonna</a>
            <a href="#" class="chart-like">984<i class="icon-small-like"></i></a>
        </li>
        <li class="clearfix">
            <span class="position">3</span>
            <div class="chart-avatar"><img src="images/temp/thumb-8.jpg" alt="" /></div>
            <a href="#" class="chart-title"><strong>She Wolf</strong>Rihanna</a>
            <a href="#" class="chart-like">896<i class="icon-small-like"></i></a>
        </li>
    </ul>

    <ul class="chart-tab video active">
        <li class="clearfix">
            <span class="position">1</span>
            <div class="chart-avatar"><img src="images/temp/thumb-9.jpg" alt="" /></div>
            <a href="#" class="chart-title"><strong>She Wolf</strong>Shakira</a>
            <a href="#" class="chart-like">593<i class="icon-small-like"></i></a>
        </li>
        <li class="clearfix">
            <span class="position">2</span>
            <div class="chart-avatar"><img src="images/temp/thumb-10.jpg" alt="" /></div>
            <a href="#" class="chart-title"><strong>Wide Awake</strong>Katy Perry</a>
            <a href="#" class="chart-like">412<i class="icon-small-like"></i></a>
        </li>
        <li class="clearfix">
            <span class="position">3</span>
            <div class="chart-avatar"><img src="images/temp/thumb-11.jpg" alt="" /></div>
            <a href="#" class="chart-title"><strong>Bullet proof</strong>Bruno Mars</a>
            <a href="#" class="chart-like">360<i class="icon-small-like"></i></a>
        </li>
    </ul>
    <ul class="chart-links green clearfix">
        <li class="text">Top3</li>
        <li>
            <a href="javascript:;" class="music"><i class="icon-small-note"></i>Music</a>
        </li>
        <li>
            <a href="javascript:;" class="video active"><i class="icon-small-cam"></i>Videos</a>
        </li>
    </ul>
</div>


text:
<?xml version="1.0" encoding="UTF-8"?>
<model model-package="com.dianping.cat.home.router" enable-merger="true"  enable-sax-parser="true"
	enable-base-visitor="true"  enable-json-parser="true" enable-json-builder="true" enable-native-parser="true"  enable-native-builder="true"
	enable-xml-parser="false"  enable-xml-builder="false" >
  <entity name="router-config" root="true">
    <attribute name="startTime" value-type="Date" format="yyyy-MM-dd HH:mm:ss" />
    <attribute name="domain" value-type="String" key="true"/>
    <attribute name="backup-server" value-type="String"/>
    <attribute name="backup-server-port" value-type="int"  primitive="true" />
    <attribute name="endTime" value-type="Date" format="yyyy-MM-dd HH:mm:ss" />
    <entity-ref name="domain" type="map" names="domains" method-find-or-create='true'/>
  </entity>
  <entity name="default-server">
    <attribute name="id" value-type="String" />
    <attribute name="port" value-type="int" primitive="true"/>
    <attribute name="weight" value-type="double" primitive="true" default-value="1"/>
    <attribute name="enable" value-type="boolean" primitive="true"/>
  </entity>
  <entity name="domain">
    <attribute name="id" value-type="String" key="true"/>
    <entity-ref name="server" type="list" names="servers" />
  </entity>
  <entity name="server">
    <attribute name="id" value-type="String"/>
    <attribute name="port" value-type="int" primitive="true" />
    <attribute name="weight" value-type="double" primitive="true" default-value="1"/>
  </entity>
</model>

redpajama_set_name: RedPajamaGithub


text:
test:
	@./node_modules/.bin/mocha --require ./test/init.js --require should test/*.test.js

.PHONY: test
.PHONY: doc
.PHONY: docs


text:
package griffon.builder.javafx;

import griffon.builder.javafx.factory.OctIconFactory;
import griffon.inject.DependsOn;
import groovy.util.Factory;
import org.codehaus.griffon.runtime.groovy.view.AbstractBuilderCustomizer;

import javax.inject.Named;
import java.util.LinkedHashMap;
import java.util.Map;

/**
 * @author Andres Almiray
 */
@DependsOn({"javafx"})
@Named("octicons-javafx")
public class OctIconsJavaFXBuilderCustomizer extends AbstractBuilderCustomizer {
    public OctIconsJavaFXBuilderCustomizer() {
        Map<String, Factory> factories = new LinkedHashMap<>();
        factories.put("octIcon", new OctIconFactory());
        setFactories(factories);
    }
}


text:
// Copyright 2018 by PeopleWare n.v..
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

using System;
using System.Transactions;

using NHibernate;

using IsolationLevel = System.Data.IsolationLevel;

namespace PPWCode.Vernacular.NHibernate.III.Providers
{
    /// <inheritdoc />
    public class TransactionProvider : ITransactionProvider
    {
        /// <inheritdoc />
        public void Run(ISession session, IsolationLevel isolationLevel, Action action)
        {
            Func<int> ActionWrapper()
            {
                return () =>
                       {
                           action.Invoke();
                           return default;
                       };
            }

            Run(session, isolationLevel, ActionWrapper());
        }

        /// <inheritdoc />
        public TResult Run<TResult>(ISession session, IsolationLevel isolationLevel, Func<TResult> func)
        {
            if (session == null)
            {
                throw new ArgumentNullException(nameof(session));
            }

            if (func == null)
            {
                throw new ArgumentNullException(nameof(func));
            }

            if ((session.GetCurrentTransaction()?.IsActive == true) || (Transaction.Current != null))
            {
                return func.Invoke();
            }

            TResult result;
            ITransaction transaction = session.BeginTransaction(isolationLevel);
            try
            {
                result = func.Invoke();
                transaction.Commit();
            }
            catch
            {
                transaction.Rollback();
                throw;
            }
            finally
            {
                transaction.Dispose();
            }

            return result;
        }
    }
}


text:
import os
import shutil

class AtomicFileCreator(object):
    """Atomically create a group of files/directories, with a rollback function
    if any or all of the files exist, or if there is another problem.
    """

    def __init__(self):
        self._files_created = []

    def _rollback(self):
        for file_type, path, _contents in self._files_created:
            if file_type == 'file':
                if os.path.exists(path):
                    os.remove(path)
            elif file_type == 'dir':
                shutil.rmtree(path)

    def create_file(self, file_type, path, contents):
        """
        Create a file or directory.

        :param str file_type:
            "file" or "dir"
        :param str path:
            Path to the file or directory to be created.
        :param str contents:
            Contents of the file. Can be `None` (and is ignored) when
            ``file_type`` is "dir".
        """
        if os.path.exists(path):
            raise IOError("'%s' already exists!" % path)

        if file_type == 'file':
            with open(path, 'w') as fp:
                fp.write(contents)
        elif file_type == 'dir':
            os.makedirs(path)
        else:
            raise ValueError("Invalid file type '%s'!" % file_type)

        self._files_created.append((file_type, path, contents))

    def __enter__(self):
        return self

    def __exit__(self, exc_type, exc_value, _traceback):
        if exc_type is not None:
            self._rollback()
            raise exc_value


text:
namespace Stumps
{
    using System;

    /// <summary>
    ///     An interface for a class that manages a collection of <see cref="Stump"/> objects.
    /// </summary>
    internal interface IStumpsManager : IDisposable
    {
        /// <summary>
        /// Gets the count of Stumps in the collection.
        /// </summary>
        /// <value>
        /// The count of Stumps in the collection.
        /// </value>
        int Count { get; }

        /// <summary>
        ///     Adds a new <see cref="Stump" /> to the collection.
        /// </summary>
        /// <param name="stump">The <see cref="Stump" /> to add to the collection.</param>
        /// <exception cref="ArgumentNullException"><paramref name="stump"/> is <c>null</c>.</exception>
        /// <exception cref="ArgumentException">A <see cref="Stump" /> with the same identifier already exists.</exception>
        void AddStump(Stump stump);

        /// <summary>
        ///     Deletes all stumps from the collection.
        /// </summary>
        void DeleteAll();

        /// <summary>
        ///     Deletes the specified stump from the collection.
        /// </summary>
        /// <param name="stumpId">The  unique identifier for the stump to remove.</param>
        void DeleteStump(string stumpId);

        /// <summary>
        ///     Finds an existing stump.
        /// </summary>
        /// <param name="stumpId">The unique identifier for the Stump.</param>
        /// <returns>
        ///     A <see cref="Stump"/> with the specified <paramref name="stumpId"/>.
        /// </returns>
        /// <remarks>
        ///     A <c>null</c> value is returned if a Stump is not found.
        /// </remarks>
        Stump FindStump(string stumpId);

        /// <summary>
        ///     Finds the Stump that matches an incoming HTTP request.
        /// </summary>
        /// <param name="context">The incoming HTTP request context.</param>
        /// <returns>
        ///     A <see cref="Stump"/> that matches the incoming HTTP request.
        /// </returns>
        /// <remarks>
        ///     A <c>null</c> value is returned if a matching Stump is not found.
        /// </remarks>
        Stump FindStumpForContext(IStumpsHttpContext context);
    }
}


text:
using System;
using System.Runtime.InteropServices;
using Microsoft.Win32.SafeHandles;

internal partial class Interop
{
    internal partial class Kernel32
    {
        public const int FORMAT_MESSAGE_IGNORE_INSERTS = 0x00000200;
        public const int FORMAT_MESSAGE_FROM_HMODULE = 0x00000800;
        public const int FORMAT_MESSAGE_ARGUMENT_ARRAY = 0x00002000;

        [DllImport(Libraries.Kernel32, CharSet = CharSet.Unicode, SetLastError = true, BestFitMapping = true)]
        public static extern unsafe int FormatMessage(
            int dwFlags,
            SafeLibraryHandle lpSource,
            uint dwMessageId,
            int dwLanguageId,
            [Out] char[] lpBuffer,
            int nSize,
            IntPtr[] arguments);
    }
}


text:
/*
 * As
 *
 * 弹性伸缩API
 *
 */

package model

import (
	"encoding/json"

	"strings"
)

// Request Object
type ShowResourceQuotaRequest struct {
}

func (o ShowResourceQuotaRequest) String() string {
	data, _ := json.Marshal(o)
	return strings.Join([]string{"ShowResourceQuotaRequest", string(data)}, " ")
}


text:
package frames

import (
	"io"

	"github.com/SlyMarbo/spdy/common"
)

type NOOP struct{}

func (frame *NOOP) Compress(comp common.Compressor) error {
	return nil
}

func (frame *NOOP) Decompress(decomp common.Decompressor) error {
	return nil
}

func (frame *NOOP) Name() string {
	return "NOOP"
}

func (frame *NOOP) ReadFrom(reader io.Reader) (int64, error) {
	c := common.ReadCounter{R: reader}
	data, err := common.ReadExactly(&c, 8)
	if err != nil {
		return c.N, err
	}

	err = controlFrameCommonProcessing(data[:5], _NOOP, 0)
	if err != nil {
		return c.N, err
	}

	// Get and check length.
	length := int(common.BytesToUint24(data[5:8]))
	if length != 0 {
		return c.N, common.IncorrectDataLength(length, 0)
	}

	return c.N, nil
}

func (frame *NOOP) String() string {
	return "NOOP {\n\tVersion:              2\n}\n"
}

func (frame *NOOP) WriteTo(writer io.Writer) (int64, error) {
	return 0, nil
}


text:
<?php
abstract class custom_controller{
	protected $exp, $_debug, $displayed, $length, $page, $params, $view, $curl, $from;
	protected $view_params = array();
	protected $title_suffix = ' - 在线编程挑战赛';

	public function main($action){
		$pre_run_result = $this->projectPreRun();
		if(!empty($pre_run_result)){
			return $pre_run_result;
		}
		$pre_run_result = $this->preRun();
		if(!empty($pre_run_result)){
			return $pre_run_result;
		}
		$this->page = $this->params->page->getInt();
		$this->curl = $this->getCurl();
		$this->length = 20;
		$this->setTKD();
		$this->assign('page', $this->page);
		$this->assign('curl', $this->curl);
		return $this->$action();
	}

	protected function getCurl(){
		$curl = CURRENT_URL;
		$curl_array = parse_url($curl);
		if(!empty($curl_array['query'])){
			parse_str($curl_array['query'], $query_array);
			//过滤掉当前URL的from参数,以保证此参数不会传递到下一级页面中去
			unset($query_array['from']);
			if(empty($query_array)){
				$curl = substr($curl, 0, strpos($curl, '?'));
			}else{
				$curl_array['query'] = http_build_query($query_array);
				$curl = substr($curl, 0, strpos($curl, '?')) . '?' . $curl_array['query'];
			}
		}
		return rawurlencode($curl);
	}

	abstract protected function preRun();
	abstract protected function projectPreRun();

	protected function assign($key, $value){
		if(strpos($key, '.')){
			$key = explode('.', $key);
			if(count($key) == 2){
				$this->view_params[$key[0]][$key[1]] = $value;
			}
		}else{
			$this->view_params[$key] = $value;
		}
	}

	protected function htmlView($template = ''){
		$view = new custom_view();
		$view->setTemplateData($this->view_params);
		if(empty($template)){
			$template = CONTROLLER . '/' . ACTION . '.html';
		}
		return $view->render($template);
	}

	protected function jsonView($array, $callback = ''){
		$string = json_encode($array);
		if(!empty($callback)){
			$string = "{$callback}({$string});";
		}
		return $string;
	}

	protected function messageView($message = '', $redirect = '', $buttons = array(), $icon = 'win'){
		$redirect = empty($redirect) ? $this->params->from->getValue() : $redirect;
		if(empty($message)){
			header('location: ' . $redirect);
            return 'redirect';
		}
        if(empty($buttons)){
            $buttons = array(
                array(
                    'text'      => '返回',
                    'href'      => $redirect,
                    'class'     => 'return-btn',
                    'highlight' => true,
                ),
                array(
                    'text'      => '返回首页',
                    'href'      => '/',
                    'class'     => 'index-btn',
                    'highlight' => true,
                ),
            );
        }
        if($redirect == '/'){
            $redirect_name = '首页';
        }elseif(stripos($redirect, '/my') !== false){
            $redirect_name = '个人中心';
        }elseif(stripos($redirect, '/user/login') !== false){
            $redirect_name = '登录页面';
        }else{
            $redirect_name = '上个页面';
        }
        $this->assign('message', $message);
        $this->assign('buttons', $buttons);
        $this->assign('icon', $icon);
        $this->assign('redirect_name', $redirect_name);
        return $this->htmlView('public/alert.html');
	}

	protected function setTKD($title = '编程英雄', $keywords = array(), $description = '编程英雄在线编程挑战赛。'){
		$this->setPageTitle($title);
		$this->setPageKeywords($keywords);
		$this->setPageDescription($description);
	}

	protected function setPageTitle($title){
		$this->assign('page_title', "{$title}{$this->title_suffix}");
	}

	protected function setPageKeywords(array $keywords){
        array_unshift($keywords, '编程英雄');
		$this->assign('page_keywords', implode(',', $keywords));
	}

	protected function setPageDescription($description){
		$this->assign('page_description', $description);
	}

	public function __destruct(){
		if(!empty($_GET['debug'])){
			printr($this->view_params);
			printr(custom_db::getInstance()->getQueryStack());
		}
		custom_db::getInstance()->closeAll();
		custom_cache::getInstance()->closeAll();
	}
}


text:
{% extends 'accounts/auth_base.html' %}
{% load crispy_forms_tags %}
{% block title %}{{ block.super }}Sign Up{% endblock %}
{% block form_heading %}Signing Up is Free{% endblock %}
{% block form %}
    <form method="post" action="{{ request.get_full_path }}?next=/">
        {% csrf_token %}

            Email address*

<input autofocus="" class="emailinput form-control" id="id_email" maxlength="255"
                                          name="email" placeholder="Enter Email" type="email"/>

            Name*

<input class="textinput textInput form-control" id="id_name" maxlength="255"
                                          name="name" placeholder="Enter Full Name" type="text"/>

            Password*

<input class="textinput textInput form-control" id="id_password1" name="password1"
                                          placeholder="Enter Password" type="password"/>

            Password confirmation*

<input class="textinput textInput form-control" id="id_password2" name="password2"
                                          placeholder="Re-enter Password" type="password"/>

Enter the same password as above, for verification.

        <input type="submit"
               name="sign_up"
               value="Sign up"

               class="btn btn-primary btn-warning"
               id="submit-id-sign_up"/>
    </form>

Already signed up? Log in.

{% endblock form %}


text:
* `all` defaults to `*`
* option to set `all`


text:
$(document).ready(function(){

// Release 1:
  //Link this script and the jQuery library to the jQuery_example.html file and analyze what this code does.
$('body').css({'background-color': 'pink'});

//RELEASE 2: Link your Code
  bodyElement = $('body');

//RELEASE 3: Selecting Elements with jQuery
$('h1').css({"color": "blue", "border" : "2px solid red", "visibility" : "visible" });

//Release 4: Modify Elements with jQuery
$("div.mascot").find("h1").html("BOBOLINKS");

//RELEASE 5: Event Handlers

 $('img').hover(function(e){
    e.preventDefault()
    $(this).attr('src', 'http://www.birdsgallery.net/gallery/bobolink/bobolink_2.jpg')
  }, function(e){
    e.preventDefault()
    $(this).attr('src', './dbc_logo.png')
  });

// Release 6: Have Some Fun

})  // end of the document.ready function: do not remove or write DOM manipulation below this.

// Reflection:
// What is jQuery?
// It is a JavaScript Library.

// What does jQuery do for you?
// It allows for easier HTML document manipulation,animation, and event handling.

// What did you learn about the DOM while working on this challenge?
// I learned about event handlers, and the different ways to go about accessing child nodes


text:
#ifndef FE_WARP_PIECEWIDE_LINEAR_H
#define FE_WARP_PIECEWIDE_LINEAR_H

#include "sphinxbase/fe.h"

#ifdef __cplusplus
extern "C" {
#endif
#if 0
/* Fool Emacs. */
}
#endif

const char *
fe_warp_piecewise_linear_doc(void);

uint32
fe_warp_piecewise_linear_id(void);

uint32
fe_warp_piecewise_linear_n_param(void);

void
fe_warp_piecewise_linear_set_parameters(char const *param_str, float sampling_rate);

float
fe_warp_piecewise_linear_warped_to_unwarped(float nonlinear);

float
fe_warp_piecewise_linear_unwarped_to_warped(float linear);

void
fe_warp_piecewise_linear_print(const char *label);

#ifdef __cplusplus
}
#endif

#endif /* FE_WARP_PIECEWIDE_LINEAR_H */


text:
require 'wargaming_api/world_of_tanks/tankopedia'

module WargamingApi
  class WargamingApi::WorldOfTanks::Tankopedia
    class WargamingApi::WorldOfTanks::Tankopedia::VehicleDetails < WargamingApi::WorldOfTanks::Tankopedia

      attr_accessor :tank_id

      def initialize
        @language = 'en'
        @application_id = WargamingApi::APP_TOKEN
        @link = 'api.worldoftanks.eu/wot/encyclopedia/tankinfo'
        @tank_id = 1841
      end

      puts 'WorldOfTanks => Tankopedia -> VehicleDetails loaded.'
    end
  end
end


text:
/**
 *
 * This component is the skeleton around the actual pages, and should only
 * contain code that should be seen on all pages. (e.g. navigation bar)
 *
 */

import React from 'react';
import { Switch, Route } from 'react-router-dom';

import pluginId from '../../pluginId';

// Containers
import ConfigPage from '../ConfigPage';
import HomePage from '../HomePage';
import NotFoundPage from '../NotFoundPage';

function App() {
  return (
    <div className={pluginId}>
      <Switch>
        <Route path={`/plugins/${pluginId}/configurations/:env`} component={ConfigPage} exact />
        <Route path={`/plugins/${pluginId}`} component={HomePage} exact />
        <Route component={NotFoundPage} />
      </Switch>
    </div>
  );
}

export default App;


text:
package boofcv.alg.filter.binary;

import android.graphics.BlurMaskFilter;
import android.renderscript.ScriptGroup;

import boofcv.alg.InputSanityCheck;
import boofcv.alg.distort.universal.UniOmniPtoS_F32;
import boofcv.alg.filter.blur.BlurImageOps;
import boofcv.alg.filter.convolve.ConvolveImageMean;
import boofcv.alg.filter.convolve.ConvolveImageNoBorder;
import boofcv.alg.filter.convolve.ConvolveNormalized;
import boofcv.alg.filter.convolve.noborder.ImplConvolveMean;
import boofcv.alg.filter.convolve.normalized.ConvolveNormalizedNaive;
import boofcv.alg.filter.convolve.normalized.ConvolveNormalized_JustBorder;
import boofcv.core.image.GeneralizedImageOps;
import boofcv.factory.filter.kernel.FactoryKernelGaussian;
import boofcv.struct.image.*;
import sapphire.app.SapphireObject;

/**
 *

 * Operations for thresholding images and converting them into a binary image.
 *

 *
 *

 * WARNING: Do not modify.  Automatically generated by GenerateThresholdImageOps.
 *

 *
 * @author Peter Abeles
 */
public class ThresholdImageOps implements SapphireObject {
	public ThresholdImageOps() {}

	/**
	 * Applies a global threshold across the whole image.  If 'down' is true, then pixels with values ≤
	 * to 'threshold' are set to 1 and the others set to 0.  If 'down' is false, then pixels with values >
	 * to 'threshold' are set to 1 and the others set to 0.
	 *
	 * @param input Input image. Not modified.
	 * @param output (Optional) Binary output image. If null a new image will be declared. Modified.
	 * @param threshold threshold value.
	 * @param down If true then the inequality ≤ is used, otherwise if false then > is used.
	 * @return Output image.
	 */
	public GrayU8 threshold(GrayF32 input , GrayU8 output ,
								   float threshold , boolean down, InputSanityCheck ISC, GeneralizedImageOps GIO )
	{
		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]) > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Applies a global threshold across the whole image.  If 'down' is true, then pixels with values ≤
	 * to 'threshold' are set to 1 and the others set to 0.  If 'down' is false, then pixels with values >
	 * to 'threshold' are set to 1 and the others set to 0.
	 *
	 * @param input Input image. Not modified.
	 * @param output (Optional) Binary output image. If null a new image will be declared. Modified.
	 * @param threshold threshold value.
	 * @param down If true then the inequality ≤ is used, otherwise if false then > is used.
	 * @return Output image.
	 */
	public GrayU8 threshold(GrayF64 input , GrayU8 output ,
							double threshold , boolean down, InputSanityCheck ISC, GeneralizedImageOps GIO)
	{
		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]) > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Applies a global threshold across the whole image.  If 'down' is true, then pixels with values ≤
	 * to 'threshold' are set to 1 and the others set to 0.  If 'down' is false, then pixels with values >
	 * to 'threshold' are set to 1 and the others set to 0.
	 *
	 * @param input Input image. Not modified.
	 * @param output (Optional) Binary output image. If null a new image will be declared. Modified.
	 * @param threshold threshold value.
	 * @param down If true then the inequality ≤ is used, otherwise if false then > is used.
	 * @return Output image.
	 */
	public GrayU8 threshold(GrayU8 input , GrayU8 output ,
							int threshold , boolean down , InputSanityCheck ISC, GeneralizedImageOps GIO)
	{
		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]& 0xFF) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]& 0xFF) > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Applies a global threshold across the whole image.  If 'down' is true, then pixels with values ≤
	 * to 'threshold' are set to 1 and the others set to 0.  If 'down' is false, then pixels with values >
	 * to 'threshold' are set to 1 and the others set to 0.
	 *
	 * @param input Input image. Not modified.
	 * @param output (Optional) Binary output image. If null a new image will be declared. Modified.
	 * @param threshold threshold value.
	 * @param down If true then the inequality ≤ is used, otherwise if false then > is used.
	 * @return Output image.
	 */
	public GrayU8 threshold(GrayS16 input , GrayU8 output ,
								   int threshold , boolean down, InputSanityCheck ISC, GeneralizedImageOps GIO)
	{
		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]) > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Applies a global threshold across the whole image.  If 'down' is true, then pixels with values ≤
	 * to 'threshold' are set to 1 and the others set to 0.  If 'down' is false, then pixels with values >
	 * to 'threshold' are set to 1 and the others set to 0.
	 *
	 * @param input Input image. Not modified.
	 * @param output (Optional) Binary output image. If null a new image will be declared. Modified.
	 * @param threshold threshold value.
	 * @param down If true then the inequality ≤ is used, otherwise if false then > is used.
	 * @return Output image.
	 */
	public GrayU8 threshold(GrayU16 input , GrayU8 output ,
								   int threshold , boolean down , InputSanityCheck ISC, GeneralizedImageOps GIO)
	{
		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]& 0xFFFF) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]& 0xFFFF) > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Applies a global threshold across the whole image.  If 'down' is true, then pixels with values ≤
	 * to 'threshold' are set to 1 and the others set to 0.  If 'down' is false, then pixels with values >
	 * to 'threshold' are set to 1 and the others set to 0.
	 *
	 * @param input Input image. Not modified.
	 * @param output (Optional) Binary output image. If null a new image will be declared. Modified.
	 * @param threshold threshold value.
	 * @param down If true then the inequality ≤ is used, otherwise if false then > is used.
	 * @return Output image.
	 */
	public GrayU8 threshold(GrayS32 input , GrayU8 output ,
								   int threshold , boolean down , InputSanityCheck ISC, GeneralizedImageOps GIO)
	{
		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++ ) {
					if( (input.data[indexIn]) > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Thresholds the image using a locally adaptive threshold that is computed using a local square region centered
	 * on each pixel.  The threshold is equal to the average value of the surrounding pixels times the scale.
	 * If down is true then b(x,y) = I(x,y) ≤ T(x,y) * scale ? 1 : 0.  Otherwise
	 * b(x,y) = I(x,y) * scale > T(x,y) ? 0 : 1
	 *
	 * @param input Input image.
	 * @param output (optional) Output binary image.  If null it will be declared internally.
	 * @param radius Radius of square region.
	 * @param scale Scale factor used to adjust threshold.  Try 0.95
	 * @param down Should it threshold up or down.
	 * @param storage1 (Optional) Storage for intermediate step. If null will be declared internally.
	 * @param storage2 (Optional) Storage for intermediate step. If null will be declared internally.
	 * @return Thresholded image.
	 */
	public GrayU8 localSquare(GrayU8 input , GrayU8 output ,
							  int radius , float scale , boolean down ,
							  GrayU8 storage1 , GrayU8 storage2, InputSanityCheck ISC, GeneralizedImageOps GIO, BlurImageOps BIO, ConvolveImageMean CIM,
							  ConvolveNormalized CN, ConvolveNormalizedNaive CNN, ConvolveImageNoBorder CINB, ConvolveNormalized_JustBorder CNJB, ImplConvolveMean ICM) {

		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);
		storage1 = ISC.checkDeclare(input,storage1,GrayU8.class, GIO);
		storage2 = ISC.checkDeclare(input,storage2,GrayU8.class, GIO);

		GrayU8 mean = storage1;
		BIO.mean(input,mean,radius,storage2,ISC, CIM, CN, CNN, CINB, CNJB, ICM);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;
				int indexMean = mean.startIndex + y*mean.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++, indexMean++ ) {
					float threshold = (mean.data[indexMean]& 0xFF) * scale;

					if( (input.data[indexIn]& 0xFF) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;
				int indexMean = mean.startIndex + y*mean.stride;

				int end = indexIn + input.width;

				int x = 0;
				for( ; indexIn < end; indexIn++ , indexOut++, indexMean++ , x++) {
					int threshold = (mean.data[indexMean]& 0xFF);

					if( (input.data[indexIn]& 0xFF) * scale > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Thresholds the image using a locally adaptive threshold that is computed using a local square region centered
	 * on each pixel.  The threshold is equal to the gaussian weighted sum of the surrounding pixels times the scale.
	 * If down is true then b(x,y) = I(x,y) ≤ T(x,y) * scale ? 1 : 0.  Otherwise
	 * b(x,y) = I(x,y) * scale > T(x,y) ? 0 : 1
	 *
	 * @param input Input image.
	 * @param output (optional) Output binary image.  If null it will be declared internally.
	 * @param radius Radius of square region.
	 * @param scale Scale factor used to adjust threshold.  Try 0.95
	 * @param down Should it threshold up or down.
	 * @param storage1 (Optional) Storage for intermediate step. If null will be declared internally.
	 * @param storage2 (Optional) Storage for intermediate step. If null will be declared internally.
	 * @return Thresholded image.
	 */
	public GrayU8 localGaussian(GrayU8 input , GrayU8 output ,
								int radius , float scale , boolean down ,
								GrayU8 storage1 , GrayU8 storage2 , InputSanityCheck ISC, GeneralizedImageOps GIO, BlurImageOps BIO,
								FactoryKernelGaussian FKG, ConvolveNormalized CN, ConvolveNormalizedNaive CNN, ConvolveImageNoBorder CINB, ConvolveNormalized_JustBorder CNJB) {

		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);
		storage1 = ISC.checkDeclare(input,storage1,GrayU8.class, GIO);
		storage2 = ISC.checkDeclare(input,storage2,GrayU8.class, GIO);

		GrayU8 blur = storage1;

		BIO.gaussian(input,blur,-1,radius,storage2, ISC, GIO, FKG, CN, CNN, CINB, CNJB);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;
				int indexMean = blur.startIndex + y*blur.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++, indexMean++ ) {
					float threshold = (blur.data[indexMean]& 0xFF) * scale;

					if( (input.data[indexIn]& 0xFF) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;
				int indexMean = blur.startIndex + y*blur.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++, indexMean++ ) {
					int threshold = (blur.data[indexMean]& 0xFF);

					if( (input.data[indexIn]& 0xFF) * scale > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Thresholds the image using a locally adaptive threshold that is computed using a local square region centered
	 * on each pixel.  The threshold is equal to the average value of the surrounding pixels times the scale.
	 * If down is true then b(x,y) = I(x,y) ≤ T(x,y) * scale ? 1 : 0.  Otherwise
	 * b(x,y) = I(x,y) * scale > T(x,y) ? 0 : 1
	 *
	 * @param input Input image.
	 * @param output (optional) Output binary image.  If null it will be declared internally.
	 * @param radius Radius of square region.
	 * @param scale Scale factor used to adjust threshold.  Try 0.95
	 * @param down Should it threshold up or down.
	 * @param storage1 (Optional) Storage for intermediate step. If null will be declared internally.
	 * @param storage2 (Optional) Storage for intermediate step. If null will be declared internally.
	 * @return Thresholded image.
	 */
	public GrayU8 localSquare(GrayF32 input , GrayU8 output ,
									 int radius , float scale , boolean down ,
									 GrayF32 storage1 , GrayF32 storage2, InputSanityCheck ISC, GeneralizedImageOps GIO, BlurImageOps BIO, ConvolveImageMean CIM,
							  ConvolveNormalized CN, ConvolveNormalizedNaive CNN, ConvolveImageNoBorder CINB, ConvolveNormalized_JustBorder CNJB, ImplConvolveMean
									  ICM) {

		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);
		storage1 = ISC.checkDeclare(input,storage1,GrayF32.class, GIO);
		storage2 = ISC.checkDeclare(input,storage2,GrayF32.class, GIO);

		GrayF32 mean = storage1;

		BIO.mean(input,mean,radius,storage2, ISC, CIM, CN, CNN, CINB, CNJB, ICM);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;
				int indexMean = mean.startIndex + y*mean.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++, indexMean++ ) {
					float threshold = (mean.data[indexMean]) * scale;

					if( (input.data[indexIn]) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;
				int indexMean = mean.startIndex + y*mean.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++, indexMean++ ) {
					float threshold = (mean.data[indexMean]);

					if( (input.data[indexIn]) * scale > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

	/**
	 * Thresholds the image using a locally adaptive threshold that is computed using a local square region centered
	 * on each pixel.  The threshold is equal to the gaussian weighted sum of the surrounding pixels times the scale.
	 * If down is true then b(x,y) = I(x,y) ≤ T(x,y) * scale ? 1 : 0.  Otherwise
	 * b(x,y) = I(x,y) * scale > T(x,y) ? 0 : 1
	 *
	 * @param input Input image.
	 * @param output (optional) Output binary image.  If null it will be declared internally.
	 * @param radius Radius of square region.
	 * @param scale Scale factor used to adjust threshold.  Try 0.95
	 * @param down Should it threshold up or down.
	 * @param storage1 (Optional) Storage for intermediate step. If null will be declared internally.
	 * @param storage2 (Optional) Storage for intermediate step. If null will be declared internally.
	 * @return Thresholded image.
	 */
	public GrayU8 localGaussian(GrayF32 input , GrayU8 output ,
									   int radius , float scale , boolean down ,
									   GrayF32 storage1 , GrayF32 storage2 , InputSanityCheck ISC, GeneralizedImageOps GIO, BlurImageOps BIO,
								FactoryKernelGaussian FKG, ConvolveNormalized CN, ConvolveNormalizedNaive CNN, ConvolveImageNoBorder CINB, ConvolveNormalized_JustBorder CNJB) {

		output = ISC.checkDeclare(input,output,GrayU8.class, GIO);
		storage1 = ISC.checkDeclare(input,storage1,GrayF32.class, GIO);
		storage2 = ISC.checkDeclare(input,storage2,GrayF32.class, GIO);

		GrayF32 blur = storage1;

		BIO.gaussian(input,blur,-1,radius,storage2, ISC, FKG, CN, CNN, CINB, CNJB);

		if( down ) {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;
				int indexMean = blur.startIndex + y*blur.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++, indexMean++ ) {
					float threshold = (blur.data[indexMean]) * scale;

					if( (input.data[indexIn]) <= threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		} else {
			for( int y = 0; y < input.height; y++ ) {
				int indexIn = input.startIndex + y*input.stride;
				int indexOut = output.startIndex + y*output.stride;
				int indexMean = blur.startIndex + y*blur.stride;

				int end = indexIn + input.width;

				for( ; indexIn < end; indexIn++ , indexOut++, indexMean++ ) {
					float threshold = (blur.data[indexMean]);

					if( (input.data[indexIn]) * scale > threshold )
						output.data[indexOut] = 1;
					else
						output.data[indexOut] = 0;
				}
			}
		}

		return output;
	}

}


text:
package org.wso2.carbon.identity.core.internal;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.osgi.framework.BundleContext;
import org.osgi.service.component.ComponentContext;
import org.wso2.carbon.identity.base.IdentityConstants;
import org.wso2.carbon.identity.core.persistence.JDBCPersistenceManager;
import org.wso2.carbon.identity.core.um.listener.IdentityUserMgtListener;
import org.wso2.carbon.identity.core.util.IdentityTenantUtil;
import org.wso2.carbon.identity.core.util.IdentityUtil;
import org.wso2.carbon.registry.core.service.RegistryService;
import org.wso2.carbon.security.config.SecurityConfigAdmin;
import org.wso2.carbon.user.core.listener.UserStoreManagerListener;
import org.wso2.carbon.user.core.service.RealmService;

/**
 * @scr.component name="identity.core.component" immediate="true"
 * @scr.reference name="security.config.service"
 * interface="org.wso2.carbon.security.config.SecurityConfigAdmin" cardinality="1..1"
 * policy="dynamic" bind="setSecurityConfigAdminService"
 * unbind="unsetSecurityConfigAdminService"
 * @scr.reference name="registry.service"
 * interface="org.wso2.carbon.registry.core.service.RegistryService"
 * cardinality="1..1" policy="dynamic" bind="setRegistryService"
 * unbind="unsetRegistryService"
 * @scr.reference name="user.realmservice.default"
 * interface="org.wso2.carbon.user.core.service.RealmService" cardinality="1..1"
 * policy="dynamic" bind="setRealmService" unbind="unsetRealmService"
 */

public class IdentityCoreServiceComponent {
    private static Log log = LogFactory.getLog(IdentityCoreServiceComponent.class);

    private static BundleContext bundleContext = null;

    public IdentityCoreServiceComponent() {
    }

    /**
     * @param ctxt
     */
    protected void activate(ComponentContext ctxt) {
        if (log.isDebugEnabled()) {
            log.debug("Identity Core bundle is activated");
        }
        try {
            IdentityUtil.populateProperties();
            IdentityUserMgtListener userMgtListener = new IdentityUserMgtListener();
            ctxt.getBundleContext().registerService(UserStoreManagerListener.class.getName(), userMgtListener, null);
            bundleContext = ctxt.getBundleContext();

            // Identity database schema creation can be avoided by setting
            // JDBCPersistenceManager.SkipDBSchemaCreation property to "true".
            String skipSchemaCreation = IdentityUtil.getProperty(
                    IdentityConstants.ServerConfig.SKIP_DB_SCHEMA_CREATION);

            // initialize the identity persistence manager, if it is not already initialized.
            JDBCPersistenceManager jdbcPersistenceManager = JDBCPersistenceManager.getInstance();
            if (("true".equals(skipSchemaCreation))) {
                // This ideally should be an info log but in API Manager it could be confusing to say
                // DB initialization was skipped, because DB initialization is done by apimgt components
                log.debug("Identity Provider Database initialization attempt was skipped since '" +
                        IdentityConstants.ServerConfig.SKIP_DB_SCHEMA_CREATION + "' property has been set to \'true\'");
            } else if (System.getProperty("setup") == null){
                 log.info("Identity Database schema initialization check was skipped since " +
                         "\'setup\' variable was not given during startup");
            } else {
                jdbcPersistenceManager.initializeDatabase();
            }

            //taking the service registration after DB initialization.
            ctxt.getBundleContext().registerService(IdentityUtil.class.getName(),
                    new IdentityUtil(), null);

        } catch (Throwable e) {
            log.error("Error occurred while populating identity configuration properties", e);
        }
    }

    /**
     * @param ctxt
     */
    protected void deactivate(ComponentContext ctxt) {
        if (log.isDebugEnabled()) {
            log.debug("Identity Core bundle is deactivated");
        }
    }

    protected void setRegistryService(RegistryService registryService) {
        IdentityTenantUtil.setRegistryService(registryService);
    }

    protected void unsetRegistryService(RegistryService registryService) {
        IdentityTenantUtil.setRegistryService(null);
    }

    /**
     * @param realmService
     */
    protected void setRealmService(RealmService realmService) {
        IdentityTenantUtil.setRealmService(realmService);
    }

    /**
     * @param realmService
     */
    protected void unsetRealmService(RealmService realmService) {
        IdentityTenantUtil.setRealmService(null);
    }

    /**
     * @param securityConfig
     */
    protected void setSecurityConfigAdminService(SecurityConfigAdmin securityConfig) {
        if (log.isDebugEnabled()) {
            log.debug("SecurityConfigAdmin set in Identity Core bundle");
        }
    }

    /**
     * @param securityConfig
     */
    protected void unsetSecurityConfigAdminService(SecurityConfigAdmin securityConfig) {
        if (log.isDebugEnabled()) {
            log.debug("SecurityConfigAdmin unset in Identity Core bundle");
        }
    }

    public static BundleContext getBundleContext() {
        return bundleContext;
    }

}


text:
@(feedList: List[Feed])
@import models.Feed

    @if(feedList != null && feedList.nonEmpty){

        @views.html.feed.list(feedList)

    }else{

Ingen feeds å vise

    }

        Publisér nyhetsmelding
        <form>

                Tittel:
                <input class="feed-messageTitle" type="text">

                Melding:
                <textarea class="feed-message" rows="8" placeholder="innhold"></textarea>

                BildeLink:

                    Bildet må være minimum 500x250, og maksimum 1000x500. Størrelsesforholdet må være 2:1
                <input class="feed-pictureUrl" type="text" placeholder="url her">

        </form>


text:
package org.compass.core.mapping;

/**
 * An interface allowing for implemenations to provide a {@link ResourceMapping}
 * instance.
 *
 * @author kimchy
 */
public interface ResourceMappingProvider {

    /**
     * Retruns the resource mapping to use.
     */
    ResourceMapping getMapping();
}