rave icon indicating copy to clipboard operation
rave copied to clipboard

Add blip text as HTML, Textile, Markdown

Open bil-bas opened this issue 16 years ago • 3 comments

Currently, we can only set_text and append_text in plain text. Wave also accepts text as HTML and so, if we use a markup generator (textile/markdown) to convert those markups into HTML, we can send them too.

blip.set_text("- *frog* _eats_ a -fish-", :format => :textile)

bil-bas avatar Dec 10 '09 12:12 bil-bas

Yep, this is done and dusted (HTML and Textile). Added Redcloth to the build, but it isn't bloated so I hope that isn't a problem.

bil-bas avatar Dec 10 '09 17:12 bil-bas

RedCloth has some issues with converting some special characters to HTML (e.g. '&#xxx' format), which are displayed unchanged by Wave. Either need to turn off that conversion or manually return tags to the original character after RedCloth has parsed.

bil-bas avatar Dec 11 '09 09:12 bil-bas

Checked what Java does and it just trims the tags out and adds that to the local content. If we do this (or continue with the currently better, but still inaccurate, method) then really we need to put a "incorrect" flag on the text. Any attempts to further modify it, except append_text or set_text should be prevented, since it is likely to cause corruption of the text that is actually stored by wave.

bil-bas avatar Dec 15 '09 10:12 bil-bas