Saturday, August 25, 2018

accessibility - Is there an optimal font size / line height ratio?


When styling text on web pages, both font size and line height can be set. For example, the text of this post will be displayed using a font-size of 14px and a line-height of (about) 18px, set using the value 1.3em.


Looking at other websites, it seems that a ratio around 1.2 is a common practice.


What is the best practice regarding this? What are some good resources from which I can learn more on the subject?



Answer




You want to look to sites such as W3.org for advice on this.



Many people with cognitive disabilities have trouble tracking lines of text when a block of text is single spaced. Providing spacing between 1.5 to 2 allows them to start a new line more easily once they have finished the previous one.



The W3C accessibility guidelines 1.4.8 state (emphasis mine):



Visual Presentation: For the visual presentation of blocks of text, a mechanism is available to achieve the following: (Level AAA)


Foreground and background colors can be selected by the user.


Width is no more than 80 characters or glyphs (40 if CJK).


Text is not justified (aligned to both the left and the right margins).



Line spacing (leading) is at least space-and-a-half within paragraphs, and paragraph spacing is at least 1.5 times larger than the line spacing.


Text can be resized without assistive technology up to 200 percent in a way that does not require the user to scroll horizontally to read a line of text on a full-screen window.



No comments:

Post a Comment

technique - How credible is wikipedia?

I understand that this question relates more to wikipedia than it does writing but... If I was going to use wikipedia for a source for a res...