iPhone 中的字体显示

发布于 2024-09-05 22:29:46 字数 139 浏览 3 评论 0原文

我开发了一个简单的移动页面;尽管我将其设置为 33px 并且 iPhone 的屏幕分辨率为 320 X 480,但显示的字体很小。

有谁知道为什么它这么小? 或者屏幕分辨率不是 320 X 480,因为它可以缩放。那么如何让字体自动适应分辨率呢?

I develop a simple mobile page; the font displayed is very samll although I set it as 33px and the screen resolution for iPhone is 320 X 480.

Does anyone know why it is so small?
Or the screen resolution is not 320 X 480 since it can be zoomed. Then how do I make the font to be adapted to the resolution automatically?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

梦言归人 2024-09-12 22:29:46

Safari 可以放大和缩小,因此 CSS 像素并不总是等于屏幕像素(尤其是当 iPhone 4 的屏幕密度更大时 - 你不会希望你的网站大小只是 1/4,因为有更多像素填充到显示器中!)。

您可以使用特殊的元标记关闭 Safari 的缩放功能,如 Apple 文档中描述

<meta name="viewport" content="user-scalable=no, width=device-width" />

Safari can be zoomed in and out, so a CSS pixel doesn't always equal a screen pixel (especially when the iPhone 4's denser screen comes out - you wouldn't want your website to be 1/4 the size just because there are more pixels stuffed into the display!).

You can turn off Safari's zooming with a special meta tag, as described in the Apple docs:

<meta name="viewport" content="user-scalable=no, width=device-width" />
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文