6
4
How do I display a wide-screen wide web site on an XGA screen (1024px
) in Chrome 26 on Windows XP. Of course, I can zoom out in Chrome, but then still the < 1220px
media query fires , bummer! So I do not get the >= 1220px
version of the web site.
What can I do?
With Firefox it works: I zoom out, and then the >= 1220px
media query fires, great! But it's not Chrome, on which I want to test the web site as well.
Source code for test web page:
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8>
<title>Test</title>
<link rel="stylesheet" type="text/css" media="screen" href="index.css">
<style>
p {
color: black;
}
@media (min-width: 1220px) {
p {
color: red;
}
}
</style>
<script>
window.addEventListener("resize", function () {
console.log(window.innerWidth);
});
</script>
</head>
<body>
<p>Turns red for window width >= 1220px</p>
</body>
</html>
What kind of graphics card do you have? Depending on that, you could add a custom screen resolution that's higher than 1220 pixels wide (not the most elegant solution, I know, but it can be useful for testing a lot of things) – Marcus Chan – 2013-01-27T16:47:48.727
@MarcusChan, yes I know that I can do that. But I want a solution where I can stay at XGA resolution, because I don't like a scrolling screen. – feklee – 2013-01-27T17:11:57.073
1
Hmm. There's a Chrome extension (https://chrome.google.com/webstore/detail/resolution-test/idhfcdbheobinplaamokffboaccidbal) that can change your browser wondow to be bigger than your screen, but that's not optimal either...
– Marcus Chan – 2013-01-27T17:16:10.027@MarcusChan: Thanks, that extension is better than nothing! Write it as an answer, and I will mark it as accepted, until someone comes up with a nicer solution (zoom). – feklee – 2013-01-27T17:28:53.137