61 |
├── .gitignore ├── assets ├── images │ ├── tab.png │ ├── icons │ │ ├── alias.png │ │ ├── bug.png │ │ ├── check.png │ │ ├── class.png │ │ ├── date.png │ │ ├── file.png │ │ ├── find.png │ │ ├── fixme.png │ │ ├── list.png │ │ ├── page.png │ │ ├── ruby.png │ │ ├── stat.png │ │ ├── tool.png │ │ ├── zoom.png │ │ ├── bullet.png │ │ ├── loading.gif │ │ ├── method.png │ │ ├── module.png │ │ ├── plugin.png │ │ ├── project.png │ │ ├── attribute.png │ │ ├── constant.png │ │ ├── singleton.png │ │ ├── bullet_minus.png │ │ └── bullet_plus.png │ └── tab_background.gif ├── javascripts │ ├── firebug.js │ ├── jquery.mousewheel.min.js │ ├── keymaster.js │ ├── main.js │ ├── quicksearch.js │ ├── handlebars.helpers.js │ ├── shortcut.js │ ├── handlebars.runtime.js │ ├── jquery.history.js │ ├── rebecca.js │ ├── rundown.js │ └── handlebars.templates.js └── stylesheets │ ├── quicksearch.css │ ├── index.css │ ├── nav.css │ └── rdoc.css ├── source └── templates │ ├── document.handlebars │ ├── title.handlebars │ ├── script.handlebars │ ├── file_stats.handlebars │ ├── footer.handlebars │ ├── method.handlebars │ ├── index.handlebars │ ├── navigation.handlebars │ └── module.handlebars ├── Rulefile ├── index.html ├── README.rdoc └── COPYING.rdoc /.gitignore: -------------------------------------------------------------------------------- 1 | .fire/digest 2 | work 3 | web 4 | -------------------------------------------------------------------------------- /assets/images/tab.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/tab.png -------------------------------------------------------------------------------- /assets/images/icons/alias.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/alias.png -------------------------------------------------------------------------------- /assets/images/icons/bug.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/bug.png -------------------------------------------------------------------------------- /assets/images/icons/check.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/check.png -------------------------------------------------------------------------------- /assets/images/icons/class.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/class.png -------------------------------------------------------------------------------- /assets/images/icons/date.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/date.png -------------------------------------------------------------------------------- /assets/images/icons/file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/file.png -------------------------------------------------------------------------------- /assets/images/icons/find.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/find.png -------------------------------------------------------------------------------- /assets/images/icons/fixme.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/fixme.png -------------------------------------------------------------------------------- /assets/images/icons/list.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/list.png -------------------------------------------------------------------------------- /assets/images/icons/page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/page.png -------------------------------------------------------------------------------- /assets/images/icons/ruby.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/ruby.png -------------------------------------------------------------------------------- /assets/images/icons/stat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/stat.png -------------------------------------------------------------------------------- /assets/images/icons/tool.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/tool.png -------------------------------------------------------------------------------- /assets/images/icons/zoom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/zoom.png -------------------------------------------------------------------------------- /assets/images/icons/bullet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/bullet.png -------------------------------------------------------------------------------- /assets/images/icons/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/loading.gif -------------------------------------------------------------------------------- /assets/images/icons/method.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/method.png -------------------------------------------------------------------------------- /assets/images/icons/module.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/module.png -------------------------------------------------------------------------------- /assets/images/icons/plugin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/plugin.png -------------------------------------------------------------------------------- /assets/images/icons/project.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/project.png -------------------------------------------------------------------------------- /assets/images/icons/attribute.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/attribute.png -------------------------------------------------------------------------------- /assets/images/icons/constant.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/constant.png -------------------------------------------------------------------------------- /assets/images/icons/singleton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/singleton.png -------------------------------------------------------------------------------- /assets/images/tab_background.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/tab_background.gif -------------------------------------------------------------------------------- /assets/images/icons/bullet_minus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/bullet_minus.png -------------------------------------------------------------------------------- /assets/images/icons/bullet_plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rubyworks/rebecca/master/assets/images/icons/bullet_plus.png -------------------------------------------------------------------------------- /source/templates/document.handlebars: -------------------------------------------------------------------------------- 1 | 2 | 3 |
14 |
15 | {{source}}
16 |
17 |
18 | {{/if}}
19 | {{source}}
23 | s around 236 | // "paragraphs" that are wrapped in non-block-level tags, such as anchors, 237 | // phrase emphasis, and spans. The list of tags we're looking for is 238 | // hard-coded: 239 | var block_tags_a = "p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math|ins|del" 240 | var block_tags_b = "p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math" 241 | 242 | // First, look for nested blocks, e.g.: 243 | //
tags around block-level tags.
390 | text = _HashHTMLBlocks(text);
391 | text = _FormParagraphs(text);
392 |
393 | return text;
394 | }
395 |
396 |
397 | var _RunSpanGamut = function(text) {
398 | //
399 | // These are all the transformations that occur *within* block-level
400 | // tags like paragraphs, headers, and list items.
401 | //
402 |
403 | text = _DoCodeSpans(text);
404 | text = _EscapeSpecialCharsWithinTagAttributes(text);
405 | text = _EncodeBackslashEscapes(text);
406 |
407 | // Process anchor and image tags. Images must come first,
408 | // because ![foo][f] looks like an anchor.
409 | text = _DoImages(text);
410 | text = _DoAnchors(text);
411 |
412 | // Make links out of things like ` Just type tags
1105 | //
1106 |
1107 | // Strip leading and trailing lines:
1108 | text = text.replace(/^\n+/g,"");
1109 | text = text.replace(/\n+$/g,"");
1110 |
1111 | var grafs = text.split(/\n{2,}/g);
1112 | var grafsOut = new Array();
1113 |
1114 | //
1115 | // Wrap tags.
1116 | //
1117 | var end = grafs.length;
1118 | for (var i=0; i ");
1128 | str += " ";
668 | foundHelper = helpers.comment;
669 | stack1 = foundHelper || depth0.comment;
670 | if(typeof stack1 === functionType) { stack1 = stack1.call(depth0, { hash: {} }); }
671 | else if(stack1=== undef) { stack1 = helperMissing.call(depth0, "comment", { hash: {} }); }
672 | buffer += escapeExpression(stack1) + " ";
699 | foundHelper = helpers.comment;
700 | stack1 = foundHelper || depth0.comment;
701 | if(typeof stack1 === functionType) { stack1 = stack1.call(depth0, { hash: {} }); }
702 | else if(stack1=== undef) { stack1 = helperMissing.call(depth0, "comment", { hash: {} }); }
703 | buffer += escapeExpression(stack1) + "
\n");
421 |
422 | return text;
423 | }
424 |
425 | var _EscapeSpecialCharsWithinTagAttributes = function(text) {
426 | //
427 | // Within tags -- meaning between < and > -- encode [\ ` * _] so they
428 | // don't conflict with their use in Markdown for code, italics and strong.
429 | //
430 |
431 | // Build a regex to find HTML tags and comments. See Friedl's
432 | // "Mastering Regular Expressions", 2nd Ed., pp. 200-201.
433 | var regex = /(<[a-z\/!$]("[^"]*"|'[^']*'|[^'">])*>|)/gi;
434 |
435 | text = text.replace(regex, function(wholeMatch) {
436 | var tag = wholeMatch.replace(/(.)<\/?code>(?=.)/g,"$1`");
437 | tag = escapeCharacters(tag,"\\`*_");
438 | return tag;
439 | });
440 |
441 | return text;
442 | }
443 |
444 | var _DoAnchors = function(text) {
445 | //
446 | // Turn RDoc and Markdown link shortcuts into XHTML tags.
447 | //
448 |
449 | //
450 | // First, handle reference-style links: [link text] [id]
451 | //
452 |
453 | /*
454 | text = text.replace(/
455 | ( // wrap whole match in $1
456 | \[
457 | (
458 | (?:
459 | \[[^\]]*\] // allow brackets nested one level
460 | |
461 | [^\[] // or anything else
462 | )*
463 | )
464 | \]
465 |
466 | [ ]? // one optional space
467 | (?:\n[ ]*)? // one optional newline followed by spaces
468 |
469 | \[
470 | (.*?) // id = $3
471 | \]
472 | )()()()() // pad remaining backreferences
473 | /g,_DoAnchors_callback);
474 | */
475 | text = text.replace(/(\[((?:\[[^\]]*\]|[^\[\]])*)\][ ]?(?:\n[ ]*)?\[(.*?)\])()()()()/g,writeAnchorTag);
476 |
477 | //
478 | // Next, RDoc inline-style links: {link text}[url "optional title"]
479 | //
480 |
481 | /*
482 | text = text.replace(/
483 | ( // wrap whole match in $1
484 | \{
485 | (
486 | (?:
487 | \{[^\}]*\] // allow brackets nested one level
488 | |
489 | [^\{\}] // or anything else
490 | )
491 | )
492 | \}
493 | \[ // literal paren
494 | [ \t]*
495 | () // no id, so leave $3 empty
496 | (.*?)>? // href = $4
497 | [ \t]*
498 | ( // $5
499 | (['"]) // quote char = $6
500 | (.*?) // Title = $7
501 | \6 // matching quote
502 | [ \t]* // ignore any spaces/tabs between closing quote and )
503 | )? // title is optional
504 | \]
505 | )
506 | /g,writeAnchorTag);
507 | */
508 | text = text.replace(/(\{((?:\{[^\}]*\}|[^\{\}])*)\}\[[ \t]*()(.*?)>?[ \t]*((['"])(.*?)\6[ \t]*)?\])/g,writeAnchorTag);
509 |
510 | //
511 | // Next, Mardown inline-style links: [link text](url "optional title")
512 | //
513 |
514 | /*
515 | text = text.replace(/
516 | ( // wrap whole match in $1
517 | \[
518 | (
519 | (?:
520 | \[[^\]]*\] // allow brackets nested one level
521 | |
522 | [^\[\]] // or anything else
523 | )
524 | )
525 | \]
526 | \( // literal paren
527 | [ \t]*
528 | () // no id, so leave $3 empty
529 | (.*?)>? // href = $4
530 | [ \t]*
531 | ( // $5
532 | (['"]) // quote char = $6
533 | (.*?) // Title = $7
534 | \6 // matching quote
535 | [ \t]* // ignore any spaces/tabs between closing quote and )
536 | )? // title is optional
537 | \)
538 | )
539 | /g,writeAnchorTag);
540 | */
541 | text = text.replace(/(\[((?:\[[^\]]*\]|[^\[\]])*)\]\([ \t]*()(.*?)>?[ \t]*((['"])(.*?)\6[ \t]*)?\))/g,writeAnchorTag);
542 |
543 | //
544 | // Last, handle reference-style shortcuts: [link text]
545 | // These must come last in case you've also got [link test][1]
546 | // or [link test](/foo)
547 | //
548 |
549 | /*
550 | text = text.replace(/
551 | ( // wrap whole match in $1
552 | \[
553 | ([^\[\]]+) // link text = $2; can't contain '[' or ']'
554 | \]
555 | )()()()()() // pad rest of backreferences
556 | /g, writeAnchorTag);
557 | */
558 | text = text.replace(/(\[([^\[\]]+)\])()()()()()/g, writeAnchorTag);
559 |
560 | return text;
561 | }
562 |
563 | var writeAnchorTag = function(wholeMatch,m1,m2,m3,m4,m5,m6,m7) {
564 | if (m7 == undefined) m7 = "";
565 | var whole_match = m1;
566 | var link_text = m2;
567 | var link_id = m3.toLowerCase();
568 | var url = m4;
569 | var title = m7;
570 |
571 | if (url == "") {
572 | if (link_id == "") {
573 | // lower-case and turn embedded newlines into spaces
574 | link_id = link_text.toLowerCase().replace(/ ?\n/g," ");
575 | }
576 | url = "#"+link_id;
577 |
578 | if (g_urls.get(link_id) != undefined) {
579 | url = g_urls.get(link_id);
580 | if (g_titles.get(link_id) != undefined) {
581 | title = g_titles.get(link_id);
582 | }
583 | }
584 | else {
585 | if (whole_match.search(/\(\s*\)$/m)>-1) {
586 | // Special case for explicit empty url
587 | url = "";
588 | } else {
589 | return whole_match;
590 | }
591 | }
592 | }
593 |
594 | url = escapeCharacters(url,"*_");
595 | var result = "" + link_text + "";
604 |
605 | return result;
606 | }
607 |
608 |
609 | var _DoImages = function(text) {
610 | //
611 | // Turn Markdown image shortcuts into tags.
612 | //
613 |
614 | //
615 | // First, handle reference-style labeled images: ![alt text][id]
616 | //
617 |
618 | /*
619 | text = text.replace(/
620 | ( // wrap whole match in $1
621 | !\[
622 | (.*?) // alt text = $2
623 | \]
624 |
625 | [ ]? // one optional space
626 | (?:\n[ ]*)? // one optional newline followed by spaces
627 |
628 | \[
629 | (.*?) // id = $3
630 | \]
631 | )()()()() // pad rest of backreferences
632 | /g,writeImageTag);
633 | */
634 | text = text.replace(/(!\[(.*?)\][ ]?(?:\n[ ]*)?\[(.*?)\])()()()()/g,writeImageTag);
635 |
636 | //
637 | // Next, handle inline images: 
638 | // Don't forget: encode * and _
639 |
640 | /*
641 | text = text.replace(/
642 | ( // wrap whole match in $1
643 | !\[
644 | (.*?) // alt text = $2
645 | \]
646 | \s? // One optional whitespace character
647 | \( // literal paren
648 | [ \t]*
649 | () // no id, so leave $3 empty
650 | (\S+?)>? // src url = $4
651 | [ \t]*
652 | ( // $5
653 | (['"]) // quote char = $6
654 | (.*?) // title = $7
655 | \6 // matching quote
656 | [ \t]*
657 | )? // title is optional
658 | \)
659 | )
660 | /g,writeImageTag);
661 | */
662 | text = text.replace(/(!\[(.*?)\]\s?\([ \t]*()(\S+?)>?[ \t]*((['"])(.*?)\6[ \t]*)?\))/g,writeImageTag);
663 |
664 | return text;
665 | }
666 |
667 | var writeImageTag = function(wholeMatch,m1,m2,m3,m4,m5,m6,m7) {
668 | var whole_match = m1;
669 | var alt_text = m2;
670 | var link_id = m3.toLowerCase();
671 | var url = m4;
672 | var title = m7;
673 |
674 | if (!title) title = "";
675 |
676 | if (url == "") {
677 | if (link_id == "") {
678 | // lower-case and turn embedded newlines into spaces
679 | link_id = alt_text.toLowerCase().replace(/ ?\n/g," ");
680 | }
681 | url = "#"+link_id;
682 |
683 | if (g_urls.get(link_id) != undefined) {
684 | url = g_urls.get(link_id);
685 | if (g_titles.get(link_id) != undefined) {
686 | title = g_titles.get(link_id);
687 | }
688 | }
689 | else {
690 | return whole_match;
691 | }
692 | }
693 |
694 | alt_text = alt_text.replace(/"/g,""");
695 | url = escapeCharacters(url,"*_");
696 | var result = "
";
708 |
709 | return result;
710 | }
711 |
712 |
713 | var _DoHeaders = function(text) {
714 |
715 | // Setext-style headers:
716 | // Header 1
717 | // ========
718 | //
719 | // Header 2
720 | // --------
721 | //
722 | text = text.replace(/^(.+)[ \t]*\n=+[ \t]*\n+/gm,
723 | function(wholeMatch,m1){return hashBlock("
" + _RunSpanGamut(m1) + "
");});
724 |
725 | text = text.replace(/^(.+)[ \t]*\n-+[ \t]*\n+/gm,
726 | function(matchFound,m1){return hashBlock("" + _RunSpanGamut(m1) + "
");});
727 |
728 | // atx-style headers:
729 | // # Header 1
730 | // ## Header 2
731 | // ## Header 2 with closing hashes ##
732 | // ...
733 | // ###### Header 6
734 | //
735 |
736 | /*
737 | text = text.replace(/
738 | ^(\#{1,6}) // $1 = string of #'s
739 | [ \t]*
740 | (.+?) // $2 = Header text
741 | [ \t]*
742 | \#* // optional closing #'s (not counted)
743 | \n+
744 | /gm, function() {...});
745 | */
746 |
747 | text = text.replace(/^([#=]{1,6})[ \t]*(.+?)[ \t]*\#*\n+/gm,
748 | function(wholeMatch,m1,m2) {
749 | var h_level = m1.length;
750 | return hashBlock("` blocks.
923 | //
924 |
925 | // attacklab: sentinel workarounds for lack of \A and \Z, safari\khtml bug
926 | text += "~0";
927 |
928 | //text = text.replace(/(?:\n\n|^)((?:(?:[ ]{2}|\t).*\n+)+)(\n*[ ]{0,1}[^ \t\n]|(?=~0))/g,
929 | text = text.replace(_RE_DoCodeBlocks,
930 | function(wholeMatch,m1,m2) {
931 | var codeblock = m1;
932 | var nextChar = m2;
933 |
934 | codeblock = _EncodeCode( _Outdent(codeblock));
935 | codeblock = _Detab(codeblock);
936 | codeblock = codeblock.replace(/^\n+/g,""); // trim leading newlines
937 | codeblock = codeblock.replace(/\n+$/g,""); // trim trailing whitespace
938 |
939 | codeblock = "
";
940 |
941 | return hashBlock(codeblock) + nextChar;
942 | }
943 | );
944 |
945 | // attacklab: strip sentinel
946 | text = text.replace(/~0/,"");
947 |
948 | return text;
949 | }
950 |
951 | var hashBlock = function(text) {
952 | text = text.replace(/(^\n+|\n+$)/g,"");
953 | return "\n\n~K" + (g_html_blocks.push(text)-1) + "K\n\n";
954 | }
955 |
956 |
957 | var _DoCodeSpans = function(text) {
958 | //
959 | // * Backtick quotes are used for " + codeblock + "\n spans.
960 | //
961 | // * You can use multiple backticks as the delimiters if you want to
962 | // include literal backticks in the code span. So, this input:
963 | //
964 | // Just type ``foo `bar` baz`` at the prompt.
965 | //
966 | // Will translate to:
967 | //
968 | // foo `bar` baz at the prompt.`bar` ...
981 | //
982 |
983 | /*
984 | text = text.replace(/
985 | (^|[^\\]) // Character before opening ` can't be a backslash
986 | (`+) // $2 = Opening run of `
987 | ( // $3 = The code block
988 | [^\r]*?
989 | [^`] // attacklab: work around lack of lookbehind
990 | )
991 | \2 // Matching closer
992 | (?!`)
993 | /gm, function(){...});
994 | */
995 |
996 | text = text.replace(/(^|[^\\])(`+)([^\r]*?[^`])\2(?!`)/gm,
997 | function(wholeMatch,m1,m2,m3,m4) {
998 | var c = m3;
999 | c = c.replace(/^([ \t]*)/g,""); // leading whitespace
1000 | c = c.replace(/[ \t]*$/g,""); // trailing whitespace
1001 | c = _EncodeCode(c);
1002 | return m1+""+c+"";
1003 | });
1004 |
1005 | return text;
1006 | }
1007 |
1008 |
1009 | var _EncodeCode = function(text) {
1010 | //
1011 | // Encode/escape certain characters inside Markdown code runs.
1012 | // The point is that in code, these characters are literals,
1013 | // and lose their special Markdown meanings.
1014 | //
1015 | // Encode all ampersands; HTML entities are not
1016 | // entities within a Markdown code span.
1017 | text = text.replace(/&/g,"&");
1018 |
1019 | // Do the angle bracket song and dance:
1020 | text = text.replace(//g,">");
1022 |
1023 | // Now, escape characters that are magic in Markdown:
1024 | text = escapeCharacters(text,"\*_{}[]\\",false);
1025 |
1026 | // jj the line above breaks this:
1027 | //---
1028 |
1029 | //* Item
1030 |
1031 | // 1. Subitem
1032 |
1033 | // special char: *
1034 | //---
1035 |
1036 | return text;
1037 | }
1038 |
1039 |
1040 | var _DoItalicsAndBold = function(text) {
1041 |
1042 | // must go first:
1043 | text = text.replace(/(\*\*|__)(?=\S)([^\r]*?\S[\*_]*)\1/g,
1044 | "$2");
1045 |
1046 | text = text.replace(/(\*|_)(?=\S)([^\r]*?\S)\1/g,
1047 | "$2");
1048 |
1049 | return text;
1050 | }
1051 |
1052 |
1053 | var _DoBlockQuotes = function(text) {
1054 |
1055 | /*
1056 | text = text.replace(/
1057 | ( // Wrap whole match in $1
1058 | (
1059 | ^[ \t]*>[ \t]? // '>' at the start of a line
1060 | .+\n // rest of the first line
1061 | (.+\n)* // subsequent consecutive lines
1062 | \n* // blanks
1063 | )+
1064 | )
1065 | /gm, function(){...});
1066 | */
1067 |
1068 | text = text.replace(/((^[ \t]*>[ \t]?.+\n(.+\n)*\n*)+)/gm,
1069 | function(wholeMatch,m1) {
1070 | var bq = m1;
1071 |
1072 | // attacklab: hack around Konqueror 3.5.4 bug:
1073 | // "----------bug".replace(/^-/g,"") == "bug"
1074 |
1075 | bq = bq.replace(/^[ \t]*>[ \t]?/gm,"~0"); // trim one level of quoting
1076 |
1077 | // attacklab: clean up hack
1078 | bq = bq.replace(/~0/g,"");
1079 |
1080 | bq = bq.replace(/^[ \t]+$/gm,""); // trim whitespace-only lines
1081 | bq = _RunBlockGamut(bq); // recurse
1082 |
1083 | bq = bq.replace(/(^|\n)/g,"$1 ");
1084 | // These leading spaces screw with content, so we need to fix that:
1085 | bq = bq.replace(
1086 | /(\s*
[^\r]+?<\/pre>)/gm,
1087 | function(wholeMatch,m1) {
1088 | var pre = m1;
1089 | // attacklab: hack around Konqueror 3.5.4 bug:
1090 | pre = pre.replace(/^ /mg,"~0");
1091 | pre = pre.replace(/~0/g,"");
1092 | return pre;
1093 | });
1094 |
1095 | return hashBlock("\n" + bq + "\n
");
1096 | });
1097 | return text;
1098 | }
1099 |
1100 |
1101 | var _FormParagraphs = function(text) {
1102 | //
1103 | // Params:
1104 | // $text - string to process with html \n ";
28 | foundHelper = helpers.requires;
29 | stack1 = foundHelper || depth0.requires;
30 | tmp1 = self.program(2, program2, data);
31 | tmp1.hash = {};
32 | tmp1.fn = tmp1;
33 | tmp1.inverse = self.noop;
34 | if(foundHelper && typeof stack1 === functionType) { stack1 = stack1.call(depth0, tmp1); }
35 | else { stack1 = blockHelperMissing.call(depth0, stack1, tmp1); }
36 | if(stack1 || stack1 === 0) { buffer += stack1; }
37 | buffer += "\n
\n File Stats
\n \n
\n
\n
\n \n
\nDocuments
\n Alphabetical Index
\n\n ";
200 | foundHelper = helpers.documents;
201 | stack1 = foundHelper || depth0.documents;
202 | stack1 = (stack1 === null || stack1 === undefined || stack1 === false ? stack1 : stack1.length);
203 | stack2 = helpers['if'];
204 | tmp1 = self.program(1, program1, data);
205 | tmp1.hash = {};
206 | tmp1.fn = tmp1;
207 | tmp1.inverse = self.noop;
208 | stack1 = stack2.call(depth0, stack1, tmp1);
209 | if(stack1 || stack1 === 0) { buffer += stack1; }
210 | buffer += "\n\n \n Class Index
\n Method Index
\n ";
358 | foundHelper = helpers.source;
359 | stack1 = foundHelper || depth0.source;
360 | if(typeof stack1 === functionType) { stack1 = stack1.call(depth0, { hash: {} }); }
361 | else if(stack1=== undef) { stack1 = helperMissing.call(depth0, "source", { hash: {} }); }
362 | buffer += escapeExpression(stack1) + "\n ";
383 | foundHelper = helpers.name;
384 | stack1 = foundHelper || depth0.name;
385 | if(typeof stack1 === functionType) { stack1 = stack1.call(depth0, { hash: {} }); }
386 | else if(stack1=== undef) { stack1 = helperMissing.call(depth0, "name", { hash: {} }); }
387 | buffer += escapeExpression(stack1) + "
\n ";
388 | return buffer;}
389 |
390 | function program3(depth0,data) {
391 |
392 | var buffer = "", stack1, stack2;
393 | buffer += "\n Parent
\n \n ";
394 | foundHelper = helpers.superclass;
395 | stack1 = foundHelper || depth0.superclass;
396 | stack2 = helpers['if'];
397 | tmp1 = self.program(4, program4, data);
398 | tmp1.hash = {};
399 | tmp1.fn = tmp1;
400 | tmp1.inverse = self.noop;
401 | stack1 = stack2.call(depth0, stack1, tmp1);
402 | if(stack1 || stack1 === 0) { buffer += stack1; }
403 | buffer += "\n
\n Namespace
\n \n ";
428 | foundHelper = helpers.modules;
429 | stack1 = foundHelper || depth0.modules;
430 | foundHelper = helpers.doc;
431 | stack2 = foundHelper || depth0.doc;
432 | tmp1 = self.program(7, program7, data);
433 | tmp1.hash = {};
434 | tmp1.fn = tmp1;
435 | tmp1.inverse = self.noop;
436 | if(foundHelper && typeof stack2 === functionType) { stack1 = stack2.call(depth0, stack1, tmp1); }
437 | else { stack1 = blockHelperMissing.call(depth0, stack2, stack1, tmp1); }
438 | if(stack1 || stack1 === 0) { buffer += stack1; }
439 | buffer += "\n\n ";
440 | foundHelper = helpers.classes;
441 | stack1 = foundHelper || depth0.classes;
442 | foundHelper = helpers.doc;
443 | stack2 = foundHelper || depth0.doc;
444 | tmp1 = self.program(9, program9, data);
445 | tmp1.hash = {};
446 | tmp1.fn = tmp1;
447 | tmp1.inverse = self.noop;
448 | if(foundHelper && typeof stack2 === functionType) { stack1 = stack2.call(depth0, stack1, tmp1); }
449 | else { stack1 = blockHelperMissing.call(depth0, stack2, stack1, tmp1); }
450 | if(stack1 || stack1 === 0) { buffer += stack1; }
451 | buffer += "\n
\n Included Modules
\n \n ";
499 | foundHelper = helpers.includes;
500 | stack1 = foundHelper || depth0.includes;
501 | foundHelper = helpers.doc;
502 | stack2 = foundHelper || depth0.doc;
503 | tmp1 = self.program(12, program12, data);
504 | tmp1.hash = {};
505 | tmp1.fn = tmp1;
506 | tmp1.inverse = self.noop;
507 | if(foundHelper && typeof stack2 === functionType) { stack1 = stack2.call(depth0, stack1, tmp1); }
508 | else { stack1 = blockHelperMissing.call(depth0, stack2, stack1, tmp1); }
509 | if(stack1 || stack1 === 0) { buffer += stack1; }
510 | buffer += "\n
\n Extension Modules
\n \n ";
532 | foundHelper = helpers.extensions;
533 | stack1 = foundHelper || depth0.extensions;
534 | foundHelper = helpers.doc;
535 | stack2 = foundHelper || depth0.doc;
536 | tmp1 = self.program(15, program15, data);
537 | tmp1.hash = {};
538 | tmp1.fn = tmp1;
539 | tmp1.inverse = self.noop;
540 | if(foundHelper && typeof stack2 === functionType) { stack1 = stack2.call(depth0, stack1, tmp1); }
541 | else { stack1 = blockHelperMissing.call(depth0, stack2, stack1, tmp1); }
542 | if(stack1 || stack1 === 0) { buffer += stack1; }
543 | buffer += "\n
\n Constants
\n \n ";
565 | foundHelper = helpers.constants;
566 | stack1 = foundHelper || depth0.constants;
567 | foundHelper = helpers.doc;
568 | stack2 = foundHelper || depth0.doc;
569 | tmp1 = self.program(18, program18, data);
570 | tmp1.hash = {};
571 | tmp1.fn = tmp1;
572 | tmp1.inverse = self.noop;
573 | if(foundHelper && typeof stack2 === functionType) { stack1 = stack2.call(depth0, stack1, tmp1); }
574 | else { stack1 = blockHelperMissing.call(depth0, stack2, stack1, tmp1); }
575 | if(stack1 || stack1 === 0) { buffer += stack1; }
576 | buffer += "\n
\n Attributes
\n\n ";
608 | foundHelper = helpers.accessors;
609 | stack1 = foundHelper || depth0.accessors;
610 | stack2 = helpers.each;
611 | tmp1 = self.program(21, program21, data);
612 | tmp1.hash = {};
613 | tmp1.fn = tmp1;
614 | tmp1.inverse = self.noop;
615 | stack1 = stack2.call(depth0, stack1, tmp1);
616 | if(stack1 || stack1 === 0) { buffer += stack1; }
617 | buffer += "\n Public Class Methods
\n ";
787 | stack1 = "public";
788 | stack2 = "class";
789 | foundHelper = helpers.methods_by;
790 | stack3 = foundHelper || depth0.methods_by;
791 | tmp1 = self.program(28, program28, data);
792 | tmp1.hash = {};
793 | tmp1.fn = tmp1;
794 | tmp1.inverse = self.noop;
795 | if(foundHelper && typeof stack3 === functionType) { stack1 = stack3.call(depth0, stack2, stack1, tmp1); }
796 | else { stack1 = blockHelperMissing.call(depth0, stack3, stack2, stack1, tmp1); }
797 | if(stack1 || stack1 === 0) { buffer += stack1; }
798 | buffer += "\n Private Class Methods
\n ";
814 | stack1 = "private";
815 | stack2 = "class";
816 | foundHelper = helpers.methods_by;
817 | stack3 = foundHelper || depth0.methods_by;
818 | tmp1 = self.program(31, program31, data);
819 | tmp1.hash = {};
820 | tmp1.fn = tmp1;
821 | tmp1.inverse = self.noop;
822 | if(foundHelper && typeof stack3 === functionType) { stack1 = stack3.call(depth0, stack2, stack1, tmp1); }
823 | else { stack1 = blockHelperMissing.call(depth0, stack3, stack2, stack1, tmp1); }
824 | if(stack1 || stack1 === 0) { buffer += stack1; }
825 | buffer += "\n Protected Class Methods
\n ";
841 | stack1 = "protected";
842 | stack2 = "class";
843 | foundHelper = helpers.methods_by;
844 | stack3 = foundHelper || depth0.methods_by;
845 | tmp1 = self.program(34, program34, data);
846 | tmp1.hash = {};
847 | tmp1.fn = tmp1;
848 | tmp1.inverse = self.noop;
849 | if(foundHelper && typeof stack3 === functionType) { stack1 = stack3.call(depth0, stack2, stack1, tmp1); }
850 | else { stack1 = blockHelperMissing.call(depth0, stack3, stack2, stack1, tmp1); }
851 | if(stack1 || stack1 === 0) { buffer += stack1; }
852 | buffer += "\n Public Instance Methods
\n ";
868 | stack1 = "public";
869 | stack2 = "instance";
870 | foundHelper = helpers.methods_by;
871 | stack3 = foundHelper || depth0.methods_by;
872 | tmp1 = self.program(37, program37, data);
873 | tmp1.hash = {};
874 | tmp1.fn = tmp1;
875 | tmp1.inverse = self.noop;
876 | if(foundHelper && typeof stack3 === functionType) { stack1 = stack3.call(depth0, stack2, stack1, tmp1); }
877 | else { stack1 = blockHelperMissing.call(depth0, stack3, stack2, stack1, tmp1); }
878 | if(stack1 || stack1 === 0) { buffer += stack1; }
879 | buffer += "\n Private Instance Methods
\n ";
895 | stack1 = "private";
896 | stack2 = "instance";
897 | foundHelper = helpers.methods_by;
898 | stack3 = foundHelper || depth0.methods_by;
899 | tmp1 = self.program(40, program40, data);
900 | tmp1.hash = {};
901 | tmp1.fn = tmp1;
902 | tmp1.inverse = self.noop;
903 | if(foundHelper && typeof stack3 === functionType) { stack1 = stack3.call(depth0, stack2, stack1, tmp1); }
904 | else { stack1 = blockHelperMissing.call(depth0, stack3, stack2, stack1, tmp1); }
905 | if(stack1 || stack1 === 0) { buffer += stack1; }
906 | buffer += "\n Protected Instance Methods
\n ";
922 | stack1 = "protected";
923 | stack2 = "instance";
924 | foundHelper = helpers.methods_by;
925 | stack3 = foundHelper || depth0.methods_by;
926 | tmp1 = self.program(43, program43, data);
927 | tmp1.hash = {};
928 | tmp1.fn = tmp1;
929 | tmp1.inverse = self.noop;
930 | if(foundHelper && typeof stack3 === functionType) { stack1 = stack3.call(depth0, stack2, stack1, tmp1); }
931 | else { stack1 = blockHelperMissing.call(depth0, stack3, stack2, stack1, tmp1); }
932 | if(stack1 || stack1 === 0) { buffer += stack1; }
933 | buffer += "\n In Files
\n \n ";
1097 | foundHelper = helpers.files;
1098 | stack1 = foundHelper || depth0.files;
1099 | foundHelper = helpers.doc;
1100 | stack2 = foundHelper || depth0.doc;
1101 | tmp1 = self.program(45, program45, data);
1102 | tmp1.hash = {};
1103 | tmp1.fn = tmp1;
1104 | tmp1.inverse = self.noop;
1105 | if(foundHelper && typeof stack2 === functionType) { stack1 = stack2.call(depth0, stack1, tmp1); }
1106 | else { stack1 = blockHelperMissing.call(depth0, stack2, stack1, tmp1); }
1107 | if(stack1 || stack1 === 0) { buffer += stack1; }
1108 | buffer += "\n
\n \n \n ";
1128 | return buffer;}
1129 | function program2(depth0,data) {
1130 |
1131 | var buffer = "", stack1, stack2;
1132 | buffer += "\n Documents
\n \n ";
1118 | foundHelper = helpers.documents;
1119 | stack1 = foundHelper || depth0.documents;
1120 | tmp1 = self.program(2, program2, data);
1121 | tmp1.hash = {};
1122 | tmp1.fn = tmp1;
1123 | tmp1.inverse = self.noop;
1124 | if(foundHelper && typeof stack1 === functionType) { stack1 = stack1.call(depth0, tmp1); }
1125 | else { stack1 = blockHelperMissing.call(depth0, stack1, tmp1); }
1126 | if(stack1 || stack1 === 0) { buffer += stack1; }
1127 | buffer += "\n
\n \n
\n\n \n ";
1210 | foundHelper = helpers.documents;
1211 | stack1 = foundHelper || depth0.documents;
1212 | stack1 = (stack1 === null || stack1 === undefined || stack1 === false ? stack1 : stack1.length);
1213 | stack2 = helpers['if'];
1214 | tmp1 = self.program(1, program1, data);
1215 | tmp1.hash = {};
1216 | tmp1.fn = tmp1;
1217 | tmp1.inverse = self.noop;
1218 | stack1 = stack2.call(depth0, stack1, tmp1);
1219 | if(stack1 || stack1 === 0) { buffer += stack1; }
1220 | buffer += "\n\n \n \n \n \n\n \n Class Index\n \n
\n \n\n
\n \n \n ";
1221 | foundHelper = helpers.modules;
1222 | stack1 = foundHelper || depth0.modules;
1223 | tmp1 = self.program(4, program4, data);
1224 | tmp1.hash = {};
1225 | tmp1.fn = tmp1;
1226 | tmp1.inverse = self.noop;
1227 | if(foundHelper && typeof stack1 === functionType) { stack1 = stack1.call(depth0, tmp1); }
1228 | else { stack1 = blockHelperMissing.call(depth0, stack1, tmp1); }
1229 | if(stack1 || stack1 === 0) { buffer += stack1; }
1230 | buffer += "\n
\n \n \n\n Method Index\n \n
\n \n
\n \n \n ";
1231 | foundHelper = helpers.methods;
1232 | stack1 = foundHelper || depth0.methods;
1233 | tmp1 = self.program(6, program6, data);
1234 | tmp1.hash = {};
1235 | tmp1.fn = tmp1;
1236 | tmp1.inverse = self.noop;
1237 | if(foundHelper && typeof stack1 === functionType) { stack1 = stack1.call(depth0, tmp1); }
1238 | else { stack1 = blockHelperMissing.call(depth0, stack1, tmp1); }
1239 | if(stack1 || stack1 === 0) { buffer += stack1; }
1240 | buffer += "\n
\n \n
\n ";
1266 | return buffer;}
1267 |
1268 | buffer += "\n\n\n ";
1261 | foundHelper = helpers.source;
1262 | stack1 = foundHelper || depth0.source;
1263 | if(typeof stack1 === functionType) { stack1 = stack1.call(depth0, { hash: {} }); }
1264 | else if(stack1=== undef) { stack1 = helperMissing.call(depth0, "source", { hash: {} }); }
1265 | buffer += escapeExpression(stack1) + "\n \n ";
1273 | foundHelper = helpers.name;
1274 | stack1 = foundHelper || depth0.name;
1275 | if(typeof stack1 === functionType) { stack1 = stack1.call(depth0, { hash: {} }); }
1276 | else if(stack1=== undef) { stack1 = helperMissing.call(depth0, "name", { hash: {} }); }
1277 | buffer += escapeExpression(stack1) + "
\n
\n ";
1278 | foundHelper = helpers.uri;
1279 | stack1 = foundHelper || depth0.uri;
1280 | stack2 = helpers['if'];
1281 | tmp1 = self.program(1, program1, data);
1282 | tmp1.hash = {};
1283 | tmp1.fn = tmp1;
1284 | tmp1.inverse = self.noop;
1285 | stack1 = stack2.call(depth0, stack1, tmp1);
1286 | if(stack1 || stack1 === 0) { buffer += stack1; }
1287 | buffer += "\n ";
1288 | foundHelper = helpers.source;
1289 | stack1 = foundHelper || depth0.source;
1290 | stack2 = helpers['if'];
1291 | tmp1 = self.program(3, program3, data);
1292 | tmp1.hash = {};
1293 | tmp1.fn = tmp1;
1294 | tmp1.inverse = self.noop;
1295 | stack1 = stack2.call(depth0, stack1, tmp1);
1296 | if(stack1 || stack1 === 0) { buffer += stack1; }
1297 | buffer += "\n";
1305 | foundHelper = helpers.title;
1306 | stack1 = foundHelper || depth0.title;
1307 | if(typeof stack1 === functionType) { stack1 = stack1.call(depth0, { hash: {} }); }
1308 | else if(stack1=== undef) { stack1 = helperMissing.call(depth0, "title", { hash: {} }); }
1309 | buffer += escapeExpression(stack1) + "
\n\n
\n\n";
1310 | return buffer;});
1311 | })();
--------------------------------------------------------------------------------
\n README\n