Professional Web Applications Themes

[ANN] RedCloth 2.0 -- A Textile Humane Web Text Generator - Ruby

h1. RedCloth h2. Humane text for Ruby RedCloth is a module for using Textile in Ruby. Textile is a text format. A very simple text format. Another stab at making readable text that can be converted to HTML. Textile is (c) 2003 Dean Allen. All rights reserved. You can read more "here":http://www.textism.com/tools/textile/. RedCloth is also based on PyTextile, which is: Copyright (c) 2003, "Mark Pilgrim":http://diveintomark.org/. All rights reserved. You can read more about PyTextile "here":http://diveintomark.org/projects/pytextile/. h2. About Version 2.0 Last year, a new version of Textile was released for PHP. This 2.0 version allowed specification of style attributes and element ...

  1. #1

    Default [ANN] RedCloth 2.0 -- A Textile Humane Web Text Generator

    h1. RedCloth


    h2. Humane text for Ruby

    RedCloth is a module for using Textile in Ruby. Textile is a text
    format. A very simple text format. Another stab at making readable
    text that can be converted to HTML.

    Textile is (c) 2003 Dean Allen. All rights reserved. You can read more
    "here":http://www.textism.com/tools/textile/.

    RedCloth is also based on PyTextile, which is: Copyright (c) 2003, "Mark
    Pilgrim":http://diveintomark.org/. All rights reserved. You can read
    more about PyTextile "here":http://diveintomark.org/projects/pytextile/.

    h2. About Version 2.0

    Last year, a new version of Textile was released for PHP. This 2.0
    version allowed specification of style attributes and element
    alignments. Below, is a header element with a green font coloring added.

    <pre>
    h2{color:green}. This is a title
    </pre>

    You can also add elements ids, classes, and language settings.

    <pre>
    h2(class)
    h2(#id)
    h2[language]
    </pre>

    RedCloth 2.0 has been completely recoded and tested with Ruby versions
    1.8.0 and 1.6.8. There are some outstanding bugs with using RedCloth in
    1.6.8, but I'm pushing it out the door anyway. Hopefully, I can get
    some further revisions up in the coming weeks.

    <http://www.textpattern.com/help/?item=attributes>h2. Installing RedCloth

    To install RedCloth via raa-install:

    <pre>
    raa-install -i redcloth
    </pre>

    Or "download
    RedCloth":http://prdownloads.sourceforge.net/yaml4r/redcloth-2.0.tar.gz
    and simply run the install.rb like so:

    <pre>
    ruby install.rb config
    ruby install.rb setup
    sudo ruby install.rb install
    </pre>


    h2. Using RedCloth

    The RedCloth class is an extension of Ruby's String class. Use it like
    you would a String:

    <pre> [/ref]
    => "*strong text* and _emphasized text_" [/ref]
    => "*strong words* and _emphasized words_"
    </pre>

    To generate HTML from your RedCloth object, use the RedCloth#to_html
    method:

    <pre> [/ref]
    => "<p><strong>strong words</strong> and <em>emphasized words</em></p>"
    </pre>


    h2. The Textile language

    See the "Textile home page":http://www.textism.com/tools/textile/ for
    details on the Textile language.


    why Guest

  2. #2

    Default Re: [ANN] RedCloth 2.0 -- A Textile Humane Web Text Generator

    Yura Kloubakov wrote:
     
    >
    >How does it compare to reStructuredText?
    >http://docutils.sourceforge.net/rst.html
    >
    >Yura.
    >
    >[/ref]
    I'm not terribly familiar with reStructuredText, so another might be
    better suited. reST is a more expansive (markup for definitions, field
    lists) and makes use of footnotes for linking. reST is also bit more
    focused on making the text look like it's just formatted text. You
    still often have to use <pre> in Textile.

    However, Textile is geared more toward HTML generation, so there are
    hooks into using style sheets. Also, tables are simpler. The HTML
    generator does smart quotes, title/alt tags, citations, acronyms. I
    think there are ways of doing this in reST.

    reST is probably a better overall design, especially if you want PDF
    output for your text. Textile is great for HTML stuffs.

    _why




    why Guest

  3. #3

    Default Re: [ANN] RedCloth 2.0 -- A Textile Humane Web Text Generator

    * why the lucky stiff <net> [Feb, 06 2004 23:40]: 

    good summary I'd say.
     

    i quite like the balance between not too much markup while still
    allowing for flexibility. the problem with reST in my opinion (why I
    can't use it for my thesis anymore) is that it is too limiting, you
    can't add new stuff yourself easily.
     

    Rant
    ----

    mm...I'm getting the "Donald Knuth Complex" here, while writing my
    masters' thesis...I still need to write all the code for my project, yet
    i'm still contemplating writing my own doentation format as none of
    the one i've ever used satisfy me. DocBook is great, if it weren't for
    its verbosity and shoddy design (honestly, it's too limiting). relax ng
    and docbook 5 will hopefully aleviate this somewhat...and, i'm sorry,
    but MathML2 is great, if you're a markup processor. if you're a
    doentor, it's truly far too verbose, even with content markup...and
    the fact that the DocBook MathML Module requires you to use the mml:
    namespace you don't really gain much by having short element names such
    as <mml:cn>1</mml:cn>...I'm thinking of doing some xslt preprocessing of
    my DocBook files to make this a bit simpler, but in the end it's still a
    bit too verbose...and the fact that there doesn't seem to be a good way
    to have more than one DocBook Module in a doent really s.
    My vision is to have something much like reST without all the html
    related shortcuts (the multitude of ways to link stuff really annoys me)
    and also not be so limiting in always maintaining WYSIWYG because it
    makes parsing hell and it's not always necessary to be this way to be
    appreciable text-wise. Anyway, math and graphics would be drawn by
    eqn(1) and pic(1) from [gt]roff, which are very textual in their
    functionality, which would keep to the reST spirit. Anyway, I dunno...I
    really just need to start focusing on the stuff I really need to get
    done...*sigh*...

    What I would like to see in a good doentation format is:

    * PS/PDF output backends
    * Math support done in an intuitive way
    * Graphics support done in an intuitive way
    * Markup that doesn't chop the input into bits while still allowing you
    to markup easily and with meaning (such as adding emphasis and so on)

    nikolai

    P.S.
    TeX produces wonderful output, but is crap when it comes to actually
    writing doents with it, I'm sorry to say. And its graphics packages
    are rather retarded as well.

    Lout is stupid...end of story

    roff is ugly and unreadable, breaks up input too much...xml is easier to
    follow...

    hm, that's about the end of my list of formats I've ooked at

    D.S.

    --
    ::: name: Nikolai Weibull :: aliases: pcp / lone-star / aka :::
    ::: born: Chicago, IL USA :: loc atm: Gothenburg, Sweden :::
    ::: page: www.pcppopper.org :: fun atm: gf,lps,ruby,lisp,war3 :::
    main(){printf(&linux["\021%six\012\0"],(linux)["have"]+"fun"-97);}


    Nikolai Guest

  4. Moderated Post

    Default [OT] Re: [ANN] RedCloth 2.0 -- A Textile Humane Web Text Generator

    Removed by Administrator
    Gavin Guest
    Moderated Post

  5. #5

    Default Re: [ANN] RedCloth 2.0 -- A Textile Humane Web Text Generator

    Nikolai Weibull (org) wrote:
     

    Have you tried with ConTeXt?

    Sincerely,
    Gour

    --
    Gour
    inet.hr
    Registered Linux User #278493



    Gour Guest

  6. #6

    Default Re: [ANN] RedCloth 2.0 -- A Textile Humane Web Text Generator

    * Gour <inet.hr> [Feb, 07 2004 12:37]:
    [TeX bashing by me]
     

    hm, no...but i'm looking at it now...i'm getting the feeling that it's a
    lot about layout, not a lot about making TeX easier to deal with?
    There's XML related stuff there though, so may be of interest, thanks.
    Btw, do you have any example files one could look at?
    nikolai

    --
    ::: name: Nikolai Weibull :: aliases: pcp / lone-star / aka :::
    ::: born: Chicago, IL USA :: loc atm: Gothenburg, Sweden :::
    ::: page: www.pcppopper.org :: fun atm: gf,lps,ruby,lisp,war3 :::
    main(){printf(&linux["\021%six\012\0"],(linux)["have"]+"fun"-97);}


    Nikolai Guest

Similar Threads

  1. yet another xml generator
    By Martin in forum PERL Modules
    Replies: 5
    Last Post: March 20th, 10:40 AM
  2. Illustrator 10.0 - Windows/swatches/-pantone textile swatch
    By Jordana_Fleischer@adobeforums.com in forum Adobe Illustrator Windows
    Replies: 4
    Last Post: May 14th, 04:46 AM
  3. insert textile in illustrator
    By amycuty@adobeforums.com in forum Adobe Illustrator Macintosh
    Replies: 3
    Last Post: April 8th, 09:56 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139