Oh how useful text-emphasis would be if it didn’t affect line height.
Conversation
Notices
-
Aral Balkan (aral@mastodon.ar.al)'s status on Thursday, 04-Apr-2024 02:55:54 JST Aral Balkan -
Professor_Stevens (professor_stevens@mastodon.gamedev.place)'s status on Thursday, 04-Apr-2024 03:06:52 JST Professor_Stevens I have always been frustrated by the lack of consensus on how to emphasize flat text.
Is it:
I am NOT gonna take it anymore?
or
I am *not* gonna take it anymore?
or
I am _not_ gonna take it anymore?
Caps kinda work in the example above, because I'm shouting.
They not so good when you're just being emphatic, as in:
Crossing by covered wagon took six months. Today, we can fly across in six HOURS.
What do you use?
-
Aral Balkan (aral@mastodon.ar.al)'s status on Thursday, 04-Apr-2024 03:06:52 JST Aral Balkan @Professor_Stevens Haha, all of the above depending on the mood ;)
-
Aral Balkan (aral@mastodon.ar.al)'s status on Thursday, 04-Apr-2024 03:11:49 JST Aral Balkan So, say you want to point at the exact place in a stack trace where the error is in HTML.
You might think, “I’ll use the text-emphasis CSS property” but that messes up line height.
So, instead, with a span surrounding the error location, try this (just realised the lh/rlh units are now widely supported):
```css
span.error-column::before {
color: deeppink;
content: '^';
position: relative;
margin-right: -1ch;
top: 1rlh;
}
```(Deeppink colour optional.) ;)
-