[Vimoutliner] vorst

Steve Litt slitt at troubleshooters.com
Thu Oct 18 12:15:20 EDT 2007


On Thursday 18 October 2007 09:12, David J Patrick wrote:
> In my ongoing quest to use vimoutliner for EVERYTHING I have been working
> hard at getting (for starters) a really good, LaTeX book output. At my
> urging, a rather brilliant friend has hacked together a perl script
> (otl2latex; to be shared once stable) that does quite a reasonable job.

I'm on that like a squirrel on a tree! Please, please please have your friend 
contact me to find out the kind of stuff I do with LaTeX, and please please 
please urge him to use reasonable Perl and use it consistently so the rest of 
us can personalize it.

> In researching that, we stumble upon Vim reStructured Text
> (http://skawina.eu.org/mikolaj/vst.html#l9696toc9696) that looks like it
> should offer a fairly wide range reStructured output, to html or latex,
> with all the sectiony, formaty goodness. The trouble is, that the
> differences between a valid .otl and a valid .vst are considerable, and
> that would make it an either/or (vimoutliner/vst) proposition UNLESS some
> genius finds a way to fuse the two. 

I might be able to help. See my Easy Menu Definition Language (EMDL) at 
http://www.troubleshooters.com/projects/emdl/index.htm. Valid menus are much 
more restrictive than valid .otl files, so I made a set of standards and an 
otl to .mnu converter with built in validator. I think the same thing can be 
done with LaTeX.

I'd envision that the outline has only text, calls to environments (paragraph 
delineated), calls to commands, and calls to character styles. Environments 
would look like this:

env_story This is a story about the lion and the mouse. The mouse picks a 
thorn out of the lion's paw.
env_story The morale of the story is that whatever whatefver whatever
From here on down is plain text.

A new comma comma command could be made to make this paragraph the same style 
as the last one, just to make things easy.

A characterstyle would be cs_example{something like this}, or somesuch.

I'm not sure how commands would be implemented.

Anyway, nowhere in the outline itself would these environments, commands and 
character styles be defined. Those would be defined in a stylesheet to be 
merged with the translated outline.


> It's in python, and (to my feeble mind) 
> I imagine that it /should/ be possible rewrite the VimReStructuredText plug
> in to harmonize with VO format (ignore, or USE leading whitespace as
> section definition, drop requirement for blank spaces, and way more)
> presuming said python genius/ VO hacker found it an itch worth scratching.
>
> It would mean (to selfish ol' me) that I could slam things together in VO
> and blatt out rich and finely formatted web pages and hardcopy.

You would be doing the world a HUGE favor. Please bear in mind that because 
this is the antitheses of WYSIWYG, the conversion/display must happen very 
rapidly so that the author can continuously check his work. Also, it must be 
very simple to reduce errors preventing compilation (and all the debugging 
work that goes with them). A lightning quick "lint" program might be in 
order, and I think I can do that in C if needbe (I'd prototype it in Ruby, 
and then when it's exactly right do it in C so it rips).

If you do this, and if it turns out to really be practical for writing books 
(I won't know that til I've used it), your project will probably get its own 
Linux Productivity Magazine issue.

>
> Not expecting anything, but I just wanted to put these bugs in your ears.

Here's where I see the big problem. This might turn out a lot like LyX -- it's 
very easy to author the stuff, but defining the necessary environments, 
commands and character styles (which are really just commands) can be 
exceptionally difficult. I don't know how much you've done with LaTeX (for 
all I know you make me look like a raw newbie), but for most people, LaTeX is 
an almost unclimbable learning slope. Perhaps, within the confines of my time 
constraints, I can make some documentation complete with examples of common 
things to do.

You do know don't you that this won't be easy?
>
> thanks for humouring the idea,

Thanks for giving it to us!

SteveT

Steve Litt
Author: Universal Troubleshooting Process books and courseware
http://www.troubleshooters.com/


More information about the VimOutliner mailing list