MobileRead Forums

MobileRead Forums (https://www.mobileread.com/forums/index.php)
-   Kobo Developer's Corner (https://www.mobileread.com/forums/forumdisplay.php?f=247)
-   -   Instructions for patching firmware 4.8.10956 (https://www.mobileread.com/forums/showthread.php?t=296477)

forster01 05-03-2018 05:43 AM

Thank you for a great patch.
I have a small problem using kepubs on my KA1. After the last line of the page text in kepub, parts of higher letters are visible from the first line of the next page. I.E. Letters like "b-l-d-t-f". and also those are cut out from the first text line on the next page. I know that that is the issue of the lineheight, but i dont know what values i should set.
Or if anyone else had that problem can you please share "patch_name = `My 24 line spacing values`" for KA1. Or should i enable some additional patch that i mistakenly forrgot.
Thank you in advance.

GeoffR 05-03-2018 06:42 AM

Quote:

Originally Posted by forster01 (Post 3689747)
Thank you for a great patch.
I have a small problem using kepubs on my KA1. After the last line of the page text in kepub, parts of higher letters are visible from the first line of the next page. I.E. Letters like "b-l-d-t-f". and also those are cut out from the first text line on the next page. I know that that is the issue of the lineheight, but i dont know what values i should set.
Or if anyone else had that problem can you please share "patch_name = `My 24 line spacing values`" for KA1. Or should i enable some additional patch that i mistakenly forrgot.
Thank you in advance.

That is a limitation of the KePub reader, there is not much you can do other than to keep increasing the line spacing until the problem goes away. How much you have to increase varies though, depending mainly on which font you are using.

I find most of the fonts I use are okay for KePubs down to a value of about 0.9, a few I need to increase to 0.95.

There is an option in the `My 24 line spacing values` patch to remove the smalest values from the line spacing slider:
Code:

# Replacement value: the number of initial line spacing values to exclude from
# the line spacing slider; minimum 0, maximum 13. E.g. 9 will result in a
# slider with 15 positions, starting from the 10th replace_float value below.
replace_int = 659DA6, 0, 0

If you are using the default patch line spacing values and wanted to remove the values below 0.9 say, then you could change the replacement value in red above to 7, or to remove the values below 0.96 change it to 10.

forster01 05-03-2018 08:18 AM

Thanks GeoffR on your fast reply.
But unfortunately i will loose smallest settings when reading normal epub... so, will leave it as it is (but manually increasing when i read kepub)... :(

TheDreamer 05-03-2018 07:48 PM

Quote:

Originally Posted by oren64 (Post 3686193)
[U]Missing patches from libnickel.so.1.0.0.patch

`New home screen footer rename`

Spoiler:
Code:

<Patch>
patch_name = `New home screen footer rename`
patch_enable = `yes`
#
##Multi-version patch: 4.4.9344 - 4.7.10413+
#
# Rename the left footer button.
#
#
# The lenght of the replace string must be 25 for example:
# `                        ` - replace with space show as empty
# `FirstName LastName      `
# `If lost call:123456789012`
#
find_base_address = `Find your next great read`
replace_string = 0000, `Find your next great read`, `Test, text length 25 char`
#
#replace_string = 0000, `Find your next great read`, `                        `
#replace_string = 0000, `Find your next great read`, `FirstName LastName      `
#replace_string = 0000, `Find your next great read`, `If lost call:123456789012`
#
#
# The lenght of the replace string must be 9 char.
#
#find_base_address = `SHOP KOBO`
#replace_string = 0000, `SHOP KOBO`, `--9char--`
#replace_string = 0000, `SHOP KOBO`, `4.7.10413`
</Patch>


This patch didn't work for me (KA1), I changed the first part to be:

Code:

find_base_address = `Buy, borrow, or preview books`
replace_string = 0000, `Buy, borrow, or preview books`, `Testing, text length 29 chars`

FWIW, as in the previous version...to get back to having 10 characters to cram in my phone number... I had done:

Code:

replace_string = 0000, `SHOP KOBO\0`, `1234567890`
The Dreamer.

oren64 05-04-2018 04:25 AM

@TheDreamer Thanks, I update the patch.

@GeoffR Please add the patch `Wikipedia Search language` to post #2.
Edit: Also `show games on Beta Features`

mg10 05-04-2018 01:57 PM

Any way of managing separately both four margins?
 
Hello
Is there any combination of patches for getting this in kepub?:
- set a fix margin for each side, top and bottom
- remove header and footer

Now I use these patches:

Custom kepub default margins
Fix three KePub fullScreenReading bugs
Custom left & right margins

...and full screen mode. However, when I increase margin to the first position of slide bar to get a minimum margin, a blank line in the bottom of every page appears. Changes in margin slide bar affect in a disproportionate way to bottom.

GeoffR 05-05-2018 01:51 AM

Quote:

Originally Posted by mg10 (Post 3690358)
Hello
Is there any combination of patches for getting this in kepub?:
- set a fix margin for each side, top and bottom
- remove header and footer

Now I use these patches:

Custom kepub default margins
Fix three KePub fullScreenReading bugs
Custom left & right margins

...and full screen mode. However, when I increase margin to the first position of slide bar to get a minimum margin, a blank line in the bottom of every page appears. Changes in margin slide bar affect in a disproportionate way to bottom.

This is a complicated subject. For KePubs in full-screen mode the slider adjusts all four page margins equally. However the total amount of space at the edges of the page depends on a lot of other things besides the page margins:

* Top: depends mainly on which font is used, some fonts sit higher on the line and make the top margin look smaller, others sit lower on the line and make it look larger. Also depends on font size, and a bit on line spacing setting.

* Bottom: Usually most of the space at the bottom of the page is caused by there not being enough room to fit another line of text, and the only way to change that is to adjust font size, line height, and margins until you find a setting that works. If the publisher has added some space between paragraphs then ii will be impossible, as the space at the bottom will vary from page to page depending on how many paragraphs are on each page. Also depends a bit on font choice, as with the top margin.

* Left/Right: Depends on whether the publisher has done something to increase the left/right margins. Some publishers add a wrapper <div> with margin around all text, that results in the left/right margins being much larger than the top/bottom. Only way to fix this is to edit the book and remove the margin from the stylesheet. The `Fix three full-screen bugs` patch also adds a very small amount of space to left/right.

In short, to get the space at all four edges the same you may need to edit the book to remove any left/right and inter-paragraph space added by the publissher; and adjust font size, line spacing and margin sliders by trial-and-error until you get a combination that fits evenly.

(Enabling the `My 24 line spacing values`, `Custom left/right margins` and `Custom font sizes` patches will allow finer adjustments of line spacing, margin and font sizes.)

Edit: I should also add: The smaller the margins, the more noticable any difference in size. So generally the smaller you make the page margin, the more difficulty you will have getting themn all to look even.

Edit2: One more note: The above is for KePub books. All four page margins in ePub books can be set independently via the @page style, but as there is only one margin slider it is not possible to adjust them all independently on the device, though the `ePub fixed/adjustable top/bottom margins` patch can be adapted to choose which margins are set by the slider and which remain fixed.

StillReading 05-06-2018 05:35 AM

I have a similar question/issue to mg10's: I'm trying to set the margins on my H2o (1st gen) so that I have a "zero" top margin (= text as close to the bezel as possible) which "grows" when adjusting margins via the slider in the settings menu. I've been doing lots of testing, and also tested various combinations of font/line spacing/margin settings, but no matter what I try, there always seems to be a margin on top of the page - even when using a "fixed top margin" of "00". The eBooks I'm testing with have been edited to have zero margins, and I'm using ePubs exclusively.

I'd appreciate any help, and can provide more details if needed.

GeoffR 05-06-2018 08:18 AM

Quote:

Originally Posted by StillReading (Post 3690890)
I have a similar question/issue to mg10's: I'm trying to set the margins on my H2o (1st gen) so that I have a "zero" top margin (= text as close to the bezel as possible) which "grows" when adjusting margins via the slider in the settings menu. I've been doing lots of testing, and also tested various combinations of font/line spacing/margin settings, but no matter what I try, there always seems to be a margin on top of the page - even when using a "fixed top margin" of "00". The eBooks I'm testing with have been edited to have zero margins, and I'm using ePubs exclusively.

I'd appreciate any help, and can provide more details if needed.

Are you using full-screen mode? (FullScreenReading=true in [FeatureSettings] section of "Kobo eReader.conf")

If not, then the ePub reader will always have a small (15px) space at the top of the page, there is no way to avoid that except to use full-screen mode.

StillReading 05-06-2018 12:28 PM

Thanks GeoffR, that's what I was thinking. I've never tried fullscreen mode, will have a look at it. At least I can stop trying to remove those pesky 15 px now (; .

forster01 05-07-2018 04:11 AM

GeoffR,
i feel that natural light is too red for me when it's set to 'auto' so i need to manually adjust it, but then i loose 'auto' feature. is it possible to make a patch 'maximum natural light value'. for example if the factory maximum natural light is 100 is it possible to change it to be for example max nat. light=75? Or something like that?

mg10 05-07-2018 08:22 AM

Quote:

Originally Posted by GeoffR (Post 3690561)
This is a complicated subject. For KePubs in full-screen mode the slider adjusts all four page margins equally. However the total amount of space at the edges of the page depends on a lot of other things besides the page margins:

* Top: depends mainly on which font is used, some fonts sit higher on the line and make the top margin look smaller, others sit lower on the line and make it look larger. Also depends on font size, and a bit on line spacing setting.

* Bottom: Usually most of the space at the bottom of the page is caused by there not being enough room to fit another line of text, and the only way to change that is to adjust font size, line height, and margins until you find a setting that works. If the publisher has added some space between paragraphs then ii will be impossible, as the space at the bottom will vary from page to page depending on how many paragraphs are on each page. Also depends a bit on font choice, as with the top margin.

* Left/Right: Depends on whether the publisher has done something to increase the left/right margins. Some publishers add a wrapper <div> with margin around all text, that results in the left/right margins being much larger than the top/bottom. Only way to fix this is to edit the book and remove the margin from the stylesheet. The `Fix three full-screen bugs` patch also adds a very small amount of space to left/right.

In short, to get the space at all four edges the same you may need to edit the book to remove any left/right and inter-paragraph space added by the publissher; and adjust font size, line spacing and margin sliders by trial-and-error until you get a combination that fits evenly.

(Enabling the `My 24 line spacing values`, `Custom left/right margins` and `Custom font sizes` patches will allow finer adjustments of line spacing, margin and font sizes.)

Edit: I should also add: The smaller the margins, the more noticable any difference in size. So generally the smaller you make the page margin, the more difficulty you will have getting themn all to look even.

Edit2: One more note: The above is for KePub books. All four page margins in ePub books can be set independently via the @page style, but as there is only one margin slider it is not possible to adjust them all independently on the device, though the `ePub fixed/adjustable top/bottom margins` patch can be adapted to choose which margins are set by the slider and which remain fixed.

Thank you GeoffR for your explanation, now I understand it better. I'll test what you suggest

issybird 05-10-2018 12:51 PM

I've unstuck this thread as we await developments, sticking the thread for the current official firmware.

JSWolf 05-10-2018 05:31 PM

But this one still needs a sticky because some have downloaded it and want to patch it.

forster01 05-10-2018 08:53 PM

i also agree with JSWolf


All times are GMT -4. The time now is 04:51 PM.

Powered by: vBulletin
Copyright ©2000 - 3.8.5, Jelsoft Enterprises Ltd.
MobileRead.com is a privately owned, operated and funded community.