View Single Post
Old 04-27-2018, 02:34 PM   #13
geek1011
Wizard
geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.
 
Posts: 2,808
Karma: 7423683
Join Date: May 2016
Location: Ontario, Canada
Device: Kobo Mini, Aura Edition 2 v1, Clara HD
Quote:
Originally Posted by Terisa de morgan View Post
A converter would be nice... for Geoff and oren_64. The rest of us copy and paste text at best. I think, in the long term, it will be simpler to maintain only a format for the patches.
Yes. The converter will not be perfect, and will need manual tweaking after. Also, I think it may be easier after Geoff and Oren get used to the new format, since my format has more flexibility (such as being able to use unicode escapes, being able to use int offsets, and the validation).

For copying and pasting, an advantage of my format is long patches (such as zlib ones) can be made into 1 line if needed. Here is an example:

Short:
Code:
{'Disable Reading Footer': [{Enabled: true}, {Description: "Removes the reading footer for both ePub and KePub books, leaving a 15px\nbottom margin which matches the 15px built-in top margin of ePub books.\n"}, {FindReplaceString: {Find: "ReadingFooter {\n  qproperty-footerMargin: 105;\n}\n", Replace: "ReadingFooter {min-height:15px;max-height:15px;}\n"}}, {FindReplaceString: {Find: "#caption[qApp_deviceIsTrilogy=true] {\n  font-size: 19px;\n}\n", Replace: "#caption {font-size:1px;color:transparent;}\n\0"}}]}
Readable:
Code:
# Versions: 4.6.9960 - 4.8.10956+
Disable Reading Footer:
  - Enabled: true
  - Description: |
      Removes the reading footer for both ePub and KePub books, leaving a 15px
      bottom margin which matches the 15px built-in top margin of ePub books.
  - FindReplaceString: {Find: "ReadingFooter {\n  qproperty-footerMargin: 105;\n}\n", Replace: "ReadingFooter {min-height:15px;max-height:15px;}\n"}
  - FindReplaceString: {Find: "#caption[qApp_deviceIsTrilogy=true] {\n  font-size: 19px;\n}\n", Replace: "#caption {font-size:1px;color:transparent;}\n\0"}



Long:
Code:
# Versions: 4.6.9960 - 4.8.10956+
Disable Reading Footer:
  - Enabled: true
  - Description: |
      Removes the reading footer for both ePub and KePub books, leaving a 15px
      bottom margin which matches the 15px built-in top margin of ePub books.

  - FindReplaceString: 
    Find: "ReadingFooter {\n  qproperty-footerMargin: 105;\n}\n"
    Replace: "ReadingFooter {min-height:15px;max-height:15px;}\n"

  - FindReplaceString: 
    Find: "#caption[qApp_deviceIsTrilogy=true] {\n  font-size: 19px;\n}\n"
    Replace: "#caption {font-size:1px;color:transparent;}\n\0"



Last edited by geek1011; 04-27-2018 at 02:37 PM.
geek1011 is offline   Reply With Quote