2

I'm creating an ebook with calibre but I can't set a good drop cap because the letter doesn't follow the font-family rule in the css.

Here's my code:

p:first-of-type:first-letter {
    font-family: "Dearest" !important;
    initial-letter: 3;
    -webkit-initial-letter: 3;
    margin-right: 0.5em;
    color: #903;
}

The drop cap works only with the font specified in p { } (I tested the ebook on iBooks for Mac) How can I solve this issue?

Cristian
  • 654
  • 1
  • 13
  • 30
  • 1
    Which version of Calibre? And directly related to that, which version of CSS does that support? (`first-letter` has been in CSS since CSS1, but `first-of-type` is a CSS3 feature). – Mike 'Pomax' Kamermans Oct 24 '16 at 03:04
  • Can you confirm that the rest of the style (such as the color) _does_ work? So it's not the selector that is the problem? In that case, I'd check if the "Dearest" font displays at all. Is it a webfont? – Mr Lister Oct 24 '16 at 07:00
  • first-of-type works and the color works too but the letter is not displayed as a dropcap – Cristian Nov 01 '16 at 19:19

0 Answers0