| 
	|||||||
![]()  | 
            
        
| 
             | 
        Thread Tools | Search this Thread | 
| 
			
			 | 
		#31 | |
| 
			
			
			
			 Wizard 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,592 
				Karma: 11722446 
				Join Date: Aug 2010 
				Location: NE Oregon 
				
				
				Device: Kobo Sage, Pocketbook Era, Kobo Forma, Kindle Oasis 2 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 So, for the moment at least, I've added it: Code: 
	p.chapter-lead::first-letter {
  initial-letter: 2;
  -webkit-initial-letter: 2;
}
Now, you do have to play about with it. For instance, if you add any padding, you have to consider that if a device honors first-letter but NOT initial-letter, you could get an odd look if you go crazy with too much. A tiny dab might be OK. I've been playing with adding a trace for the letter "I", because it tends to look a bit cramped otherwise. It's possible it might not play well with every font too, I tried it with Open Dyslexic and placement of the drop cap was odd. So a risk, given one never knows what fonts people will decide to read with. I've seen folks post some doozies! And, with a phone in landscape orientation, you run the risk that if only the first line of the chapter fits on the screen, your drop cap will show, but its bottom half on the second line will be truncated.... I tossed the epub into the Kobo iOS app and also BookFusion iOS, and not only is initial-letter honored, but also hanging-punctuation! YAY! I tossed in a picture of the hanging-punctuation property working in the Kobo app on my iPad! Fun times if you make backward compatible epub3! You can't eat cake ALL the time, but sometimes is nice!  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#32 | 
| 
			
			
			
			 A Hairy Wizard 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,397 
				Karma: 20212733 
				Join Date: Dec 2012 
				Location: Charleston, SC today 
				
				
				Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			Yeah, that would be nice....but.... all you need to do is put the non-supporting css first, then the @supports rule. If it supports then it takes priority since it is later in the css. 
		
	
		
		
		
		
		
		
		
		
		
		
	
	Here is the example from W3Schools: Code: 
	/* use this CSS if the browser does not support display: grid */
.container {
  display: table;
  width: 90%;
  background-color: #2196F3;
  padding: 10px;
}
/* use this CSS if the browser supports display: grid */
@supports (display: grid) {
  .container {
    display: grid;
    grid: auto;
    grid-gap: 10px;
    background-color: #2196F3;
    padding: 10px;
  }
}
 | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#33 | |||||
| 
			
			
			
			 Connoisseur 
			
			![]() Posts: 91 
				Karma: 10 
				Join Date: Dec 2024 
				
				
				
				Device: Tolino Shine 5 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Quote: 
	
 Quote: 
	
 ![]() Code: 
	@supports (initial-letter: 2;) {
  p.chapter-lead::first-letter {
    initial-letter: 2;
    -webkit-initial-letter: 2;
}
}
Quote: 
	
 Quote: 
	
 Code: 
	span.dropcap-epub2 {
  font-size:580%;
  float:left;
  margin: -0.1em 0.1em -0.1em 0;
  vertical-align: top;
  line-height: 1 !important;
}
@supports (initial-letter:2) or (-webkit-initial-letter:2) {
  span.dropcap-epub2 {
    font-size:revert;
    float:revert;
    margin: revert;
    vertical-align: revert;
    line-height: revert;
    }
  
  h2 + p::first-letter{
    initial-letter: 2;
    -webkit-initial-letter: 2;
    margin-right: 0.3em;
    }  
}
 | 
|||||
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#34 | |||
| 
			
			
			
			 Resident Curmudgeon 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 80,782 
				Karma: 150249619 
				Join Date: Nov 2006 
				Location: Roslindale, Massachusetts 
				
				
				Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Quote: 
	
  | 
|||
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#35 | 
| 
			
			
			
			 Bibliophagist 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 48,175 
				Karma: 174315444 
				Join Date: Jul 2010 
				Location: Vancouver 
				
				
				Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			I was under the impression that ADE2 disregarding the entire style sheet after an error was triggered by a structural error in the stylesheet not by an correctly structured unknown item. A missing { or } for instance.
		 
		
	
		
		
		
		
		
		
		
		
		
		
	
	 | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#36 | |
| 
			
			
			
			 Resident Curmudgeon 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 80,782 
				Karma: 150249619 
				Join Date: Nov 2006 
				Location: Roslindale, Massachusetts 
				
				
				Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Here is code that ADE 2.0.1 thinks is an error from a StandardEbooks CSS. It's code that will not work in most cases anyway. So there's no need for it. Code: 
	@media all and (prefers-color-scheme: dark) {
  img.epub-type-se-image-color-depth-black-on-transparent {
    filter: invert(100%);
  }
  img.epub-type-se-image-color-depth-black-on-transparent.epub-type-se-image-style-realistic {
    background: currentColor;
    filter: none;
  }
}
@media all and (prefers-color-scheme) {
  img.epub-type-se-image-color-depth-black-on-transparent:not(.epub-type-se-image-style-realistic) {
    background: transparent !important;
  }
}
 | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#37 | |
| 
			
			
			
			 Wizard 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,877 
				Karma: 8821117 
				Join Date: Mar 2013 
				Location: Rosario - Santa Fe - Argentina 
				
				
				Device: Kindle 4 NT 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 https://www.mobileread.com/forums/sh...8&postcount=12  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#38 | |
| 
			
			
			
			 Wizard 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,877 
				Karma: 8821117 
				Join Date: Mar 2013 
				Location: Rosario - Santa Fe - Argentina 
				
				
				Device: Kindle 4 NT 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 https://www.mobileread.com/forums/sh...4&postcount=29 Last edited by RbnJrg; 06-24-2025 at 08:35 PM.  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#39 | |
| 
			
			
			
			 Connoisseur 
			
			![]() Posts: 91 
				Karma: 10 
				Join Date: Dec 2024 
				
				
				
				Device: Tolino Shine 5 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 With a 100% height setting, things can become messy in calibre viewer. (see attachment). Not setting it eliminates all issues with the caption overlapping the text. The solution you linked places the caption on the picture in Thorium and Calibre viewer and may split the image in ADE and in Books. Removing the div and setting the height for the SVG works better for me, but splits can still happen.  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#40 | |
| 
			
			
			
			 Resident Curmudgeon 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 80,782 
				Karma: 150249619 
				Join Date: Nov 2006 
				Location: Roslindale, Massachusetts 
				
				
				Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 In your CSS for figure, if you do need webkit code, then the program being used is not ePub3 compliant enough.  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#41 | 
| 
			
			
			
			 Connoisseur 
			
			![]() Posts: 91 
				Karma: 10 
				Join Date: Dec 2024 
				
				
				
				Device: Tolino Shine 5 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			Ensuring backwards compatibility for a renderer with broken forward compatibility sure is a pain. Might be one of the reasons why it's taking so long for epub3 to catch on.
		 
		
	
		
		
		
		
		
		
		
		
		
		
	
	 | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#42 | |||
| 
			
			
			
			 Wizard 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,877 
				Karma: 8821117 
				Join Date: Mar 2013 
				Location: Rosario - Santa Fe - Argentina 
				
				
				Device: Kindle 4 NT 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Quote: 
	
 1. In Thorium (with a font-size of 100%): 2. In Thorium (with a font-size of 137.5%): 3. In Calibre Viewer (with a font-size of 14px): 4. In Calibre Viewer (with a font-size of 18px): I attach the respective epub so you can test it in your system. Open it in Calibre Viewer and start with a font-size: 14px; then increase the font-size to 28px. As you will be able to see, the caption remains with the picture and there is no fragmentation in the text (there is no blank space generated by the image and the change of the font-size). You must be doing something wrong, otherwise you would have the same output than me. Quote: 
	
  | 
|||
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#43 | |
| 
			
			
			
			 Wizard 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,877 
				Karma: 8821117 
				Join Date: Mar 2013 
				Location: Rosario - Santa Fe - Argentina 
				
				
				Device: Kindle 4 NT 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#44 | ||
| 
			
			
			
			 Wizard 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,877 
				Karma: 8821117 
				Join Date: Mar 2013 
				Location: Rosario - Santa Fe - Argentina 
				
				
				Device: Kindle 4 NT 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Quote: 
	
  | 
||
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#45 | ||
| 
			
			
			
			 Resident Curmudgeon 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 80,782 
				Karma: 150249619 
				Join Date: Nov 2006 
				Location: Roslindale, Massachusetts 
				
				
				Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Webkit code has to go as it's nothing to do with ePub3 or ePub2 code. Quote: 
	
  | 
||
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
![]()  | 
            
        
            
| Thread Tools | Search this Thread | 
            
  | 
    
			 
			Similar Threads
		 | 
	||||
| Thread | Thread Starter | Forum | Replies | Last Post | 
| Kindle Epub vs Standard Epub | JudahsShadow | Library Management | 3 | 05-01-2023 02:55 PM | 
| Linux ePub reader app that best fullfills the ePUB standard | celiapgt | Reading and Management | 12 | 04-19-2022 01:42 AM | 
| Help revise the Epub standard | Nate the great | General Discussions | 8 | 04-18-2010 12:29 PM | 
| Standard Reader for Epub | bhuvana786 | ePub | 6 | 08-21-2009 12:00 PM |