WaniKani random font

Thanks for that, it worked perfectly.
Did lower the font to 30 to make it still readable but more comparable to real world text.

I found that even tough i knew the kanji when huge on my screen i had troubles distinguishing it on smaller text.


Great script, very useful!

But it seems that the hover font ‘Meiryo’ is not installed on windows 10.
Or at least for me it’s not working (Windows 10 and Chrome).
To make it work I replaced the good font ‘Meiryo’ with the Wanikani default font collection: '“Meiryo”,“Hiragino Kaku Gothic Pro”,“Yu Gothic”,“ヒラギノ角ゴ Pro W3”,“メイリオ”,“Osaka”,“MS PGothic”,“MS Pゴシック”,sans-serif’
And now the font changes when I hover over it.

I installed the script through the link Mempo posted but for some reason, I can not get it to work…
I thought that it was cause I added some fonts to the list but after reinstalling the default script it will not change fonts either. 
Nothing changes when I hover over the kanji either in reviews.
Perhaps I’m doing something wrong…

Amenophyckxs said... I installed the script through the link Mempo posted but for some reason, I can not get it to work...
I thought that it was cause I added some fonts to the list but after reinstalling the default script it will not change fonts either. 
Nothing changes when I hover over the kanji either in reviews.
Perhaps I'm doing something wrong....
 You HAVE to replace the fonts I wrote in my script with those available on your computer. I use Ubuntu Linux and only included fonts that can be installed on my OS. There are more than enough examples of fonts that work on both Windows and Mac in the earlier pages of this thread.

I have a big list of fonts installed from an earlier post in this thread (for win 10), and i added all of them to the script, but nothing changes
Using chrome

Amenophyckxs said... I have a big list of fonts installed from an earlier post in this thread (for win 10), and i added all of them to the script, but nothing changes
Using chrome
 It's possible there's nothing wrong actually. The thing is, if the script encounters a font that isn't installed, it will display the default font for a full interval period. So if you add a whole list of fonts, but don't know which ones you have, it's possible that by chance, it only selects the ones you don't have, which creates the illusion the script doesn't work.

That's one possibility. Another would that it in fact doesn't work. I'll test it later in Chrome after fixing the anki mode script you're having problems with.

PS: if you're a bit tech-savvy, you can test which fonts work on your computer. Go to your reviews, right click on the review item and click "inspect element". This opens the developer tools. In the right column you should find a property (most likely at the very top- "font-family: XXXX,YYYY,ZZZZ" with a bunch of fonts instead of X's, Y's and Z's. If all is well, only the first one should work. So you can test all the fonts you want to try out by copy-pasting their name at the front of the line until something changes. If it does, it's one you can use.

Nope, should work in Chrome, so just check my response above for further advice.

Thanks a lot for being so helpful, I will try that out, but it is a long list so it might take me a while. I will keep you updated

Update: I just tried adding some fonts to the font family in developer tools, like suggested, and that changed the font, so it seems it was working all along! (my bad)
I will go through them all one by one now and filter out the bad apples :stuck_out_tongue:
Thanks again!

update update:
Finally filtered through all fonts and removed all the fonts that did not make the kanji  change when added in font family in developer tools.
It does change when i actually do reviews now, but it doesnt cycle through the fonts. It picks one of the fonts and sticks to that one.
(that in itself is already  a great improvement)
I only touched what was between the var fonts brackets btw, did not touch any other lines

Amenophyckxs said... update update:
Finally filtered through all fonts and removed all the fonts that did not make the kanji  change when added in font family in developer tools.
It does change when i actually do reviews now, but it doesnt cycle through the fonts. It picks one of the fonts and sticks to that one.
(that in itself is already  a great improvement)
I only touched what was between the var fonts brackets btw, did not touch any other lines  
You can also change the speed at which it selects a new font. A few lines below the font-family line you'll find:

 var interval = 30; // Seconds

Just change it a lower number for more frequent changes

 var interval = 30; // Seconds

Just change it a lower number for more frequent changes
 I just changed it to 
var interval = 1; // Seconds
just as a test to see if it changed, but it stays with one of the random fonts it picked out of the list (I saved and reloaded)
Either way, I'm already happy it picks a random font every time I start a new review session.

Edit: Works perfectly after disabling Wanikani Reorder Ultimate 2, however, ive gotten used to that script so ill be content with it changing every review session :)

again, thanks so much for bearing with me and assisting me with these scripts. You're the best

edit:
Tried using WaniKani Review Order instead of reorder ultimate 2.
as soon as i click the reorder button it stops cycling through the fonts, so the same issue as i posted in previous comment

I’ve written a new font randomizer script - this one didn’t really work like I wanted it to.

If you’d like to try it, it’s called Jitai, and it’s available here on the forums!

Jitai does a few things differently. For one, it’s not on a timer - it changes font for each new question. I like that way much better; I found it a bit iffy to have the font just change right in front of your eyes at random. I addition, you don’t have to edit it to use it. Oh, and it’s only activated for reviews and not lessons, and it doesn’t change the font of the answer box (which I know some people were annoyed about). It also makes a bunch of other small quality-of-life changes, to fit as smoothly as possible in with WaniKani.

If you’re up for trying a new font randomizer, check it out maybe! :smiley:

1 Like
obskyr said... I've written a new font randomizer script - this one didn't really work like I wanted it to.

If you'd like to try it, it's called Jitai, and it's available here on the forums!

Jitai does a few things differently. For one, it's not on a timer - it changes font for each new question. I like that way much better; I found it a bit iffy to have the font just change right in front of your eyes at random. I addition, you don't have to edit it to use it. Oh, and it's only activated for reviews and not lessons, and it doesn't change the font of the answer box (which I know some people were annoyed about). It also makes a bunch of other small quality-of-life changes, to fit as smoothly as possible in with WaniKani.

If you're up for trying a new font randomizer, check it out maybe! :D
I'll test it and see which one i prefer. Thanks :)

I noticed that this actually randomizes the kanji on this part of the main page (at least for me)



so in the script on the 2 lines where it says @include wanikani.com I just changed it to wanikani.com/reviews to fix it

Since the pastie link has been throwing up 503 errors every time I tried to access it lately, I posted a mirror of the script on Greasyfork
https://greasyfork.org/en/scripts/22692-wanikani-random-font . If Wind wants this removed, I’ll take it down immediately.

thank you so much!

Jitai is probably a more up-to-date version of this

Jitai is probably a more 上-to-date version of this

yes!! its waaayyyy better! thanks!

2 Likes