Thursday, March 21, 2013

Re: How to keep folds intact when the file is sent over mail

Hi Tim!

On Do, 21 Mär 2013, Tim Chase wrote:

> On 2013-03-21 00:15, sheetal wrote:
> > I don't konw if this is possible, but i've a text file on which
> > i've applied fold cmd using the marks, Now when i send the file to
> > over email, I want to keep the fold intact so that the other person
> > viewing the file should also see the folds, Current behaviour is
> > the person viewing the file will see all the fold extended and also
> > if we try fold using 'zc' Error saying fold not defined pops up.
> > Any pointers on this would be appreciated.
>
> You'd need to coordinate your configurations. You say that you're
> using "marks", which I presume means you're using fold markers
> (":set foldmethod=marker", note that you might have to also change
> 'commentstring' to something appropriate for the language you're
> using) rather than "set foldmethod=manual".
>
> According to
>
> :help fold-marker
>
> you can manually specify the fold-level after the markers. You can
> then have the other person set the fold-method to "marker" and then
> use "zM" to close all the folds you want closed. This gets pretty
> close to what you want, though it breaks down if you want to send
> folds that don't get closed.

I am not exactly sure, since I have never used it, but using :mkview
should create a script that when applied by the other user, he should be
able to view it exactly like the author did see it.

regards
Christian
--
Wie man sein Kind nicht nennen sollte:
Axel Zucken

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

No comments: