Thread: Remove Indent?
View Single Post
Old 02-17-2012, 07:09 AM   #4
kiwidude
Calibre Plugins Developer
kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.kiwidude ought to be getting tired of karma fortunes by now.
 
Posts: 4,637
Karma: 2162064
Join Date: Oct 2010
Location: Australia
Device: Kindle Oasis
If you are using Tweak ePub (or Sigil), you will want to open one of the html pages for the book content where you are seeing the indentation. That will show you what tags are applied, and more importantly what style name it has. Then you can edit the .css file and make changes to the appropriate style name and/or body style tags. You can also use calibre's ebook viewer with its rather nifty ability to show the hierarchy of styles that are applied to a particular paragraph, since of course there could be multiple levels of div tags etc.

My personal approach for a book like you mention would be after converting to ePub, to open with Sigil, open one of the chapter pages, lookup the style name(s) causing the issue, open the css, zero the margin-left for that style name. If it isn't <blockquote> based paragraphs, then it is just a case of looking at the relevant tag hierarchy to see whether it is the paragraphs, div or some body level class style that you need to change. I would also normally do any other margin adjustments for other relevant styles to my preference, fixup the TOC styles if needed, resplit/join to resolve any page break issues and do some basic checks for broken lines etc.

You are going to have to learn some basics about what files make up an epub to know which to edit, and some basic css/html concepts. If you get into heavier editing regex knowledge is mandatory as well. There is a forum on MobileRead dedicated to Sigil for any questions for it and google is your friend.

If using Sigil I suggest installing the "Open With" plugin as well, which gives you a convenient right-click or keyboard shortcut to open an ePub with Sigil. Sigil just gives you a more convenient way of working with the files that you saw Tweak ePub.

The Modify ePub plugin is for "touch-up" type tasks - an automated way to correct "flaws" identified by the Quality Check plugin or that a user otherwise knows they want applied. Many of its features are just options that you could achieve by doing an ePub->ePub conversion, but there are circumstances where avoiding such a conversion is desirable. You are correct in that the plugin does not have anything specific that would apply to your particular mobi issue, but I mentioned it because if you start down the route if converting or using ePub as a "master" source in your library, then it may come in useful for other reasons.

Final point - you are likely downloading the latest Sigil of 0.5.2. The 0.5 releases have been fairly problematic, the guys are working through the issues still. Personally I still use 0.4.2, which has a truckload of problems of its own but until the next Sigil comes out I am still waiting for the dust to settle. Just look at the 0.5.2 thread in the Sigil forum to make sure you are aware of the known gotchas and you should be fine.
kiwidude is offline   Reply With Quote