View Single Post
Old 05-14-2017, 05:54 PM   #48
jackie_w
Grand Sorcerer
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 6,212
Karma: 16534894
Join Date: Sep 2009
Location: UK
Device: Kobo: KA1, ClaraHD, Forma, Libra2, Clara2E. PocketBook: TouchHD3
Patch: `Dictionary text font-family/font-size/line-height

This is a patch which will allow you to customise the appearance of the text in the dictionary pop-up widget and full-screen dictionary page. It can be found in kobopatch's libnickel.so.1.0.0.yaml file.

You can customise one or more of the following:
  • font-family (choose any font on your device, built-in or sideloaded)
  • font-size
  • line-height
As far as I can tell (trial and error) these are the current unpatched Kobo defaults:
Code:
         font-family    font-size   line-height
         -----------    ---------   -----------
    Glo: Georgia        23px        1.4em
    H2O: Georgia        29px        1.4em
  GloHD: Georgia        32px        1.4em
AuraONE: Georgia        42px        1.4em
... so work out your new custom font-size/line-height settings using these as a guideline.

The first 3 screenshots date from firmware 4.4.9298 when the patch was new:
  1. unpatched KA1 [**]
  2. patched KA1: font-family: "Gill Sans", font-size: 38px, line-height: 1.1em
  3. patched KA1: font-family: Bookerly, font-size: 45px, line-height: 1.4em
[**] Let me rephrase that. By 'unpatched' I mean before this particular patch was enabled. My other dictionary patch `Dictionary pop-up - increase available text area` (in nickel.yaml) is already enabled in all 3 of the screenshots. The 2 dictionary patches are not dependent on each other. Enable either, both or neither as you wish.

Note:
If you own several different Kobo models it is unlikely that you will be able to find one custom font-size which will look good on all your devices so you may need to run the patch process multiple times with a different settings.


Update for firmware 4.17.13694

This update should benefit those who have also installed some of the many custom dictionaries posted elsewhere in the Kobo forum.

Custom dictionaries often appear to have many blank lines. The aim of this update is to remove some of that excess whitespace in both pop-up and full-screen dictionary widgets.

This update will not adversely affect patch users who only use Kobo's built-in dictionaries. Patch customisation looks pretty much the same as ever.

The last 3 attached screenshots are taken from firmware 4.17.13694.
Each shows both the pop-up and full-screen widgets for a custom dictionary [Oxford English]

4. unpatched KA1
5. patched Forma: WITHOUT customisation of font-family/font-size/line-height
6. patched Forma: WITH customisation. font-family: Arial, font-size: 32px, line-height: 1.30em

Screenshots 4-6 do NOT have my 2nd dictionary patch enabled, Dictionary pop-up - increase available text area.

Enabling this 2nd patch would also reduce the header and left/right margins inside the pop-up widget reclaiming a little more room for the dictionary definition

Unfortunately, due to Kobo changes, the 2nd patch can no longer increase the box-size of the pop-up widget nor reduce the height of the 'Page x of y' footer.
Attached Thumbnails
Click image for larger version

Name:	KA1_unpatched.png
Views:	935
Size:	231.1 KB
ID:	156755   Click image for larger version

Name:	KA1_gillsans_38_1-1.png
Views:	914
Size:	235.4 KB
ID:	156756   Click image for larger version

Name:	KA1_bookerly_45_1-4.png
Views:	879
Size:	239.9 KB
ID:	156757   Click image for larger version

Name:	fw417_1_patch_off.png
Views:	530
Size:	323.2 KB
ID:	173546   Click image for larger version

Name:	fw417_2_patch_on.png
Views:	489
Size:	369.6 KB
ID:	173547   Click image for larger version

Name:	fw417_3_patch_custom.png
Views:	442
Size:	380.3 KB
ID:	173548  

Last edited by jackie_w; 09-20-2019 at 05:59 PM. Reason: Updated for firmware 4.17.13694
jackie_w is offline   Reply With Quote