Module talk:Glag-translit

From Wiktionary, the free dictionary
Latest comment: 10 years ago by CodeCat in topic Glagolitic
Jump to navigation Jump to search

Glagolitic

[edit]

For Glagolitic it displays empty white boxes. --Vahag (talk) 17:06, 27 August 2013 (UTC)Reply

It is called Cyrs-translit after all. I'm not sure where the boxes are coming from, it should really just leave the text untouched if it doesn't recognise it. Can you give an example where this happens? —CodeCat 17:33, 27 August 2013 (UTC)Reply
E.g. this revision. --Vahag (talk) 20:09, 27 August 2013 (UTC)Reply
Oh, I think I see. Those boxes are actually the Glagolitic characters in the original word, but transliterations don't add the script tags so they are showing in the wrong font for you. My default system font is able to show them so I don't see boxes. I'm not quite sure what would be the best way to solve this. The translit_module value in Module:languages doesn't allow for multiple values, and it probably shouldn't either to avoid ambiguity. I suppose that means creating Module:cu-translit and telling it to use either Module:Cyrs-translit or Module:Glag-translit based on the sc parameter. We could also write one module that transliterates both scripts at the same time, which might make more sense considering the two scripts are used more or less interchangeably by the same languages. We could then also make a function that transliterates from Cyrillic to Glagolitic and vice versa, which might simplify writing inflection tables a bit (no longer need to make endings for both scripts). What do you think? —CodeCat 20:17, 27 August 2013 (UTC)Reply
I have no opinion. Just make the scary boxes go away. --Vahag (talk) 21:13, 27 August 2013 (UTC)Reply

Can't you do script detection? If Cyrillic range use Cyrs-translit, otherwise don't do transliteration at all. --Ivan Štambuk (talk) 20:32, 27 August 2013 (UTC)Reply

That would mean doing the detection twice. This module is normally used by other modules which already have done the detection themselves, so doing it again wouldn't be very useful. —CodeCat 20:57, 27 August 2013 (UTC)Reply
So what exactly is the problem? if sc!=Cyrs then don't invoke this, and don't generate transliteration. --Ivan Štambuk (talk) 21:40, 27 August 2013 (UTC)Reply
I've added Glagolitic transliteration to this module instead. It seems to work, but apparently the Glagolitic words we have are all in uppercase so the transliteration is too? —CodeCat 21:55, 27 August 2013 (UTC)Reply
Original Glagolitic had no distinction uppercase/lowercase, that was made up in Unicode. I've previously added Glagolitic OCS spellings as all uppercase, those recently (e.g. ⱌⱑⱄⰰⱃⱐ (cěsarĭ) as lowercase. There are only a few dozen words and I'll move them now. --Ivan Štambuk (talk) 22:33, 27 August 2013 (UTC)Reply
Ok. {{head}} now has script detection and automatic transliteration as well, and I converted {{cu-noun}} to use it, so you won't need to specify either of them any more and it can be used for both scripts. —CodeCat 22:49, 27 August 2013 (UTC)Reply