Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 04-04-2018, 08:06 PM   #1
talizorah
Junior Member
talizorah began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Apr 2018
Device: Kindle Paperwhite
Help with unordered list bullets please

Hello,
I'm currently busy with editing my ebook in Calibre in epub format. I've got my custom css attached to it.

In CSS my unordered list is set to display dashes, instead of circles. The code looks like this:

Code:
ul {
  list-style-type: none;
  text-align: justify;
}

ul li:before {
  content: '–';
  position: absolute;
  margin-left: -20px;
}
It all works well in the Editor and everything is displayed properly, but when I load my book into Calibre Library and check the preview there (shortcut V) the dashes are gone. There's absolutely nothing where they should be. The rest of the ebook formatting looks ok, except for those lists.
When I convert my book to MOBI format, the dashes turn into circles, just like the part of the css was omitted. Also wrong.

The dashes are actually very crucial to my book because in my native language you write dialogues using dashes, not quotation marks, so I'd really like them to stay where they should be, else all the dialogue parts are totally disrupted.

Any help, please?
talizorah is offline   Reply With Quote
Old 04-04-2018, 09:19 PM   #2
Sarmat89
Evangelist
Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.Sarmat89 ought to be getting tired of karma fortunes by now.
 
Posts: 482
Karma: 2267928
Join Date: Nov 2015
Device: none
Why would you use list items for dialogues?
Sarmat89 is offline   Reply With Quote
Advert
Old 04-04-2018, 09:52 PM   #3
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,565
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by Sarmat89 View Post
Why would you use list items for dialogues?
I would assume to save typing the leading dash (usually an em dash)

IIRC languages that mark dialogue with a leading dash, such as Russian, only use a trailing dash if the speech is broken by a dialogue descriptor followed by more speech.

BR
BetterRed is offline   Reply With Quote
Old 04-04-2018, 11:05 PM   #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,850
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
MOBI has no support for CSS you need to convert to AZW3 instead. And using absolute positioning with pixel offsets is not really reflowable so whether it works or not in any given viewer is entirely a matter of luck.
kovidgoyal is offline   Reply With Quote
Old 04-05-2018, 04:33 PM   #5
talizorah
Junior Member
talizorah began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Apr 2018
Device: Kindle Paperwhite
Quote:
Originally Posted by BetterRed View Post
I would assume to save typing the leading dash (usually an em dash)

IIRC languages that mark dialogue with a leading dash, such as Russian, only use a trailing dash if the speech is broken by a dialogue descriptor followed by more speech.

BR
Exactly, BetterRed. Central European countries also mark dialogues with dashes. My language is among them. We use quotation marks for ...quoting only or for metaphores.
talizorah is offline   Reply With Quote
Advert
Old 04-05-2018, 04:36 PM   #6
talizorah
Junior Member
talizorah began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Apr 2018
Device: Kindle Paperwhite
Quote:
Originally Posted by kovidgoyal View Post
MOBI has no support for CSS you need to convert to AZW3 instead. And using absolute positioning with pixel offsets is not really reflowable so whether it works or not in any given viewer is entirely a matter of luck.
Thank you very much. I'll try my luck with AZW3 then, but as I see, I should re-make all the dialogues in a manner I wanted to avoid - typing every single dash on about 800 pages. Ah, well... At least I know what to do. Have a nice day!

Update: converting to AZW3 did the trick!

Last edited by talizorah; 04-05-2018 at 05:25 PM.
talizorah is offline   Reply With Quote
Old 04-05-2018, 09:50 PM   #7
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,850
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Assuming you are using <li> only for dialogues, it should be a simple search and replace to insert the quote mark automatically. I dont really understand how wrapping every dialogue in <li> is easier than using <p>- instead.
kovidgoyal is offline   Reply With Quote
Old 04-06-2018, 11:14 AM   #8
talizorah
Junior Member
talizorah began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Apr 2018
Device: Kindle Paperwhite
Quote:
Originally Posted by kovidgoyal View Post
Assuming you are using <li> only for dialogues, it should be a simple search and replace to insert the quote mark automatically. I dont really understand how wrapping every dialogue in <li> is easier than using <p>- instead.
I use <li> only for dialogues. <p> I use for anything else and they have also different formatting than <li>. For example they have indents on first line by 5% which is also standard for a paragraph in my language. They also have different margin settings. Nevertheless your advice helped and now everything looks ok. I tested it on the device and no problems whatsoever anymore.
talizorah is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Unordered list not changing font spamis ePub 3 03-03-2017 03:18 PM
Bullets do not flush after conversion mystica Conversion 0 11-09-2012 02:24 PM
Bullets Gerlyn Sigil 0 02-23-2012 08:36 AM
Need some assistance with CSS and unordered lists Artha ePub 0 11-24-2011 05:17 AM
Mobi unordered list style framallo Conversion 1 03-23-2011 01:22 PM


All times are GMT -4. The time now is 06:51 PM.


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