R
R
Russland Russland2017-08-12 10:14:40
Layout
Russland Russland, 2017-08-12 10:14:40

Specifies the line height (line-height) for single-line text blocks. How to calculate?

A question for experienced coders. By what principle do you set the line height for text blocks, which are represented by only one line in the layout. For multi-line text, no problem: we stupidly measure the distance between the upper word boundaries (must be in the same case) of adjacent lines. But what about single-line texts? Does knowledge of the theory of vertical rhythm help in this case? Poke, pliz, with your finger on materials where you can read about this ...

Answer the question

In order to leave comments, you need to log in

2 answer(s)
C
cssfish, 2017-08-12
@ruslanshakir

1. For multi-line text, you don’t need to measure anything, just click the “text” tool on the text layer and look in the font panel for the line-height value in px (accordingly, it should be set to pixels in the settings).
2. for a single line (usually for headings) - look at all the layouts of the project, if there is no multiline analogue, then either ask the design or type more test into the block (in the editor or debugger) and try different Line-heights. First, you can use the one specified for body, i.e. basic (+ it can be a fixed value or a multiplier), then we correct it by eye.
upd: if the base lh is a fixed value, then this will be the vert. rhythm. but with headers it's not always good.

M
Maxim Sofronov, 2017-08-12
@maxsof

I don't know what single-line text blocks are, but always keep in mind that one line can easily become multi-line due to the responsiveness of the site or because the editor wrote more than you intended.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question