CoEDL / nyingarn-workspace

The Nyingarn data ingest and preparation application
GNU General Public License v3.0
0 stars 0 forks source link

Diacritics displayed differently & consistently between the WRITE & PREVIEW tabs #178

Open sophlew opened 1 year ago

sophlew commented 1 year ago

User feedback, in the Holmer material there are lots of diacritics/symbols etc. These are inconsistently displayed between the WRITE and PREVIEW tabs. Incorrect display examples can be found on pages WakkaGoreng-008A and WakkaGoreng-008B, see screenshots. WakkaGoreng-008B, line 16, over the e and in ben, the character has moved "d'ūm bē̜̆n be̜ 'smoking' (JW)". Screen Shot 2023-05-09 at 5 02 23 pm Screen Shot 2023-05-09 at 5 02 35 pm Screen Shot 2023-05-09 at 5 03 49 pm

Correct display example in WarregoBurdekinV-046A, see screenshot, line 5. Is this something to do with how different users have edited the text? Please help. Screen Shot 2023-05-09 at 5 11 07 pm

marcolarosa commented 1 year ago

I think this is a display issue but i'm really not sure. @Conal-Tuohy What do you think?

sophlew commented 1 year ago

Some of these I have been able to fix. WakkaGoreng-008B still has an issue. This text (line 15) bē̜̆n be̜ 'smoking' (JW). @Conal-Tuohy could you please take. The symbols over e are being elongated.

Conal-Tuohy commented 1 year ago

am I right in thinking the text should actually appear something like this? image

Conal-Tuohy commented 1 year ago

I think we can fix this by using a font with better support for combining diacritics. At the moment the web pages are relying on the browser's generic monospace font, which will vary between different users' computers, and will often not be a great font. To get a consistent rendering, we should actually supply a particular font, and specify that it's the font used to display the transcription.

I have created a work-around for this that seems to do the trick, in my browser, just by using the Chrome dev tools to add a user CSS stylesheet that loads a specific font (the monospaced version of Google's "Noto" font, which is a font that's designed specifically for good multilingual support), and then overrides the font used in the "codemirror" TEI editor panel and also the TEI preview panel:

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Mono&display=swap');

.cm-scroller,
.tei {
  font-family: 'Noto Sans Mono' !important;
}

I haven't added this to the codebase at all; I've just tested it out in my own browser. We should slot this font specification into the proper places in Nyingarn's CSS.

Conal-Tuohy commented 1 year ago

I think we'll probably want to also include italic, bold, and bold italic styles from the same font family (for formatted text in the preview pane). What do you prefer, @marcolarosa; should we host the font files on nyingarn.net or just rely on fonts.googleapis.com?

Conal-Tuohy commented 1 year ago

Also, should we actually use a monospaced font, or should we just use a normal variable-width font?

nthieberger commented 1 year ago

is there a problem with non-monospace? If not that sounds fine

On Tue, 16 May 2023 at 18:27, Conal Tuohy @.***> wrote:

  • External email: Please exercise caution *

    Also, should we actually use a monospaced font, or should we just use a normal variable-width font?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you are subscribed to this thread.Message ID: @.***>