hc-skins.c 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. /*
  2. Skins engine.
  3. Set of hardcoded skins
  4. Copyright (C) 2009, 2011, 2012
  5. The Free Software Foundation, Inc.
  6. Written by:
  7. Slava Zanko <slavazanko@gmail.com>, 2009
  8. Andrew Borodin <aborodin@vmail.ru>, 2012
  9. This file is part of the Midnight Commander.
  10. The Midnight Commander is free software: you can redistribute it
  11. and/or modify it under the terms of the GNU General Public License as
  12. published by the Free Software Foundation, either version 3 of the License,
  13. or (at your option) any later version.
  14. The Midnight Commander is distributed in the hope that it will be useful,
  15. but WITHOUT ANY WARRANTY; without even the implied warranty of
  16. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  17. GNU General Public License for more details.
  18. You should have received a copy of the GNU General Public License
  19. along with this program. If not, see <http://www.gnu.org/licenses/>.
  20. */
  21. #include <config.h>
  22. #include "internal.h"
  23. /*** global variables ****************************************************************************/
  24. /*** file scope macro definitions ****************************************************************/
  25. #define set_lines(x,y) mc_config_set_string(mc_skin->config, "Lines", x, y)
  26. /*** file scope type declarations ****************************************************************/
  27. /*** file scope variables ************************************************************************/
  28. /*** file scope functions ************************************************************************/
  29. /* --------------------------------------------------------------------------------------------- */
  30. /* --------------------------------------------------------------------------------------------- */
  31. /*** public functions ****************************************************************************/
  32. /* --------------------------------------------------------------------------------------------- */
  33. void
  34. mc_skin_hardcoded_blackwhite_colors (mc_skin_t * mc_skin)
  35. {
  36. mc_config_set_string (mc_skin->config, "core", "_default_", "default;default");
  37. mc_config_set_string (mc_skin->config, "core", "selected", "A_REVERSE");
  38. mc_config_set_string (mc_skin->config, "core", "marked", "A_BOLD");
  39. mc_config_set_string (mc_skin->config, "core", "markselect", "A_BOLD_REVERSE");
  40. mc_config_set_string (mc_skin->config, "core", "disabled", "default");
  41. mc_config_set_string (mc_skin->config, "core", "reverse", "A_REVERSE");
  42. mc_config_set_string (mc_skin->config, "dialog", "_default_", "A_REVERSE");
  43. mc_config_set_string (mc_skin->config, "dialog", "dfocus", "A_BOLD");
  44. mc_config_set_string (mc_skin->config, "dialog", "dhotnormal", "A_UNDERLINE");
  45. mc_config_set_string (mc_skin->config, "dialog", "dhotfocus", "A_UNDERLINE");
  46. mc_config_set_string (mc_skin->config, "error", "_default_", "A_BOLD");
  47. mc_config_set_string (mc_skin->config, "menu", "_default_", "A_REVERSE");
  48. mc_config_set_string (mc_skin->config, "menu", "menuhot", "A_BOLD");
  49. mc_config_set_string (mc_skin->config, "menu", "menusel", "default");
  50. mc_config_set_string (mc_skin->config, "menu", "menuhotsel", "A_UNDERLINE");
  51. mc_config_set_string (mc_skin->config, "menu", "menuinactive", "A_REVERSE");
  52. mc_config_set_string (mc_skin->config, "popupmenu", "_default_", "A_REVERSE");
  53. mc_config_set_string (mc_skin->config, "popupmenu", "menusel", "default");
  54. mc_config_set_string (mc_skin->config, "popupmenu", "menutitle", "A_REVERSE");
  55. mc_config_set_string (mc_skin->config, "statusbar", "_default_", "A_REVERSE");
  56. mc_config_set_string (mc_skin->config, "help", "_default_", "A_REVERSE");
  57. mc_config_set_string (mc_skin->config, "help", "helpitalic", "A_REVERSE");
  58. mc_config_set_string (mc_skin->config, "help", "helpbold", "A_REVERSE");
  59. mc_config_set_string (mc_skin->config, "help", "helpslink", "A_BOLD");
  60. mc_config_set_string (mc_skin->config, "viewer", "viewunderline", "A_UNDERLINE");
  61. mc_config_set_string (mc_skin->config, "editor", "editbold", "A_BOLD");
  62. mc_config_set_string (mc_skin->config, "editor", "editmarked", "A_REVERSE");
  63. mc_config_set_string (mc_skin->config, "editor", "editframeactive", "A_BOLD");
  64. mc_config_set_string (mc_skin->config, "editor", "editframedrag", "A_REVERSE");
  65. mc_config_set_string (mc_skin->config, "buttonbar", "hotkey", "default");
  66. mc_config_set_string (mc_skin->config, "buttonbar", "button", "A_REVERSE");
  67. }
  68. /* --------------------------------------------------------------------------------------------- */
  69. void
  70. mc_skin_hardcoded_space_lines (mc_skin_t * mc_skin)
  71. {
  72. /* single lines */
  73. set_lines ("vert", " ");
  74. set_lines ("horiz", " ");
  75. set_lines ("lefttop", " ");
  76. set_lines ("righttop", " ");
  77. set_lines ("leftbottom", " ");
  78. set_lines ("rightbottom", " ");
  79. set_lines ("topmiddle", " ");
  80. set_lines ("bottommiddle", " ");
  81. set_lines ("leftmiddle", " ");
  82. set_lines ("rightmiddle", " ");
  83. set_lines ("cross", " ");
  84. set_lines ("dvert", " ");
  85. set_lines ("dhoriz", " ");
  86. set_lines ("dlefttop", " ");
  87. set_lines ("drighttop", " ");
  88. set_lines ("dleftbottom", " ");
  89. set_lines ("drightbottom", " ");
  90. set_lines ("dtopmiddle", " ");
  91. set_lines ("dbottommiddle", " ");
  92. set_lines ("dleftmiddle", " ");
  93. set_lines ("drightmiddle", " ");
  94. }
  95. /* --------------------------------------------------------------------------------------------- */
  96. void
  97. mc_skin_hardcoded_ugly_lines (mc_skin_t * mc_skin)
  98. {
  99. /* single lines */
  100. set_lines ("vert", "|");
  101. set_lines ("horiz", "-");
  102. set_lines ("lefttop", "+");
  103. set_lines ("righttop", "+");
  104. set_lines ("leftbottom", "+");
  105. set_lines ("rightbottom", "+");
  106. set_lines ("topmiddle", "-");
  107. set_lines ("bottommiddle", "-");
  108. set_lines ("leftmiddle", "|");
  109. set_lines ("rightmiddle", "|");
  110. set_lines ("cross", "+");
  111. /* double lines */
  112. set_lines ("dvert", "|");
  113. set_lines ("dhoriz", "-");
  114. set_lines ("dlefttop", "+");
  115. set_lines ("drighttop", "+");
  116. set_lines ("dleftbottom", "+");
  117. set_lines ("drightbottom", "+");
  118. set_lines ("dtopmiddle", "-");
  119. set_lines ("dbottommiddle", "-");
  120. set_lines ("dleftmiddle", "|");
  121. set_lines ("drightmiddle", "|");
  122. }
  123. /* --------------------------------------------------------------------------------------------- */