| CODENOTIFIER | HelpYou are not signed inSign in |
Project: BlueCloth
Revision: 69
Author: ged
Date: 25 Aug 2004 01:27:15
Diff at Trac: http://www.deveiate.org/projects/BlueCloth/changeset/69
Changes:- Fixed bug introduced by the last bugfix, fixed tests that missed the new bug.
Files:| ... | ...@@ -557,10 +557,11 @@ | |
| 557 | 557 | |
| 558 | 558 | str.gsub( CodeBlockRegexp ) {|block| |
| 559 | 559 | codeblock = $1 |
| 560 | remainder = $2 | |
| 560 | 561 | |
| 561 | 562 | # Generate the codeblock |
| 562 | %{\n\n<pre><code>%s\n</code></pre>\n\n} % | |
| 563 | [ encode_code( outdent(codeblock), rs ).rstrip ] | |
| 563 | %{\n\n<pre><code>%s\n</code></pre>\n\n%s} % | |
| 564 | [ encode_code( outdent(codeblock), rs ).rstrip, remainder ] | |
| 564 | 565 | } |
| 565 | 566 | end |
| 566 | 567 |
| ... | ...@@ -531,11 +531,14 @@ | |
| 531 | 531 | |
| 532 | 532 | some.code > some.other_code |
| 533 | 533 | |
| 534 | Some stuff. | |
| 534 | 535 | --- Should become: |
| 535 | 536 | <p>This is a chunk of code:</p> |
| 536 | 537 | |
| 537 | 538 | <pre><code>some.code > some.other_code |
| 538 | 539 | </code></pre> |
| 540 | ||
| 541 | <p>Some stuff.</p> | |
| 539 | 542 | >>> |
| 540 | 543 | |
| 541 | 544 | # Para plus code block (literal tab, no colon) |
| ... | ...@@ -544,11 +547,14 @@ | |
| 544 | 547 | |
| 545 | 548 | some.code > some.other_code |
| 546 | 549 | |
| 550 | Some stuff. | |
| 547 | 551 | --- Should become: |
| 548 | 552 | <p>This is a chunk of code</p> |
| 549 | 553 | |
| 550 | 554 | <pre><code>some.code > some.other_code |
| 551 | 555 | </code></pre> |
| 556 | ||
| 557 | <p>Some stuff.</p> | |
| 552 | 558 | >>> |
| 553 | 559 | |
| 554 | 560 | # Para plus code block (tab-width spaces) |
| ... | ...@@ -557,11 +563,14 @@ | |
| 557 | 563 | |
| 558 | 564 | some.code > some.other_code |
| 559 | 565 | |
| 566 | Some stuff. | |
| 560 | 567 | --- Should become: |
| 561 | 568 | <p>This is a chunk of code:</p> |
| 562 | 569 | |
| 563 | 570 | <pre><code>some.code > some.other_code |
| 564 | 571 | </code></pre> |
| 572 | ||
| 573 | <p>Some stuff.</p> | |
| 565 | 574 | >>> |
| 566 | 575 | |
| 567 | 576 | # Para plus code block (tab-width spaces, no colon) |
| ... | ...@@ -570,11 +579,14 @@ | |
| 570 | 579 | |
| 571 | 580 | some.code > some.other_code |
| 572 | 581 | |
| 582 | Some stuff. | |
| 573 | 583 | --- Should become: |
| 574 | 584 | <p>This is a chunk of code</p> |
| 575 | 585 | |
| 576 | 586 | <pre><code>some.code > some.other_code |
| 577 | 587 | </code></pre> |
| 588 | ||
| 589 | <p>Some stuff.</p> | |
| 578 | 590 | >>> |
| 579 | 591 | |
| 580 | 592 | # Colon with preceeding space |
| ... | ...@@ -582,11 +594,15 @@ | |
| 582 | 594 | A regular paragraph, without a colon. : |
| 583 | 595 | |
| 584 | 596 | This is a code block. |
| 597 | ||
| 598 | Some stuff. | |
| 585 | 599 | --- Should become: |
| 586 | 600 | <p>A regular paragraph, without a colon. :</p> |
| 587 | 601 | |
| 588 | 602 | <pre><code>This is a code block. |
| 589 | 603 | </code></pre> |
| 604 | ||
| 605 | <p>Some stuff.</p> | |
| 590 | 606 | >>> |
| 591 | 607 | |
| 592 | 608 | # Single colon |
| ... | ...@@ -595,11 +611,14 @@ | |
| 595 | 611 | |
| 596 | 612 | some.code > some.other_code |
| 597 | 613 | |
| 614 | Some stuff. | |
| 598 | 615 | --- Should become: |
| 599 | 616 | <p>:</p> |
| 600 | 617 | |
| 601 | 618 | <pre><code>some.code > some.other_code |
| 602 | 619 | </code></pre> |
| 620 | ||
| 621 | <p>Some stuff.</p> | |
| 603 | 622 | >>> |
| 604 | 623 | |
| 605 | 624 | # Preserve leading whitespace (Bug #541) |
| ... | ...@@ -611,6 +630,8 @@ | |
| 611 | 630 | x = 1 |
| 612 | 631 | x += 1 |
| 613 | 632 | puts x |
| 633 | ||
| 634 | Some stuff. | |
| 614 | 635 | --- Should become: |
| 615 | 636 | <p>Examples:</p> |
| 616 | 637 | |
| ... | ...@@ -620,6 +641,8 @@ | |
| 620 | 641 | x += 1 |
| 621 | 642 | puts x |
| 622 | 643 | </code></pre> |
| 644 | ||
| 645 | <p>Some stuff.</p> | |
| 623 | 646 | >>> |
| 624 | 647 | |
| 625 | 648 |