10-12-2009, 02:52 PM | #1 |
Guru
Posts: 718
Karma: 1085610
Join Date: Mar 2009
Location: Bristol, England
Device: PRS-T1, 1825PT, Galaxy Tab, One X, TF700T, Aura HD, Nexus 7
|
Issues scrolling the cursor
I converted several books into HTML (for conversion into epub) but for some reason the conversion went wrong and all the paragraphs in a chapter merged into one. The books ended up with between 20-50 massive paragraphs (one per chapter) with no way to figure out what the actual paragraphs were.
This meant breaking out the original paper books and going through each chapter line-by-line to figure out the proper paragraphs. This may take some time, but it had to be done. Now, when I do this I'm normally got the book in one hand and visually scanning down the page, while my other hand manipulated the cursor and enter keys. In a regular text editor this would be fine but I've been coming across a couple of issues that this a bit of a pain. 1. If there is any italic text withing the paragraph below, as I scroll across to the correct ending point of the paragraph, the cursor can randomly jump to the italic text and then jump back to where it should be and then continues on the line. This wouldn't caus me too much of a problem except for the fact that the page will suddenly jump and scoll as much as a full screen of text and then jump back. This gets very disorienting. 2. The larger the paragraph the slower it takes to scroll. I press and hold the left of right scroll button and the cursor moves just one place. I leave my finger on the cursor key and the cursor doesn't move, except that when I take my finger off, the cursor jumps several characters. This makes it difficult to tell where the cursor actually is. Are these things worth raising as an issue or are these an issue with Qt? |
10-12-2009, 07:24 PM | #2 | |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
Quote:
You're editing in Book View, right? Then the problem is with WebKit which Qt integrates. To tell you the truth, WebKit is starting to piss me off as much as HTML Tidy (and Tidy has pissed me off a truly great deal). While I can usually beat Tidy into submission by diving into its source code and fixing things, I can't really do this with WebKit. Doing it for WebKit would mean diverging from the vanilla Qt distributed by Nokia, and that's not something I'm eager to do. It would mean the default Qt libs for Linux systems would no longer apply and people would have to download and compile this custom Qt version if they wanted to compile Sigil directly. Did I mention it takes ~4 hours to compile Qt? And working on the Apple upstream version of WebKit is pointless since Nokia updates their port every six months. Then there's the elephant in the room: WebKit's huge. It's a whole browser engine, used in Safari and Chrome and a multitude of other applications. Hundreds of thousands of lines of code. Just familiarizing myself with the internal architecture would probably take a couple of months. So I'm building up frustration with it until I say "oh to hell with it" and then diverge from vanilla Qt and WebKit. I'm currently holding out until Qt 4.6 which should be out in a month or so. If that doesn't solve some of my major grievances, it will be time for more extreme measures. So for your first problem... yeah I don't know what to tell you. Use the Code View, that shouldn't have these problems. Just paste "</p><p>" where you want one paragraph to end and another to begin. Also create an issue on the tracker with this, providing the step-by-step instructions to replicate it. Maybe I'm doing something stupid to mess this up, but I highly doubt it. For your second problem... well you have a whole chapter as a paragraph, and Book View is justifying the text. Try setting it to left-justified while you work on it, it should speed up. But the problem remains, you have a whole chapter worth of text in a single <p> element. That will hurt every HTML renderer, no matter what. You should also see massive speed-ups with this when 0.2.0 ships with the multi-flow redesign, since you'll be able to split these paragraph chapters into different XHTML files and work on them one by one. This should relieve WebKit's pain. |
|
Advert | |
|
10-12-2009, 07:35 PM | #3 | |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
One more thing... why don't you just work on raw text here? You said the HTML conversion went bad and now you have all the chapters as one paragraph. That's hardly HTML.
Open your favourite simple text editor (I suggest Notepad++) and make the text look like this: Quote:
|
|
10-13-2009, 08:43 AM | #4 |
Guru
Posts: 718
Karma: 1085610
Join Date: Mar 2009
Location: Bristol, England
Device: PRS-T1, 1825PT, Galaxy Tab, One X, TF700T, Aura HD, Nexus 7
|
Thanks for this.
Yes I am doing it in Book View as under normal circumstances, I don't have to mess with adding paragraph formatting as Sigil does it automatically. I suspected this might not be an issue with Sigil. I'll raise an issue about the first point. As to the second point: I've tried copying in raw text in the past by having a blank line between paragraphs and this works fine if my text is wrapped in the text editor. But if I have a text file which has hard breaks at the end of the line and is not wrapped, Sigil will create the paragraph but merges the end of the previous line with the start of the next line. e.g. I "getthis". I should "get this". This means I have to go line-by-line to find all the merged words. Looks like I might need to do most of my editing outside of Sigil, I was trying to move away from that and get the basic book structure complete within the one tool. Not to worry, I'm sure Sigil will mature to the point that it will be the one-stop-shop I need for this. I'll still keep using it as it is an excellent program and am (in general) loving the way it works. BTW, never used Notepad++, I normally use Edit+. Might give Notepad++ a try and see which is better. |
10-13-2009, 10:14 AM | #5 | |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
Quote:
|
|
Advert | |
|
10-13-2009, 01:01 PM | #6 |
Guru
Posts: 718
Karma: 1085610
Join Date: Mar 2009
Location: Bristol, England
Device: PRS-T1, 1825PT, Galaxy Tab, One X, TF700T, Aura HD, Nexus 7
|
I mean't import, but haven't tried importing raw text since 0.1.2. I'll give it another go and see if this help one of my issues.
|
10-13-2009, 01:22 PM | #7 |
Guru
Posts: 718
Karma: 1085610
Join Date: Mar 2009
Location: Bristol, England
Device: PRS-T1, 1825PT, Galaxy Tab, One X, TF700T, Aura HD, Nexus 7
|
I've just tried importing text from a txt file and am again getting the words merging. This is using v0.1.4.
I think I see why though: If there is a space just before the carriage return, importing the text will cause two words. If there is no space before the carriage return, I get one merged word. So for this to work I'm going to need to check every text file to see if they are word wrapped. And if they are not, add a space before every carriage return. Not what I had hoped for, but can do it if I have to. But you are right, if there is a blank line in the text file, I'll get a new paragraph. So thats good. |
10-13-2009, 03:52 PM | #8 |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
That's a bug. Report it on the tracker with a test case and I'll fix it.
|
10-14-2009, 04:38 AM | #9 |
Guru
Posts: 718
Karma: 1085610
Join Date: Mar 2009
Location: Bristol, England
Device: PRS-T1, 1825PT, Galaxy Tab, One X, TF700T, Aura HD, Nexus 7
|
I've created issue #147 for the jumping to italics, and issue #148 for the merging of the text.
|
10-15-2009, 05:13 AM | #10 | |
Member
Posts: 22
Karma: 166
Join Date: Dec 2007
Location: Czech Republic, Sedlice
Device: Cybook Gen 3, HTC Desire
|
Quote:
http://www.youtube.com/watch?v=G60agHsYkPM recorded on Win Vista, Intel C2Q6600 with 4GB RAM. It should be faster |
|
10-15-2009, 08:10 AM | #11 | |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
Quote:
I agree. And it's going to be. |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
The Case of the Disappearing Cursor... | Hitch | EPUBReader | 8 | 09-08-2010 04:20 AM |
Cursor in PDF not start from first link, why? | bthoven | 0 | 02-05-2010 04:37 AM | |
Silver cursor thingie | honeybunny | Amazon Kindle | 0 | 05-14-2008 08:45 PM |
What is the Technology of the Kindle Cursor? | Kruskal | Amazon Kindle | 2 | 01-30-2008 10:54 AM |
Dead cursor | lordd | Amazon Kindle | 0 | 01-02-2008 09:54 PM |