ExamSimple 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. checksums.yaml +7 -0
  2. data/.coveralls.yml +1 -0
  3. data/.gitignore +15 -0
  4. data/.rspec +3 -0
  5. data/.travis.yml +5 -0
  6. data/Exam.gemspec +28 -0
  7. data/Gemfile +8 -0
  8. data/Guardfile +41 -0
  9. data/LICENSE.txt +22 -0
  10. data/README.md +48 -0
  11. data/README.rdoc +0 -0
  12. data/Rakefile +24 -0
  13. data/doc/prct10.pdf +0 -0
  14. data/doc/prct11.pdf +0 -0
  15. data/doc/prct5.pdf +0 -0
  16. data/doc/prct6.pdf +0 -0
  17. data/doc/prct7.pdf +0 -0
  18. data/doc/prct8.pdf +0 -0
  19. data/doc/prct9.pdf +0 -0
  20. data/doc/test/index.html +467 -0
  21. data/html/Exam.html +316 -0
  22. data/html/Examui.html +230 -0
  23. data/html/List.html +469 -0
  24. data/html/Object.html +119 -0
  25. data/html/Question.html +357 -0
  26. data/html/README_rdoc.html +82 -0
  27. data/html/TrueOrFalse.html +169 -0
  28. data/html/created.rid +10 -0
  29. data/html/fonts.css +167 -0
  30. data/html/fonts/Lato-Light.ttf +0 -0
  31. data/html/fonts/Lato-LightItalic.ttf +0 -0
  32. data/html/fonts/Lato-Regular.ttf +0 -0
  33. data/html/fonts/Lato-RegularItalic.ttf +0 -0
  34. data/html/fonts/SourceCodePro-Bold.ttf +0 -0
  35. data/html/fonts/SourceCodePro-Regular.ttf +0 -0
  36. data/html/images/add.png +0 -0
  37. data/html/images/arrow_up.png +0 -0
  38. data/html/images/brick.png +0 -0
  39. data/html/images/brick_link.png +0 -0
  40. data/html/images/bug.png +0 -0
  41. data/html/images/bullet_black.png +0 -0
  42. data/html/images/bullet_toggle_minus.png +0 -0
  43. data/html/images/bullet_toggle_plus.png +0 -0
  44. data/html/images/date.png +0 -0
  45. data/html/images/delete.png +0 -0
  46. data/html/images/find.png +0 -0
  47. data/html/images/loadingAnimation.gif +0 -0
  48. data/html/images/macFFBgHack.png +0 -0
  49. data/html/images/package.png +0 -0
  50. data/html/images/page_green.png +0 -0
  51. data/html/images/page_white_text.png +0 -0
  52. data/html/images/page_white_width.png +0 -0
  53. data/html/images/plugin.png +0 -0
  54. data/html/images/ruby.png +0 -0
  55. data/html/images/tag_blue.png +0 -0
  56. data/html/images/tag_green.png +0 -0
  57. data/html/images/transparent.png +0 -0
  58. data/html/images/wrench.png +0 -0
  59. data/html/images/wrench_orange.png +0 -0
  60. data/html/images/zoom.png +0 -0
  61. data/html/index.html +102 -0
  62. data/html/js/darkfish.js +140 -0
  63. data/html/js/jquery.js +18 -0
  64. data/html/js/navigation.js +142 -0
  65. data/html/js/search.js +109 -0
  66. data/html/js/search_index.js +1 -0
  67. data/html/js/searcher.js +228 -0
  68. data/html/rdoc.css +580 -0
  69. data/html/table_of_contents.html +159 -0
  70. data/lib/Exam.rb +2 -0
  71. data/lib/Exam/base.rb +5 -0
  72. data/lib/Exam/examen.rb +37 -0
  73. data/lib/Exam/examui.rb +27 -0
  74. data/lib/Exam/list.rb +106 -0
  75. data/lib/Exam/question.rb +44 -0
  76. data/lib/Exam/quiz.rb +52 -0
  77. data/lib/Exam/trueorfalse.rb +15 -0
  78. data/lib/Exam/version.rb +5 -0
  79. data/spec/Exam_spec.rb +392 -0
  80. data/spec/spec_helper.rb +98 -0
  81. metadata +226 -0
data/html/js/search.js ADDED
@@ -0,0 +1,109 @@
1
+ Search = function(data, input, result) {
2
+ this.data = data;
3
+ this.$input = $(input);
4
+ this.$result = $(result);
5
+
6
+ this.$current = null;
7
+ this.$view = this.$result.parent();
8
+ this.searcher = new Searcher(data.index);
9
+ this.init();
10
+ }
11
+
12
+ Search.prototype = $.extend({}, Navigation, new function() {
13
+ var suid = 1;
14
+
15
+ this.init = function() {
16
+ var _this = this;
17
+ var observer = function(e) {
18
+ switch(e.originalEvent.keyCode) {
19
+ case 38: // Event.KEY_UP
20
+ case 40: // Event.KEY_DOWN
21
+ return;
22
+ }
23
+ _this.search(_this.$input[0].value);
24
+ };
25
+ this.$input.keyup(observer);
26
+ this.$input.click(observer); // mac's clear field
27
+
28
+ this.searcher.ready(function(results, isLast) {
29
+ _this.addResults(results, isLast);
30
+ })
31
+
32
+ this.initNavigation();
33
+ this.setNavigationActive(false);
34
+ }
35
+
36
+ this.search = function(value, selectFirstMatch) {
37
+ value = jQuery.trim(value).toLowerCase();
38
+ if (value) {
39
+ this.setNavigationActive(true);
40
+ } else {
41
+ this.setNavigationActive(false);
42
+ }
43
+
44
+ if (value == '') {
45
+ this.lastQuery = value;
46
+ this.$result.empty();
47
+ this.$result.attr('aria-expanded', 'false');
48
+ this.setNavigationActive(false);
49
+ } else if (value != this.lastQuery) {
50
+ this.lastQuery = value;
51
+ this.$result.attr('aria-busy', 'true');
52
+ this.$result.attr('aria-expanded', 'true');
53
+ this.firstRun = true;
54
+ this.searcher.find(value);
55
+ }
56
+ }
57
+
58
+ this.addResults = function(results, isLast) {
59
+ var target = this.$result.get(0);
60
+ if (this.firstRun && (results.length > 0 || isLast)) {
61
+ this.$current = null;
62
+ this.$result.empty();
63
+ }
64
+
65
+ for (var i=0, l = results.length; i < l; i++) {
66
+ var item = this.renderItem.call(this, results[i]);
67
+ item.setAttribute('id', 'search-result-' + target.childElementCount);
68
+ target.appendChild(item);
69
+ };
70
+
71
+ if (this.firstRun && results.length > 0) {
72
+ this.firstRun = false;
73
+ this.$current = $(target.firstChild);
74
+ this.$current.addClass('search-selected');
75
+ }
76
+ if (jQuery.browser.msie) this.$element[0].className += '';
77
+
78
+ if (isLast) this.$result.attr('aria-busy', 'false');
79
+ }
80
+
81
+ this.move = function(isDown) {
82
+ if (!this.$current) return;
83
+ var $next = this.$current[isDown ? 'next' : 'prev']();
84
+ if ($next.length) {
85
+ this.$current.removeClass('search-selected');
86
+ $next.addClass('search-selected');
87
+ this.$input.attr('aria-activedescendant', $next.attr('id'));
88
+ this.scrollIntoView($next[0], this.$view[0]);
89
+ this.$current = $next;
90
+ this.$input.val($next[0].firstChild.firstChild.text);
91
+ this.$input.select();
92
+ }
93
+ return true;
94
+ }
95
+
96
+ this.hlt = function(html) {
97
+ return this.escapeHTML(html).
98
+ replace(/\u0001/g, '<em>').
99
+ replace(/\u0002/g, '</em>');
100
+ }
101
+
102
+ this.escapeHTML = function(html) {
103
+ return html.replace(/[&<>]/g, function(c) {
104
+ return '&#' + c.charCodeAt(0) + ';';
105
+ });
106
+ }
107
+
108
+ });
109
+
@@ -0,0 +1 @@
1
+ var search_data = {"index":{"searchIndex":["exam","examui","list","object","question","trueorfalse","<=>()","==()","compare()","each()","invert()","inverter()","new()","new()","new()","new()","new()","pop()","push()","push()","right()","to_s()","to_s()","to_s()","readme"],"longSearchIndex":["exam","examui","list","object","question","trueorfalse","question#<=>()","question#==()","examui#compare()","list#each()","list#invert()","list#inverter()","exam::new()","examui::new()","list::new()","question::new()","trueorfalse::new()","list#pop()","exam#push()","list#push()","exam#right()","exam#to_s()","list#to_s()","question#to_s()",""],"info":[["Exam","","Exam.html","","<p>Clase para la gestión de examens con preguntas.\n<p>Clase para ver las diferentes versiones de la gema\n"],["Examui","","Examui.html","","<p>Clase para la muestra de examenes con interfaz grafica.\n"],["List","","List.html","","<p>Clase para las listas doblemente enlazadas\n"],["Object","","Object.html","",""],["Question","","Question.html","","<p>Clase para la gestion de preguntas de multiples opciones.\n"],["TrueOrFalse","","TrueOrFalse.html","","<p>Clase de gestion de preguntar True or False.\n"],["<=>","Question","Question.html#method-i-3C-3D-3E","(other)",""],["==","Question","Question.html#method-i-3D-3D","(other)",""],["compare","Examui","Examui.html#method-i-compare","(useranswers)","<p>Comparacion de respuestas que se evaluan con la indicacion de cuales son\ncorrectas y cuales no.\n"],["each","List","List.html#method-i-each","()","<p>Metodo para le manejo de metodos del modulo Enumerable\n"],["invert","List","List.html#method-i-invert","(actual, &block)","<p>Metodo auxiliar que se utiliza para invertir la lista (recursividad).\n"],["inverter","List","List.html#method-i-inverter","(&block)","<p>Metodo que devuelve la lista actual invertida.\n"],["new","Exam","Exam.html#method-c-new","(o)","<p>Creacion de una isntancia a partir de una pregunta.\n"],["new","Examui","Examui.html#method-c-new","(o)","<p>inicialización de la instancia a partir de una pregunta.\n"],["new","List","List.html#method-c-new","(o)","<p>Inicializacion de una instancia de la clase Lista a partir de una Question\npregunta).\n"],["new","Question","Question.html#method-c-new","(args)","<p>Inicializacion de una nueva instancia de una nueva pregunta a partir de un\ntexto.\n"],["new","TrueOrFalse","TrueOrFalse.html#method-c-new","(args)","<p>Inicializacion de la isntancia de la clase TrueOrFalse al cual se le pasa\nun texto para la pregunta y …\n"],["pop","List","List.html#method-i-pop","()","<p>Metodo para extraer “por la cabeza” de la lista acutalmente.\n"],["push","Exam","Exam.html#method-i-push","(*input)","<p>Metodo para la inserción de preguntas sucesivamente.\n"],["push","List","List.html#method-i-push","(*input)","<p>Metodo para instertar varias preguntas sucesivamente\n"],["right","Exam","Exam.html#method-i-right","()","<p>Metodo para obtener el conjunto de respuestas correctas asociadas a las\nrespuestas.\n"],["to_s","Exam","Exam.html#method-i-to_s","()","<p>Metodo to_s.\n"],["to_s","List","List.html#method-i-to_s","()","<p>Metodo to_s\n"],["to_s","Question","Question.html#method-i-to_s","()","<p>Metodo to_s.\n"],["README","","README_rdoc.html","",""]]}}
@@ -0,0 +1,228 @@
1
+ Searcher = function(data) {
2
+ this.data = data;
3
+ this.handlers = [];
4
+ }
5
+
6
+ Searcher.prototype = new function() {
7
+ // search is performed in chunks of 1000 for non-blocking user input
8
+ var CHUNK_SIZE = 1000;
9
+ // do not try to find more than 100 results
10
+ var MAX_RESULTS = 100;
11
+ var huid = 1;
12
+ var suid = 1;
13
+ var runs = 0;
14
+
15
+ this.find = function(query) {
16
+ var queries = splitQuery(query);
17
+ var regexps = buildRegexps(queries);
18
+ var highlighters = buildHilighters(queries);
19
+ var state = { from: 0, pass: 0, limit: MAX_RESULTS, n: suid++};
20
+ var _this = this;
21
+
22
+ this.currentSuid = state.n;
23
+
24
+ if (!query) return;
25
+
26
+ var run = function() {
27
+ // stop current search thread if new search started
28
+ if (state.n != _this.currentSuid) return;
29
+
30
+ var results =
31
+ performSearch(_this.data, regexps, queries, highlighters, state);
32
+ var hasMore = (state.limit > 0 && state.pass < 4);
33
+
34
+ triggerResults.call(_this, results, !hasMore);
35
+ if (hasMore) {
36
+ setTimeout(run, 2);
37
+ }
38
+ runs++;
39
+ };
40
+ runs = 0;
41
+
42
+ // start search thread
43
+ run();
44
+ }
45
+
46
+ /* ----- Events ------ */
47
+ this.ready = function(fn) {
48
+ fn.huid = huid;
49
+ this.handlers.push(fn);
50
+ }
51
+
52
+ /* ----- Utilities ------ */
53
+ function splitQuery(query) {
54
+ return jQuery.grep(query.split(/(\s+|::?|\(\)?)/), function(string) {
55
+ return string.match(/\S/)
56
+ });
57
+ }
58
+
59
+ function buildRegexps(queries) {
60
+ return jQuery.map(queries, function(query) {
61
+ return new RegExp(query.replace(/(.)/g, '([$1])([^$1]*?)'), 'i')
62
+ });
63
+ }
64
+
65
+ function buildHilighters(queries) {
66
+ return jQuery.map(queries, function(query) {
67
+ return jQuery.map(query.split(''), function(l, i) {
68
+ return '\u0001$' + (i*2+1) + '\u0002$' + (i*2+2);
69
+ }).join('');
70
+ });
71
+ }
72
+
73
+ // function longMatchRegexp(index, longIndex, regexps) {
74
+ // for (var i = regexps.length - 1; i >= 0; i--){
75
+ // if (!index.match(regexps[i]) && !longIndex.match(regexps[i])) return false;
76
+ // };
77
+ // return true;
78
+ // }
79
+
80
+
81
+ /* ----- Mathchers ------ */
82
+
83
+ /*
84
+ * This record matches if the index starts with queries[0] and the record
85
+ * matches all of the regexps
86
+ */
87
+ function matchPassBeginning(index, longIndex, queries, regexps) {
88
+ if (index.indexOf(queries[0]) != 0) return false;
89
+ for (var i=1, l = regexps.length; i < l; i++) {
90
+ if (!index.match(regexps[i]) && !longIndex.match(regexps[i]))
91
+ return false;
92
+ };
93
+ return true;
94
+ }
95
+
96
+ /*
97
+ * This record matches if the longIndex starts with queries[0] and the
98
+ * longIndex matches all of the regexps
99
+ */
100
+ function matchPassLongIndex(index, longIndex, queries, regexps) {
101
+ if (longIndex.indexOf(queries[0]) != 0) return false;
102
+ for (var i=1, l = regexps.length; i < l; i++) {
103
+ if (!longIndex.match(regexps[i]))
104
+ return false;
105
+ };
106
+ return true;
107
+ }
108
+
109
+ /*
110
+ * This record matches if the index contains queries[0] and the record
111
+ * matches all of the regexps
112
+ */
113
+ function matchPassContains(index, longIndex, queries, regexps) {
114
+ if (index.indexOf(queries[0]) == -1) return false;
115
+ for (var i=1, l = regexps.length; i < l; i++) {
116
+ if (!index.match(regexps[i]) && !longIndex.match(regexps[i]))
117
+ return false;
118
+ };
119
+ return true;
120
+ }
121
+
122
+ /*
123
+ * This record matches if regexps[0] matches the index and the record
124
+ * matches all of the regexps
125
+ */
126
+ function matchPassRegexp(index, longIndex, queries, regexps) {
127
+ if (!index.match(regexps[0])) return false;
128
+ for (var i=1, l = regexps.length; i < l; i++) {
129
+ if (!index.match(regexps[i]) && !longIndex.match(regexps[i]))
130
+ return false;
131
+ };
132
+ return true;
133
+ }
134
+
135
+
136
+ /* ----- Highlighters ------ */
137
+ function highlightRegexp(info, queries, regexps, highlighters) {
138
+ var result = createResult(info);
139
+ for (var i=0, l = regexps.length; i < l; i++) {
140
+ result.title = result.title.replace(regexps[i], highlighters[i]);
141
+ result.namespace = result.namespace.replace(regexps[i], highlighters[i]);
142
+ };
143
+ return result;
144
+ }
145
+
146
+ function hltSubstring(string, pos, length) {
147
+ return string.substring(0, pos) + '\u0001' + string.substring(pos, pos + length) + '\u0002' + string.substring(pos + length);
148
+ }
149
+
150
+ function highlightQuery(info, queries, regexps, highlighters) {
151
+ var result = createResult(info);
152
+ var pos = 0;
153
+ var lcTitle = result.title.toLowerCase();
154
+
155
+ pos = lcTitle.indexOf(queries[0]);
156
+ if (pos != -1) {
157
+ result.title = hltSubstring(result.title, pos, queries[0].length);
158
+ }
159
+
160
+ result.namespace = result.namespace.replace(regexps[0], highlighters[0]);
161
+ for (var i=1, l = regexps.length; i < l; i++) {
162
+ result.title = result.title.replace(regexps[i], highlighters[i]);
163
+ result.namespace = result.namespace.replace(regexps[i], highlighters[i]);
164
+ };
165
+ return result;
166
+ }
167
+
168
+ function createResult(info) {
169
+ var result = {};
170
+ result.title = info[0];
171
+ result.namespace = info[1];
172
+ result.path = info[2];
173
+ result.params = info[3];
174
+ result.snippet = info[4];
175
+ return result;
176
+ }
177
+
178
+ /* ----- Searching ------ */
179
+ function performSearch(data, regexps, queries, highlighters, state) {
180
+ var searchIndex = data.searchIndex;
181
+ var longSearchIndex = data.longSearchIndex;
182
+ var info = data.info;
183
+ var result = [];
184
+ var i = state.from;
185
+ var l = searchIndex.length;
186
+ var togo = CHUNK_SIZE;
187
+ var matchFunc, hltFunc;
188
+
189
+ while (state.pass < 4 && state.limit > 0 && togo > 0) {
190
+ if (state.pass == 0) {
191
+ matchFunc = matchPassBeginning;
192
+ hltFunc = highlightQuery;
193
+ } else if (state.pass == 1) {
194
+ matchFunc = matchPassLongIndex;
195
+ hltFunc = highlightQuery;
196
+ } else if (state.pass == 2) {
197
+ matchFunc = matchPassContains;
198
+ hltFunc = highlightQuery;
199
+ } else if (state.pass == 3) {
200
+ matchFunc = matchPassRegexp;
201
+ hltFunc = highlightRegexp;
202
+ }
203
+
204
+ for (; togo > 0 && i < l && state.limit > 0; i++, togo--) {
205
+ if (info[i].n == state.n) continue;
206
+ if (matchFunc(searchIndex[i], longSearchIndex[i], queries, regexps)) {
207
+ info[i].n = state.n;
208
+ result.push(hltFunc(info[i], queries, regexps, highlighters));
209
+ state.limit--;
210
+ }
211
+ };
212
+ if (searchIndex.length <= i) {
213
+ state.pass++;
214
+ i = state.from = 0;
215
+ } else {
216
+ state.from = i;
217
+ }
218
+ }
219
+ return result;
220
+ }
221
+
222
+ function triggerResults(results, isLast) {
223
+ jQuery.each(this.handlers, function(i, fn) {
224
+ fn.call(this, results, isLast)
225
+ })
226
+ }
227
+ }
228
+
data/html/rdoc.css ADDED
@@ -0,0 +1,580 @@
1
+ /*
2
+ * "Darkfish" Rdoc CSS
3
+ * $Id: rdoc.css 54 2009-01-27 01:09:48Z deveiant $
4
+ *
5
+ * Author: Michael Granger <ged@FaerieMUD.org>
6
+ *
7
+ */
8
+
9
+ /* vim: ft=css et sw=2 ts=2 sts=2 */
10
+ /* Base Green is: #6C8C22 */
11
+
12
+ * { padding: 0; margin: 0; }
13
+
14
+ body {
15
+ background: #fafafa;
16
+ font-family: Lato, sans-serif;
17
+ font-weight: 300;
18
+ }
19
+
20
+ h1 span,
21
+ h2 span,
22
+ h3 span,
23
+ h4 span,
24
+ h5 span,
25
+ h6 span {
26
+ display: none;
27
+ padding-left: 1em;
28
+ font-size: 10px;
29
+ vertical-align: super;
30
+ }
31
+
32
+ h1:hover span,
33
+ h2:hover span,
34
+ h3:hover span,
35
+ h4:hover span,
36
+ h5:hover span,
37
+ h6:hover span {
38
+ display: inline;
39
+ }
40
+
41
+ :link,
42
+ :visited {
43
+ color: #6C8C22;
44
+ text-decoration: none;
45
+ }
46
+
47
+ :link:hover,
48
+ :visited:hover {
49
+ border-bottom: 1px dotted #6C8C22;
50
+ }
51
+
52
+ code,
53
+ pre {
54
+ font-family: "Source Code Pro", Monaco, monospace;
55
+ }
56
+
57
+ /* @group Generic Classes */
58
+
59
+ .initially-hidden {
60
+ display: none;
61
+ }
62
+
63
+ #search-field {
64
+ width: 98%;
65
+ background: white;
66
+ border: none;
67
+ height: 1.5em;
68
+ -webkit-border-radius: 4px;
69
+ -moz-border-radius: 4px;
70
+ border-radius: 4px;
71
+ text-align: left;
72
+ }
73
+ #search-field:focus {
74
+ background: #f1edba;
75
+ }
76
+ #search-field:-moz-placeholder,
77
+ #search-field::-webkit-input-placeholder {
78
+ font-weight: bold;
79
+ color: #666;
80
+ }
81
+
82
+ .missing-docs {
83
+ font-size: 120%;
84
+ background: white url(images/wrench_orange.png) no-repeat 4px center;
85
+ color: #ccc;
86
+ line-height: 2em;
87
+ border: 1px solid #d00;
88
+ opacity: 1;
89
+ padding-left: 20px;
90
+ text-indent: 24px;
91
+ letter-spacing: 3px;
92
+ font-weight: bold;
93
+ -webkit-border-radius: 5px;
94
+ -moz-border-radius: 5px;
95
+ }
96
+
97
+ .target-section {
98
+ border: 2px solid #dcce90;
99
+ border-left-width: 8px;
100
+ padding: 0 1em;
101
+ background: #fff3c2;
102
+ }
103
+
104
+ /* @end */
105
+
106
+ /* @group Index Page, Standalone file pages */
107
+ .table-of-contents ul {
108
+ margin: 1em;
109
+ list-style: none;
110
+ }
111
+
112
+ .table-of-contents ul ul {
113
+ margin-top: 0.25em;
114
+ }
115
+
116
+ .table-of-contents ul :link,
117
+ .table-of-contents ul :visited {
118
+ font-size: 16px;
119
+ }
120
+
121
+ .table-of-contents li {
122
+ margin-bottom: 0.25em;
123
+ }
124
+
125
+ .table-of-contents li .toc-toggle {
126
+ width: 16px;
127
+ height: 16px;
128
+ background: url(images/add.png) no-repeat;
129
+ }
130
+
131
+ .table-of-contents li .toc-toggle.open {
132
+ background: url(images/delete.png) no-repeat;
133
+ }
134
+
135
+ /* @end */
136
+
137
+ /* @group Top-Level Structure */
138
+
139
+ nav {
140
+ float: left;
141
+ width: 260px;
142
+ font-family: Helvetica, sans-serif;
143
+ font-size: 14px;
144
+ }
145
+
146
+ main {
147
+ display: block;
148
+ margin: 0 2em 5em 260px;
149
+ padding-left: 20px;
150
+ min-width: 340px;
151
+ font-size: 16px;
152
+ }
153
+
154
+ main h1,
155
+ main h2,
156
+ main h3,
157
+ main h4,
158
+ main h5,
159
+ main h6 {
160
+ font-family: Helvetica, sans-serif;
161
+ }
162
+
163
+ .table-of-contents main {
164
+ margin-left: 2em;
165
+ }
166
+
167
+ #validator-badges {
168
+ clear: both;
169
+ margin: 1em 1em 2em;
170
+ font-size: smaller;
171
+ }
172
+
173
+ /* @end */
174
+
175
+ /* @group navigation */
176
+ nav {
177
+ margin-bottom: 1em;
178
+ }
179
+
180
+ nav .nav-section {
181
+ margin-top: 2em;
182
+ border-top: 2px solid #aaa;
183
+ font-size: 90%;
184
+ overflow: hidden;
185
+ }
186
+
187
+ nav h2 {
188
+ margin: 0;
189
+ padding: 2px 8px 2px 8px;
190
+ background-color: #e8e8e8;
191
+ color: #555;
192
+ font-size: 125%;
193
+ text-align: center;
194
+ }
195
+
196
+ nav h3,
197
+ #table-of-contents-navigation {
198
+ margin: 0;
199
+ padding: 2px 8px 2px 8px;
200
+ text-align: right;
201
+ background-color: #e8e8e8;
202
+ color: #555;
203
+ }
204
+
205
+ nav ul,
206
+ nav dl,
207
+ nav p {
208
+ padding: 4px 8px 0;
209
+ list-style: none;
210
+ }
211
+
212
+ #project-navigation .nav-section {
213
+ margin: 0;
214
+ border-top: 0;
215
+ }
216
+
217
+ #home-section h2 {
218
+ text-align: center;
219
+ }
220
+
221
+ #table-of-contents-navigation {
222
+ font-size: 1.2em;
223
+ font-weight: bold;
224
+ text-align: center;
225
+ }
226
+
227
+ #search-section {
228
+ margin-top: 0;
229
+ border-top: 0;
230
+ }
231
+
232
+ #search-field-wrapper {
233
+ border-top: 1px solid #aaa;
234
+ border-bottom: 1px solid #aaa;
235
+ padding: 3px 8px;
236
+ background-color: #e8e8e8;
237
+ color: #555;
238
+ }
239
+
240
+ ul.link-list li {
241
+ white-space: nowrap;
242
+ line-height: 1.4em;
243
+ }
244
+
245
+ ul.link-list .type {
246
+ font-size: 8px;
247
+ text-transform: uppercase;
248
+ color: white;
249
+ background: #969696;
250
+ padding: 2px 4px;
251
+ -webkit-border-radius: 5px;
252
+ }
253
+
254
+ .calls-super {
255
+ background: url(images/arrow_up.png) no-repeat right center;
256
+ }
257
+
258
+ /* @end */
259
+
260
+ /* @group Documentation Section */
261
+ main {
262
+ color: #333;
263
+ }
264
+
265
+ main > h1:first-child,
266
+ main > h2:first-child,
267
+ main > h3:first-child,
268
+ main > h4:first-child,
269
+ main > h5:first-child,
270
+ main > h6:first-child {
271
+ margin-top: 0px;
272
+ }
273
+
274
+ main sup {
275
+ vertical-align: super;
276
+ font-size: 0.8em;
277
+ }
278
+
279
+ /* The heading with the class name */
280
+ main h1[class] {
281
+ margin-top: 0;
282
+ margin-bottom: 1em;
283
+ font-size: 2em;
284
+ color: #6C8C22;
285
+ }
286
+
287
+ main h1 {
288
+ margin: 2em 0 0.5em;
289
+ font-size: 1.7em;
290
+ }
291
+
292
+ main h2 {
293
+ margin: 2em 0 0.5em;
294
+ font-size: 1.5em;
295
+ }
296
+
297
+ main h3 {
298
+ margin: 2em 0 0.5em;
299
+ font-size: 1.2em;
300
+ }
301
+
302
+ main h4 {
303
+ margin: 2em 0 0.5em;
304
+ font-size: 1.1em;
305
+ }
306
+
307
+ main h5 {
308
+ margin: 2em 0 0.5em;
309
+ font-size: 1em;
310
+ }
311
+
312
+ main h6 {
313
+ margin: 2em 0 0.5em;
314
+ font-size: 1em;
315
+ }
316
+
317
+ main p {
318
+ margin: 0 0 0.5em;
319
+ line-height: 1.4em;
320
+ }
321
+
322
+ main pre {
323
+ margin: 1.2em 0.5em;
324
+ padding: 1em;
325
+ font-size: 0.8em;
326
+ }
327
+
328
+ main hr {
329
+ margin: 1.5em 1em;
330
+ border: 2px solid #ddd;
331
+ }
332
+
333
+ main blockquote {
334
+ margin: 0 2em 1.2em 1.2em;
335
+ padding-left: 0.5em;
336
+ border-left: 2px solid #ddd;
337
+ }
338
+
339
+ main ol,
340
+ main ul {
341
+ margin: 1em 2em;
342
+ }
343
+
344
+ main li > p {
345
+ margin-bottom: 0.5em;
346
+ }
347
+
348
+ main dl {
349
+ margin: 1em 0.5em;
350
+ }
351
+
352
+ main dt {
353
+ margin-bottom: 0.5em;
354
+ font-weight: bold;
355
+ }
356
+
357
+ main dd {
358
+ margin: 0 1em 1em 0.5em;
359
+ }
360
+
361
+ main header h2 {
362
+ margin-top: 2em;
363
+ border-width: 0;
364
+ border-top: 4px solid #bbb;
365
+ font-size: 130%;
366
+ }
367
+
368
+ main header h3 {
369
+ margin: 2em 0 1.5em;
370
+ border-width: 0;
371
+ border-top: 3px solid #bbb;
372
+ font-size: 120%;
373
+ }
374
+
375
+ .documentation-section-title {
376
+ position: relative;
377
+ }
378
+ .documentation-section-title .section-click-top {
379
+ position: absolute;
380
+ top: 6px;
381
+ left: 12px;
382
+ font-size: 10px;
383
+ color: #9b9877;
384
+ visibility: hidden;
385
+ padding-left: 0.5px;
386
+ }
387
+
388
+ .documentation-section-title:hover .section-click-top {
389
+ visibility: visible;
390
+ }
391
+
392
+ .constants-list > dl {
393
+ margin: 1em 0 2em;
394
+ border: 0;
395
+ }
396
+
397
+ .constants-list > dl dt {
398
+ margin-bottom: 0.75em;
399
+ padding-left: 0;
400
+ font-family: "Source Code Pro", Monaco, monospace;
401
+ font-size: 110%;
402
+ }
403
+
404
+ .constants-list > dl dt a {
405
+ color: inherit;
406
+ }
407
+
408
+ .constants-list > dl dd {
409
+ margin: 0 0 2em 0;
410
+ padding: 0;
411
+ color: #666;
412
+ }
413
+
414
+ .documentation-section h2 {
415
+ position: relative;
416
+ }
417
+
418
+ .documentation-section h2 a {
419
+ position: absolute;
420
+ top: 8px;
421
+ right: 10px;
422
+ font-size: 12px;
423
+ color: #9b9877;
424
+ visibility: hidden;
425
+ }
426
+
427
+ .documentation-section h2:hover a {
428
+ visibility: visible;
429
+ }
430
+
431
+ /* @group Method Details */
432
+
433
+ main .method-source-code {
434
+ display: none;
435
+ }
436
+
437
+ main .method-description .method-calls-super {
438
+ color: #333;
439
+ font-weight: bold;
440
+ }
441
+
442
+ main .method-detail {
443
+ margin-bottom: 2.5em;
444
+ cursor: pointer;
445
+ }
446
+
447
+ main .method-detail:target {
448
+ margin-left: -10px;
449
+ border-left: 10px solid #f1edba;
450
+ }
451
+
452
+ main .method-heading {
453
+ position: relative;
454
+ font-family: "Source Code Pro", Monaco, monospace;
455
+ font-size: 110%;
456
+ font-weight: bold;
457
+ color: #333;
458
+ }
459
+ main .method-heading :link,
460
+ main .method-heading :visited {
461
+ color: inherit;
462
+ }
463
+ main .method-click-advice {
464
+ position: absolute;
465
+ top: 2px;
466
+ right: 5px;
467
+ font-size: 12px;
468
+ color: #9b9877;
469
+ visibility: hidden;
470
+ padding-right: 20px;
471
+ line-height: 20px;
472
+ background: url(images/zoom.png) no-repeat right top;
473
+ }
474
+ main .method-heading:hover .method-click-advice {
475
+ visibility: visible;
476
+ }
477
+
478
+ main .method-alias .method-heading {
479
+ color: #666;
480
+ }
481
+
482
+ main .method-description,
483
+ main .aliases {
484
+ margin-top: 0.75em;
485
+ color: #333;
486
+ }
487
+
488
+ main .aliases {
489
+ padding-top: 4px;
490
+ font-style: italic;
491
+ cursor: default;
492
+ }
493
+ main .method-description ul {
494
+ margin-left: 1.5em;
495
+ }
496
+
497
+ main #attribute-method-details .method-detail:hover {
498
+ background-color: transparent;
499
+ cursor: default;
500
+ }
501
+ main .attribute-access-type {
502
+ text-transform: uppercase;
503
+ padding: 0 1em;
504
+ }
505
+ /* @end */
506
+
507
+ /* @end */
508
+
509
+ /* @group Source Code */
510
+
511
+ pre {
512
+ margin: 0.5em 0;
513
+ border: 1px dashed #999;
514
+ padding: 0.5em;
515
+ background: #262626;
516
+ color: white;
517
+ overflow: auto;
518
+ }
519
+
520
+ .ruby-constant { color: #7fffd4; background: transparent; }
521
+ .ruby-keyword { color: #00ffff; background: transparent; }
522
+ .ruby-ivar { color: #eedd82; background: transparent; }
523
+ .ruby-operator { color: #00ffee; background: transparent; }
524
+ .ruby-identifier { color: #ffdead; background: transparent; }
525
+ .ruby-node { color: #ffa07a; background: transparent; }
526
+ .ruby-comment { color: #dc0000; background: transparent; }
527
+ .ruby-regexp { color: #ffa07a; background: transparent; }
528
+ .ruby-value { color: #7fffd4; background: transparent; }
529
+
530
+ /* @end */
531
+
532
+
533
+ /* @group search results */
534
+ #search-results {
535
+ font-family: Lato, sans-serif;
536
+ font-weight: 300;
537
+ }
538
+
539
+ #search-results .search-match {
540
+ font-family: Helvetica, sans-serif;
541
+ font-weight: normal;
542
+ }
543
+
544
+ #search-results .search-selected {
545
+ background: #e8e8e8;
546
+ border-bottom: 1px solid transparent;
547
+ }
548
+
549
+ #search-results li {
550
+ list-style: none;
551
+ border-bottom: 1px solid #aaa;
552
+ margin-bottom: 0.5em;
553
+ }
554
+
555
+ #search-results li:last-child {
556
+ border-bottom: none;
557
+ margin-bottom: 0;
558
+ }
559
+
560
+ #search-results li p {
561
+ padding: 0;
562
+ margin: 0.5em;
563
+ }
564
+
565
+ #search-results .search-namespace {
566
+ font-weight: bold;
567
+ }
568
+
569
+ #search-results li em {
570
+ background: yellow;
571
+ font-style: normal;
572
+ }
573
+
574
+ #search-results pre {
575
+ margin: 0.5em;
576
+ font-family: "Source Code Pro", Monaco, monospace;
577
+ }
578
+
579
+ /* @end */
580
+