/*
 *  rsfs10/def.js
 *  
 *  This file loads the  font into jsMath. To do this use
 *  
 *      <SCRIPT>jsMath.Font.Load("rsfs10")</SCRIPT>
 *
 *  after loading jsMath.js itself.  The user will need to have
 *  the rsfs10.ttf font installed, otherwise corresponding unicode
 *  characters will be used, but the mapping is not perfect, and it is not 
 *  customized on a per-browser basis as it probably should be.
 *  
 *  If the font isn't installed, the user will receive a message indicating
 *  that fact, and pointing to the jsMath web site where the font can be
 *  downloaded.
 *  
 *  Once this file is loaded, you can use \char{rsfs10}{nn} to access
 *  any character in the font.  In addition, the \rsfs10 macro will switch to
 *  the eufm font
 *  
 *  ---------------------------------------------------------------------
 *
 *  jsMath is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  jsMath is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with jsMath; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */

jsMath.Add(jsMath.TeX,{

  rsfs10: [
    // 00 - 0F
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    // 10 - 1F
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    // 20 - 2F
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    // 30 - 3F
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    // 40 - 4F
    [0,0,0],
    [0.803,0.7,0,{ic: 0.229, krn: {'127': 0.389}}],
    [0.908,0.7,0,{ic: 0.0409, krn: {'127': 0.194}}],
    [0.666,0.7,0,{ic: 0.169, krn: {'127': 0.278}}],
    [0.774,0.7,0,{ic: 0.0937, krn: {'127': 0.111}}],
    [0.562,0.7,0,{ic: 0.186, krn: {'127': 0.139}}],
    [0.895,0.7,0,{ic: 0.136, krn: {'127': 0.222}}],
    [0.61,0.7,0,{ic: 0.173, krn: {'127': 0.25}}],
    [0.969,0.7,0,{ic: 0.297, krn: {'127': 0.333}}],
    [0.809,0.7,0,{ic: 0.192, krn: {'127': 0.333}}],
    [1.05,0.7,0.278,{ic: 0.192, krn: {'127': 0.417}}],
    [0.914,0.7,0,{ic: 0.313, krn: {'127': 0.361}}],
    [0.874,0.7,0,{ic: 0.192, krn: {'127': 0.306}}],
    [1.08,0.7,0,{ic: 0.16, krn: {'127': 0.444}}],
    [0.902,0.7,0,{ic: 0.352, krn: {'127': 0.389}}],
    [0.738,0.7,0,{ic: 0.0808, krn: {'127': 0.167}}],
    // 50 - 5F
    [1.01,0.7,0,{ic: 0.0808, krn: {'127': 0.222}}],
    [0.883,0.7,0,{ic: 0.0331, krn: {'127': 0.278}}],
    [0.85,0.7,0,{ic: 0.0626, krn: {'127': 0.194}}],
    [0.868,0.7,0,{ic: 0.192, krn: {'127': 0.333}}],
    [0.747,0.7,0,{ic: 0.291, krn: {'127': 0.222}}],
    [0.8,0.7,0,{ic: 0.258, krn: {'127': 0.25}}],
    [0.622,0.7,0,{ic: 0.275, krn: {'127': 0.222}}],
    [0.805,0.7,0,{ic: 0.275, krn: {'127': 0.25}}],
    [0.944,0.7,0,{ic: 0.26, krn: {'127': 0.278}}],
    [0.71,0.7,0,{ic: 0.294, krn: {'127': 0.194}}],
    [0.821,0.7,0,{ic: 0.24, krn: {'127': 0.306}}],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    // 60 - 6F
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    // 70 - 7F
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0,0,0],
    [0.278,0.556,0,{ic: 0.526}]
  ]

});
jsMath.Setup.EncodeFont('rsfs10');

jsMath.Font.Register({
  name: 'rsfs10',
  prefix: 'jsMath-',
  // The test used to see if font is available
  test: jsMath.Font.Test1, testChar: 0x4A, testFactor: 2,
  // Can add style, styles, macros here
  tex: function (font,fam) {
    // do browser-specific adjustments here
  },
  fallback: function (font,fam) {
    jsMath.Setup.Styles({'.typeset .rsfs10': 'font-family: cursive;'});
    jsMath.Update.TeXfonts({
      rsfs10: {
        '127': {c: '&#x2040;', tclass: 'normal'} // tie
      }
    });
  }
});
