Why is text rendered with a greater font-size in Opera?

后端 未结 8 793
悲&欢浪女
悲&欢浪女 2021-01-17 22:19

I\'m working on an HTML page that needs to be more or less pixel-perfect, and I noticed that in Opera 10, fonts are rendering larger than they do in other browsers, even tho

相关标签:
8条回答
  • 2021-01-17 22:37

    I had similar issue until I used reset CSS of Eric Meyer :)

    0 讨论(0)
  • 2021-01-17 22:38

    This is where a css reset stylesheet can really simplify things for you.

    http://meyerweb.com/eric/thoughts/2007/05/01/reset-reloaded/

    0 讨论(0)
  • 2021-01-17 22:40

    Came across similar issues, had to change my fallback order from:

    font-family: Helvetica, Verdana, Arial, sans-serif;
    

    to

    font-family: Helvetica, Arial, sans-serif;
    

    Since Arial and Helvetica are almost exactly the same size, when opera falls back it still looks good.

    0 讨论(0)
  • 2021-01-17 22:44

    I came across this thread when I was having similar issues with Opera 11.10 on Windows 7 x64.

    Opera was defaulting to using 20px as the body font-size (rather than 16px which is what other browsers use). This persisted even after uninstalling, deleting Opera preferences and re-installing. It turns out that Opera will honor your system font-size preferences (set under 'Control Panel\Appearance and Personalization\Display' on Win7) for rendered website text whereas other browsers (I tested FF4, Chrome 11, Safari 5, IE 9) do not. My system font size was set to 125% which explains the 20px. Once I set my system font zoom to 100%, Opera behaved the same as the others.

    I'm not sure which behavior is more correct (In a way, it's nice that Opera honors my font choice) but since since other browsers do not do the same, it is "unexpected". I don't have a Mac to test but perhaps MacOS has a similar system font preference?

    0 讨论(0)
  • 2021-01-17 22:45

    I think I know your problem. I am getting it exactly the same size in all browsers (at least Firefox, Opera and Chrome). This, I am sure, can be easily overlooked if you dont know you or someone else has done this, but try checking the zoom settings in Opera... let me know if it doesnt help and I will work some more on it.

    0 讨论(0)
  • 2021-01-17 22:46

    My suspicion is that Opera uses a different fallback font for Sans-serif than the other browsers do. That should be possible to confirm or eliminate by using a different font that is definitely installed on the system.

    0 讨论(0)
提交回复
热议问题