[TxMt] Reformat paragraph and the LaTeX mode

Charilaos Skiadas cskiadas at uchicago.edu
Sun Jan 8 23:30:12 UTC 2006


Marco,
On Jan 8, 2006, at 2:57 PM, Marco Kuhlmann wrote:

>     Dear Textmates,
>
> I am currently evaluating Textmate as a substitute for Emacs.  My  
> first impression is really good (especially due to the excellent  
> documentation), but now I have encountered a problem that I cannot  
> resolve by myself.  I hope you can help me with it.
>
Welcome.
>
> The corresponding action in Textmate (Control-Q) produces this:
>
This command is for plain text files. You can try the "tidy" command  
in the LaTeX bundle (bound to ctrl-shift-h I think), though I am not  
sure it does exactly what you want. I think it will try to tidy the  
entire document though, which might not be exactly what you need.

In general, the LaTeX and Source bundles are the places to look at  
for LaTeX related tasks.
>
> I wonder if there is any way to tell Textmate that in LaTeX mode, a  
> paragraph should only stretch from the beginning of an \item to the  
> beginning of the next \item (or the \end{...} token), rather than  
> between empty lines? (This is what AucTeX does in the Emacs setting.)
>
That's not the way to do this in TextMate, I think. You would  
probably want to write a command to do what you want, or mess with  
the tidy command a bit.

Did you create this text in TextMate? If so, would you mind telling  
me the steps you took? The way I would naturally do it in TM, using  
the "insert environment..." and "insert item..." commands of the  
LaTeX bundle, each new item line would be indented by default, so  
this issue would not arise.
If it did arise, as in your case, I would select the rows, switch to  
columnar editing mode and press tab, thus inserting a tab in each line.

Coming from emacs, you might want to consider altering your workflow  
a bit to adjust to "the TM way of doing things". Lots of things are  
exactly the same, others are similar, and others yet are completely  
different. In particular, there are not many things in common between  
AUCTeX and TM's LaTeX bundle. Have a look at the bundle's README  
(available from the bundle through its "help" command) for a  
description of what you can do.

Feel free to keep on pestering the list with questions, or try the  
#textmate irc channel as well.
Good luck.
> Any help is appreciated.
>
>     Best,
>     Marco

Haris






More information about the textmate mailing list