A: 

Is it possible that one of the superviews that contains your webview is being rescaled? I don't remember seeing any automatic scaling in WebKit docs.

EightyEight
Thanks for the suggestion, but it looks like that's not it. It's just a simple WebView in an NSPanel that pops up when you click a button. I also have another WebView elsewhere that has the same problem.
Ellie P.
A: 

You may want to try this method: - (void)setTextSizeMultiplier:(float)multiplier.

Pierre-Antoine LaFayette
Shouldn't that default to 1? And, like I said, both text and images are getting scaled down. I'll give it a try, though...
Ellie P.
Could be that the default text sizes are different for the WebView, not that they are scaled down.
Pierre-Antoine LaFayette
Nope, I checked the default text sizes. They're correct. And like I said, the images are scaling down too.
Ellie P.
Thanks! I thought this wasn't working, but it ended up working when I set the multiplier to a value greater than 1.0. Surprisingly, it scaled the images and everything, not just text. However, this makes me wonder: 1) Why is the method named "setTextSizeMultiplier" when it is actually the entire page that gets scaled? The documentation doesn't mention this. 2) Why is the default value of 1.0 making things much smaller than they should be? The text was unreadable and my 1px horizontal rule disappeared.
Ellie P.
+1  A: 

In Interface Builder, try changing the font size default option for the web view from 12 to 16. I believe most web browsers, including Safari, use a default font size of 16, but the default font size is set to 12 for a Cocoa web view, so everything is rendered a bit smaller.

Zach Waugh
This doesn't work, but calling setTextSizeMultiplier: with a value > 1.0 does. Go figure.
Ellie P.