Template talk:ko-hanjatab

From Wiktionary, the free dictionary
Latest comment: 6 years ago by Suzukaze-c in topic ko-hanjatab is too uninformative
Jump to navigation Jump to search

Lua-ize[edit]

Does anyone object to converting this to Lua? There should be no reason to have to enter any parameters just to display the hanja used in the entry. Haplogy () 23:57, 9 January 2014 (UTC)Reply

Good idea! --Anatoli (обсудить/вклад) 03:45, 12 January 2014 (UTC)Reply

Plus category[edit]

Can this automatically add to Category:Korean hanja? --Anatoli (обсудить/вклад) 00:13, 14 January 2014 (UTC)Reply

It can, but are you sure it should do that? I thought only individual hanja characters were placed in Category:Korean hanja. (I assume that) this should not be used on those entries. Maybe you're thinking of {{ko-hanja}}?
ja-kanjitab adds categories like Category:Japanese terms spelled with 韓 and Category:Japanese terms written with two Han script characters but afaik nobody has made categories like that for Korean hanja. Haplogy () 00:22, 14 January 2014 (UTC)Reply
Ideally it could be done with more complex and detailed categories like in Japanese but Korean doesn't consider hanja as common script any more, so any word (including multi-character) written in hanja is considered a hanja. I've seen categorised manually so in many enrties but inconsistently, just wanted to group all Korean words written in hanja. If a more complicated categorisation is created then this can be dropped. I appreciate your efforts but not sure how far you want to go with this project.
Actually, the Vietnamese categorisation is added via Template:han tu form of, not via Template:vi-hantutab and there's also Template:ko-hanja form of, which does it so maybe it's not necessary --Anatoli (обсудить/вклад) 00:40, 14 January 2014 (UTC)Reply
I see. It could be could be categorized here but then it would be unsorted. Hanja terms could also be put into Category:Korean hanja at ko-headword and they would be sorted by hangeul, so I would recommend doing it there. Haplogy () 01:06, 14 January 2014 (UTC)Reply

changes[edit]

I've gone ahead and converted this to Lua by writing the function hanjatab in Module:ko-utilities. There are a few changes to the behavior and if anybody feels that this was too radical, just undo my edits. These are the changes:

  • It's no longer possible to link to blocks of more than one hanja.
  • The formatting (colors, sizes, line thicknesses) may have changed a little bit.
  • It's no longer possible to add glosses (but I haven't yet found any entries that used them anyway.)
  • It can only be used to display hanja on the respective entry (e.g. not on your user page.)

On the other hand,

  • There's no limit to the number of hanja that can be displayed.
  • It displays the correct hanja every time.
  • Editors don't have to type as much.

With this, you can enter {{ko-hanjatab}} and it will get it right every time. Haplogy () 00:31, 14 January 2014 (UTC)Reply

ko-hanjatab is too uninformative[edit]

As it is now, ko-hanjatab can generate a table which contains the hanja in a term which can be clicked to link to their respective pages. However, when one sees a page dedicated to a han character, the Chinese hànzì entry for the character is up top, followed by the Japanese kanji entry, and then the Korean hanja entry, which is followed by the Vietnamese chữ Nôm / Hán tự entry. In these pages, the superiority of the ja-kanjitab, which displays additional information such as reading of the character, grade, and reading type (yomi), makes the ko-hanjatab look inadequate. Since Korean hanja are separated into characters taught in Middle School and characters taught in High School (at least the characters included in the Basic Hanja for educational use are), and hanja might have multiple readings, it seems that expanding the functionality of the ko:hanjatab to support such information is of interest. AstroVulpes (talk) 19:15, 11 March 2018 (UTC)Reply

As a preliminary step, I got data from the Korean Wiktionary and put it at Module:ko/data. It seems like the first list has 904 hanja and the second list has 906 hanja. —suzukaze (tc) 19:51, 11 March 2018 (UTC)Reply