Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 05-01-2007, 04:06 PM   #31
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,842
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Released 0.3.18 which fixes Xenophon's bug, adds support for <blockquote> elements (See text section in updated demo file) and allows control of link recursion.
kovidgoyal is online now   Reply With Quote
Old 05-02-2007, 12:28 PM   #32
Xenophon
curmudgeon
Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.
 
Xenophon's Avatar
 
Posts: 1,481
Karma: 5748190
Join Date: Jun 2006
Location: Redwood City, CA USA
Device: Kobo Aura HD, (ex)nook, (ex)PRS-700, (ex)PRS-500
Thanks, Kovid. No more crashes; the converter seems to work fine. I did notice one bit of odd behaviour, however. The resulting lrf files have distinctly different behaviour when it comes to page turning. The lrf file made from the example html source I sent you takes about 10 seconds per page turn on the Reader. Others take the usual one second. But ALL of them take 10+ seconds to page forward onto the page that contains all the links from the ToC!

Any idea what's going on with this? I'd be very interested in an upgrade to html2lrf that makes the Reader happier with these files. Would it help if I also sent you the source for one of the ones that didn't slow down?

Xenophon
Xenophon is offline   Reply With Quote
Advert
Old 05-02-2007, 01:02 PM   #33
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,842
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Interestingly, I found that with the grantville gazette, a reset of the reader made the page turns all 1s again. The TOC page turns seem to be simply because the reader can't handle the large number of links. Do you have an LRF file with a large number of links in the TOC that has a quick page turn to the TOC?

One thing that was different about the grantville gazette was the large number of empty <a name> elements throughout the text. These get mapped to empty textblocks by html2lrf. Perhaps the resulting large number of textblocks is what the reader finds hard to handle. I'll look into that.

Last edited by kovidgoyal; 05-02-2007 at 01:12 PM.
kovidgoyal is online now   Reply With Quote
Old 05-02-2007, 03:37 PM   #34
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,842
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
I've added a patch to svn that fixes the slowdowns for me. Can you test it and let me know? Thanks. There was also a fix that will cause the TOC elements to link to the page before the actual chapter...this is the correct behavior as per the grantville HTML file. There was a bug in previous verions that caused the TOC links to point to the first page of the chapter.

Last edited by kovidgoyal; 05-02-2007 at 03:39 PM.
kovidgoyal is online now   Reply With Quote
Old 05-02-2007, 05:13 PM   #35
Xenophon
curmudgeon
Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.
 
Xenophon's Avatar
 
Posts: 1,481
Karma: 5748190
Join Date: Jun 2006
Location: Redwood City, CA USA
Device: Kobo Aura HD, (ex)nook, (ex)PRS-700, (ex)PRS-500
Quote:
Originally Posted by kovidgoyal
I've added a patch to svn that fixes the slowdowns for me. Can you test it and let me know? Thanks. There was also a fix that will cause the TOC elements to link to the page before the actual chapter...this is the correct behavior as per the grantville HTML file. There was a bug in previous verions that caused the TOC links to point to the first page of the chapter.
I'll give it a try. I should note that I actually thought that having the TOC links point to the first page of the chapter was a good thing rather than a bug. I think that the issue is that the next, prev, contents links that show up as their own page on the Reader are just the top line of the first page of the chapter in a web browser.

I'll let you know if the version in svn fixes the slowdown.
Xenophon is offline   Reply With Quote
Advert
Old 05-02-2007, 05:34 PM   #36
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,842
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Quote:
Originally Posted by Xenophon
I'll give it a try. I should note that I actually thought that having the TOC links point to the first page of the chapter was a good thing rather than a bug. I think that the issue is that the next, prev, contents links that show up as their own page on the Reader are just the top line of the first page of the chapter in a web browser.
It is a good thing for this particular HTML file. However that is because of a poor design choice in the HTML file. It specifies a page-break-before for all H1 elements, thus html2lrf puts in a page break after the first line. Since browsers are not affected by the page-break CSS properties whoever made this file, probably didn't realize the mistake.
kovidgoyal is online now   Reply With Quote
Old 05-02-2007, 05:37 PM   #37
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,842
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Released v 0.3.19 with support for creating the external TOC (I've reversed my earlier decision not to do this upon further consideration). This version also contains completely reworked code for handling <a name> elements. This code hasn't been as thoroughly tested as the original, so there may be bugs.
kovidgoyal is online now   Reply With Quote
Old 05-02-2007, 07:38 PM   #38
Xenophon
curmudgeon
Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.
 
Xenophon's Avatar
 
Posts: 1,481
Karma: 5748190
Join Date: Jun 2006
Location: Redwood City, CA USA
Device: Kobo Aura HD, (ex)nook, (ex)PRS-700, (ex)PRS-500
The svn version does, in fact, fix the slowdown. I'll report the page-break issue to Arnold Bailey (Baen's web guy), and perhaps get a fix from that end, instead. Thanks for the quick turn-around on the fixes.

Xenophon
Xenophon is offline   Reply With Quote
Old 05-02-2007, 11:28 PM   #39
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,842
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Glad to hear it...I read a lot of ebooks converted from HTML so getting this tool shipshape is a high priority for me.
kovidgoyal is online now   Reply With Quote
Old 05-03-2007, 05:24 PM   #40
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,842
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Released 0.3.20 with bug fixes too numerous to elaborate. An upgrade is highly recommended.
kovidgoyal is online now   Reply With Quote
Old 05-05-2007, 10:45 AM   #41
Xenophon
curmudgeon
Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.Xenophon ought to be getting tired of karma fortunes by now.
 
Xenophon's Avatar
 
Posts: 1,481
Karma: 5748190
Join Date: Jun 2006
Location: Redwood City, CA USA
Device: Kobo Aura HD, (ex)nook, (ex)PRS-700, (ex)PRS-500
For those of you converting Baen html files with html2lrf, here's a little trick that may help.

First, process the original html to remove the anchors for each paragraph that are used to show paragraph numbers on mouse over. Then, remove the "page-break-before:" from the css declaration in each htm file. Then, remove the "onmouseover" entry from each paragraph element in the htm files. Only after all of that should you convert it to an lrf.

The result of these changes is a clean lrf file, with no slow-downs in page changes. In addition, when you open it for the first time on the reader, it only takes about 10 seconds to process (as compared to the minute-or-so needed when you convert the original html). I've created a little sed script that automates all of this. Its contents are:
Code:
s/<a id=\"p[0-9]*\" name=\"p[0-9]*\"><\/a>//
s/ onmouseover=\"PNo([0-9]*)\"//
s/page-break-before://
You invoke it with the command-line:
Code:
sed -i old -f yoursedfilehere *.htm
from the directory where you've unpacked the sources.

Those of you on non-Unix hosts are on your own for how to do this, but perhaps this'll give you a good start.

Xenophon
Attached Files
File Type: zip cleaner.sed.zip (567 Bytes, 514 views)
Xenophon is offline   Reply With Quote
Old 05-05-2007, 11:58 AM   #42
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,842
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Cool I'll add this to html2lrf as a commandline option so people can use it in windows too. Could you open a bug and attach the sed script so I dont forget.

Thanks.

EDIT: I doubt removing the onmouseover is neccessary since it's essentially ignored by html2lrf
kovidgoyal is online now   Reply With Quote
Old 05-05-2007, 05:01 PM   #43
Dave Berk
Fanatic
Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.Dave Berk can fool all of the people all of the time.
 
Dave Berk's Avatar
 
Posts: 574
Karma: 138556
Join Date: May 2006
Device: PRS505
When I try to run the program in Ubuntu Feisty i get:
Code:
dave@aurora:~$ prs500 info
Traceback (most recent call last):
  File "/usr/bin/prs500", line 8, in <module>
    load_entry_point('libprs500==0.3.20', 'console_scripts', 'prs500')()
  File "/usr/lib/python2.5/site-packages/libprs500-0.3.20-py2.5.egg/libprs500/cli/main.py", line 235, in main
  File "/usr/lib/python2.5/site-packages/libprs500-0.3.20-py2.5.egg/libprs500/cli/main.py", line 100, in info
  File "/usr/lib/python2.5/site-packages/libprs500-0.3.20-py2.5.egg/libprs500/prs500.py", line 164, in run_session
  File "/usr/lib/python2.5/site-packages/libprs500-0.3.20-py2.5.egg/libprs500/prs500.py", line 260, in open
libprs500.errors.DeviceBusy: Device is in use by another application:
Underlying error:Failed to set device configuration to: 2. Error code: -1
But the only applications I have open are a terminal (to run prs500) and opera browser..
Any help?
Dave Berk is offline   Reply With Quote
Old 05-06-2007, 04:55 PM   #44
allovertheglobe
Grumpy Old Man
allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.
 
allovertheglobe's Avatar
 
Posts: 267
Karma: 30194
Join Date: Jul 2006
Location: L.A., Euro ex-pat
Device: Kobo, Nook Classic,Color,ST/Glow, iRex DR1000, Sony 505, REB1100&1200
Quote:
Originally Posted by simple dave
When I try to run the program in Ubuntu Feisty i get:
Code:
dave@aurora:~$ prs500 info
Traceback (most recent call last):
<snip>
libprs500.errors.DeviceBusy: Device is in use by another application:
Underlying error:Failed to set device configuration to: 2. Error code: -1
But the only applications I have open are a terminal (to run prs500) and opera browser..
Any help?
Had the same problem, most likely a permissions issue, try:
sudo prs500 info
(Using SUDO will require you to enter your password once for that session)
allovertheglobe is offline   Reply With Quote
Old 05-06-2007, 05:16 PM   #45
allovertheglobe
Grumpy Old Man
allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.allovertheglobe can even cheer up an android equipped with a defective Genuine Personality Prototype.
 
allovertheglobe's Avatar
 
Posts: 267
Karma: 30194
Join Date: Jul 2006
Location: L.A., Euro ex-pat
Device: Kobo, Nook Classic,Color,ST/Glow, iRex DR1000, Sony 505, REB1100&1200
First, Thanks for html2lrf!

Second, is there some sort of simple, comprehensive feature list of the supported HTML anywhere? I couldn't find one on the website. I plan on writing a little program that outputs HTML files, and I want to be sure I would be able to upload that result to the PRS500. For instance which version of (X)HTML? CSS support? Anchor support? Image support, what formatting works? etc.

Any pointers would be appreciated to cut down the trial-and-error to a minimum...

Tia,
P.

(BTW, Kovid, my browser keeps having an issue with your site's certificate: "Website certified by an unknown Authority"... Could not verify this certificate for unknown reasons)
Edit: Nevermind, just went through it again and saw that you issued it yourself. No problem. Noticed you're a local of the greater LA area like myself )

Last edited by allovertheglobe; 05-06-2007 at 05:20 PM.
allovertheglobe is offline   Reply With Quote
Reply

Tags
html2lrf, libprs500

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
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


All times are GMT -4. The time now is 09:46 PM.


MobileRead.com is a privately owned, operated and funded community.