Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 01-18-2022, 03:49 AM   #1
rinaron
Junior Member
rinaron began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Oct 2020
Device: kindle
Sigil does not find my embedded font

from css=
@font-face {
font-family: “Mekorot-Rashi”;
font-weight: normal;
font-style: normal;
src: url(“../Fonts/Mekorot-Rashi.ttf”);
}
.cs_Times-Rashi{
text-decoration-line:none;
font-weight:487;
font-size:0.92em;
font-family:"Mekorot-Rashi", serif;
letter-spacing:0em;
vertical-align:0px;
color:black;
text-transform:inherit;
font-style:normal;
font-variant:inherit;
font-stretch:normal;
background-color:inherit;
}
from xhtml=
<p class='ps_chapter' dir='rtl'><span class='cs_Times-Rashi'>תנא לישנא דעלמא נקט - אי לא הדר תנא כולה שלי הוה אמינא, מאי מצאתיה דקתני תנא, לשון בני אדם אחז במשנתנו, ולא לשון מקרא, והרבה בני אדם קורין לה מציאה משעת ראיה.</span></p>

the font file was added to the Fonts folder in Sigil

when the font is installed on the computer it shows correctly in the preview
but it doesn't show correctly when not installed
screen shots are included
Attached Thumbnails
Click image for larger version

Name:	Screen Shot 2022-01-18 at 10.22.33.png
Views:	160
Size:	45.9 KB
ID:	191663   Click image for larger version

Name:	Screen Shot 2022-01-18 at 10.21.57.png
Views:	160
Size:	68.4 KB
ID:	191664   Click image for larger version

Name:	Screen Shot 2022-01-18 at 10.29.49.png
Views:	149
Size:	64.6 KB
ID:	191665  
rinaron is offline   Reply With Quote
Old 01-18-2022, 04:11 AM   #2
BeckyEbook
Guru
BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.
 
BeckyEbook's Avatar
 
Posts: 839
Karma: 2657572
Join Date: Jan 2017
Location: Poland
Device: Various
I did a test and the font (without installing it on the system) is visible in the preview window.

Windows 10, Sigil 1.8.0 + current master (two separate tests).

EDIT: I see problem in your styles – use normal (not qurly) quotes:

Code:
font-family: "Mekorot-Rashi";
font-weight: normal;
font-style: normal;
src: url("../Fonts/Mekorot-Rashi.ttf");

Last edited by BeckyEbook; 01-18-2022 at 04:20 AM.
BeckyEbook is offline   Reply With Quote
Advert
Old 01-18-2022, 10:47 AM   #3
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,745
Karma: 5703586
Join Date: Nov 2009
Device: many
Yes, quote chars in css are " and ', any other chars will be treated as normal chars for that url or name. That is correct behaviour according to the css spec.

In many cases with no special chars in the string, the quotes themselves are optional, too.
KevinH is offline   Reply With Quote
Old 01-18-2022, 10:53 AM   #4
rinaron
Junior Member
rinaron began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Oct 2020
Device: kindle
sigil still does not find fonts

Thank you for mentioning about the quote marks. I did not notice that. I changed the quote marks and Sigil still does not find the embedded fonts and uses the default serif instead. I am attaching a sample and screen shots of how it looks and how it should look.
Attached Thumbnails
Click image for larger version

Name:	Screen Shot 2022-01-18 at 17.20.31.png
Views:	158
Size:	140.8 KB
ID:	191679   Click image for larger version

Name:	Screen Shot 2022-01-18 at 17.21.52.png
Views:	147
Size:	136.4 KB
ID:	191680  
Attached Files
File Type: epub sampleembed.epub (72.5 KB, 133 views)
rinaron is offline   Reply With Quote
Old 01-18-2022, 11:09 AM   #5
BeckyEbook
Guru
BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.
 
BeckyEbook's Avatar
 
Posts: 839
Karma: 2657572
Join Date: Jan 2017
Location: Poland
Device: Various
If css styles are in root, fonts in "Fonts", you can fix paths to font files:
Code:
@font-face {
font-family: "Mekorot-Rashi";
font-weight: normal;
font-style: normal;
src: url("Fonts/Mekorot-Rashi.ttf");
}
@font-face {
font-family: "David CLM";
font-weight: normal;
font-style: normal;
src: url("Fonts/DavidCLM-Medium.otf");
}
@font-face {
font-family: "David CLM";
font-weight: bold;
font-style: normal;
src: url("Fonts/DavidCLM-Bold.otf");
}
BeckyEbook is offline   Reply With Quote
Advert
Old 01-18-2022, 11:12 AM   #6
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,745
Karma: 5703586
Join Date: Nov 2009
Device: many
Forgive my ignorance here.

This is an example of RTL language, correct.

Assuming that the first screenshot is "how it looks" and the second screenshot is "how it should look":

I loaded your sampleembed.epub and I see the second picture based on the far right first word on the top line.

Is that correct behaviour or broken behaviour?

What version of Sigil are you using and on what platform?
KevinH is offline   Reply With Quote
Old 01-18-2022, 11:13 AM   #7
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,745
Karma: 5703586
Join Date: Nov 2009
Device: many
Good catch. I did not think to even look at the full paths. So the first screenshot is the correct one, right?


Quote:
Originally Posted by BeckyEbook View Post
If css styles are in root, fonts in "Fonts", you can fix paths to font files:
Code:
@font-face {
font-family: "Mekorot-Rashi";
font-weight: normal;
font-style: normal;
src: url("Fonts/Mekorot-Rashi.ttf");
}
@font-face {
font-family: "David CLM";
font-weight: normal;
font-style: normal;
src: url("Fonts/DavidCLM-Medium.otf");
}
@font-face {
font-family: "David CLM";
font-weight: bold;
font-style: normal;
src: url("Fonts/DavidCLM-Bold.otf");
}

Last edited by KevinH; 01-18-2022 at 11:20 AM.
KevinH is offline   Reply With Quote
Old 01-18-2022, 11:22 AM   #8
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,745
Karma: 5703586
Join Date: Nov 2009
Device: many
Sometimes, I really think we should change the Sigil default settings to show full epub root relative paths in BookBrowser so that people do not need to use tool-tips to see the path.

Quote:
Originally Posted by KevinH View Post
Good catch. I did not think to even look at the full paths. So the first screenshot is the correct one, right?
KevinH is offline   Reply With Quote
Old 01-18-2022, 02:41 PM   #9
rinaron
Junior Member
rinaron began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Oct 2020
Device: kindle
It worked! Sorry I wasn't clear about which was the correct screen shot. It is the one with the "fancier" font which is called Rashi script (on the left). This is mostly in Aramaic which is written with Hebrew letters (unicode) but the letters are shaped differently. This book is mostly in English but the Rashi script must be embedded or else it comes out looking like Hebrew. I do not know if the readers in the US even have Hebrew fonts. Will using the fonts as you showed work on all ebook readers not just Sigil on my computer? I have Sigil 1.8 and Mac OS Montery, but I also tried it on Windows 10 with the same results.
Thank you so much!
rinaron is offline   Reply With Quote
Old 01-18-2022, 02:55 PM   #10
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,745
Karma: 5703586
Join Date: Nov 2009
Device: many
It shoud. You should go to Sigil Preferences and enable showing full book paths in BookBrowser.

Once you do that, you can more easily see where the css was located, and where the font files are located within the epub, so you can create the proper relative links.

FYI, I think there is a Sigil plugin that makes adding embedded fonts easier.

Do not forget to either obfuscate or subset (or both) that font depending on its licence if need be.
KevinH is offline   Reply With Quote
Old 01-18-2022, 04:10 PM   #11
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 28,550
Karma: 204127028
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by KevinH View Post
Sometimes, I really think we should change the Sigil default settings to show full epub root relative paths in BookBrowser so that people do not need to use tool-tips to see the path.
I always leave the full-path in Book Browser preference turned on.
DiapDealer is offline   Reply With Quote
Old 01-18-2022, 04:14 PM   #12
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,745
Karma: 5703586
Join Date: Nov 2009
Device: many
So do I now. But should we make it the default for new installs?
KevinH is offline   Reply With Quote
Old 01-18-2022, 06:27 PM   #13
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 28,550
Karma: 204127028
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
It might help new users stop making the assumption that the virtual Book Browser groupings are also (always) indicative of the epub's actual file structure.
DiapDealer is offline   Reply With Quote
Old 01-18-2022, 06:33 PM   #14
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,023
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by KevinH View Post
So do I now. But should we make it the default for new installs?
Yes. If they don't want it, they can turn it off.
theducks is offline   Reply With Quote
Old 01-18-2022, 07:35 PM   #15
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: 21,708
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
FWIW - I'd like to be able to toggle show/hide full-path via a menu option or keyboard shortcut. I don't need it most of the time, it just adds clutter. But when I need it I don't like having to change Preferences - which I regard as 'set and forget'.
BetterRed is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Embedded Style and Embedded Font labels truncated in KA1 sladflob KOReader 2 06-25-2020 08:43 PM
Preventing Sigil embedded font files from user access bobcdy Sigil 34 02-22-2015 09:13 AM
Mini advanced font settings ignored in one book - embedded font? lordofazeroth Kobo Reader 4 09-20-2013 02:15 PM
Sigil + embedded font variants troymc Sigil 6 10-17-2012 11:00 AM
embedded font - now line with embedded font not re-flowing Kaylee Skylyn ePub 23 08-09-2012 07:30 PM


All times are GMT -4. The time now is 12:24 AM.


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