![]() |
#496 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 84
Karma: 1166
Join Date: Apr 2007
Location: New Jersey, Outside of Philadelphia
Device: Sony Reader
|
As always, you know your stuff. I built the new SVN under the VM image and tested converting some documents and they're not quite right (quite possible I don't know the appropriate switches- the only one i used is --book-designer). Here's what I've noticed on the first round:
|
![]() |
![]() |
![]() |
#497 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,355
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Bug in the BD regexp fixed in svn
|
![]() |
![]() |
![]() |
#498 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 84
Karma: 1166
Join Date: Apr 2007
Location: New Jersey, Outside of Philadelphia
Device: Sony Reader
|
Kovid-
The formatting is getting better now, here are some new observations (and one question) 1)images in the lrf generated from the test book i posted aren't centered 2) the pagebreak (<hr>) before the first chapter in the sample posted doesn't get picked up correctly by html2lrf 3) images in some other books aren't getting picked up right. In another document this image: <DIV align=center><IMG hspace=0 src="chapter1.jpg" align=baseline border=0></DIV> isn't picked up 4) Would you prefer I enter these types of comments as tickets on your trac page? and do you prefer 1 ticket per comment or one "round-up" ticket? Thanks again as always. |
![]() |
![]() |
![]() |
#499 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,355
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
The image centering is simply because in html2lrf images are usually inline, so they aren't centred. I could add some code to the preprocessor to generate centered images.
Yeah, tickets help me keep track of things. |
![]() |
![]() |
![]() |
#500 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 84
Karma: 1166
Join Date: Apr 2007
Location: New Jersey, Outside of Philadelphia
Device: Sony Reader
|
Jeez, you're fast.
Okay, from now on I will enter comments as tickets. One thing I forgot to ask. Is it possible to have the first paragraph of every chapter use drop caps? I have looked around a bit, but I don't see that documented (seems like it is basically supposed to be in the atributes of the par in the HTML?) It would be a nice feature when converting from another format to be able to specify that as an option. Also, in what file or group of files does the BD pre-processor lie? I've not used Python before, but I am a developer and I'm fairly comfortable with regex's so I may be able to offer more useful suggestions if I know where to look. Also, how does drop caps handle an open quote or an open smart quote before the first letter? Finally (for now), is there a guide to getting a python environment up and running under Windows that would be approprate for compiling libprs500? If not, I'll do my best to get things running and write a guide for others to follow. |
![]() |
![]() |
![]() |
#501 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,355
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
There isn't an option to enable drop caps, open a ticket and I'll get it done.
it uses the css pseudo-selector first-letter. And at the moment, it doesnt handle quotes. Add that to the ticket and I'll implement it. All the code (except for table handling) for html2lrf is in the file html/convert_from.py look for the variable BOOK_DESIGNER There isn't a guide for windows. It's a pretty laborious process in which you have to install Unix toolchain to compile dependencies and so on. EDIT: Actually now that i think of it having a dropcaps on every paragraph would be pretty weird. |
![]() |
![]() |
![]() |
#502 | |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,355
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Quote:
|
|
![]() |
![]() |
![]() |
#503 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 84
Karma: 1166
Join Date: Apr 2007
Location: New Jersey, Outside of Philadelphia
Device: Sony Reader
|
|
![]() |
![]() |
![]() |
#504 |
Time Vortex Manipulator
![]() Posts: 30
Karma: 10
Join Date: Aug 2007
Location: Greece
Device: Sony Reader
|
Thank you, kovidgoyal, the new version works. I just didn't have much time to try out html2lrf, so I would like to ask if it supports unicode ...
|
![]() |
![]() |
![]() |
#505 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,355
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
yeah it does. see demo attached to first post. You have to embed a unicode enabled font for the characters to actualy show up.
|
![]() |
![]() |
![]() |
#506 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,355
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
version 0.4.9 is on its way to the servers. There was an extensive refactoring of html2lrf's internals to support two new features:
1) --use-spine Reads the spine information from opf files to determine the order in which individual HTML files should be appended to the LRF 2) --override-css Allows you to specify CSS that will override the CSS loaded through stylesheets and <style> elements in the HTML file. It will not override CSS found in the tags themselves via the style attribute. Because of the refactoring there may be regressions in this version. If you find any please report them. |
![]() |
![]() |
![]() |
#507 |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 79,758
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
See https://www.mobileread.com/forums/sho...126#post106126 for what happened when I ran lit2lrf on Autumn.lit.
|
![]() |
![]() |
![]() |
#508 |
Member
![]() Posts: 13
Karma: 10
Join Date: Aug 2007
Device: SONY
|
i try the new version but seem it not support the foreign language , it turn out with all of sign and stuff even when i embedding
html2lrf --serif-family="C:\Windows\Fonts, VNI-Aptima" untitled.html but does not work can some one help me convert this to lrf and show me how to work with this please, here is the font :http://www.megaupload.com/?d=YWPI1FL5 and the pdf file:http://www.megaupload.com/?d=OD3T7A02 please, thank you |
![]() |
![]() |
![]() |
#509 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,355
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
pdf2lrf --serif-family "C:\Windows\Fonts, Times New Roman" myfile.pdf should work. I doubt the font you mentioned is a proper unicode font. See the attached LRF.
|
![]() |
![]() |
![]() |
#510 | |
Member
![]() Posts: 13
Karma: 10
Join Date: Aug 2007
Device: SONY
|
Quote:
but thanks anyway for the great progam, anyway to fix that |
|
![]() |
![]() |
![]() |
Tags |
html2lrf, libprs500 |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Change font of header for LRF Output on PRS 505 | duckbill | Calibre | 3 | 05-15-2010 11:07 AM |
Pissed off with LRF formatting: LRF/LRS clean tool? | grimborg | LRF | 8 | 02-15-2010 01:14 PM |
Fonts for LRF output | krischik | Calibre | 1 | 10-03-2009 05:01 AM |
CBZ > LRF (LRF>HTML/MOBI????) | sideburnt | Calibre | 4 | 09-15-2009 06:44 AM |
libprs500 Issues Converting .LIT to .LRF - .LRF crashes everything | vasbinde | Calibre | 6 | 02-14-2008 12:16 PM |