View Single Post
Old 08-16-2025, 12:06 PM   #10
chrisridd
Guru
chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.chrisridd ought to be getting tired of karma fortunes by now.
 
chrisridd's Avatar
 
Posts: 983
Karma: 2209358
Join Date: Nov 2011
Location: London, UK
Device: Kobo Aura, Kobo Aura ONE, PocketBook InkPad Color 3
Thinking about why <pre> used the UI custom font, but <tt> fonts were still monospace, I tried an experiment:

Added a @font-face for a monospaced font - Jetbrains Mono - and set a CSS class to use it.

Used the class on a block-level element - it got ignored.

Used the class on an inline element - it got used!!

So my theory is that PB, or RMSDK, is overriding the UI custom font only on block level CSS objects.

Or in other words this CSS:

Code:
@font-face {
    font-family: 'JetBrains Mono';
	font-style: normal;
	font-weight: normal;
	font-stretch: normal;
    src: url('../Fonts/JetBrainsMonoRegular.ttf') format('truetype');
}

.mono {
	font-family: "JetBrains Mono";
	font-size: 90%;
}
with this HTML:

Code:
  <p class="mono">This is hopefully drawn in the IntelliJ font.</p>
  <p>Yeah you wish! But <span class="mono">this may work</span> - who knows?</p>
chrisridd is offline   Reply With Quote