-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Beamer frame attributes not always output when using pandoc-ling filter #15
Comments
It looks like maybe the frame attribute classes are getting removed from first level headings at line Lines 210 to 222 in a9eae71
I don't know enough about Lua to suggest a fix, but I think any solution would probably need to take into account lines 230-238 as well: Lines 228 to 238 in a9eae71
|
add "restart" class instead of overwriting other classes only remove inserted "restart" class
The change in my fork seems to work? Again, I don't know much Lua, but the changes I made:
The removal code is based on the example for minted here: Running on the modified filter on my example maintains the beamer frame attributes, and I tried it with a few examples from the readme here that didn't seem to break anything. But, again, I don't know much about Lua. :) |
I just realized I probably broke the intent of tracking the headers by accidental removing the check for "restart". :) |
I did some further tests, and I guess I didn't actually seem to break it. But something doesn't seem quite right about skipping the check. |
use List.insert to add "restart" class to header added back check that "restart" class had been added
Ok. I figured out the reason it still worked was because only the first level headers were being converted to divs. The second commit in my fork (somelinguist@4e4da4e) adds back the check and is probably more efficient than my first attempt. It just inserts the "restart" class at index 1 so that it's easy to check later and remove. |
Hello,
Thanks for this wonderful filter.
I was trying to create a slide show with Beamer using the pandoc-ling filter. However, I discovered that when using the filter, Beamer frame attributes don't always get passed through.
For example, given the following input:
If I run pandoc without the filter, for example
pandoc -t beamer beamer-ling.md --pdf-engine=xelatex -o beamer.tex
, I get the following tex output. Note the[t]
option passed to the frame environments:However, when running pandoc with the filter (
pandoc -t beamer beamer-ling.md --pdf-engine=xelatex --lua-filter ./pandoc-ling.lua -o beamer-ling.tex
), even when not including and kinds of numbered/glossed examples, the[t]
option is not included in the tex output for the frames:Any ideas?
Thanks again for this great filter!
The text was updated successfully, but these errors were encountered: