Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Conversion

Notices

Reply
 
Thread Tools Search this Thread
Old 06-10-2015, 10:11 PM   #1
BruceEckel
Junior Member
BruceEckel began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Aug 2013
Device: Kindle Keyboard
Indentation for numbered/bulletted paragraphs

I'm converting from docx, and both my numbered paragraphs and bulleted paragraphs are getting indented by quite a bit. Ideally, the numbers and bullets would be flush left, in line with all the other paragraphs (which is how the styles have them in the docx).

I'd love to be able to do something in the Word doc to fix this.

I have been able to edit the ePub doc stylesheet, but it feels rather crude -- I have to go find a numbered/bulleted item, see the style (block_n) then go edit that. Would prefer a fix that takes care of itself.

Thanks for any help, and thanks again for such a wonderful tool!
BruceEckel is offline   Reply With Quote
Old 06-10-2015, 11:12 PM   #2
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,858
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Conversion should automatically preserve the indentation in the original document. If it is not, then follow the steps here: https://www.mobileread.com/forums/sho...d.php?t=186697
kovidgoyal is online now   Reply With Quote
Old 06-11-2015, 02:21 AM   #3
BruceEckel
Junior Member
BruceEckel began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Aug 2013
Device: Kindle Keyboard
Problem: this forum's uploader will not accept .DOCX or .DOCM files. Is there a way to email the files to you directly?
BruceEckel is offline   Reply With Quote
Old 06-11-2015, 02:41 AM   #4
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,858
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
zip it up, or use the calibre bug tracker.
kovidgoyal is online now   Reply With Quote
Old 06-11-2015, 08:58 AM   #5
BruceEckel
Junior Member
BruceEckel began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Aug 2013
Device: Kindle Keyboard
Sample showing indentation issue

Zip file attached.

Trace:
Spoiler:

Convert book 1 of 1 (Thinking in Java Director's Cut)
Resolved conversion options
calibre version: 2.30.0
{'asciiize': False,
'author_sort': None,
'authors': None,
'base_font_size': 0.0,
'book_producer': None,
'change_justification': u'original',
'chapter': u"//*[((name()='h1' or name()='h2') and re:test(., '\\s*((chapter|book|section|part)\\s+)|((prolog|pr ologue|epilogue)(\\s+|$))', 'i')) or @class = 'chapter']",
'chapter_mark': u'pagebreak',
'comments': None,
'cover': None,
'debug_pipeline': None,
'dehyphenate': True,
'delete_blank_paragraphs': True,
'disable_font_rescaling': False,
'docx_no_cover': False,
'docx_no_pagebreaks_between_notes': False,
'dont_split_on_page_breaks': False,
'duplicate_links_in_toc': False,
'embed_all_fonts': False,
'embed_font_family': None,
'enable_heuristics': False,
'epub_flatten': False,
'epub_inline_toc': False,
'epub_toc_at_end': False,
'expand_css': False,
'extra_css': None,
'extract_to': None,
'filter_css': u'',
'fix_indents': True,
'flow_size': 260,
'font_size_mapping': None,
'format_scene_breaks': True,
'html_unwrap_factor': 0.4,
'input_encoding': None,
'input_profile': <calibre.customize.profiles.InputProfile object at 0x02270270>,
'insert_blank_line': False,
'insert_blank_line_size': 0.5,
'insert_metadata': False,
'isbn': None,
'italicize_common_cases': True,
'keep_ligatures': False,
'language': None,
'level1_toc': None,
'level2_toc': None,
'level3_toc': None,
'line_height': 0.0,
'linearize_tables': False,
'margin_bottom': 5.0,
'margin_left': 5.0,
'margin_right': 5.0,
'margin_top': 5.0,
'markup_chapter_headings': True,
'max_toc_links': 50,
'minimum_line_height': 120.0,
'no_chapters_in_toc': False,
'no_default_epub_cover': False,
'no_inline_navbars': False,
'no_svg_cover': False,
'output_profile': <calibre.customize.profiles.GenericEink object at 0x02270470>,
'page_breaks_before': u'/',
'prefer_metadata_cover': False,
'preserve_cover_aspect_ratio': False,
'pretty_print': True,
'pubdate': None,
'publisher': None,
'rating': None,
'read_metadata_from_opf': u'C:\\Users\\Bruce\\AppData\\Local\\Temp\\calibre_ g3sev9\\6bsrhn.opf',
'remove_fake_margins': True,
'remove_first_image': False,
'remove_paragraph_spacing': False,
'remove_paragraph_spacing_indent_size': 1.5,
'renumber_headings': True,
'replace_scene_breaks': u'',
'search_replace': '[]',
'series': None,
'series_index': None,
'smarten_punctuation': False,
'sr1_replace': None,
'sr1_search': None,
'sr2_replace': None,
'sr2_search': None,
'sr3_replace': None,
'sr3_search': None,
'start_reading_at': None,
'subset_embedded_fonts': False,
'tags': None,
'timestamp': None,
'title': None,
'title_sort': None,
'toc_filter': None,
'toc_threshold': 6,
'toc_title': None,
'unsmarten_punctuation': False,
'unwrap_lines': True,
'use_auto_toc': False,
'verbose': 2}
InputFormatPlugin: DOCX Input running
on C:\Users\Bruce\AppData\Local\Temp\calibre_g3sev9\i hctvr.docx
Converting Word markup to HTML
Converting styles to CSS
Cleaning up redundant markup generated by Word
Generating Table of Contents from headings
Parsing all content...
Parsing index.html ...
Initial parse failed, using more forgiving parsers
Parsing index.html as HTML
Parsing docx.css ...
Reading TOC from NCX...
Merging user specified metadata...
Detecting structure...
Flattening CSS and remapping font sizes...
Source base font size is 10.50000pt
Removing fake margins...
Found 4 items of level: p_1
Found 1 items of level: p_3
Ignoring level p_1
Ignoring level p_3
Cleaning up manifest...
Trimming unused files from manifest...
Creating EPUB Output...
Splitting markup on page breaks and flow limits, if any...
Splitting on page-break at id=toc_id_1
Looking for large trees in index.html...
No large trees found
Split into 2 parts
Generating default cover
Removing anchor from TOC href: index_split_000.html#id_GoBack
Removing anchor from TOC href: index_split_001.html#toc_id_1
EPUB output written to C:\Users\Bruce\AppData\Local\Temp\calibre_g3sev9\y jezqk.epub
Attached Files
File Type: zip sample.zip (4.97 MB, 101 views)

Last edited by theducks; 06-11-2015 at 10:18 AM. Reason: wrap long paste in spoiler
BruceEckel is offline   Reply With Quote
Old 06-11-2015, 05:34 PM   #6
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,568
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by BruceEckel View Post
I'm converting from docx, and both my numbered paragraphs and bulleted paragraphs are getting indented by quite a bit. Ideally, the numbers and bullets would be flush left, in line with all the other paragraphs (which is how the styles have them in the docx).

I'd love to be able to do something in the Word doc to fix this.

I have been able to edit the ePub doc stylesheet, but it feels rather crude -- I have to go find a numbered/bulleted item, see the style (block_n) then go edit that. Would prefer a fix that takes care of itself.

Thanks for any help, and thanks again for such a wonderful tool!
@BruceEckel - what are you using to view the EPUB?

Here's what I see in Calibre's ebook-viewer [2.30] and Adobe digital editions [4.0.3]:-

Click image for larger version

Name:	Capture calview.JPG
Views:	152
Size:	483.5 KB
ID:	139214 Click image for larger version

Name:	Capture adeview.JPG
Views:	158
Size:	331.5 KB
ID:	139216

Which is about what I'd expect from this in Word 2007:-

Click image for larger version

Name:	Capture wordview.JPG
Views:	170
Size:	256.6 KB
ID:	139215

BR

*I suspect the white boxes in the calibre viewer are caused by my CSS hack.
BetterRed is offline   Reply With Quote
Old 06-11-2015, 09:48 PM   #7
BruceEckel
Junior Member
BruceEckel began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Aug 2013
Device: Kindle Keyboard
ePub Reader

I'm using Readium, which claims to be very compliant (and it's a fast way to check the doc).

Also in iBooks on the iPad.

What you are seeing is pretty much the same as I see -- very big indents, that don't match what's in the word document.

Also, my h1 font size is not getting reflected; the h1 font seems about the same size as h2.

I've been able to fix all these things by patching the CSS but it would be nice if Calibre took care of it.

Last edited by BruceEckel; 06-11-2015 at 09:52 PM.
BruceEckel is offline   Reply With Quote
Old 06-11-2015, 10:21 PM   #8
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,568
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Yeah, I guess the bullet points are indented a bit too far, but the numbered paragraphs look OK to me. For my personal use none of that wouldn't bother me.

My expectation is that I will have to do some fine tuning with an EPUB editor.

Did you try importing the DOCX directly into book-editor - there's an option in the File menu. Not saying it will produce a better result, but might be worth a try.

BR
BetterRed is offline   Reply With Quote
Old 06-11-2015, 11:41 PM   #9
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,858
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
There is no way to fix that. The problem is that the extra padding applied to the list is user agent (HTML renderer) dependant. Some user agents allow it to be overridden, using non-standard CSS properties, some do not. And setting it to zero for the ones that do allow it, can end up breaking the rendering of the list.

The only way to "fix" that would be to not use html <ul> tags for the list. And I think the cure is worse than the disease in that case.

As for font sizes, turn off font size rescaling in the conversion dialog under look & feel.
kovidgoyal is online now   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Limitation in numbered lists? MacEachaidh ePub 16 03-04-2014 12:36 PM
[Suggestion] Change indentation to one letter per indentation level. John Peterson Development 1 10-22-2012 02:05 PM
Numbered Lists on the Nook Mark3 Conversion 1 09-07-2011 10:56 PM
control blockquote indentation bobb40 Conversion 9 08-10-2011 05:04 AM
Preserving Indentation zaph0d Conversion 5 05-30-2011 04:41 PM


All times are GMT -4. The time now is 11:42 AM.


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