Font used in review card

Index » Feedback

 
Pangolin
Member
From: UK
Registered: 2006-07-23
Posts: 137

I mean the big kanji on the flashcard in the Review section of this site. I presume the font is MS Mincho, could the font used to display these character be changed on a per user basis? A Greasemonkey job perhaps?

It's just that I don't like Mincho because it is a 'printed' style and not a helpful guide for handwritten kanji. I'd like to use an Epson font that I have on my system: 教科 (きょうか), which is a beautifully clear plain brush style that's very similar to my kanji handwriting style. (It's almost exactly the same font as used in RTK1 for the stroke-order diagrams.)

Obviously this could only be a user-defined function, because it's dependent on what fonts you have on your computer. I really have no idea if this is a practical option, but I am asking ^^

よろしくね

wrightak
Member
From: Tokyo
Registered: 2006-04-07
Posts: 873
Website

I'm not sure about this, but I believe that the font used depends on your browser. I once accessed the site from my Japanese language school that used Macs. A totally different font came up. If you have firefox, go into options and change the font to the one you want. Let me know if it works.

Pangolin
Member
From: UK
Registered: 2006-07-23
Posts: 137

Thanks, that works but the side effect is that the font I choose is used for all text on the site (and presumable all web sites) designated with the same style as the flash card (in this case sans serif, it seems). This includes kanji in posts on this forum, which are small enough already, but become unreadable in the font I want to use.

Last edited by Pangolin (2006 September 03, 6:38 pm)

Advertising (register and sign in to hide this)
JapanesePod101
Sponsor
 
woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

Kanji.Koohii: Change kanji font does just that. You will however have to edit it to select your own font. The default is HG正楷書体-PRO (HGせいかいしょたい-PRO, a kaisho, i.e. block-style font), which is quite a nice font, *edit* originating from wood block carving (like mincho actually) *edit*.

In Firefox, select Tools -> Options -> Contents and check the list of fonts available for your browser. The above-mentioned font was part of this list on my machine, though it's no guarantee the same holds true on yours, so go check. Choose a font, open a Japanese page (e.g. one from the Japanese Wikipedia) and check if it suits you (size shouldn't matter, you're going to have it five times the normal size).

If the font name of your choice contains kanji or any other non-ASCII value, you will have to transform them to Unicode characters. I use an Eclipse plugin called PropertiesEditor. I create a properties file, type in the font name, change to a normal text editor and presto. If you don't know what Eclipse is or can't make head or tails of this plugin, simply post the font name in this thread and I'll look it up for you.

With that information in hand, click Tools -> Greasemonkey ->  Manage User Scripts, select Kanji.Koohii: Change kanji font from the list and push the Edit button. You will be asked to select an editor. If you're on Windows, Wordpad will do just fine. On my system it's located in C:\Program Files\Windows NT\Accessories\wordpad.exe. You can find out for yourself by clicking the Start button -> All Programs -> Accessories and then right-click on Wordpad and select the Properties item (usually the last item). The link location will tell you the exact address.

Now edit the line that reads

var fontFamily = "HG\u6b63\u6977\u66f8\u4f53-PRO";

replacing the string (the thing between quotes, i.e. "HG...") with your (unicoded) font name (leave the quotes as is). A few examples are given in the previous comment lines (all lines starting with // are comments). Save and refresh your browser window. できた?

Last edited by woelpad (2007 January 02, 6:24 pm)

woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

I should have checked sources first before commenting on fonts. This website lists a few printing styles; I've adapted my comment on HG正楷書体-PRO accordingly.

Hmm, looks like a 教科書 (kyoukasho) font would be more appropriate as a substitute font, problem is to find one for your browser. Any advice?

As for converting kanji to UTF-16, this site might be of help. Enter \u@\u in the pattern field to get it copy-paste ready.

Last edited by woelpad (2007 January 03, 6:09 pm)

woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

I've created a new version that allows to enter the font name directly in your browser. No more fiddling with text editors or UTF-16 codes, simply click the "my profile" tab and enter your font as is in the Kanji Font edit box in the newly added GreaseMonkey settings section.

Will only affect that account on that computer, so if you have multiple accounts and/or study on different computers, you'll have your work cut out, so to speak. OTOH it also allows to see the kanji under different fonts simultaneously, if you so fancy.

Download from the same spot.

Last edited by woelpad (2007 January 05, 7:26 pm)

woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

Hmm, looks like a 教科書 (kyoukasho) font would be more appropriate as a substitute font, problem is to find one for your browser. Any advice?

Answering myself: My computer at home fortunately has the font AR P教科書体M installed. Must have come with one of those 年賀状 (ねんがじょう) packages the Japanese, including my wife, are so fond of. No free download AFAICT.

woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

Could have saved myself some trouble by reading this post first.

colonel32 wrote:

I found a nice kyoukasho download here in three different weights which is free for non-commercial use.  The ?Kyokasho-tai? font download link on that page is a word document which gives detailed instructions on how to download.

I found the green CID versions (a kind of Type 1 postscript) worked on the mac. Presumably the Truetype versions are the best for Windows.

Downloaded and installed the TrueType version of the recommended モトヤ教科書体2 font and got 3 fonts: NTモトヤ教科書2, NTモトヤ教科書2KP and NTモトヤ教科書2等幅. Presumably these are simple variations in character breadth and such. A great disadvantage is that they "only" contain 1006 non-kana kanjis (trial version, eh). All the others are shown as ■ (a black square).

colonel32
Member
From: Oxford UK
Registered: 2006-09-03
Posts: 60

Yes sorry, I didn't realise that until after I'd posted.

Thank you very much for making this script, and all the other ones. Sorry I didn't post about it before.

Sadly though I still haven't found a kyoukasho font that actually works with your script, on either windows or mac. The Motoya one I posted does work, but it's useless as you pointed out.

Another one I got hold of had a kanji name which showed up as question marks. I tried opening it up in a font editor and trying all the different variants of the names I could find in the info tables. But none of them worked. I even tried changing the names, but the font editor I was using refused to save anything containing over 6400 glyphs.

The best font I've found yet is a Chinese one (BlauKai on the mac). But it's still not really good enough, lots of the characters are written differently - the grass radical in two parts, the absence of the drop on dog, sometimes different hooking on human legs.

So the quest for the perfect kyoukasho font continues. I don't even mind paying for one that someone recommends, if the online purchasing is readable. Or if someone else can have a go at editing the names so that the script recognises it, that'd be great.

Reply #10 - 2007 January 10, 6:45 pm
dilandau23
Member
From: Japan
Registered: 2006-09-13
Posts: 330

Here I just made a group and put a (as far as I know) complete copy of a Kyokasho font into it.  http://tech.groups.yahoo.com/group/Kyokashotai/  It should let you auto join and then you can download it.  Sorry its such a quick and dirty solution but maybe it will help some people.  Oh, I almost forgot, it will list as HGPKyokasho in your fonts and its True Type.

Last edited by dilandau23 (2007 January 10, 7:01 pm)

Reply #11 - 2007 January 10, 8:02 pm
RoboTact
Member
From: Russia
Registered: 2006-11-26
Posts: 108

You know about http://rapidshare.com and so forth, right? It was a challenge to restore my long-forgotten yahoo password (luckily I was already registered). Only drawback is that file gets removed from there after nobody downloads it for a while.

Last edited by RoboTact (2007 January 10, 8:47 pm)

Reply #12 - 2007 January 10, 9:58 pm
dilandau23
Member
From: Japan
Registered: 2006-09-13
Posts: 330

Behind a whole mess of firewalls...i could not even FTP the file to my website from work.  I just used what I knew best.  I fear things I have not tried before.  Take any excuse you like.  I would have just tried to post it to existing RTK group but I have still not been "accepted".

Last edited by dilandau23 (2007 January 10, 10:26 pm)

woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

dilandau23 wrote:

Here I just made a group and put a (as far as I know) complete copy of a Kyokasho font into it.  http://tech.groups.yahoo.com/group/Kyokashotai/  It should let you auto join and then you can download it.  Sorry its such a quick and dirty solution but maybe it will help some people.  Oh, I almost forgot, it will list as HGPKyokasho in your fonts and its True Type.

Are you sure you're not breaking any copyright laws? Don't want to promote any piracy activities, which could get you in dire troubles later on.

colonel32 wrote:

I don't even mind paying for one that someone recommends, if the online purchasing is readable.

JustMyShop offers a package with the aforementioned AR P教科書体M called 年賀状デザイン集2007 for 2100 yen, but only services people in Japan AFAICT. For those outside Japan, persuade a friend or try out some auction site. Another package is 一太郎特選テンプレート&イラスト集 [学校・教育編] at triple the price. Check that page to see a sample of the font's rendering. (For proof of the font's inclusion in the first package, go here).

colonel32 wrote:

Another one I got hold of had a kanji name which showed up as question marks.

Does it show up as question marks in Firefox's Options -> Contents -> Font pull down list? Or in your system's font resource application (Mac's equivalent for Windows' Control Panel)? If so, registration could have gone awry, due to some peculiarity with the font files. Search the net for answers or copy the font name here.

Reply #14 - 2007 April 26, 6:55 pm
cangy
Member
From: 平安京
Registered: 2006-12-13
Posts: 370
Website

woelpad wrote:

I've created a new version that allows to enter the font name directly in your browser. No more fiddling with text editors or UTF-16 codes, simply click the "my profile" tab and enter your font as is in the Kanji Font edit box in the newly added GreaseMonkey settings section.

Just where it would be if it was built in to the site -- beautiful, thanks!  Is it possible to generate a list of available fonts?  The firefox font choser doesn't support copying of font names...  The one I'm using now ends in 教科書体 if anyone's having trouble entering the font name and is looking for something to copy and paste.  An option to set the font size would also be helpful!

Last edited by cangy (2007 April 26, 7:01 pm)

Reply #15 - 2007 May 18, 6:40 am
woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

The Flash plugin apparently includes a JavaScript extension with a getFontList() function, from which one could build a drop-downbox. No success getting it to work so far.

Font sizes should indeed be easy to implement. If I have another hour of spare time...

Reply #16 - 2007 May 18, 10:15 pm
cangy
Member
From: 平安京
Registered: 2006-12-13
Posts: 370
Website

woelpad wrote:

The Flash plugin apparently includes a JavaScript extension with a getFontList() function, from which one could build a drop-downbox. No success getting it to work so far.

Font sizes should indeed be easy to implement. If I have another hour of spare time...

The font list wold be great if you can manage it -- the firefox font chooser has no apply button so it's painful to try out all the possible fonts, and the os x font chooser uses different font names for some reason...

Size selection might be a bit harder to implement and less needed now that the new grid function enlarges the character, but I think it'd still be useful.

Thanks again!

Reply #17 - 2007 May 19, 1:53 am
Kieron
Member
From: Seattle - USA
Registered: 2007-02-23
Posts: 63

The different font names should work too.  TrueType fonts can contain multiple names for different languages, but (at least for the ones I've checked) putting any of those names into the Greasemonkey settings will work.

Reply #18 - 2007 May 27, 6:54 pm
dilandau23
Member
From: Japan
Registered: 2006-09-13
Posts: 330

Is it just my imagination, or did this script break with the addition of the grid?  Not a big deal, as I do most of my reviews in Mnemosyne these days.  Just was curious if it was everyone or if I am just doing something wrong.

Reply #19 - 2007 May 27, 7:45 pm
Megaqwerty
Member
Registered: 2007-04-05
Posts: 318

dilandau23 wrote:

Is it just my imagination, or did this script break with the addition of the grid?

Actually, now that you mention it: it did. The script still works in the study section, the only section where it's really needed, so I really didn't care, but, yes, the script no longer works in the review section.

Reply #20 - 2007 May 29, 3:57 am
woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

Acknowledged. Script corrected. Also noticed that the katakana in HGS font names are half-width, as in HGS創英角ポップ体. Another one you can copy and paste.

Last edited by woelpad (2007 May 29, 4:06 am)

Reply #21 - 2007 June 04, 7:11 pm
cangy
Member
From: 平安京
Registered: 2006-12-13
Posts: 370
Website

woelpad wrote:

Acknowledged. Script corrected.

Fantastic, thanks!  Mincho was really starting to piss me off again...

Reply #22 - 2007 June 25, 5:06 pm
woelpad
Member
From: Chiba
Registered: 2006-11-07
Posts: 425

woelpad wrote:

The Flash plugin apparently includes a JavaScript extension with a getFontList() function, from which one could build a drop-downbox. No success getting it to work so far.

Got it up and running. Download the latest version, look in My Profile, click the font picker page link and all the fonts on your system should be there. Pick whichever you like. Enjoy.

Now, there is something weird about that font picker page. But what?...

Last edited by woelpad (2007 June 26, 4:51 pm)

Reply #23 - 2007 August 10, 1:29 am
Kieron
Member
From: Seattle - USA
Registered: 2007-02-23
Posts: 63

I've started using the handwritten-style kiloji font from http://www.ez0.net/ for my reviews.  It's a free download, and I prefer its style over mikachan's.

Example:
http://img169.imageshack.us/img169/4449/charactersu3.png

smithsonian
New member
From: Japan
Registered: 2006-10-16
Posts: 3

Where is this Greasemonkey thing? The font for my reviews mysteriously changed today in Safari on Windows from a nice, brush-stroke font to a fat, ugly bold one. I'd really like to change it back somehow, but I can't find any of the options outlined above . . . sad

nilfisq
Member
From: Belgium
Registered: 2007-07-05
Posts: 33
Website

Kieron wrote:

I've started using the handwritten-style kiloji font from http://www.ez0.net/ for my reviews.  It's a free download, and I prefer its style over mikachan's.

hi kieron,
i downloaded this font, and it works fine in text editors etcetera, but i don't get it to work on this website. i work on a mac. someone knows how to install new fonts and make them work here?