\n"
- ])
- if options.panelview and not noPV:
- if not noHorizontalPV and not noVerticalPV:
- if rotatedPage:
- if options.righttoleft:
- order = [1, 3, 2, 4]
- else:
- order = [2, 4, 1, 3]
+ else:
+ rotatedPage = False
+ noPV = False
+ noHorizontalPV = False
+ noVerticalPV = False
+ htmlpath = ''
+ postfix = ''
+ backref = 1
+ head = path
+ while True:
+ head, tail = os.path.split(head)
+ if tail == 'Images':
+ htmlpath = os.path.join(head, 'Text', postfix)
+ break
+ postfix = tail + "/" + postfix
+ backref += 1
+ if not os.path.exists(htmlpath):
+ os.makedirs(htmlpath)
+ htmlfile = os.path.join(htmlpath, filename[0] + '.html')
+ f = open(htmlfile, "w", encoding='UTF-8')
+ f.writelines(["\n",
+ "\n",
+ "\n",
+ "", filename[0], "\n",
+ "\n",
+ "\n",
+ "\n",
+ "\n",
+ "
\n",
+ "
\n"
+ ])
+ if options.panelview and not noPV:
+ if not noHorizontalPV and not noVerticalPV:
+ if rotatedPage:
+ if options.righttoleft:
+ order = [1, 3, 2, 4]
else:
- if options.righttoleft:
- order = [2, 1, 4, 3]
- else:
- order = [1, 2, 3, 4]
- boxes = ["BoxTL", "BoxTR", "BoxBL", "BoxBR"]
- elif noHorizontalPV and not noVerticalPV:
- if rotatedPage:
- if options.righttoleft:
- order = [1, 2]
- else:
- order = [2, 1]
+ order = [2, 4, 1, 3]
+ else:
+ if options.righttoleft:
+ order = [2, 1, 4, 3]
else:
- order = [1, 2]
- boxes = ["BoxT", "BoxB"]
- elif not noHorizontalPV and noVerticalPV:
- if rotatedPage:
+ order = [1, 2, 3, 4]
+ boxes = ["BoxTL", "BoxTR", "BoxBL", "BoxBR"]
+ elif noHorizontalPV and not noVerticalPV:
+ if rotatedPage:
+ if options.righttoleft:
order = [1, 2]
else:
- if options.righttoleft:
- order = [2, 1]
- else:
- order = [1, 2]
- boxes = ["BoxL", "BoxR"]
+ order = [2, 1]
else:
- order = [1]
- boxes = ["BoxC"]
- for i in range(0, len(boxes)):
- f.writelines(["