mirror of
https://github.com/ciromattia/kcc
synced 2025-12-20 05:01:55 +00:00
@@ -156,6 +156,10 @@ The app relies and includes the following scripts:
|
|||||||
* [Kobo Aura H2O](http://kcc.iosphe.re/Samples/Ubunchu-KoAH2O.kepub.epub)
|
* [Kobo Aura H2O](http://kcc.iosphe.re/Samples/Ubunchu-KoAH2O.kepub.epub)
|
||||||
|
|
||||||
## CHANGELOG
|
## CHANGELOG
|
||||||
|
####4.6.2:
|
||||||
|
* Fixed critical MOBI header bug
|
||||||
|
* Fixed metadata encoding error
|
||||||
|
|
||||||
####4.6.1:
|
####4.6.1:
|
||||||
* Fixed KEPUB TOC generator
|
* Fixed KEPUB TOC generator
|
||||||
* Added warning about too small input files
|
* Added warning about too small input files
|
||||||
|
|||||||
2
kcc.iss
2
kcc.iss
@@ -1,5 +1,5 @@
|
|||||||
#define MyAppName "Kindle Comic Converter"
|
#define MyAppName "Kindle Comic Converter"
|
||||||
#define MyAppVersion "4.6.1"
|
#define MyAppVersion "4.6.2"
|
||||||
#define MyAppPublisher "Ciro Mattia Gonano, Paweł Jastrzębski"
|
#define MyAppPublisher "Ciro Mattia Gonano, Paweł Jastrzębski"
|
||||||
#define MyAppURL "http://kcc.iosphe.re/"
|
#define MyAppURL "http://kcc.iosphe.re/"
|
||||||
#define MyAppExeName "KCC.exe"
|
#define MyAppExeName "KCC.exe"
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
__version__ = '4.6.1'
|
__version__ = '4.6.2'
|
||||||
__license__ = 'ISC'
|
__license__ = 'ISC'
|
||||||
__copyright__ = '2012-2015, Ciro Mattia Gonano <ciromattia@gmail.com>, Pawel Jastrzebski <pawelj@iosphe.re>'
|
__copyright__ = '2012-2015, Ciro Mattia Gonano <ciromattia@gmail.com>, Pawel Jastrzebski <pawelj@iosphe.re>'
|
||||||
__docformat__ = 'restructuredtext en'
|
__docformat__ = 'restructuredtext en'
|
||||||
|
|||||||
@@ -38,6 +38,7 @@ from PIL import Image
|
|||||||
from subprocess import STDOUT, PIPE
|
from subprocess import STDOUT, PIPE
|
||||||
from psutil import Popen, virtual_memory
|
from psutil import Popen, virtual_memory
|
||||||
from scandir import walk
|
from scandir import walk
|
||||||
|
from html import escape
|
||||||
try:
|
try:
|
||||||
from PyQt5 import QtCore
|
from PyQt5 import QtCore
|
||||||
except ImportError:
|
except ImportError:
|
||||||
@@ -313,18 +314,15 @@ def buildOPF(dstdir, title, filelist, cover=None):
|
|||||||
"<meta property=\"rendition:spread\">portrait</meta>\n",
|
"<meta property=\"rendition:spread\">portrait</meta>\n",
|
||||||
"<meta property=\"rendition:layout\">pre-paginated</meta>\n"])
|
"<meta property=\"rendition:layout\">pre-paginated</meta>\n"])
|
||||||
if options.iskindle and options.profile != 'Custom':
|
if options.iskindle and options.profile != 'Custom':
|
||||||
f.writelines(["<meta property=\"RegionMagnification\">true</meta>\n",
|
f.writelines(["<meta name=\"original-resolution\" content=\"",
|
||||||
"<meta property=\"region-mag\">true</meta>\n",
|
str(deviceres[0]) + "x" + str(deviceres[1]) + "\"/>\n",
|
||||||
"<meta property=\"book-type\">comic</meta>\n",
|
"<meta name=\"book-type\" content=\"comic\"/>\n",
|
||||||
"<meta property=\"zero-gutter\">true</meta>\n",
|
"<meta name=\"RegionMagnification\" content=\"true\"/>\n",
|
||||||
"<meta property=\"zero-margin\">true</meta>\n",
|
"<meta name=\"primary-writing-mode\" content=\"" + writingmode + "\"/>\n",
|
||||||
"<meta property=\"fixed-layout\">true</meta>\n",
|
"<meta name=\"zero-gutter\" content=\"true\"/>\n",
|
||||||
"<meta property=\"orientation-lock\">portrait</meta>\n",
|
"<meta name=\"zero-margin\" content=\"true\"/>\n",
|
||||||
"<meta property=\"original-resolution\">",
|
"<meta name=\"ke-border-color\" content=\"#ffffff\"/>\n",
|
||||||
str(deviceres[0]) + "x" + str(deviceres[1]) + "</meta>\n",
|
"<meta name=\"ke-border-width\" content=\"0\"/>\n"])
|
||||||
"<meta property=\"primary-writing-mode\">" + writingmode + "</meta>\n",
|
|
||||||
"<meta property=\"ke-border-color\">#ffffff</meta>\n",
|
|
||||||
"<meta property=\"ke-border-width\">0</meta>\n"])
|
|
||||||
f.writelines(["</metadata>\n<manifest>\n<item id=\"ncx\" href=\"toc.ncx\" ",
|
f.writelines(["</metadata>\n<manifest>\n<item id=\"ncx\" href=\"toc.ncx\" ",
|
||||||
"media-type=\"application/x-dtbncx+xml\"/>\n",
|
"media-type=\"application/x-dtbncx+xml\"/>\n",
|
||||||
"<item id=\"nav\" href=\"nav.xhtml\" ",
|
"<item id=\"nav\" href=\"nav.xhtml\" ",
|
||||||
@@ -746,7 +744,7 @@ def getComicInfo(path, originalPath):
|
|||||||
options.authors = []
|
options.authors = []
|
||||||
if defaultTitle:
|
if defaultTitle:
|
||||||
if xml.data['Series']:
|
if xml.data['Series']:
|
||||||
options.title = xml.data['Series']
|
options.title = escape(xml.data['Series'])
|
||||||
if xml.data['Volume']:
|
if xml.data['Volume']:
|
||||||
titleSuffix += ' V' + xml.data['Volume']
|
titleSuffix += ' V' + xml.data['Volume']
|
||||||
if xml.data['Number']:
|
if xml.data['Number']:
|
||||||
@@ -754,7 +752,7 @@ def getComicInfo(path, originalPath):
|
|||||||
options.title += titleSuffix
|
options.title += titleSuffix
|
||||||
for field in ['Writers', 'Pencillers', 'Inkers', 'Colorists']:
|
for field in ['Writers', 'Pencillers', 'Inkers', 'Colorists']:
|
||||||
for person in xml.data[field]:
|
for person in xml.data[field]:
|
||||||
options.authors.append(person)
|
options.authors.append(escape(person))
|
||||||
if len(options.authors) > 0:
|
if len(options.authors) > 0:
|
||||||
options.authors = list(set(options.authors))
|
options.authors = list(set(options.authors))
|
||||||
options.authors.sort()
|
options.authors.sort()
|
||||||
@@ -765,7 +763,7 @@ def getComicInfo(path, originalPath):
|
|||||||
if xml.data['Bookmarks']:
|
if xml.data['Bookmarks']:
|
||||||
options.chapters = xml.data['Bookmarks']
|
options.chapters = xml.data['Bookmarks']
|
||||||
if xml.data['Summary']:
|
if xml.data['Summary']:
|
||||||
options.summary = xml.data['Summary']
|
options.summary = escape(xml.data['Summary'])
|
||||||
os.remove(xmlPath)
|
os.remove(xmlPath)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user