themelist.js 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. /* ***** BEGIN LICENSE BLOCK *****
  2. * Distributed under the BSD license:
  3. *
  4. * Copyright (c) 2013 Matthew Christopher Kastor-Inare III, Atropa Inc. Intl
  5. * All rights reserved.
  6. *
  7. * Contributed to Ajax.org under the BSD license.
  8. *
  9. * Redistribution and use in source and binary forms, with or without
  10. * modification, are permitted provided that the following conditions are met:
  11. * * Redistributions of source code must retain the above copyright
  12. * notice, this list of conditions and the following disclaimer.
  13. * * Redistributions in binary form must reproduce the above copyright
  14. * notice, this list of conditions and the following disclaimer in the
  15. * documentation and/or other materials provided with the distribution.
  16. * * Neither the name of Ajax.org B.V. nor the
  17. * names of its contributors may be used to endorse or promote products
  18. * derived from this software without specific prior written permission.
  19. *
  20. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
  21. * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  22. * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  23. * DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
  24. * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
  25. * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  26. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  27. * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  28. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
  29. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  30. *
  31. * ***** END LICENSE BLOCK ***** */
  32. /**
  33. * Generates a list of themes available when ace was built.
  34. * @fileOverview Generates a list of themes available when ace was built.
  35. * @author <a href="mailto:matthewkastor@gmail.com">
  36. * Matthew Christopher Kastor-Inare III </a><br />
  37. * ☭ Hial Atropa!! ☭
  38. */
  39. define(function(require, exports, module) {
  40. "use strict";
  41. require("ace/lib/fixoldbrowsers");
  42. var themeData = [
  43. ["Chrome" ],
  44. ["Clouds" ],
  45. ["Crimson Editor" ],
  46. ["Dawn" ],
  47. ["Dreamweaver" ],
  48. ["Eclipse" ],
  49. ["GitHub" ],
  50. ["IPlastic" ],
  51. ["Solarized Light"],
  52. ["TextMate" ],
  53. ["Tomorrow" ],
  54. ["XCode" ],
  55. ["Kuroir"],
  56. ["KatzenMilch"],
  57. ["SQL Server" ,"sqlserver" , "light"],
  58. ["Ambiance" ,"ambiance" , "dark"],
  59. ["Chaos" ,"chaos" , "dark"],
  60. ["Clouds Midnight" ,"clouds_midnight" , "dark"],
  61. ["Cobalt" ,"cobalt" , "dark"],
  62. ["idle Fingers" ,"idle_fingers" , "dark"],
  63. ["krTheme" ,"kr_theme" , "dark"],
  64. ["Merbivore" ,"merbivore" , "dark"],
  65. ["Merbivore Soft" ,"merbivore_soft" , "dark"],
  66. ["Mono Industrial" ,"mono_industrial" , "dark"],
  67. ["Monokai" ,"monokai" , "dark"],
  68. ["Pastel on dark" ,"pastel_on_dark" , "dark"],
  69. ["Solarized Dark" ,"solarized_dark" , "dark"],
  70. ["Terminal" ,"terminal" , "dark"],
  71. ["Tomorrow Night" ,"tomorrow_night" , "dark"],
  72. ["Tomorrow Night Blue" ,"tomorrow_night_blue" , "dark"],
  73. ["Tomorrow Night Bright","tomorrow_night_bright" , "dark"],
  74. ["Tomorrow Night 80s" ,"tomorrow_night_eighties" , "dark"],
  75. ["Twilight" ,"twilight" , "dark"],
  76. ["Vibrant Ink" ,"vibrant_ink" , "dark"]
  77. ];
  78. exports.themesByName = {};
  79. /**
  80. * An array containing information about available themes.
  81. */
  82. exports.themes = themeData.map(function(data) {
  83. var name = data[1] || data[0].replace(/ /g, "_").toLowerCase();
  84. var theme = {
  85. caption: data[0],
  86. theme: "ace/theme/" + name,
  87. isDark: data[2] == "dark",
  88. name: name
  89. };
  90. exports.themesByName[name] = theme;
  91. return theme;
  92. });
  93. });