View Single Post
Old 07-13-2023, 06:37 PM   #155
Comfy.n
want to learn what I want
Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.
 
Posts: 1,641
Karma: 7908443
Join Date: Sep 2020
Device: none
Hi Jellby,

For most conversions, I'm using this CSS:

PHP Code:
body  {background-color:transparent !important;}
@
font-face {font-familyserif;  srclocal("ChareInk6")}

@
page {
  
size17cm 32cm;
  
margin5mm 3mm 5mm 3mm !important;
    @
top-left {
    
font-size50%;
    
font-styleitalic;
    
border-bottomsolid thin black;
    
margin-bottom1mm;
    
contentstring(booktitle);
    
  }
  @
top-center {
    
font-size50%;
    
font-styleitalic;
    
border-bottomsolid thin black;
    
margin-bottom1mm;
    
contentstring(chaptertitle);
  }
  @
top-right {
    
font-size50%;
    
border-bottomsolid thin black;
    
margin-bottom1mm;
    
contentcounter(page"/" counter(pages);
  }
}

@
page:first {
  
margin1mm 1mm 1mm 1mm;

  @
top-left {
    
border-width0;
    
margin0;
    
contentnormal;
  }
  @
top-center {
    
border-width0;
    
margin0;
    
contentnormal;
  }
  @
top-right {
    
border-width0;
    
margin0;
    
contentnormal;
  }
}

body {
  
font-size15pt;
  
font-family"ChareInk6";  
  
text-alignjustify;
  
prince-image-resolution166dpi;
  
hyphensauto;
  
string-setbooktitle "@{@{title}@}@"
  
string-setauthor "@{@{author}@}@"
 

Now I noticed that, on books with large covers, the cover image exceeds the printing area on the converted PDF's first page.

Is there some CSS styling I can apply to get the cover to fit the page size (17cm x 32cm, in most cases)?

Last edited by Comfy.n; 07-13-2023 at 07:01 PM.
Comfy.n is offline   Reply With Quote