【问题标题】:reveal.js resize fonts to fit the slidereveal.js 调整字体大小以适应幻灯片
【发布时间】:2015-12-04 00:10:18
【问题描述】:

我正在尝试了解如何自动调整字体大小以适合我的幻灯片。 我正在使用远程演示控制器主库 https://github.com/thehung111/remote-presentation-controller

我已尝试添加到 /punlic/css/main.cc

@media screen and (max-width: 1024px), (max-height: 600px) {
    .reveal .slides {
        font-size: 0.82em;
    }
}

@media screen and (max-width: 700px), (max-height: 400px) {
    .reveal .slides {
        font-size: 0.66em;
    }
}

但它不起作用。 知道我需要做什么吗? 谢谢,

【问题讨论】:

    标签: reveal.js


    【解决方案1】:

    你总是可以试试这个。

    它看起来与您想要实现的目标非常相似。

    更改屏幕宽度以进行测试。 示例: https://chunksnbits.github.io/jquery-quickfit/

    安装: https://github.com/chunksnbits/jquery-quickfit

    【讨论】:

    • 那行不通。 $('section').quickfit({'min': 6, 'max': 36}) 还调整了标题的大小,文本仍然从幻灯片中流出。 $('section').children().not('h1').not('h2').not('h3').quickfit({'min': 6, 'max': 36}) 使所有 li 元素的大小为 6pt。 - 我可以在你的回答中要求一个完整的解决方案吗?
    猜你喜欢
    • 2013-10-14
    • 1970-01-01
    • 1970-01-01
    • 2019-09-22
    • 1970-01-01
    • 2012-11-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多