Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2010-03-23 12:11:41

whaleen
Member
From: Portland
Registered: 2006-05-11
Posts: 373
Website

Textile in TextEdit

Where to start looking to build a plugin that would allow you to run a neighboring window in TextEdit (mac .txt editor also with .rtf) that show the HTML conversion upon button click, holler, or zap?

Anyone heard of such a thing?

For those of you who word process (computationally) in Textile, this might appeal to you.

Last edited by whaleen (2010-03-24 07:37:32)


txtstrap (Textpattern + Twitter Bootstrap + etc…)

Offline

#2 2010-03-24 02:10:04

jm
Plugin Author
From: Missoula, MT
Registered: 2005-11-27
Posts: 1,746
Website

Re: Textile in TextEdit

You’ll want to look into using redcloth from the command line (e.g., redcloth my-file.textile > my-file.html). Make sure you have a 4.x.x version of redcloth, unless you want broken bc blocks. Not sure if TextEdit has any hooks, but you could probably write an AppleScript to take the current file and feed it to redcloth.

I really wouldn’t bother with TextEdit though (it’s mainly an RTF editor like WordPad) — check out MacVim (or Vim with +ruby) with Textile.vim or TextMate. With Textile.vim, you just do :TextilePreview and it’ll open Safari with the rendered page. Of course, with either editor you can just create a mapping to redcloth too.

Offline

Board footer

Powered by FluxBB