sotte / presenting.vim

A simple tool for presenting slides in vim based on text files.
MIT License
300 stars 50 forks source link

Add top margin option. Set options to wrap text. Fix doc. #21

Closed PhilRunninger closed 7 years ago

PhilRunninger commented 7 years ago

The changes are pretty well documented in the commit messages. In summary:

sotte commented 7 years ago

Thanks for the contributions!

Also, can you add an example in the examples/ folder which demonstrates the feature. You can use vim's modeline to set the presenting_top_margin.

Now that I'm thinking about it I'm wondering if "add top margins" is really what we want, or if it's rather a "center vertically" feature. What do you think?

PhilRunninger commented 7 years ago

Regarding the example, I may be missing something, but isn't the modeline used to set options, not variables? Vim is complaining that presenting_top_margin is an unknown option.

<!--
vim:tw=40:ft=markdown:presenting_top_margin=5
-->

Centering vertically could be challenging if lines start wrapping. We can count the lines of text in the array and make a calculation that way, but if a line displays on more than one, the text will be too low on the screen. Personally, I like seeing the slides with a consistent top margin, à la Powerpoint.

sotte commented 7 years ago

Hey Phil,

you're totally right about the modeline and variables. For whatever reason I thought you can do it. So no example file needed.

Centering vertically: maybe it's too much trouble. I'll merge it and we can change it later (if someone want to do that :)).

Thanks for the contributions!