我正在尝试使用 repo readme 中记录的 reveal.js 的 pdf 导出选项.
我有以下问题:
- 我在 chrome 打印窗口中没有看到布局选项(横向与纵向)
- 只打印第一张幻灯片
不知道我做错了什么或如何解决它。我在这个 example file 上使用来自 Github 的最新版本的 reveal.js css 等(sha:131c00689a4c7a18e5c991fc8102347e4594b5d4) .
我在 Ubuntu 14.04 上使用 Google-chrome 版本 34.0.1847.132
最佳答案
删除
<link rel="stylesheet" media="print" href="reveal.js/css/print/pdf.css" />
添加
<!-- If the query includes 'print-pdf', include the PDF print sheet --> <script> if( window.location.search.match( /print-pdf/gi ) ) { var link = document.createElement( 'link' ); link.rel = 'stylesheet'; link.type = 'text/css'; link.href = 'reveal.js/css/print/pdf.css'; document.getElementsByTagName( 'head' )[0].appendChild( link ); } </script>
将
?print-pdf
添加到 URL 的末尾,例如将.../index.html#
更改为.../index.html?print-pdf#
关于javascript - reveal.js 打印到 pdf 只打印第一张幻灯片?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23571270/