lib/texstylist/unicode_babel.rb
def locale_to_babel_option(locale)
    case locale
    when /latin extended-a/
      # ["czech","dutch","polish","turkish"]
      "polish"
    when /latin extended-b/
      # ["afrikaans","croatian","serbian","slovene","romanian"]
      "romanian"
    when /latin-1 supplement/
      "ngerman"
    when /cyrillic/
      # ["bulgarian","ukrainian","russian"]
      "russian"
    when /greek/
      "greek"
    when "hangul"
      # TODO: \usepackage{xeCJK}, install on server
      nil
      # ... and so on
    when /latin|ascii/
      # "english" -- only if nothing else is found, we'll handle this from latex_inclusions for now
    else
      nil
    end
  end
# Only class methods, this is a general utility library
Only class methods, this is a general utility library
Only class methods this is a general utility library
def locale_to_babel_option(locale)
    case locale
    when /latin extended-a/
      "polish"
    when /latin extended-b/
      "romanian"
    when /latin-1 supplement/
      "ngerman"
    when /cyrillic/
      "russian"
    when /greek/
      "greek"
    when "hangul"
      nil
    when /latin|ascii/
    else
      nil
    end
  end
def locale_to_babel_option ( locale ) case locale when / latin extended-a / "polish" when / latin extended-b / "romanian" when / latin-1 supplement / "ngerman" when / cyrillic / "russian" when / greek / "greek" when "hangul" nil when / latin|ascii / else nil end end
Only class methods, this is a general utility library
Only class methods this is a general utility library
# ["czech","dutch","polish","turkish"] # ["afrikaans","croatian","serbian","slovene","romanian"] # ["bulgarian","ukrainian","russian"] # TODO: \usepackage{xeCJK}, install on server # ... and so on # "english" -- only if nothing else is found, we'll handle this from latex_inclusions for now
locale