123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638 |
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <!-- Author Dirk Datzert 2007
- Patches and improvements by Juan Carlos Raña Trabado 2008 and Ivan Tcholakov 2009 -->
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <meta name="robots" content="noindex, nofollow" />
- <script src="../../dialog/common/fck_dialog_common.js" type="text/javascript"></script>
- <script type="text/javascript" src="jquery.js"></script>
- <script type="text/javascript">
- var oEditor = window.parent.InnerDialogLoaded() ;
- var FCKLang = oEditor.FCKLang ;
- var FCK = oEditor.FCK ;
- var FCKConfig = oEditor.FCKConfig ;
- var FCKTools = oEditor.FCKTools ;
- var FCKBrowserInfo = oEditor.FCKBrowserInfo ;
- //Set the language direction.
- window.document.dir = FCKLang.Dir ;
- // Initialization of the URLs to be used.
- var mimetex_url = FCKConfig.MimetexUrl ;
- var mimetex_cgi = mimetex_url + "? \\Large " ;
- var preview_cgi = mimetex_cgi + "\\nocach " ;
- var result_cgi = mimetex_cgi ;
- var img_tag = true ;
- // FCKEditor
- // We have to avoid javascript errors if some language variables have not been defined.
- FCKLang['DlgMimeTeXSymbols'] = FCKLang['DlgMimeTeXSymbols'] ? FCKLang['DlgMimeTeXSymbols'] : 'Symbols' ;
- FCKLang['DlgMimeTeXCalendar'] = FCKLang['DlgMimeTeXCalendar'] ? FCKLang['DlgMimeTeXCalendar'] : 'Calendar' ;
- FCKLang['DlgMimeTeXNumeric'] = FCKLang['DlgMimeTeXNumeric'] ? FCKLang['DlgMimeTeXNumeric'] : 'Numeric' ;
- FCKLang['DlgMimeTeXLowerGreeks'] = FCKLang['DlgMimeTeXLowerGreeks'] ? FCKLang['DlgMimeTeXLowerGreeks'] : 'Lower Greeks' ;
- FCKLang['DlgMimeTeXUpperGreeks'] = FCKLang['DlgMimeTeXUpperGreeks'] ? FCKLang['DlgMimeTeXUpperGreeks'] : 'Upper Greeks' ;
- FCKLang['DlgMimeTeXOperators'] = FCKLang['DlgMimeTeXOperators'] ? FCKLang['DlgMimeTeXOperators'] : 'Operators' ;
- FCKLang['DlgMimeTeXFunctions'] = FCKLang['DlgMimeTeXFunctions'] ? FCKLang['DlgMimeTeXFunctions'] : 'Functions' ;
- FCKLang['DlgMimeTeXTrigonometry'] = FCKLang['DlgMimeTeXTrigonometry'] ? FCKLang['DlgMimeTeXTrigonometry'] : 'Trigonometry' ;
- FCKLang['DlgMimeTeXAnalysis'] = FCKLang['DlgMimeTeXAnalysis'] ? FCKLang['DlgMimeTeXAnalysis'] : 'Analysis' ;
- FCKLang['DlgMimeTeXMoreSamples'] = FCKLang['DlgMimeTeXMoreSamples'] ? FCKLang['DlgMimeTeXMoreSamples'] : 'More Samples' ;
- switch ( oEditor.FCKLanguageManager.DefaultLanguage )
- {
- case 'es' :
- istallation_file_name = 'installation_guide_es_ES.html' ;
- break ;
- default :
- istallation_file_name = 'installation_guide.html' ;
- break ;
- }
- FCKLang['DlgMimeTeXSeeInstallationManual'] = FCKLang['DlgMimeTeXSeeInstallationManual']
- ? FCKLang['DlgMimeTeXSeeInstallationManual'] : 'To resolve the problem, see the Chamilo LMS %1installation guide%2.' ;
- if ( FCKConfig['UserIsPlatformAdmin'] || FCKConfig['UserIsCourseAdmin'] )
- {
- FCKLang['DlgMimeTeXSeeInstallationManual'] = FCKLang['DlgMimeTeXSeeInstallationManual'].replace( /%1/g,
- '<a href="../../../../../../../documentation/' + istallation_file_name + '#9._Mathematical_formulas" target="_blank">' ).replace( /%2/g, '<\/a>' ) ;
- }
- else
- {
- FCKLang['DlgMimeTeXSeeInstallationManual'] = FCKLang['DlgMimeTeXSeeInstallationManual'].replace( /%1/g, '' ).replace( /%2/g, '' ) ;
- }
- // look for a MATH-tag
- var eSelected = FCK.Selection.MoveToAncestorNode( 'MATH' ) ;
- // else look for an IMG-tag
- if ( !eSelected )
- {
- eSelected = FCK.Selection.MoveToAncestorNode( 'IMG' ) ;
- }
- // End FCKEditor
- function setSelRange( inputEl, selStart, selEnd )
- {
- if ( inputEl.setSelectionRange )
- {
- inputEl.focus() ;
- inputEl.setSelectionRange( selStart, selEnd ) ;
- }
- else if ( inputEl.createTextRange )
- {
- var range = inputEl.createTextRange() ;
- range.collapse(true) ;
- range.moveEnd( 'character', selEnd ) ;
- range.moveStart( 'character', selStart ) ;
- range.select();
- }
- }
- function insertAtCursor( myField, myValue )
- {
- // IE support
- if ( document.selection )
- {
- myField.focus() ;
- sel = document.selection.createRange() ;
- sel.text = myValue;
- }
- // MOZILLA/NETSCAPE support
- else if ( myField.selectionStart || myField.selectionStart == '0' )
- {
- var startPos = myField.selectionStart ;
- var endPos = myField.selectionEnd ;
- myField.value = myField.value.substring( 0, startPos )
- + myValue
- + myField.value.substring( endPos, myField.value.length ) ;
- setSelRange( myField, startPos + myValue.length, endPos + myValue.length ) ;
- }
- else
- {
- myField.value += myValue ;
- }
- }
- function cursorHand( obj )
- {
- $(obj).css( 'cursor', 'pointer' ) ;
- }
- function cursorDefault( obj )
- {
- $(obj).css( 'cursor', 'default' ) ;
- }
- function formulaPreview()
- {
- if ( document.pastemath.formula.value.length > 0 )
- {
- $( "#preview" ).css( 'display', 'block' ) ;
- $( "#formula_preview" ).attr( 'src', preview_cgi + document.pastemath.formula.value ) ;
- }
- else
- {
- $( "#preview" ).css( 'display', 'none' ) ;
- }
- }
- function addFormula( expr )
- {
- if ( document.pastemath.formula.value.length > 0 )
- {
- expr = ' ' + expr ;
- }
- textField = document.getElementById( "formula" ) ;
- insertAtCursor( textField, expr ) ;
- formulaPreview() ;
- }
- // Append a mimetex image to the last DIV of the Helper-DIV
- function appendHelper( expr, alt )
- {
- add_expr = expr.replace( /\\/g, "\\\\" ) ;
- src_expr = mimetex_cgi + expr ;
- $( "#helpers/div:last/p:last" ).append( "<img class=helper title='" + alt + "' alt='" + alt + "' onMouseOver='javascript: cursorHand(this);' onMouseOut='javascript: cursorDefault(this);' onClick='javascript: addFormula( \"" + add_expr + "\" ) ;' src='" + src_expr + "'>" ) ;
- }
- function htmlHelper( html )
- {
- $("#helpers/div:last/p:last").append(html);
- }
- function addHelper( id, title )
- {
- $( "#helpers" ).append( "<div id='" + id + "' class=helper>" + title + "<p id='" + id + "_pane' class='off pane' /></div>" ) ;
- }
- // Init helper on document ready
- $(function () {
- // FCKEditor
- // First of all, translate the dialog box texts
- oEditor.FCKLanguageManager.TranslatePage( document ) ;
- if ( !FCKConfig.IsMimetexInstalled )
- {
- ShowE( 'content', false ) ;
- ShowE( 'mimetex_error_message', true ) ;
- return ;
- }
- ShowE( 'content', true ) ;
- // End FCKEditor
- ////jc
- addHelper( "symbols1", FCKLang["DlgMimeTeXSymbols"] + " 1" ) ;
- //appendHelper( "\\-", "-" ) ; //jc
- appendHelper( "\-", "-" ) ;
- appendHelper( "\\cdot", "cdot" ) ;
- appendHelper( "\\times", "times" ) ;
- appendHelper( "\\ast", "ast" ) ;
- appendHelper( "\\div", "div" ) ;
- appendHelper( "\\diamond", "diamond" ) ;
- appendHelper( "\\pm", "pm" ) ;
- appendHelper( "\\mp", "mp" ) ;
- appendHelper( "\\oplus", "oplus" ) ;
- appendHelper( "\\ominus", "ominus" ) ;
- appendHelper( "\\otimes", "otimes" ) ;
- appendHelper( "\\oslash", "oslash" ) ;
- appendHelper( "\\odot", "odot" ) ;
- appendHelper( "\\bigcirc", "bigcirc" ) ;
- appendHelper( "\\circ", "circ" ) ;
- appendHelper( "\\bullet", "bullet" ) ;
- appendHelper( "\\asymp", "asymp" ) ;
- appendHelper( "\\equiv", "equiv" ) ;
- appendHelper( "\\subseteq", "subseteq" ) ;
- appendHelper( "\\supseteq", "supseteq" ) ;
- appendHelper( "\\leq", "leq" ) ;
- appendHelper( "\\geq", "geq" ) ;
- appendHelper( "\\preceq", "preceq" ) ;
- appendHelper( "\\succeq", "succeq" ) ;
- appendHelper( "\\sim", "sim" ) ;
- appendHelper( "\\approx", "approx" ) ;
- appendHelper( "\\subset", "subset" ) ;
- appendHelper( "\\supset", "supset" ) ;
- appendHelper( "\\ll", "ll" ) ;
- appendHelper( "\\gg", "gg" ) ;
- appendHelper( "\\prec", "prec" ) ;
- appendHelper( "\\succ", "succ" ) ;
- appendHelper( "\\leftar", "leftar" ) ;
- appendHelper( "\\rightar", "rightar" ) ;
- appendHelper( "\\uparr", "uparr" ) ;
- appendHelper( "\\downar", "downar" ) ;
- appendHelper( "\\leftrightar", "leftrightar" ) ;
- appendHelper( "\\near", "near" ) ;
- appendHelper( "\\sear", "sear" ) ;
- appendHelper( "\\simeq", "simeq" ) ;
- appendHelper( "\\Leftar", "Leftar" ) ;
- appendHelper( "\\Rightar", "Rightar" ) ;
- appendHelper( "\\Upar", "Upar" ) ;
- appendHelper( "\\Downar", "Downar" ) ;
- appendHelper( "\\Leftrightar", "Leftrightar" ) ;
- appendHelper( "\\nwar", "nwar" ) ;
- appendHelper( "\\swar", "swar" ) ;
- appendHelper( "\\propto", "propto" ) ;
- appendHelper( "\\prime", "prime" ) ;
- appendHelper( "\\infty", "infty" ) ;
- appendHelper( "\\in", "in" ) ;
- appendHelper( "\\ni", "ni" ) ;
- appendHelper( "\\triangle", "triangle" ) ;
- appendHelper( "\\bigtriangledo", "bigtriangledo" ) ;
- appendHelper( "\/", "/" ) ; //no va es la barra normal inclinada a la derecha
- appendHelper( "\\forall", "forall" ) ;
- appendHelper( "\\exists", "exists" ) ;
- appendHelper( "\\neg", "neg" ) ;
- appendHelper( "\\emptyset", "emptyset" ) ;
- appendHelper( "\\Re", "Re" ) ;
- appendHelper( "\\Im", "Im" ) ;
- appendHelper( "\\top", "top" ) ;
- appendHelper( "\\bot", "bot" ) ;
- appendHelper( "\\aleph", "aleph" ) ;
- appendHelper( "\\calA", "calA" ) ;
- appendHelper( "\\calZ", "calZ" ) ;
- appendHelper( "\\cup", "cup" ) ;
- appendHelper( "\\cap", "cap" ) ;
- appendHelper( "\\uplus", "uplus" ) ;
- appendHelper( "\\wedge", "wedge" ) ;
- appendHelper( "\\vee", "vee" ) ;
- appendHelper( "\\vdash", "vdash" ) ;
- appendHelper( "\\dashv", "dshv" ) ;
- appendHelper( "\\lfloor", "lfloor" ) ;
- appendHelper( "\\rfloor", "rfloor" ) ;
- appendHelper( "\\lceil", "lceil" ) ;
- appendHelper( "\\rceil", "rceil" ) ;
- appendHelper( "\\lbrace", "lbrace" ) ;
- appendHelper( "\\rbrace", "rbrace" ) ;
- appendHelper( "\\langle", "langle" ) ;
- appendHelper( "\\rangle", "rangle" ) ;
- appendHelper( "\\mid", "mid" ) ;
- appendHelper( "\\parallel", "parallel" ) ;
- appendHelper( "\\updownar", "updownar" ) ;
- appendHelper( "\\Updownar", "Updownar" ) ;
- appendHelper( "\\setminus", "setminus" ) ;
- appendHelper( "\\wr", "wr" ) ;
- appendHelper( "\\surd", "surd" ) ;
- appendHelper( "\\amalg", "amalg" ) ;
- appendHelper( "\\nabla", "nabla" ) ;
- appendHelper( "\\int", "int" ) ;
- appendHelper( "\\sqcup", "sqcup" ) ;
- appendHelper( "\\sqcap", "sqcap" ) ;
- appendHelper( "\\sqsubseteq", "sqsubseteq" ) ;
- appendHelper( "\\sqsupseteq", "sqsupseteq" ) ;
- appendHelper( "\\S", "S" ) ;
- appendHelper( "\\dag", "dag" ) ;
- appendHelper( "\\ddag", "ddag" ) ;
- appendHelper( "\\P", "P" ) ;
- appendHelper( "\\clubsuit", "clubsuit" ) ;
- appendHelper( "\\Diamond", "Diamond" ) ;
- appendHelper( "\\Heart", "Heart" ) ;
- appendHelper( "\\spadesuit", "spadesuit" ) ;
- addHelper( "symbols2", FCKLang["DlgMimeTeXSymbols"] + " 2" ) ;
- appendHelper( "\\leftharpoonup", "leftharpoonup" ) ;
- appendHelper( "\\leftharpoondo", "leftharpoondo" ) ;
- appendHelper( "\\rightharpoonup", "rightharpoonup" ) ;
- appendHelper( "\\rightharpoondo", "rightharpoondo" ) ;
- appendHelper( "\\triangleright", "triangleright" ) ;
- appendHelper( "\\triangleleft", "triangleleft" ) ;
- appendHelper( "\\star", "star" ) ;
- appendHelper( "\\partial", "partial" ) ;
- appendHelper( "\\flat", "flat" ) ;
- appendHelper( "\\natural", "natural" ) ;
- appendHelper( "\\sharp", "sharp" ) ;
- appendHelper( "\\smile", "smile" ) ;
- appendHelper( "\\frown", "frown" ) ;
- appendHelper( "\\ell", "ell" ) ;
- appendHelper( "\\imath", "imath" ) ;
- appendHelper( "\\jmath", "jmath" ) ;
- //appendHelper( "\\vp", "vp" ) ;
- //appendHelper( "\\vec", "vec" ) ;
- appendHelper( "\\ss", "ss" ) ;
- appendHelper( "\\ae", "ae" ) ;
- appendHelper( "\\oe", "oe" ) ;
- appendHelper( "\\AE", "AE" ) ;
- appendHelper( "\\OE", "OE" ) ;
- appendHelper( "\\moo", "moo" ) ;
- appendHelper( "\\Lbag", "Lbag" ) ;
- appendHelper( "\\Rbag", "Rbag" ) ;
- appendHelper( "\\lightning", "lightning" ) ;
- appendHelper( "\\llbracket", "llbracket" ) ;
- appendHelper( "\\rrbracket", "rrbracket" ) ;
- appendHelper( "\\subsetpluseq", "subsetpluseq" ) ;
- appendHelper( "\\supsetpluseq", "supsetpluseq" ) ;
- appendHelper( "\\Yup", "Yup" ) ;
- appendHelper( "\\Ydown", "Ydown" ) ;
- //appendHelper( "\\cyr A", "cyr A" ) ;
- //appendHelper( "\\cyr a", "cyr a" ) ;
- //appendHelper( "\\cyr Dj", "cyr Dj" ) ;
- //appendHelper( "\\cyr Zh", "cyr Zh" ) ;
- addHelper( "calendar", FCKLang["DlgMimeTeXCalendar"] ) ;
- appendHelper( "\\blue\\normalsize\\calendar", "" ) ;
- appendHelper( "\\reverse\\opaque\\red\\normalsize\\calendar[2008,9,11]", "" ) ;
- appendHelper( "\\today", "" ) ;
- appendHelper( "\\green\\today[2]", "" ) ;
- appendHelper( "\\red\\today[3]", "" ) ;
- ////jc end
- addHelper( "numeric", FCKLang["DlgMimeTeXNumeric"] ) ;
- var al_l = "abcdefghijklmnopqrstuvwxyz" ;
- var al_u = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" ;
- var num = "0123456789" ;
- var alnum = al_u + num ;
- for ( var i = 0, n = alnum.length ; i < n ; i++ )
- {
- appendHelper( "\\mathbb{" + alnum.substr( i, 1 ) + "}", "math bold " + alnum.substr( i, 1 ) ) ;
- }
- htmlHelper( "<br />" ) ;
- for ( var i = 0, n = al_u.length ; i < n ; i++ )
- {
- appendHelper( "\\mathcal{" + al_u.substr( i, 1 ) + "}", "math cal " + al_u.substr( i, 1 ) ) ;
- }
- htmlHelper( "<br />" ) ;
- for ( var i = 0, n = al_u.length ; i < n ; i++ )
- {
- appendHelper( "\\mathfrak{" + al_u.substr( i, 1 ) + "}", "math frak " + al_u.substr( i, 1 ) ) ;
- }
- addHelper( "lowergreek", FCKLang["DlgMimeTeXLowerGreeks"] ) ;
- appendHelper( "\\alpha", "lower alpha" ) ;
- appendHelper( "\\beta", "lower beta" ) ;
- appendHelper( "\\delta", "lower delta" ) ;
- appendHelper( "\\epsilon", "lower epsilon" ) ;
- appendHelper( "\\varepsilon", "lower varepsilon" ) ;
- appendHelper( "\\eta", "lower eta" ) ;
- appendHelper( "\\gamma", "lower gamma" ) ;
- appendHelper( "\\lambda", "lower lambda" ) ;
- appendHelper( "\\mu", "lower mu" ) ;
- appendHelper( "\\nu", "lower nu" ) ;
- appendHelper( "\\omega", "lower omega" ) ;
- appendHelper( "\\rho", "lower rho" ) ;
- appendHelper( "\\varrho", "lower varrho" ) ;
- appendHelper( "\\sigma", "lower sigma" ) ;
- appendHelper( "\\varsigma", "lower varsigma" ) ;
- appendHelper( "\\tau", "lower tau" ) ;
- appendHelper( "\\phi", "lower phi" ) ;
- appendHelper( "\\psi", "lower psi" ) ;
- appendHelper( "\\chi", "lower chi" ) ;
- appendHelper( "\\theta", "lower theta" ) ;
- appendHelper( "\\kappa", "lower kappa" ) ;
- appendHelper( "\\xi", "lower xi" ) ;
- appendHelper( "\\zeta", "lower zeta" ) ;
- addHelper( "uppergreek", FCKLang["DlgMimeTeXUpperGreeks"] ) ;
- appendHelper( "\\Delta", "upper delta" ) ;
- appendHelper( "\\Gamma", "upper gamma" ) ;
- appendHelper( "\\Lambda", "upper lambda" ) ;
- appendHelper( "\\Theta", "upper theta" ) ;
- appendHelper( "\\Pi", "upper pi" ) ;
- appendHelper( "\\Phi", "upper phi" ) ;
- appendHelper( "\\Psi", "upper psi" ) ;
- appendHelper( "\\Omega", "upper omega" ) ;
- appendHelper( "\\Sigma", "upper sigma" ) ;
- appendHelper( "\\Xi", "upper xi" ) ;
- appendHelper( "\\Upsilon", "upper upsilon" ) ;
- addHelper( "operators", FCKLang["DlgMimeTeXOperators"] ) ;
- appendHelper( "\\frac{x}{y}", "" ) ;
- appendHelper( "x^{n}", "" ) ;
- appendHelper( "x_{n}", "" ) ;
- appendHelper( "\\sqrt {x}", "" ) ;
- appendHelper( "\\sqrt[3]{x}", "" ) ;
- appendHelper( "\\sqrt[4]{x}", "" ) ;
- appendHelper( "\\vec {x}", "" ) ;
- addHelper( "functions", FCKLang["DlgMimeTeXFunctions"] ) ;
- appendHelper( "\\ln", "ln" ) ;
- appendHelper( "\\log", "log" ) ;
- appendHelper( "\\exp", "exp" ) ;
- appendHelper( "\\arg", "arg" ) ;
- appendHelper( "\\Re", "Re" ) ;
- appendHelper( "\\Im", "Im" ) ;
- addHelper( "trigonometry", FCKLang["DlgMimeTeXTrigonometry"] ) ;
- appendHelper( "\\sin", "sin" ) ;
- appendHelper( "\\cos", "cos" ) ;
- appendHelper( "\\tan", "tan" ) ;
- appendHelper( "\\cot", "cot" ) ;
- appendHelper( "\\arcsin", "arcsin" ) ;
- appendHelper( "\\arccos", "arccos" ) ;
- appendHelper( "\\arctan", "arctan" ) ;
- appendHelper( "\\sinh", "sinh" ) ;
- appendHelper( "\\cosh", "cosh" ) ;
- appendHelper( "\\tanh", "tanh" ) ;
- appendHelper( "\\coth", "coth" ) ;
- addHelper( "analysis", FCKLang["DlgMimeTeXAnalysis"] ) ;
- appendHelper( "\\int _{-\\infty}^{x}\\mathrm{d}t", "integral dt from -infinite to x" ) ;
- appendHelper( "\\sum_{k=1}^{+\\infty}", "sum from k=1 to +infinite" ) ;
- appendHelper("\\frac{\\mathrm{d} f(x,y)}{\\mathrm{d}x}", "" ) ;
- appendHelper( "\\frac{\\partial f(x,y)}{\\partial x}", "" ) ;
- appendHelper( "\\lim _{\\small{x\\to +\\infty}}", "" ) ;
- ////jc
- addHelper( "moresamples", FCKLang["DlgMimeTeXMoreSamples"] ) ;
- appendHelper( "\\\large\\begin{array}{c.c|c} a_1&a_2&a_3\\\\\\hdash b_1&b_2&b_3\\\\\\hline c_1&c_2&c_3\\end{array}", "" ) ;
- appendHelper( "\\large e^x=\\sum_{n=0}^\\infty\\frac{x^n}{n!}", "" ) ;
- appendHelper( "\\large e^x=\\lim_{n\\to\\infty} \\left(1+\\frac xn\\right)^n", "" ) ;
- appendHelper( "\\large \\left( \\begin{array}{GC+30} \\cos\\frac\\theta2 & i\\,\\sin\\frac\\theta2\\\ i\\,\\sin\\frac\\theta2 & \\cos\\frac\\theta2 \\end{array} \\right) \\left( \\begin{array} z & x_{\\tiny-} \\\ x_{\\tiny+} & -z \\end{array} \\right) \\hfill{300}\\text{\\normalsize Example 1}", "" ) ;
- appendHelper( "\\large x=\\frac{-b\\pm\\sqrt{b^2-4ac}}{2a}", "" ) ;
- appendHelper( "\\large f^\\prime(x)\\ = \\lim_{\\Delta x\\to0}\\frac{f(x+\\Delta x)-f(x)}{\\Delta x}", "" ) ;
- appendHelper( "\\large\\hspace{5}\\unitlength{1} \\picture(175,100){ (50,50){\\circle(100)} (1,50){\\overbrace{\\line(46)}^{4$\\;\\;a}} (52,50){\\line(125)} (50,52;115;2){\\mid} (52,55){\\longleftar[60]} (130,56){\\longrightar[35]} (116,58){r} (c85,50;80;2){\\bullet} (c85,36){\\large-q} (c165,36){\\large q} (42,29){\\underbrace{\\line(32)}_{\\small a^2/r\\;\\;\\;}} }", "" ) ;
- appendHelper( "\\large\\varepsilon=\\sum_{i=1}^{n-1} \\frac1{\\Delta x}\\int_{x_i}^{x_{i+1}}\\left\\{\\frac1{\\Delta x}\\big[ (x_{i+1}-x)y_i^\\ast+(x-x_i)y_{i+1}^\\ast\\big]-f(x)\\right\\}^2dx", "" ) ;
- appendHelper( "\\large\\frac{dv^m}{ds}=-\\Gamma^m_{oo}v^{o^2} =-g^{mn}\\Gamma_{noo}v^{o^2}=\\frac12g^{mn}g_{oo,n}v^{o^2}", "" ) ;
- appendHelper( "\\large f=b_o+\\frac{a_1}{b_1+ \\frac{a_2}{b_2+\\frac{a_3}{b_3+a_4}}}", "" ) ;
- appendHelper( "\\large\\tilde y=\\left\\{ {\\ddot x\\text{ if \\vec x odd}\\atop\\hat{\\,\\bar x+1}\\text{ if even}}\\right.", "" ) ;
- appendHelper( "\\large\\overbrace{a,...,a}^{\\text{k a^,s}}, \\underbrace{b,...,b}_{\\text{l b^,s}}\\hspace{10} \\large\\underbrace{\\overbrace{a...a}^{\\text{k a^,s}}, \\overbrace{b...b}^{\\text{l b^,s}}}_{\\text{k+l elements}}", "" ) ;
- /*
- appendHelper( "\\large\\scr{J}^{i0}=+\\frac i2 \\left[\\begin{array}{cc}\\sigma_i&0\\\0&-\\sigma_i\\end{array}\\right] \\hspace{10}\\scr{J}^{ij}=\\frac12\\varepsilon_{ijk} \\left[\\begin{array}{cc}\\sigma_k&0\\\0&\\sigma_k\\end{array}\\right]", "" ) ;
- */
- appendHelper( "\\small\\hspace{10}\\unitlength{.75} \\picture(120,220){ (60,200){\\circle(120,40)} (0,20){\\line(0,180)} (5,189;0,-30){\\pict(110,20){(c20,10;70;2){ \\pict(40,20){(20,10){\\circle(40,20)}(c10,10)+(c30,10)-}} } } (119,20){\\line(0,180)} (60,20){\\circle(120,40;34)}}", "" ) ;
- appendHelper( "\\normalsize\\unitlength{.6}\\picture(100){ (50,50){\\circle(99)} (20,55;50,0;2){\\fs{+1}\\hat\\bullet} (50,40){\\bullet} (50,35){\\circle(50,25;34)} (50,35){\\circle(50,45;34)}}", "" ) ;
- ////jc end
- $('#helpers > div').hover(function() {
- $(this).find('p').fadeIn('fast' ) ;
- }, function() {
- $(this).find('p').fadeOut('fast' ) ;
- } ) ;
- // FCKEditor
- LoadSelected() ;
- // Show the "Ok" button.
- window.parent.SetOkButton( true ) ;
- SelectField( 'formula' ) ;
- // End FCKEditor
- } ) ;
- // FCKEditor
- function LoadSelected()
- {
- if ( !eSelected )
- {
- return ;
- }
- if ( eSelected.tagName == 'MATH' )
- {
- img_tag = false ;
- document.pastemath.formula.value = eSelected.firstChild.nodeValue ;
- formulaPreview() ;
- }
- else if ( eSelected.tagName == 'IMG' )
- {
- img_tag = true ;
- // We will read the formula from the url, because the back slash is escaped with %5C,
- // so the re is no risk the formula to be damaged by the php stripslashes(...) function.
- //document.pastemath.formula.value = eSelected.alt ;
- var formula = '' ;
- var src = eSelected.src.toString() ;
- var formula_start = src.indexOf( '?' ) ;
- if ( formula_start != -1 )
- {
- formula = src.substr( formula_start + 1 ).replace(/%5C/gi,'\\').replace(/%20/g,' ') ;
- formula = formula.Trim() ;
- if ( formula.indexOf( '\\Large' ) == 0 )
- {
- formula = formula.substr( 6 ) ;
- }
- formula = formula.Trim() ;
- }
- document.pastemath.formula.value = formula ;
- //
- formulaPreview() ;
- }
- else
- {
- eSelected == null ;
- }
- }
- function Ok()
- {
- result = document.pastemath.formula.value ;
- if( result.length > 0 ) {
- FCK.Focus() ;
- if ( eSelected )
- {
- FCK.Selection.SelectNode( eSelected ) ;
- }
- if ( img_tag )
- {
- //solved a problem with stripslashes by Christophe Lefevre
- var img_src = result_cgi + result ;
- FCK.InsertHtml( '<img src="' + img_src.replace(/\\/g, "%5C") + '" title="' + result + '" alt="' + result + '" />' ) ;
- }
- else
- {
- FCK.InsertHtml( '<math>' + result + '</math>' ) ;
- }
- }
- window.close() ;
- return true ;
- }
- // End FCKEditor
- </script>
- <script type="text/javascript">
- document.write( FCKTools.GetStyleHtml( GetCommonDialogCss() ) ) ;
- </script>
- <style type="text/css">
- body, td, input, textarea, select, label { font-family: Arial, Verdana, Geneva, helvetica, sans-serif; font-size: 11px; }
- </style>
- <!--solved a problem with iexplorer 7 by jc -->
- <style type="text/css">
- div.helpers
- {
- position: absolute;
- max-width: 360px;
- width:expression(document.body.clientWidth > 360? "360px": "auto" );
- overflow:auto;
- }
- li.helpers
- {
- margin: 3px;
- list-style-type: none;
- }
- .helper
- {
- margin: 3px;
- }
- .off
- {
- display: none;
- }
- .pane
- {
- margin: 1px;
- border: 1px solid black;
- }
- .formula
- {
- position: absolute;
- left: 375px;
- }
- #mimetex_error_message
- {
- font-size: 13px;
- }
- </style>
- </head>
- <body>
- <div id="content" style="display: none;">
- <div class="helpers">
- <b><span fckLang="DlgMimeTeXHelpers">Helpers:</span></b>
- <div id="helpers">
- </div>
- </div>
- <div class="formula">
- <div style="margin-top: 0px; margin-bottom: 10px; margin-left: 0px; margin-right: 0px; padding: 0px;">
- <b><span fckLang="DlgMimeTeXFormula">Formula:</span></b>
- </div>
- <div style="margin: 0px; padding: 0px;">
- <form name="pastemath" id="pastemath">
- <textarea id="formula" name="formula" cols="60" rows="8" onKeyUp="javascript: formulaPreview();" style="width: 370px;"></textarea>
- </form>
- </div>
- <div align="right"><a href="http://www.forkosh.com/mimetex.html" target="_blank" style="left:auto"><span fckLang="DlgMimeTeXManual">Manual</span></a></div>
- <div id="preview" class=off>
- <div style="margin-top: 0px; margin-bottom: 10px; margin-left: 0px; margin-right: 0px; padding: 0px;">
- <b><span fckLang="DlgMimeTeXPreview">Preview:</span></b>
- </div>
- <div style="margin: 0px; padding: 0px;">
- <img src="" alt="Image" name="formula_preview" id="formula_preview" align="middle"/>
- </div>
- </div>
- </div>
- </div>
- <div id="mimetex_error_message" style="display: none; text-align: center; padding-top: 100px;">
- <p><span fckLang="DlgMimeTeXEditorNotAvailable">The math formula editor is not available.</span></p>
- <p><span fckLang="DlgMimeTeXNotInstalled">A software service (MimeTeX) has not been installed on your server or it is not accessible.</span></p>
- <p><span fckLang="DlgMimeTeXSeeInstallationManual">To resolve the problem, see the Chamilo LMS installation guide.</span></p>
- <p><a href="http://www.forkosh.com/mimetex.html" target="_blank"><span fckLang="DlgMimeTeXManual">Manual</span></a></p>
- </div>
- </body>
- </html>
|