code
stringlengths
1
2.08M
language
stringclasses
1 value
/* * mobile event unit tests */ (function($){ var libName = "jquery.mobile.event.js", absFn = Math.abs, originalEventFn = $.Event.prototype.originalEvent, preventDefaultFn = $.Event.prototype.preventDefault, events = ("touchstart touchmove touchend orientationchange tap taphold " + "swipe swipel...
JavaScript
/* * mobile dialog unit tests */ (function($){ module('jquery.mobile.fieldContain.js'); test( "Field container contains appropriate css styles", function(){ ok($('#test-fieldcontain').hasClass('ui-field-contain ui-body ui-br'), 'A fieldcontain element must contain styles "ui-field-contain ui-body ui-br"'); });...
JavaScript
/* * mobile button unit tests */ (function($){ $.mobile.page.prototype.options.keepNative = "button.should-be-native"; test( "button elements in the keepNative set shouldn't be enhanced", function() { same( $("button.should-be-native").siblings("div.ui-slider").length, 0 ); }); test( "button elements should b...
JavaScript
/* * mobile media unit tests */ (function($){ var cssFn = $.fn.css, widthFn = $.fn.width; // make sure original definitions are reset module('jquery.mobile.media.js', { setup: function(){ $(document).trigger('mobileinit.htmlclass'); }, teardown: function(){ $.fn.css = cssFn; $.fn.width = widthF...
JavaScript
(function($) { asyncTest( "nested pages hash key is always in the hash on default page with no id (replaceState) ", function(){ $.testHelper.pageSequence([ function(){ // Click on the link of the third li element $('.ui-page-active li:eq(2) a:eq(0)').click(); }, function(){ ok( location.hash.se...
JavaScript
/* * mobile listview unit tests */ // TODO split out into seperate test files (function($){ var home = $.mobile.path.parseUrl( location.href ).pathname; $.mobile.defaultTransition = "none"; module( "Basic Linked list", { setup: function(){ $.testHelper.openPage( "#basic-linked-test" ); } }); asyncTes...
JavaScript
/* * mobile slider unit tests */ (function($){ var onChangeCnt = 0; window.onChangeCounter = function() { onChangeCnt++; } module('jquery.mobile.slider.js'); var keypressTest = function(opts){ var slider = $(opts.selector), val = window.parseFloat(slider.val()), handle = slider.siblings('.ui-slid...
JavaScript
/* * mobile slider unit tests */ (function($){ $.mobile.page.prototype.options.keepNative = "input.should-be-native"; // not testing the positive case here since's it's obviously tested elsewhere test( "slider elements in the keepNative set shouldn't be enhanced", function() { same( $("input.should-be-native")....
JavaScript
/* * mobile page unit tests */ (function($){ var libName = 'jquery.mobile.page.js'; module(libName); test( "nested header anchors aren't altered", function(){ ok(!$('.ui-header > div > a').hasClass('ui-btn')); }); test( "nested footer anchors aren't altered", function(){ ok(!$('.ui-footer > div > a').hasC...
JavaScript
//set namespace for unit test markp $( document ).bind( "mobileinit", function(){ $.mobile.ns = "nstest-"; });
JavaScript
(function($) { asyncTest( "dialog ui-state should be part of the hash", function(){ $.testHelper.sequence([ function() { // open the test page $.mobile.activePage.find( "a" ).click(); }, function() { // verify that the hash contains the dialogHashKey ok( location.hash.search($.mobile.dialog...
JavaScript
/* * mobile navigation base tag unit tests */ (function($){ var baseDir = $.mobile.path.parseUrl($("base").attr("href")).directory, contentDir = $.mobile.path.makePathAbsolute("../content/", baseDir); module('jquery.mobile.navigation.js - base tag', { setup: function(){ if ( location.hash ) { stop(); ...
JavaScript
/* * mobile navigation path unit tests */ (function($){ var url = $.mobile.path.parseUrl( location.href ), home = location.href.replace( url.domain, "" ); var testPageLoad = function(testPageAnchorSelector, expectedTextValue){ expect( 2 ); $.testHelper.pageSequence([ function(){ // reset before each ...
JavaScript
/* * mobile navigation unit tests */ (function($){ var siteDirectory = location.pathname.replace(/[^/]+$/, ""); module('jquery.mobile.navigation.js', { setup: function(){ if ( location.hash ) { stop(); $(document).one("pagechange", function() { start(); } ); location.hash = ""; } } ...
JavaScript
/* * mobile navigation unit tests */ (function($){ var perspective = "viewport-flip", transitioning = "ui-mobile-viewport-transitioning", animationCompleteFn = $.fn.animationComplete, //TODO centralize class names? transitionTypes = "in out fade slide flip reverse pop", isTransitioning = function(pa...
JavaScript
/* * mobile navigation unit tests */ (function($){ // TODO move siteDirectory over to the nav path helper var changePageFn = $.mobile.changePage, originalTitle = document.title, originalLinkBinding = $.mobile.linkBindingEnabled, siteDirectory = location.pathname.replace( /[^/]+$/, "" ), home = $.mobile.path...
JavaScript
/* * mobile buttonMarkup tests */ (function($){ module("jquery.mobile.buttonMarkup.js"); test( "control group buttons should be enhanced inside a footer", function(){ var group, linkCount; group = $("#control-group-footer"); linkCount = group.find( "a" ).length; same( group.find("a.ui-btn").length, linkC...
JavaScript
/* * mobile widget unit tests */ (function($){ module('jquery.mobile.widget.js'); test( "getting data from creation options", function(){ var expected = "bizzle"; $.mobile.widget.prototype.options = { "fooBar" : true }; $.mobile.widget.prototype.element = $("<div data-foo-bar=" + expected + ">"); same($.m...
JavaScript
/* * mobile widget unit tests */ (function($){ var widgetInitialized = false; module( 'jquery.mobile.widget.js' ); $( "#foo" ).live( 'pageinit', function(){ // ordering sensitive here, the value has to be set after the call // so that if the widget factory says that its not yet initialized, // which is an ...
JavaScript
/* * mobile listview unit tests */ // TODO split out into seperate test files (function( $ ){ module( "Collapsible section", {}); asyncTest( "The page should enhanced correctly", function(){ $.testHelper.pageSequence([ function(){ $.testHelper.openPage( "#basic-collapsible-test" ); }, function() {...
JavaScript
// load testswarm agent (function() { var url = window.location.search; url = decodeURIComponent( url.slice( url.indexOf("swarmURL=") + 9 ) ); if ( !url || url.indexOf("http") !== 0 ) { return; } document.write("<scr" + "ipt src='http://swarm.jquery.org/js/inject.js?" + (new Date).getTime() + "'></scr" + "...
JavaScript
/* * mobile support unit tests */ $.testHelper.excludeFileProtocol(function(){ var prependToFn = $.fn.prependTo, libName = "jquery.mobile.support.js"; module(libName, { teardown: function(){ //NOTE undo any mocking $.fn.prependTo = prependToFn; } }); // NOTE following two tests have debatable valu...
JavaScript
$(function() { var Runner = function( ) { var self = this; $.extend( self, { frame: window.frames[ "testFrame" ], testTimeout: 3 * 60 * 1000, $frameElem: $( "#testFrame" ), assertionResultPrefix: "assertion result for test:", onTimeout: QUnit.start, onFrameLoad: function() { // establis...
JavaScript
/* * mobile textinput unit tests */ (function($){ module( "jquery.mobile.forms.textinput.js" ); test( "inputs without type specified are enhanced", function(){ ok( $( "#typeless-input" ).hasClass( "ui-input-text" ) ); }); $.mobile.page.prototype.options.keepNative = "textarea.should-be-native"; // not testi...
JavaScript
/* * mobile checkboxradio unit tests */ (function($){ module( 'jquery.mobile.forms.checkboxradio.js' ); test( "widget can be disabled and enabled", function(){ var input = $( "#checkbox-1" ), button = input.parent().find( ".ui-btn" ); input.checkboxradio( "disable" ); input.checkboxradio( "enable" ); o...
JavaScript
/* * degradeInputs unit tests */ (function($){ module('jquery.mobile.slider.js'); test('keepNative elements should not be degraded', function() { same($('input#not-to-be-degraded').attr("type"), "range"); }); test('should degrade input type to a different type, as specified in page options', ...
JavaScript
/* * mobile dialog unit tests */ (function($) { module( "jquery.mobile.dialog.js", { setup: function() { $.mobile.page.prototype.options.contentTheme = "d"; } }); asyncTest( "dialog hash is added when the dialog is opened and removed when closed", function() { expect( 2 ); $.testHelper.pageSequence([ ...
JavaScript
window.Perf = (function($, Perf) { $.extend(Perf, { reportUrl: 'stats/', revUrl: 'stats/rev.php', // should be defined before report or poll are run currentRev: undefined, report: function( data, after ) { $.extend(data, { pathname: location.pathname, agent: this.agent(), agentFull: window.n...
JavaScript
(function(Perf) { var $listPage = $( "#list-page" ), firstCounter = 0; Perf.setCurrentRev(); Perf.pageLoadStart = Date.now(); $listPage.live( "pagebeforecreate", function() { if( firstCounter == 0 ) { Perf.pageCreateStart = Date.now(); firstCounter++; } }); $listPage.live( "pageinit", function( event...
JavaScript
(function($) { // TODO this is entire thing sucks $(function() { var searchMap = (function() { var searchSplit, searchMap = {}; if ( !location.search ){ return searchMap; } searchSplit = location.search.replace(/^\?/, "").split( /&|;/ ); for( var i = 0; i < searchSplit.length; i++ ) { var ...
JavaScript
//quick view source in new window links $.fn.addSourceLink = function(style){ return $(this).each(function(){ var link = $('<a href="#" data-'+ $.mobile.ns +'inline="true">View Source</a>'), src = src = $('<div></div>').append( $(this).clone() ).html(), page = $( "<div data-"+ $.mobile.ns +"role='dialog' data...
JavaScript
//set up the theme switcher on the homepage $('div').live('pagecreate',function(event){ if( !$(this).is('.ui-dialog')){ var appendEl = $(this).find('.ui-footer:last'); if( !appendEl.length ){ appendEl = $(this).find('.ui-content'); } if( appendEl.is("[data-position]") ){ return; } $('<a hre...
JavaScript
//thx @elroyjetson for the code example // When map page opens get location and display map $('.page-map').live("pagecreate", function() { //boston :) var lat = 42.35843, lng = -71.059773; //try to get GPS coords if( navigator.geolocation ) { //redirect function for successful location function gpsS...
JavaScript
//quick & dirty theme switcher, written to potentially work as a bookmarklet (function($){ $.themeswitcher = function(){ if( $('[data-'+ $.mobile.ns +'-url=themeswitcher]').length ){ return; } var themesDir = 'http://jquerymobile.com/test/css/themes/', themes = ['default','valencia'], currentPage = $.mobile....
JavaScript
function ResizePageContentHeight(page) { var $page = $(page), $content = $page.children( ".ui-content" ), hh = $page.children( ".ui-header" ).outerHeight() || 0, fh = $page.children( ".ui-footer" ).outerHeight() || 0, pt = parseFloat($content.css( "padding-top" )), pb = parseFloat($content.css( "padding-bott...
JavaScript
/* * jQuery Mobile Framework : scrollview plugin * Copyright (c) 2010 Adobe Systems Incorporated - Kin Blas (jblas@adobe.com) * Dual licensed under the MIT (MIT-LICENSE.txt) and GPL (GPL-LICENSE.txt) licenses. * Note: Code is in draft form and is subject to change */ (function($,window,document,undefined){ jQuery.wid...
JavaScript
/* * jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ * * Uses the built in easing capabilities added In jQuery 1.1 * to offer multiple easing options * * TERMS OF USE - jQuery Easing * * Open source under the BSD License. * * Copyright © 2008 George McGinley Smith * All rights reserved. * ...
JavaScript
(function() { var defaults = [ { type: "currency", from: "USD", to: "EUR" }, { type: "currency", from: "GBP", to: "EUR" } // TODO add back in as defaults once its possible to add other conversions, not just currencies /*, { type: "distance", from: "Miles", to: "Kilometer", rate: 1.609344 },...
JavaScript
$(function() { var symbols = { "USD": "$", "EUR": "&euro;", "GBP": "&pound;", "Miles": "m", "Kilometer": "km", "inch": "\"", "centimeter": "cm" }; function list() { var ul = $( "#conversions" ).empty(), ulEdit = $( "#edit-conversions" ).empty(); $.each( all, function( index, conversion ) { ...
JavaScript
/* * Copy of http://github.com/nje/jquery-tmpl/raw/master/jquery.tmpl.js at f827fb68417bc14ab9f6ae889421d5fea4cb2859 * jQuery Templating Plugin * Copyright 2010, John Resig * Dual licensed under the MIT or GPL Version 2 licenses. */ (function( jQuery, undefined ){ var oldManip = jQuery.fn.domManip, tmplItmAtt = "...
JavaScript
/** * jQuery Yii GridView plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright Copyright &copy; 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ * @version $Id: jquery.yiigridview.js 208 2010-08-06 20:03:22Z qiang.xue $ */ ;(functi...
JavaScript
/** * jQuery Yii ListView plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright Copyright &copy; 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ * @version $Id: jquery.yiilistview.js 164 2010-04-29 21:03:33Z qiang.xue $ */ ;(functi...
JavaScript
/* * Async Treeview 0.1 - Lazy-loading extension for Treeview * * http://bassistance.de/jquery-plugins/jquery-plugin-treeview/ * * Copyright (c) 2007 Jörn Zaefferer * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/...
JavaScript
/* ### jQuery Multiple File Upload Plugin v1.46 - 2009-05-12 ### * Home: http://www.fyneworks.com/jquery/multiple-file-upload/ * Code: http://code.google.com/p/jquery-multifile-plugin/ * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/...
JavaScript
/** * jQuery Yii plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright Copyright &copy; 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ * @version $Id: jquery.yii.js 2505 2010-09-27 11:51:46Z mdomba $ */ ;(function($) { $.yii = { ...
JavaScript
/** * Cookie plugin * * Copyright (c) 2006 Klaus Hartl (stilbuero.de) * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * */ /** * Create a cookie with the given name and value and other optional parameters. * * @examp...
JavaScript
(function($) { var CLASSES = $.treeview.classes; var proxied = $.fn.treeview; $.fn.treeview = function(settings) { settings = $.extend({}, settings); if (settings.add) { return this.trigger("add", [settings.add]); } if (settings.remove) { return this.trigger("remove", [settings.remove]); } return p...
JavaScript
/// <reference path="../../../lib/jquery-1.2.6.js" /> /* Masked Input plugin for jQuery Copyright (c) 2007-2009 Josh Bush (digitalbush.com) Licensed under the MIT license (http://digitalbush.com/projects/masked-input-plugin/#license) Version: 1.2.2 (03/09/2009 22:39:06) */ (function($) { var pasteEventName = ($.br...
JavaScript
/* ### jQuery Star Rating Plugin v3.13 - 2009-03-26 ### * Home: http://www.fyneworks.com/jquery/star-rating/ * Code: http://code.google.com/p/jquery-star-rating-plugin/ * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/...
JavaScript
/* * Treeview 1.5pre - jQuery plugin to hide and show branches of a tree * * http://bassistance.de/jquery-plugins/jquery-plugin-treeview/ * http://docs.jquery.com/Plugins/Treeview * * Copyright (c) 2007 Jörn Zaefferer * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-...
JavaScript
/** * jQuery Yii plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright Copyright &copy; 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ * @version $Id: jquery.yiitab.js 1827 2010-02-20 00:43:32Z qiang.xue $ */ ;(function($) { $.e...
JavaScript
/* * Metadata - jQuery plugin for parsing metadata from elements * * Copyright (c) 2006 John Resig, Yehuda Katz, J�örn Zaefferer, Paul McLanahan * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * * Revision: $Id: j...
JavaScript
/* Copyright (c) 2007 Paul Bakaus (paul.bakaus@googlemail.com) and Brandon Aaron (brandon.aaron@gmail.com || http://brandonaaron.net) * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses. * * $LastChangedDate: 2007...
JavaScript
/*! * jQuery BBQ: Back Button & Query Library - v1.2.1 - 2/17/2010 * http://benalman.com/projects/jquery-bbq-plugin/ * * Copyright (c) 2010 "Cowboy" Ben Alman * Dual licensed under the MIT and GPL licenses. * http://benalman.com/about/license/ */ // Script: jQuery BBQ: Back Button & Query Library // // *Version...
JavaScript
/* * jQuery Autocomplete plugin 1.1 * * Modified for Yii Framework: * - Renamed "autocomplete" to "legacyautocomplete". * - Fixed IE8 problems (mario.ffranco). * * Copyright (c) 2009 Jörn Zaefferer * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * ht...
JavaScript
/** * Ajax Queue Plugin * * Homepage: http://jquery.com/plugins/project/ajaxqueue * Documentation: http://docs.jquery.com/AjaxQueue */ /** <script> $(function(){ jQuery.ajaxQueue({ url: "test.php", success: function(html){ jQuery("ul").append(html); } }); jQuery.ajaxQueue({ url: "test.p...
JavaScript
/** * jQuery yiiactiveform plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright Copyright &copy; 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ * @version $Id: jquery.yiiactiveform.js 2597 2010-11-01 21:17:02Z qiang.xue $ * @since...
JavaScript
$(document).ready(function() { $('table.preview input[name="checkAll"]').click(function() { $('table.preview .confirm input').attr('checked', this.checked); }); $('table.preview td.confirm input').click(function() { $('table.preview input[name="checkAll"]').attr('checked', !$('table.preview td.confirm input:not...
JavaScript
// brush: "csharp" aliases: ["c-sharp", "c#"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('csharp', function(brush) { var k...
JavaScript
// brush: "bash-script" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('bash-script', function(brush) { var operat...
JavaScript
// brush: "javascript" aliases: ["js", "actionscript"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('javascript', function(br...
JavaScript
// brush: "diff" aliases: ["patch"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('diff', function(brush) { brush.push({patte...
JavaScript
// This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. if (!RegExp.prototype.indexOf) { RegExp.indexOf = function (match, index) { return match[0].in...
JavaScript
// brush: "xml" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.lib.xmlEntity = {pattern: /&\w+;/g, klass: 'entity'}; Syntax....
JavaScript
// brush: "python" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('python', function(brush) { var keywords = ["and...
JavaScript
// brush: "protobuf" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('protobuf', function(brush) { var keywords = [...
JavaScript
// brush: "php-script" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('php-script', function(brush) { var keywords...
JavaScript
// This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.layouts.table = function(options, code, container) { var table = jQuery('<table class="sy...
JavaScript
// brush: "apache" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('apache', function(brush) { brush.push({ patte...
JavaScript
// brush: "plain" aliases: ["text"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('plain', function(brush) { brush.push(Synta...
JavaScript
// brush: "pascal" aliases: ["delphi"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. // // Constructed using information from http://pascal.com...
JavaScript
// This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. // This layout doesn't work correctly in IE6, but is fine in all other tested browsers. Syntax.la...
JavaScript
// brush: "ocaml" aliases: ["ml", "sml", "fsharp"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. // This brush is based loosely on the followi...
JavaScript
// brush: "bash" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.brushes.dependency('bash', 'bash-script'); Syntax.register(...
JavaScript
// brush: "haskell" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('haskell', function(brush) { var keywords = ["a...
JavaScript
// brush: "smalltalk" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('smalltalk', function(brush) { var operators ...
JavaScript
// brush: "yaml" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('yaml', function(brush) { brush.push({ pattern: ...
JavaScript
// brush: "go" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('go', function(brush) { var keywords = ["break", "de...
JavaScript
// brush: "lisp" aliases: ['scheme', 'clojure'] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.lib.lispStyleComment = {pattern: /(;+) .*...
JavaScript
// This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. // This layout doesn't work correctly in IE6, but is fine in all other tested browsers. Syntax.la...
JavaScript
// brush: "kai" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('kai', function(brush) { brush.push(['(', ')', '[',...
JavaScript
// This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.layouts.list = function(options, code, container) { var listTag = options.listTag || 'ol'...
JavaScript
// brush: "assembly" aliases: ["asm"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('assembly', function(brush) { brush.push(...
JavaScript
// brush: "php" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.brushes.dependency('php', 'php-script'); Syntax.register('ph...
JavaScript
// brush: "basic" aliases: ['vb'] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.lib.vbStyleComment = {pattern: /' .*$/gm, klass: 'comme...
JavaScript
// brush: "io" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('io', function(brush) { brush.push(Syntax.lib.cStyle...
JavaScript
// This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.layouts.inline = function(options, code, container) { var inline = jQuery('<code class="s...
JavaScript
// brush: "java" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('java', function(brush) { var keywords = ["abstrac...
JavaScript
// brush: "ooc" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('ooc', function(brush) { var keywords = ["class", "...
JavaScript
/* This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. For more information, please see http://www.oriontransfer.co.nz/software/jquery-syntax Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> Permission is hereby granted, free of charge, to any pe...
JavaScript
// This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.Editor = function(container, text) { this.container = container; this.current = this.get...
JavaScript
// brush: "scala" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.brushes.dependency('scala', 'xml'); Syntax.register('scala...
JavaScript
// brush: "lua" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('lua', function(brush) { var keywords = ["and", "br...
JavaScript
// brush: "ruby" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.lib.rubyStyleFunction = {pattern: /(?:def\s+|\.)([a-z_][a-z0...
JavaScript
// brush: "clang" aliases: ["cpp", "c++", "c", "objective-c"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('clang', function(...
JavaScript
// brush: "html" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.brushes.dependency('html', 'xml'); Syntax.brushes.dependency...
JavaScript
// brush: "super-collider" aliases: ["sc"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('super-collider', function(brush) { ...
JavaScript
Syntax.themes["paper"] = ["base"]
JavaScript
// brush: "csharp" aliases: ["c-sharp", "c#"] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('csharp', function(brush) { var k...
JavaScript
// brush: "bash-script" aliases: [] // This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License. // Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz> // See <jquery.syntax.js> for licensing details. Syntax.register('bash-script', function(brush) { var operat...
JavaScript