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.15.12920 (https://www.mobileread.com/forums/showthread.php?t=320410)

Semwize 05-29-2019 05:05 PM

Quote:

Originally Posted by GeoffR (Post 3850740)
I think this would work, but have not tested.

Tested, works fine :)

jackie_w 05-29-2019 06:18 PM

Quote:

Originally Posted by GeoffR (Post 3850740)
I think this would work, but have not tested. it uses the fact that r7 = sp+8 which might change in the future.
Spoiler:
Code:

Increase TOC level indentation and fix extra indentation bug:
  - Enabled: yes
  - PatchGroup: TOC Indentation
  - Description: |
      The space indented Table of Contents levels are quite hard to see, as the
      difference is almost too small to easily notice. In addition, this fixes
      the bug where all TOC entries are indented by 1 level extra.
  - BaseAddress: 0x8B2FD2
  # Clear out existing instructions with NOPs
  - ReplaceBytes: {Offset: 0, FindH: 07 F1 0C 0B, ReplaceH: 00 20 00 20} # put string address in fp
  - ReplaceBytes: {Offset: 4, FindH: 42 00, ReplaceH: 00 20}            # shift level by 1 (multiply by 2) into r2
  - ReplaceBytes: {Offset: 6, FindH: 4F F0 20 01, ReplaceH: 00 20 00 20} # set r1 to 0x20 (space char)
  - ReplaceBytes: {Offset: 10, FindH: 58 46, ReplaceH: 00 20}            # put fp in r0
  # Put new instructions
  - ReplaceBytes: {Offset: 0, FindH: 00 20, ReplaceH: 40 1E}            # decrease level by 1
  - ReplaceBytes: {Offset: 2, FindH: 00 20, ReplaceH: 02 22}            # load multiplier into r2
  - ReplaceBytes: {Offset: 4, FindH: 00 20, ReplaceH: 42 43}            # multiply level, result into r2
  - ReplaceBytes: {Offset: 6, FindH: 00 20, ReplaceH: 20 21}            # set r1 to 0x20 (space char)
  - ReplaceBytes: {Offset: 8, FindH: 00 20, ReplaceH: 05 A8}            # put string address (sp+20==r7+12) into r0
  - ReplaceBytes: {Offset: 10, FindH: 00 20, ReplaceH: 83 46}            # save r0 into fp
  # Replacement value (multiplier):
  - ReplaceInt: {Offset: 2, Find: 2, Replace: 6}


Perfect! Now everyone can have the exact indent they want. :)
Great collaborative work geek1011 and GeoffR, karma to you both!

Martina Schein 05-30-2019 04:43 PM

@geek1011 thank you very much for the patches. They works very fine on our readers (H20 2nd Edition, GloHD and Glo). :thumbsup:

Quote:

Originally Posted by GeoffR (Post 3850740)
I think this would work, but have not tested. it uses the fact that r7 = sp+8 which might change in the future.
Spoiler:
Code:

Increase TOC level indentation and fix extra indentation bug:
  - Enabled: yes
  - PatchGroup: TOC Indentation
  - Description: |
      The space indented Table of Contents levels are quite hard to see, as the
      difference is almost too small to easily notice. In addition, this fixes
      the bug where all TOC entries are indented by 1 level extra.
  - BaseAddress: 0x8B2FD2
  # Clear out existing instructions with NOPs
  - ReplaceBytes: {Offset: 0, FindH: 07 F1 0C 0B, ReplaceH: 00 20 00 20} # put string address in fp
  - ReplaceBytes: {Offset: 4, FindH: 42 00, ReplaceH: 00 20}            # shift level by 1 (multiply by 2) into r2
  - ReplaceBytes: {Offset: 6, FindH: 4F F0 20 01, ReplaceH: 00 20 00 20} # set r1 to 0x20 (space char)
  - ReplaceBytes: {Offset: 10, FindH: 58 46, ReplaceH: 00 20}            # put fp in r0
  # Put new instructions
  - ReplaceBytes: {Offset: 0, FindH: 00 20, ReplaceH: 40 1E}            # decrease level by 1
  - ReplaceBytes: {Offset: 2, FindH: 00 20, ReplaceH: 02 22}            # load multiplier into r2
  - ReplaceBytes: {Offset: 4, FindH: 00 20, ReplaceH: 42 43}            # multiply level, result into r2
  - ReplaceBytes: {Offset: 6, FindH: 00 20, ReplaceH: 20 21}            # set r1 to 0x20 (space char)
  - ReplaceBytes: {Offset: 8, FindH: 00 20, ReplaceH: 05 A8}            # put string address (sp+20==r7+12) into r0
  - ReplaceBytes: {Offset: 10, FindH: 00 20, ReplaceH: 83 46}            # save r0 into fp
  # Replacement value (multiplier):
  - ReplaceInt: {Offset: 2, Find: 2, Replace: 6}


@GeoffR your modified version works very well. I use factor 10 on my H2O 2nd edition and factor 8 on my husband's GloHD and Glo respectively. Thank you very much. :thumbsup:


Here are the links to the patcher configurations we use:

Patcher for Firmware 4.15.12920 für Kobo Aura H2O 2nd Edition 1st Version
https://www.dropbox.com/sh/x11b8v6fa...-WpACzc7a?dl=0

Patcher for Firmware 4.15.12920 für Kobo Glo
https://www.dropbox.com/sh/48v6utf0e...H-9Y8I33a?dl=0

Patcher for Firmware 4.15.12920 für Kobo Glo HD
https://www.dropbox.com/sh/aq2t0ddd2...uFONzNW-a?dl=0

geek1011 05-30-2019 08:07 PM

Quote:

Originally Posted by GeoffR (Post 3850740)
I think this would work, but have not tested. it uses the fact that r7 = sp+8 which might change in the future.
Spoiler:
Code:

Increase TOC level indentation and fix extra indentation bug:
  - Enabled: yes
  - PatchGroup: TOC Indentation
  - Description: |
      The space indented Table of Contents levels are quite hard to see, as the
      difference is almost too small to easily notice. In addition, this fixes
      the bug where all TOC entries are indented by 1 level extra.
  - BaseAddress: 0x8B2FD2
  # Clear out existing instructions with NOPs
  - ReplaceBytes: {Offset: 0, FindH: 07 F1 0C 0B, ReplaceH: 00 20 00 20} # put string address in fp
  - ReplaceBytes: {Offset: 4, FindH: 42 00, ReplaceH: 00 20}            # shift level by 1 (multiply by 2) into r2
  - ReplaceBytes: {Offset: 6, FindH: 4F F0 20 01, ReplaceH: 00 20 00 20} # set r1 to 0x20 (space char)
  - ReplaceBytes: {Offset: 10, FindH: 58 46, ReplaceH: 00 20}            # put fp in r0
  # Put new instructions
  - ReplaceBytes: {Offset: 0, FindH: 00 20, ReplaceH: 40 1E}            # decrease level by 1
  - ReplaceBytes: {Offset: 2, FindH: 00 20, ReplaceH: 02 22}            # load multiplier into r2
  - ReplaceBytes: {Offset: 4, FindH: 00 20, ReplaceH: 42 43}            # multiply level, result into r2
  - ReplaceBytes: {Offset: 6, FindH: 00 20, ReplaceH: 20 21}            # set r1 to 0x20 (space char)
  - ReplaceBytes: {Offset: 8, FindH: 00 20, ReplaceH: 05 A8}            # put string address (sp+20==r7+12) into r0
  - ReplaceBytes: {Offset: 10, FindH: 00 20, ReplaceH: 83 46}            # save r0 into fp
  # Replacement value (multiplier):
  - ReplaceInt: {Offset: 2, Find: 2, Replace: 6}


Do you want the patch files updated to this?

GeoffR 05-30-2019 09:13 PM

Quote:

Originally Posted by geek1011 (Post 3851214)
Do you want the patch files updated to this?


I don't know, I'm not using this firmware myself, I just posted it as an example. Others will probably have a better idea about what replacement value is best to use as the default.

jackie_w 05-30-2019 09:27 PM

Quote:

Originally Posted by geek1011 (Post 3851214)
Do you want the patch files updated to this?

I'm not sure I'm entitled to a say but I'd vote for GeoffR's variation becoming the standard version of the patch because of it's more granular customisation. This is assuming you think it will be maintainable across new firmware upgrades.

geek1011 05-31-2019 12:30 PM

Quote:

Originally Posted by jackie_w (Post 3851232)
I'm not sure I'm entitled to a say but I'd vote for GeoffR's variation becoming the standard version of the patch because of it's more granular customisation. This is assuming you think it will be maintainable across new firmware upgrades.

I'm more asking about if he wants it included as-is. It's not much harder to maintain, as I just need to check the value at the beginning of the function when I update it.

Leonatus 06-01-2019 06:08 AM

While patching my Kobo Touch (A), I received this Log:
Spoiler:
Code:

kobopatch v0.13.0
https://github.com/geek1011/kobopatch



KoboPatch::LoadConfig
reading config file from *os.File
unmarshaling yaml
  | {
  |    "Version": "4.15.12920",
  |    "In": "src/kobo-update-4.15.12920.zip",
  |    "Out": "out/KoboRoot.tgz",
  |    "Log": "out/log.txt",
  |    "PatchFormat": "kobopatch",
  |    "Patches": {
  |        "src/libadobe.so.yaml": "usr/local/Kobo/libadobe.so",
  |        "src/libnickel.so.1.0.0.yaml": "usr/local/Kobo/libnickel.so.1.0.0",
  |        "src/librmsdk.so.1.0.0.yaml": "usr/local/Kobo/librmsdk.so.1.0.0",
  |        "src/nickel.yaml": "usr/local/Kobo/nickel"
  |    },
  |    "Overrides": {
  |        "src/libadobe.so.yaml": null,
  |        "src/libnickel.so.1.0.0.yaml": null,
  |        "src/librmsdk.so.1.0.0.yaml": null,
  |        "src/nickel.yaml": null
  |    },
  |    "Lrelease": "",
  |    "Translations": null,
  |    "Files": null
  | }


KoboPatch::OutputInit


KoboPatch::ApplyPatches
    KoboPatch::openIn
        Opening firmware zip 'src/kobo-update-4.15.12920.zip'
        Looking for KoboRoot.tgz in zip
        --> found KoboRoot.tgz
        -->    opening KoboRoot.tgz
        Opening gzip reader
        Creating tar reader
    patching entry name:'./usr/local/Kobo/libnickel.so.1.0.0' size:16225956 mode:'509' typeflag:'48' with files: src/libnickel.so.1.0.0.yaml
        reading entry contents
        loading patch file 'src/libnickel.so.1.0.0.yaml' (detected format kobopatch)
          | parsing patch file
          | parsing patch file: expanding shorthand hex values
          |  decoded hex `00 24` to `[0 36]`
          |  decoded hex `01 24` to `[1 36]`
          |  decoded hex `01 2C` to `[1 44]`
          |  decoded hex `A4 42` to `[164 66]`
          |  decoded hex `4F F0 00 00` to `[79 240 0 0]`
          |  decoded hex `18 B9` to `[24 185]`
          |  decoded hex `BB 61` to `[187 97]`
          |  decoded hex `BA 61` to `[186 97]`
          |  decoded hex `C9 B0` to `[201 176]`
          |  decoded hex `CB B0` to `[203 176]`
          |  decoded hex `02 AF` to `[2 175]`
          |  decoded hex `04 AF` to `[4 175]`
          |  decoded hex `AD F8 04 20` to `[173 248 4 32]`
          |  decoded hex `02 92 01 92` to `[2 146 1 146]`
          |  decoded hex `A5 F7 4A ED` to `[165 247 74 237]`
          |  decoded hex `85 F7 7A EF` to `[133 247 122 239]`
          |  decoded hex `20 22 4F F0 FF 33` to `[32 34 79 240 255 51]`
          |  decoded hex `00 23 01 22 0A 21` to `[0 35 1 34 10 33]`
          |  decoded hex `07 F1 70 0A` to `[7 241 112 10]`
          |  decoded hex `00 93 01 91` to `[0 147 1 145]`
          |  decoded hex `AD F8 04 20 00 93` to `[173 248 4 32 0 147]`
          |  decoded hex `42 43 92 08 01 3A` to `[66 67 146 8 1 58]`
          |  decoded hex `50 46 67 23` to `[80 70 103 35]`
          |  decoded hex `B8 BF 00 22` to `[184 191 0 34]`
          |  decoded hex `00 22 49 46` to `[0 34 73 70]`
          |  decoded hex `20 A8 49 46` to `[32 168 73 70]`
          |  decoded hex `91 F7 30 EC` to `[145 247 48 236]`
          |  decoded hex `85 F7 EA EA` to `[133 247 234 234]`
          |  decoded hex `51 46` to `[81 70]`
          |  decoded hex `20 A9` to `[32 169]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `58 B1` to `[88 177]`
          |  decoded hex `00 24` to `[0 36]`
          |  decoded hex `01 24` to `[1 36]`
          |  decoded hex `80 F0 01 00` to `[128 240 1 0]`
          |  decoded hex `01 20 01 20` to `[1 32 1 32]`
          |  decoded hex `4F F0 0F 00` to `[79 240 15 0]`
          |  decoded hex `4F F0 11 00` to `[79 240 17 0]`
          |  decoded hex `A7 F5 8E EC 6D A3` to `[167 245 142 236 109 163]`
          |  decoded hex `A9 46 00 25 ED 00` to `[169 70 0 37 237 0]`
          |  decoded hex `D3 E9 00 23 07 F1` to `[211 233 0 35 7 241]`
          |  decoded hex `20 46 04 A1 29 44` to `[32 70 4 161 41 68]`
          |  decoded hex `80 01 20 46` to `[128 1 32 70]`
          |  decoded hex `A7 F5 88 EC` to `[167 245 136 236]`
          |  decoded hex `61 E9 1C 23 A7 F5` to `[97 233 28 35 167 245]`
          |  decoded hex `08 35 70 2D F7 D1` to `[8 53 112 45 247 209]`
          |  decoded hex `84 EC 6A A3 D3 E9` to `[132 236 106 163 211 233]`
          |  decoded hex `7C E0 00 BF 00 BF` to `[124 224 0 191 0 191]`
          |  decoded hex `00 23 07 F1 80 01 20 46` to `[0 35 7 241 128 1 32 70]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `61 E9 1A 23 A7 F5 7A EC` to `[97 233 26 35 167 245 122 236]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `67 A3 D3 E9 00 23 07 F1` to `[103 163 211 233 0 35 7 241]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `80 01 20 46 61 E9 18 23` to `[128 1 32 70 97 233 24 35]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `A7 F5 70 EC 43 F2 33 33` to `[167 245 112 236 67 242 51 51]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `4F F0 33 32 C3 F6 F3 73` to `[79 240 51 50 195 246 243 115]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `07 F1 80 01 20 46 61 E9` to `[7 241 128 1 32 70 97 233]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `16 23 A7 F5 64 EC 5E A3` to `[22 35 167 245 100 236 94 163]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `D3 E9 00 23 07 F1 80 01` to `[211 233 0 35 7 241 128 1]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `20 46 61 E9 14 23 A7 F5` to `[32 70 97 233 20 35 167 245]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `5A EC 00 23 00 22 C3 F6` to `[90 236 0 35 0 34 195 246]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `F8 73 07 F1 80 01 20 46` to `[248 115 7 241 128 1 32 70]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `61 E9 12 23 A7 F5 4E EC` to `[97 233 18 35 167 245 78 236]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `55 A3 D3 E9 00 23 07 F1` to `[85 163 211 233 0 35 7 241]`
          |  decoded hex `00 00 00 00 00 00 F0 3F` to `[0 0 0 0 0 0 240 63]`
          |  decoded hex `00 23 00 22` to `[0 35 0 34]`
          |  decoded hex `00 BF 00 25` to `[0 191 0 37]`
          |  decoded hex `C4 F2 08 03 07 F1` to `[196 242 8 3 7 241]`
          |  decoded hex `20 46 29 A1 29 44` to `[32 70 41 161 41 68]`
          |  decoded hex `80 01 20 46` to `[128 1 32 70]`
          |  decoded hex `A7 F5 02 EC` to `[167 245 2 236]`
          |  decoded hex `61 E9 02 23 A7 F5` to `[97 233 2 35 167 245]`
          |  decoded hex `08 35 50 2D F7 D1` to `[8 53 80 45 247 209]`
          |  decoded hex `FE EB` to `[254 235]`
          |  decoded hex `4D 46` to `[77 70]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `01` to `[1]`
          |  decoded hex `00` to `[0]`
          |  decoded hex `07 F1 0C 0B` to `[7 241 12 11]`
          |  decoded hex `00 20 00 20` to `[0 32 0 32]`
          |  decoded hex `42 00` to `[66 0]`
          |  decoded hex `00 20` to `[0 32]`
          |  decoded hex `4F F0 20 01` to `[79 240 32 1]`
          |  decoded hex `00 20 00 20` to `[0 32 0 32]`
          |  decoded hex `58 46` to `[88 70]`
          |  decoded hex `00 20` to `[0 32]`
          |  decoded hex `00 20` to `[0 32]`
          |  decoded hex `40 1E` to `[64 30]`
          |  decoded hex `00 20` to `[0 32]`
          |  decoded hex `82 00` to `[130 0]`
          |  decoded hex `00 20` to `[0 32]`
          |  decoded hex `20 21` to `[32 33]`
          |  decoded hex `00 20 00 20` to `[0 32 0 32]`
          |  decoded hex `07 F1 0C 0B` to `[7 241 12 11]`
          |  decoded hex `00 20` to `[0 32]`
          |  decoded hex `58 46` to `[88 70]`
          |  decoded hex `00 20 00 20` to `[0 32 0 32]`
          |  decoded hex `18 B1` to `[24 177]`
          |  decoded hex `4F F0 00 00` to `[79 240 0 0]`
          |  decoded hex `59 46 50 46` to `[89 70 80 70]`
          |  decoded hex `5A 46 51 46` to `[90 70 81 70]`
          |  decoded hex `06 46` to `[6 70]`
          |  decoded hex `00 26` to `[0 38]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `4F F0 01 00` to `[79 240 1 0]`
          |  decoded hex `00 24` to `[0 36]`
          |  decoded hex `01 24` to `[1 36]`
          |  decoded hex `00 24` to `[0 36]`
          |  decoded hex `01 24` to `[1 36]`
          |  decoded hex `2E B1` to `[46 177]`
          |  decoded hex `42 00` to `[66 0]`
          |  decoded hex `82 00` to `[130 0]`
          |  decoded hex `40 F6 B8 31` to `[64 246 184 49]`
          |  decoded hex `03 21 89 02` to `[3 33 137 2]`
          |  decoded hex `4F F0 04 00` to `[79 240 4 0]`
          |  decoded hex `01 20 01 20` to `[1 32 1 32]`
          |  decoded hex `4F F0 00 00` to `[79 240 0 0]`
        validating patch file
        --> i4: internal error while validating `Un-Force user font-family in KePubs` (you should report this as a bug)


The patch in question has this settings:
Code:

Un-Force user font-family in KePubs:
  - Enabled: yes
  - Description: |
      The KePub reader uses a very heavy-handed method of setting the font selected
      by the user, overriding all fonts set by the publisher in the book unless
      "Publisher Default" is selected.
      This patch lets the font-family set by the publisher in the KePub stylesheet
      override the font-family selected by the reader from the device in some
      cases, which allows a mix of user-selected and publisher-selected fonts.
      Alternatives 1-3 give increasing preference to the publisher-selected fonts.
  - FindBaseAddressString: "* { font-family: %1 !important; }\n"
    #
    # Alternative 1:
    #    * { font-family: %1 !important; }\n
    # --> div,p{font-family:%1!important; }\n
  - ReplaceString:
    #  Offset: 0
    #  Find: "* { font-family: %1 !important; }\n"
    #  Replace: "div,p{font-family:%1!important; }\n"
    #  MustMatchLength: yes
    #
    # Alternative 2: (Similar to ePub default)
    #    * { font-family: %1 !important; }\n
    # --> body,p{font-family:%1!important;}\n
  - ReplaceString:
      Offset: 0
      Find: "* { font-family: %1 !important; }\n"
      Replace: "body,p{font-family:%1!important;}\n"
      MustMatchLength: yes
    #
    # Alternative 3: (similar to ePub with `Un-force font-family override p tags`)
    #    * { font-family: %1 !important; }\n
    # --> body{font-family:%1 !important; }\n
# - ReplaceString:
#    Offset: 0
#    Find: "* { font-family: %1 !important; }\n"
#    Replace: "body{font-family:%1 !important; }\n"
#    MustMatchLength: yes

Is the error caused by me?

Semwize 06-01-2019 06:26 AM

Quote:

Originally Posted by Leonatus (Post 3851642)
Is the error caused by me?

Yes, you unleashed wrong lines.
Code:

    # Alternative 1:
    #    * { font-family: %1 !important; }\n
    # --> div,p{font-family:%1!important; }\n
 # - ReplaceString:


Leonatus 06-01-2019 06:37 AM

Quote:

Originally Posted by Semwize (Post 3851650)
Yes, you unleashed wrong lines.

Yes, of course!:smack:
Thank you for the quick reply!
Suggestion for a further patch: remove tomatoes in front of the eyes.

crimson 06-01-2019 04:16 PM

1 Attachment(s)
Can anyone get "ePub fixed/adjustable top/bottom margins" to work? I want to make the top and bottom margins adjustable so I leave everything commented but all I got is this. The margins are fixed.

This patch worked on GeoffR's version so I'm not sure what I did wrong.

geek1011 06-01-2019 09:23 PM

Quote:

Originally Posted by crimson (Post 3851764)
Can anyone get "ePub fixed/adjustable top/bottom margins" to work? I want to make the top and bottom margins adjustable so I leave everything commented but all I got is this. The margins are fixed.

This patch worked on GeoffR's version so I'm not sure what I did wrong.

I can't help with this patch, as I don't use it my self, so I don't know the details.

What exactly do you mean by GeoffR's version? He updated the patch himself: https://github.com/geek1011/kobopatc...818727465c1d11.

crimson 06-02-2019 08:04 PM

Quote:

Originally Posted by geek1011 (Post 3851838)
I can't help with this patch, as I don't use it my self, so I don't know the details.

What exactly do you mean by GeoffR's version? He updated the patch himself: https://github.com/geek1011/kobopatc...818727465c1d11.

I mean back then when GeoffR still made his version of patch. Didn't realise that was a year ago :rolleyes:



GeoffR 06-02-2019 08:51 PM

Quote:

Originally Posted by crimson (Post 3851764)
Can anyone get "ePub fixed/adjustable top/bottom margins" to work? I want to make the top and bottom margins adjustable so I leave everything commented but all I got is this. The margins are fixed.

This patch worked on GeoffR's version so I'm not sure what I did wrong.

It is possible that the patch no longer works, I am still on firmware 4.8.1073 and while I have been updating that patch I haven't actually tested it on later versions.

From your screenshot I guess you have enabled the Reduce top/bottom page spacer patch? (in nickel.yaml) If so then you should also edit the last line of the ePub fixed/adjustable top/bottom margins patch to reflect the new size of the built-in margins:
Spoiler:
Code:

    # Replacement value: Set this to the size of the device's built-in top margin,
    # in pixels. This value is subtracted from the adjustable top/bottom margin
    # (if any) to compensate for any unremovable built-in top margin.
    # Suggested values:
    #  24  (Touch/Mini)
    #  32  (Glo/Aura/Aura2ed)
    #  44  (AuraHD/H2O/GloHD/ClaraHD)
    #  56  (AuraOne/Forma)
  - ReplaceInt: {Offset: 0x4A65D2, Find: 1, Replace: 44}



Edit: Two more things to check:
* Check that the book really is an ePub. The adjustable top/bottom margins stopped working for KePubs in firmware version 4.12.12111.
* Check that the book doesn't have an Adobe XPGT stylesheet: If it does then use the Modify Epub plugin in Calibre to remove it.

Mr. Goodbar 06-11-2019 06:19 PM

Feeling really stupid, but I can't seem to get the update to run. New to Kobo, but I've done the following per the instructions:
1. Upgraded to 4.15.12920
2. Downloaded patched version and unzipped
3. Downloaded original 4.15.12920 firmware
4. Copied original 4.15.12920 zip file to SRC folder in unzipped patched version
5. Copied patched folder to root directory of kobo
6. Unmounted

I've read elsewhere that the update should start automatically, but that is not happening.


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

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