View Single Post
Old 04-10-2018, 03:00 PM   #7
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 2,306
Karma: 13057279
Join Date: Jul 2012
Device: Kobo Forma, Nook
Quote:
Originally Posted by wlashack View Post
I agree,
here is the Google Document I need to convert to epub format properly, so you can try: https://docs.google.com/document/d/1...it?usp=sharing

I tried to remove all styles as suggested by BeckyEbook but it did not leed to the result.

I also tried to open it in Calibre and then use the button Convert Ebook. The result is now most close to what I need to get.
.... yeah, the code out of that Google Doc uses an abomination of CSS3 (counter-increment + counter-reset) and nested ordered lists.

Many ereaders don't support CSS3.

It also uses the HTML start and value element to renumber the lists, which doesn't carry over to many EPUB readers (they are very buggy and start from 1 in many cases).

Also, it tries to use the CSS list-style-type to try to specify lowercase letters + roman numerals, which just doesn't work well on ereaders.

The only way to get this to work on ebooks is to hardcode the letters/numbers instead.

Before (I ran it through Calibre to make it a tiny more readable... the original Google Docs -> EPUB was... horrifying):

Spoiler:
Code:
<h4 id="id_1g8uqbvmo1o" class="block_18">Nic mi nechybí (vše potřebné mi bylo dáno)</h4>
	<ol class="list_">
	<li value="18" class="block_13"><span class="text_10">Narodil jsem se přesně takový, jaký mám být</span><span class="text_9">. Byl jsem optimálně přednastaven.</span></li>
</ol>
	<ol class="list_1">
	<li class="block_11"><span class="text_5">Vypadám i funguji přesně tak, jak mám</span><span class="text_9">. Není na mně co měnit.</span></li>
</ol>
	<ol class="list_1">
	<li class="block_11"><span class="text_5">Mám všechny potřebné talenty</span><span class="text_9">. Neumím jen to, co potřebovat nebudu.</span></li>
</ol>
	<ol class="list_2">
	<li class="block_12"><span class="text_9">Život se sám stará, abych v sobě vše potřebné rozvinul (není co vymýšlet).</span></li>
</ol>
	<ol class="list_1">
	<li value="2" class="block_11"><span class="text_5">Mé touhy a role jsou nastaveny v souladu s mými talenty a schopnostmi</span><span class="text_9">. Je tím zajištěno, že mě bude můj život naplňovat.</span></li>
</ol>


After:

Spoiler:
Code:
<h4 id="id_1g8uqbvmo1o">Nic mi nechybí (vše potřebné mi bylo dáno)</h4>

<div class="list">
	<p class="listone">18. <b>Narodil jsem se přesně takový, jaký mám být</b>. Byl jsem optimálně přednastaven.</p>

		<p class="listtwo">a. <b>Vypadám i funguji přesně tak, jak mám</b>. Není na mně co měnit.</p>

		<p class="listtwo">b. <b>Mám všechny potřebné talenty</b>. Neumím jen to, co potřebovat nebudu.</p>

			<p class="listthree">i. Život se sám stará, abych v sobě vše potřebné rozvinul (není co vymýšlet).</p>

		<p class="listtwo">c. <b>Mé touhy a role jsou nastaveny v souladu s mými talenty a schopnostmi</b>. Je tím zajištěno, že mě bude můj život naplňovat.</p>
</div>


with ~ this CSS:

Spoiler:
Code:
div.list {
	margin-top: 1em;
	margin-bottom: 1em;
}
p.listone {
	text-align: left;
	text-indent: -2em;
	margin-left: 2em;
}

p.listtwo {
	text-align: left;
	text-indent: -2em;
	margin-left: 4em;
}

p.listthree {
	text-align: left;
	text-indent: -2em;
	margin-left: 6em;
}

Last edited by Tex2002ans; 04-10-2018 at 03:52 PM.
Tex2002ans is offline   Reply With Quote