Rebol [ Title: "Scan Para" Date: 16-Feb-2009 Author: "Christopher Ross-Gill" Type: 'paragraph ] (pathify: [wordify any ["/" wordify]]) not-in-word any [ some space (emit copy " ") not-in-word ; keeping the following separate to allow for separate handling... | "c:" copy text pathify (emit <code> emit text emit </code>) in-word | "g:" copy text pathify (emit <code> emit text emit </code>) in-word | "f:" copy text pathify (emit <code> emit text emit </code>) in-word | "r:" copy text ["/" wordify] (emit <code> emit text emit </code>) in-word | "d:" copy text pathify (emit <code> emit text emit </code>) in-word | "e:" copy text pathify (emit <code> emit text emit </code>) in-word | "s:" copy text pathify (emit <code> emit text emit </code>) in-word | "w:" copy text pathify (emit <code> emit text emit </code>) in-word | "v:" copy text pathify (emit <code> emit text emit </code>) in-word | copy text some alphanum (emit text) in-word | newline (emit <br />) not-in-word | #":" [ block (emit values) in-word ] | #"=" [ block (emit values) in-word ; | string (emit values) in-word ] ; | #"(" [ ; "c)" (emit 169) ; | "r)" (emit 174) ; | "o)" (emit 176) ; | "tm)" (emit 8482) ; | "e)" (emit 8364) ; ] in-word | #"[" copy char number "]" (emit reduce ['link to-issue char]) | #"<" [ "i>" (emit <i>) | "/i>" (emit </i>) | "b>" (emit <b>) | "/b>" (emit </b>) | "u>" (emit <u>) | "/u>" (emit </u>) | "tt>" (emit <code>) | "/tt>" (emit </code>) ] | #"<" (emit #"<") | #">" (emit #">") | #"&" (emit #"&") | #"~" (emit either in-word? [</code>][<code>]) | #"*" (emit either in-word? [</b>][<b>]) ; | #"." ".." (emit 8230) in-word ; | #"-" ["--" (emit 8212) | "-" (emit 8211)] in-word | "\" copy char ["\" | "(" | "=" | "[" | "^"" | "'" | "." | "-"] (emit to-char char) | copy char ascii (emit char) in-word | copy char utf-8 (emit get-ucs-code char) in-word | extended (emit "[???]") | skip ]