4 ms·
I don't think there's an ideal size. I've started scripting away problems using Greasemonkey [Firefox] or TamperMonkey [Chromium]. A sample Greasemonkey script
by brudgers 10y ago
I don't think there's an ideal size. I've started scripting away problems using Greasemonkey [Firefox] or TamperMonkey [Chromium]. A sample Greasemonkey script that changes the font size on this page:
// ==UserScript==
// @name example_fontsize
// @namespace com.kludgecode.hn.example
// @include https://news.ycombinator.com/item?id=12036162
// @version 1
// @grant none
// ==/UserScript==
/* Select Comments */
/* Make $target easily accessible for interactive debugging */
window.$target = document.getElementsByClassName("comment");
for (var i = 0; i < $target.length; i++)
{$target[i].style.fontSize = "15pt";};
Replacing:
// @include https://news.ycombinator.com/item?id=12036162
with
// @include https://news.ycombinator.com/item*
Will change ~font-size~ on all the pages for individual stories.
Good luck.
- tlb 10y agoWhat are the advantages of this over ⌘+?
- brudgers 10y agoThe advantage and disadvantages: 1. Finer grained control over what happens, i.e. the script only scales the text of comments, not the question's or title's, etc. 2. Automatic execution and implemented at a higher level, i.e. CSS. 3. Only applicable to specified pages. 4. Can be extended to modify additional elements such as line spacing as user Krapp's code shows. Mainly, I think the advantage is that it frames layout/readability issues as within the user's control by unlocking features of the browser as a tool rather than a passive consumption device.