View Single Post
Old 12-20-2022, 07:11 PM   #3
aknight2015
Junior Member
aknight2015 began at the beginning.
 
Posts: 9
Karma: 10
Join Date: Dec 2022
Device: Galaxy Tab SM-T500
I don't know if I'm doing something wrong or what, but it's not working, at all. Could you actually show what the code looks like inside the CSS? That might help me understand.


Quote:
Originally Posted by Turtle91 View Post
Hi aknight2015 - welcome to MR!

For the font, you have to tell the css to use it and where it is located with something like:
Code:
@font-face {
    font-family: 'My Italic';
    font-weight: bold;
    font-style: italic;
    src: url('../Fonts/My_Italic_Bold_Italic.ttf');
}
Then you just add it to the font-family declaration like:

Code:
h1 {font-family: 'My Italic', serif}
For the image compression, Sigil doesn't compress the image files at all - it only displays them how you have defined them in the CSS. I use something along the lines of this to display my images:

Code:
img {max-height:100%; max-width:100%}
div.image {margin:2em}
div.image img {width:100%; max-width:1200px}


<div class="image"><img alt="" src="../Images/yourimage.jpg"/></div>
The max-width is where I put the images actual width in pixels (the images dimensions) to prevent the image from becoming too stretched on large displays.
aknight2015 is offline   Reply With Quote