12-09-2013, 05:09 PM | #271 | |
Well trained by Cats
Posts: 29,816
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
I was looking for something in Code View (FWIW Preview is usually a easier place to do it) |
|
12-09-2013, 05:33 PM | #272 | |
Dead account. Bye
Posts: 587
Karma: 668244
Join Date: Mar 2011
Device: none
|
Quote:
Well, I've found both methods in different books. HTML linking is more frequent but in this case CSS linking is used. But as I said the weirdest thing is that I ALWAYS comment out page-template references (in either CSS or HTML) because I hate additional margins on ebooks (which are nearly always included in page-template.xpgt). |
|
12-09-2013, 05:39 PM | #273 | |
Dead account. Bye
Posts: 587
Karma: 668244
Join Date: Mar 2011
Device: none
|
Quote:
Just a question, is this going to be final or do you plan to add a "full" preview sometime in the future? |
|
12-09-2013, 05:45 PM | #274 |
Grand Sorcerer
Posts: 6,212
Karma: 16534894
Join Date: Sep 2009
Location: UK
Device: Kobo: KA1, ClaraHD, Forma, Libra2, Clara2E. PocketBook: TouchHD3
|
Maybe my reason is wrong but the solution is the same. If you click the 'Try to correct' option, the nbsp entities get converted to unicode, the DOCTYPE is removed and the errors go away. I've noticed that calibre never creates DOCTYPEs in conversions but I don't know the background to this decision.
|
12-09-2013, 05:54 PM | #275 | |
Dead account. Bye
Posts: 587
Karma: 668244
Join Date: Mar 2011
Device: none
|
Quote:
BUT, the possible issue which Kovid should know about is that s cause a lot of warnings and I don't know if that is the intended behaviour because AFAIK is a perfect valid statement inside epubs, isn't it? More over, Check Book only gives you one error per file, (I find this behaviour quite logical). In this way the very first masks any other possible "real" bug after it. Last edited by arspr; 12-09-2013 at 06:00 PM. |
|
12-09-2013, 06:01 PM | #276 |
Grand Sorcerer
Posts: 6,111
Karma: 34000001
Join Date: Mar 2008
Device: KPW1, KA1
|
I've been playing around with the Tweak Book function. It looks very nice
A bug, it seems: Shortcuts not sticking (tested with Split function). I add a shortcut and press "Done", and the shortcut is shown. I press "OK", but the shortcut does not work. Upon returning to the Shortcut window, the shortcut is gone. If there was a different shortcut before customizing it, the previous shortcut is shown. edit: The shortcut DOES stick, but it only works and shows up after restarting ebook-tweak. There are some questions: 1. Is it possible to make the font in the preview window smaller? CTRL+Scroll, or CTRL-minus does not do anything, and I didn't see any options. The font is huge. 2. Is there a way to open the table of contents to use it for navigation? 3. What purpose does the inspector serve? It seems to provide a lot of information, but I can't think of a use for it for ebooks; it could be useful for a big website, but most ebooks seem to be too simple to need it. 4. If someone has the preview disabled, is there still another way to split a file? While it is a very intuitive way of splitting, I can imagine that there are people who'd like a Sigil-like "Split at cursor" option in one of the menu's to use in combination with code view. And a suggestion: Move the toolbar in the preview to the top, or make it a toolbar that can be displayed below the menu, next to the other ones. Personally, I always find toolbars on the bottom of windows weirdly placed, but this is a matter o taste of course. Last edited by Katsunami; 12-09-2013 at 06:06 PM. |
12-09-2013, 06:08 PM | #277 | |
Dead account. Bye
Posts: 587
Karma: 668244
Join Date: Mar 2011
Device: none
|
Quote:
In complex ebooks with a lot of cascaded styles (redundancy here) you can easily check what settings are being applied, which are overridden and why you have that behaviour. And it also helps you locating typos when you edit CSS styles. If it correctly appears in inspector you've really done it right. |
|
12-09-2013, 09:45 PM | #278 |
creator of calibre
Posts: 43,866
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
@Katsunami: The font size in the preview panel comes from the book. If the book specifies no font size then it comes from the font size settings in the calibre viewer. Decrease those if you want the font size smaller.
@arspr: named entities are illegal in XML without a doctype that defines those entities (apart from the five named XML entities). If a doctype is present then they will cause no errors, however, the checker in calibre will still report errors since otherwise it would have to download the DTD from the network and validate the entities with it, which is too slow. calibre removes all doctypes and converts all entities to unicode characters whenever it does any automated processing. That is not going to change. And no there is never going to be a "full" preview with support for page layout. When checking links in css calibre does not ignore links inside comments. I may change that in the future, or not. Depends on how common commented links in css files turn out to be. If you want to search for any unicode character, simply copy paste it from the text into the find field. At some point I will add a character entry tool like sigil has, however, most operating systems already have tools to enter special characters, you should be able to use those. Also note, that you can enter named entities like normal in the editor. They will be replaced with unicode characters automatically when saving the book. Last edited by kovidgoyal; 12-09-2013 at 11:14 PM. |
12-09-2013, 10:22 PM | #279 |
creator of calibre
Posts: 43,866
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Actually, regarding named entities, I think I am going to have the checker simply ignore them when checking for well-formed XML. Any named entities will be reported separately as an error (once per HTML file, with an option to auto-replace them with unicode characters with a single click).
|
12-09-2013, 10:48 PM | #280 | |
Color me gone
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
|
Quote:
|
|
12-10-2013, 04:00 AM | #281 |
creator of calibre
Posts: 43,866
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
I implemented the separate handling for entities, seems to work well. The XML parser ignores the entities, treating them as whitespace and they are analyzed and reported separately.
@arspr: I decided to fix links inside comments in stylesheets, for the next release. |
12-10-2013, 08:59 AM | #282 |
Color me gone
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
|
Kovid, would it be out of order to put out a call for people to put their worst pieces of malformed junk that made Sigil barf into your new editor?
It might be a good time to test out how it responds to really badly formed junk, since it seems to be nearing initial prime time. |
12-10-2013, 09:01 AM | #283 |
creator of calibre
Posts: 43,866
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Sure, junk that causes failures is most welcome.
Last edited by kovidgoyal; 12-10-2013 at 09:13 AM. |
12-10-2013, 09:04 AM | #284 |
Grand Sorcerer
Posts: 6,111
Karma: 34000001
Join Date: Mar 2008
Device: KPW1, KA1
|
LOL
That sounds so wrong... |
12-10-2013, 11:56 AM | #285 | |
Dead account. Bye
Posts: 587
Karma: 668244
Join Date: Mar 2011
Device: none
|
A REAL trouble I once suffered within a book and one that I've checked that the new Check Book doesn't inform you about either...
Remove the closing "}" from any style... It can drive you nuts as there's no information about something strange. And till the next closing "}" you have trouble in both styles. (I suffered it in the middle of font declaration statements and I got crazy till I located what the hell happened in the book.). I think it could be a good idea that, if parser finds an "entry/entity" inside any other one, it should arise a warning. Another one I haven't suffered but I think it can be REALLY easy to have. Remove the closing ";" from any property (but final one). Then you have trouble inside a style. And Check Book doesn't tell you anything about it. This situation would be a good catch too. Quote:
And another suggestion related to the ";" issue. Currently, Beautify CSS removes the last ";". As a safety measure I would do the opposite action, I would always add it even if not necessary... Last edited by arspr; 12-10-2013 at 12:04 PM. Reason: Beautify and last ";" in CSS styles |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to make Sigil live | varlog | Sigil | 136 | 10-25-2013 02:34 PM |
how many tocs does Sigil make? | Gregg Bell | Sigil | 17 | 01-31-2013 09:39 AM |
How do I make all .pdf's in my calibre library open in calibre instead of preview | morbo3000 | Library Management | 9 | 07-30-2011 10:39 AM |
using sigil to make changes befote conversion | alansplace | Sigil | 11 | 06-07-2011 07:50 AM |
i can't make sigil run in fedora 14 | nastarovia | Sigil | 1 | 01-20-2011 05:02 AM |