Japanese Pitch Accent on Flashcards

Japanese Pitch Accent on Flashcards

Postby ジョナサン・ウィアー » Sat Sep 03, 2022 4:00 pm

So I have finally decided to start adding pitch accent to my vocabulary flashcards and thought I would share my method since I couldn't find any good sources explaining how to do this.

So my goal was to copy this style of formatting for my words:

Image

Now underlining text is pretty straightforward but overlining was a pain. Luckily Flashcards Deluxe can process and view HTML so after a little Googling and testing I developed the following code which will display a thick yellow line above, below, or to the right of text:

<SPAN STYLE="text-decoration:underline yellow">Underlined Text</SPAN>

<SPAN STYLE="text-decoration:overline yellow">Overlined Text</SPAN>

<SPAN STYLE="text-decoration:overline yellow; border-right:thick yellow solid;">Overlined Text with Right Border</SPAN>


Which when combined together will show like so in the app:

基礎|<SPAN STYLE="text-decoration:overline yellow">キ</SPAN><SPAN STYLE="text-decoration:underline yellow">・ソ</SPAN>|<SPAN STYLE="text-decoration:underline yellow">キ</SPAN><SPAN STYLE="text-decoration:overline yellow; border-right:thick yellow solid;">・ソ</SPAN>


Image

Unfortunately it's not the most simple thing to implement but it's effective and doesn't take up additional character width like arrows would. I also personally think that it looks good.

Further customization can be done by changing the color written in the code so that it shows up better against the background or by adding the right border in the middle of the transition from high to low to connect the pitch change. (Sadly the underline is rendered closer to the text than the overline so this causes the right border to stick out under the underline a bit when it's between the pitch transition thus why I haven't been doing it.)

Well, now I'm off to add pitch accent code to all 3500+ flashcards I've made up to this point...

Hope this helps any other Japanese (or other pitch accented language) learners wanting to add pitch accent to their cards. Let me know if anyone has trouble getting this run on their cards. I've also been copying my code into this website to test it just make sure I don't make a mistake while making my cards:

https://www.w3schools.com/html/tryit.asp?filename=tryhtml_intro
ジョナサン・ウィアー
 
Posts: 7
Joined: Sun Oct 14, 2018 5:53 pm

Re: Japanese Pitch Accent on Flashcards

Postby Tim C. » Wed Oct 12, 2022 8:29 am

I’ve been thinking about exactly this problem, too! I think your solution is quite creative and interesting, and gives a very nice visual effect.

For my own cards, I’m leaning toward (but have not implemented) a solution that at least one dictionary uses, which is to simply put the position of the accent in as a number. So something like this:

たべる ②

The pro is that it is very simple to add such pitch information, but I think the main con is that one has to interpret the number correctly!

What do other Japanese learners think of how to represent pitch info?

— Tim C.
Tim C.
 

Return to Comments, Questions and Feedback



cron