[TxMt] Re: Blogging and code
Allan Odgaard
mailinglist at textmate.org
Sat Dec 6 11:25:24 UTC 2008
On 4 Dec 2008, at 18:36, Andrea Crotti wrote:
> I discovered the blogging bundle [...] I paste code I need to use
> the <pre> (or the
> equivalent in markup or textile) tag which keeps the indentation but
> hides
> part of the code if I enlarge the font on my browser.
>
> I could also limit the lenght of the strings but it does not solve
> completely the problem...
Put this in the CSS to get a scrollbar on demand: pre { overflow:
auto; }
> It would be also nice some sintax highlighting and better
> formatting, any
> advices?
You can use Bundles → TextMate → Paste Document / Selection
Online…
This pastes to pastie and there is instructions on how to embed the
pastie in your blog posts (pastie does a very nice presentation of the
source and it is based on how TextMate parses it, so you can paste
subsets of code / data formats and still get proper highlight, it even
strips leading indent).
> [...] Is it also possible to attach automatically binary and
> text files directly from textmate or not? (didn't see that function).
You can drag images to your blog post, this uploads them on the server
and inserts a link in the document. Nothing is added for binary or
text, but could be done by modifying the image drag command.
More information about the textmate
mailing list