{\rtf1\ansi\ansicpg1252\deff0\deflang1036{\fonttbl{\f0\fswiss\fcharset0 Arial;}}
{\*\generator Msftedit 5.41.15.1507;}\viewkind4\uc1\pard\f0\fs20 /*\par
 * jQuery corner plugin\par
 *\par
 * version 1.7 (1/26/2007)\par
 *\par
 * Dual licensed under the MIT and GPL licenses:\par
 *   http://www.opensource.org/licenses/mit-license.php\par
 *   http://www.gnu.org/licenses/gpl.html\par
 */\par
\par
/**\par
 * The corner() method provides a simple way of styling DOM elements.  \par
 *\par
 * corner() takes a single string argument:  $().corner("effect corners width")\par
 *\par
 *   effect:  The name of the effect to apply, such as round or bevel. \par
 *            If you don't specify an effect, rounding is used.\par
 *\par
 *   corners: The corners can be one or more of top, bottom, tr, tl, br, or bl. \par
 *            By default, all four corners are adorned. \par
 *\par
 *   width:   The width specifies the width of the effect; in the case of rounded corners this \par
 *            will be the radius of the width. \par
 *            Specify this value using the px suffix such as 10px, and yes it must be pixels.\par
 *\par
 * For more details see: http://methvin.com/jquery/jq-corner.html\par
 * For a full demo see:  http://malsup.com/jquery/corner/\par
 *\par
 *\par
 * @example $('.adorn').corner();\par
 * @desc Create round, 10px corners \par
 *\par
 * @example $('.adorn').corner("25px");\par
 * @desc Create round, 25px corners \par
 *\par
 * @example $('.adorn').corner("notch bottom");\par
 * @desc Create notched, 10px corners on bottom only\par
 *\par
 * @example $('.adorn').corner("tr dog 25px");\par
 * @desc Create dogeared, 25px corner on the top-right corner only\par
 *\par
 * @example $('.adorn').corner("round 8px").parent().css('padding', '4px').corner("round 10px");\par
 * @desc Create a rounded border effect by styling both the element and its parent\par
 * \par
 * @name corner\par
 * @type jQuery\par
 * @param String options Options which control the corner style\par
 * @cat Plugins/Corner\par
 * @return jQuery\par
 * @author Dave Methvin (dave.methvin@gmail.com)\par
 * @author Mike Alsup (malsup@gmail.com)\par
 */\par
jQuery.fn.corner = function(o) \{\par
    function hex2(s) \{\par
        var s = parseInt(s).toString(16);\par
        return ( s.length < 2 ) ? '0'+s : s;\par
    \};\par
    function gpc(node) \{\par
        for ( ; node && node.nodeName.toLowerCase() != 'html'; node = node.parentNode  ) \{\par
            var v = jQuery.css(node,'backgroundColor');\par
            if ( v.indexOf('rgb') >= 0 ) \{ \par
                rgb = v.match(/\\d+/g); \par
                return '#'+ hex2(rgb[0]) + hex2(rgb[1]) + hex2(rgb[2]);\par
            \}\par
            if ( v && v != 'transparent' )\par
                return v;\par
        \}\par
        return '#ffffff';\par
    \};\par
    function getW(i) \{\par
        switch(fx) \{\par
        case 'round':  return Math.round(width*(1-Math.cos(Math.asin(i/width))));\par
        case 'cool':   return Math.round(width*(1+Math.cos(Math.asin(i/width))));\par
        case 'sharp':  return Math.round(width*(1-Math.cos(Math.acos(i/width))));\par
        case 'bite':   return Math.round(width*(Math.cos(Math.asin((width-i-1)/width))));\par
        case 'slide':  return Math.round(width*(Math.atan2(i,width/i)));\par
        case 'jut':    return Math.round(width*(Math.atan2(width,(width-i-1))));\par
        case 'curl':   return Math.round(width*(Math.atan(i)));\par
        case 'tear':   return Math.round(width*(Math.cos(i)));\par
        case 'wicked': return Math.round(width*(Math.tan(i)));\par
        case 'long':   return Math.round(width*(Math.sqrt(i)));\par
        case 'sculpt': return Math.round(width*(Math.log((width-i-1),width)));\par
        case 'dog':    return (i&1) ? (i+1) : width;\par
        case 'dog2':   return (i&2) ? (i+1) : width;\par
        case 'dog3':   return (i&3) ? (i+1) : width;\par
        case 'fray':   return (i%2)*width;\par
        case 'notch':  return width; \par
        case 'bevel':  return i+1;\par
        \}\par
    \};\par
    o = (o||"").toLowerCase();\par
    var keep = /keep/.test(o);                       // keep borders?\par
    var cc = ((o.match(/cc:(#[0-9a-f]+)/)||[])[1]);  // corner color\par
    var sc = ((o.match(/sc:(#[0-9a-f]+)/)||[])[1]);  // strip color\par
    var width = parseInt((o.match(/(\\d+)px/)||[])[1]) || 10; // corner width\par
    var re = /round|bevel|notch|bite|cool|sharp|slide|jut|curl|tear|fray|wicked|sculpt|long|dog3|dog2|dog/;\par
    var fx = ((o.match(re)||['round'])[0]);\par
    var edges = \{ T:0, B:1 \};\par
    var opts = \{\par
        TL:  /top|tl/.test(o),       TR:  /top|tr/.test(o),\par
        BL:  /bottom|bl/.test(o),    BR:  /bottom|br/.test(o)\par
    \};\par
    if ( !opts.TL && !opts.TR && !opts.BL && !opts.BR )\par
        opts = \{ TL:1, TR:1, BL:1, BR:1 \};\par
    var strip = document.createElement('div');\par
    strip.style.overflow = 'hidden';\par
    strip.style.height = '1px';\par
    strip.style.backgroundColor = sc || 'transparent';\par
    strip.style.borderStyle = 'solid';\par
    return this.each(function(index)\{\par
        var pad = \{\par
            T: parseInt(jQuery.css(this,'paddingTop'))||0,     R: parseInt(jQuery.css(this,'paddingRight'))||0,\par
            B: parseInt(jQuery.css(this,'paddingBottom'))||0,  L: parseInt(jQuery.css(this,'paddingLeft'))||0\par
        \};\par
\par
        if (jQuery.browser.msie) this.style.zoom = 1; // force 'hasLayout' in IE\par
        if (!keep) this.style.border = 'none';\par
        strip.style.borderColor = cc || gpc(this.parentNode);\par
        var cssHeight = jQuery.curCSS(this, 'height');\par
\par
        for (var j in edges) \{\par
            var bot = edges[j];\par
            strip.style.borderStyle = 'none '+(opts[j+'R']?'solid':'none')+' none '+(opts[j+'L']?'solid':'none');\par
            var d = document.createElement('div');\par
            var ds = d.style;\par
\par
            bot ? this.appendChild(d) : this.insertBefore(d, this.firstChild);\par
\par
            if (bot && cssHeight != 'auto') \{\par
                if (jQuery.css(this,'position') == 'static')\par
                    this.style.position = 'relative';\par
                ds.position = 'absolute';\par
                ds.bottom = ds.left = ds.padding = ds.margin = '0';\par
                if (jQuery.browser.msie)\par
                    ds.setExpression('width', 'this.parentNode.offsetWidth');\par
                else\par
                    ds.width = '100%';\par
            \}\par
            else \{\par
                ds.margin = !bot ? '-'+pad.T+'px -'+pad.R+'px '+(pad.T-width)+'px -'+pad.L+'px' : \par
                                    (pad.B-width)+'px -'+pad.R+'px -'+pad.B+'px -'+pad.L+'px';                \par
            \}\par
\par
            for (var i=0; i < width; i++) \{\par
                var w = Math.max(0,getW(i));\par
                var e = strip.cloneNode(false);\par
                e.style.borderWidth = '0 '+(opts[j+'R']?w:0)+'px 0 '+(opts[j+'L']?w:0)+'px';\par
                bot ? d.appendChild(e) : d.insertBefore(e, d.firstChild);\par
            \}\par
        \}\par
    \});\par
\};\par
}
 