Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

TL;DR: use vh/vw CSS units in your bookmarklets.

I have a 15" MBP (older than retina, but higher resolution than the default configuration, 1680x1050) and another laptop with same screen size and even higher resolution (1920x1200), and most of the time I need to zoom in to comfortably read text for long periods.

I also have some grips with contrast, so I ended up using a bookmarklet that increases the text size and improves contrast, based on the Darken bookmarklet popularized in LifeHacker some time ago.

The interesting change is that since I browse with my browser window maximized most of the time, I took advantage of the vh CSS (vh = Viewport Height) unit to find the text size I'm most comfortable with, and then I can use the same bookmarklet in both computers.

Unfortunately VH/VW is relative to the window size, not screen size, so I wouldn't recommend using it for websites in general -- although for mobile web apps it should be a great fit!

The gist of it is:

font-size:2.5vh !important; line-height:4vh !important; background: black ! important; color: #DDD !important; text-shadow: 0 0 black !important;



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: