View Single Post
Old 11-04-2017, 10:31 PM   #21
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,106
Karma: 60406498
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 jackie_w View Post
My *nix knowledge isn't good enough to figure out the absolute path required. I've tried a lot of alternatives but haven't hit on one that works yet. If you have time please will you look at the 2 screencaps below to see whether it's obvious to you what the absolute url path should be.

My font .ttf files are in /fonts in phone internal storage. Using an Android file manager I can navigate to them in 2 ways:
  1. The easier way via Internal storage > fonts (image 1).
  2. From the phone's root directory (image 2).
    To arrive at this location I actually navigated via root > mnt > sdcard > fonts
    but it shows as something???/storage/self/primary/fonts
    once I get there.

To minimise typing until I can get it working (or not). I'm assuming the User style sheet would look something like this:
Code:
@font-face {font-family: MyFont; src: url("abs_path_to_fonts/MyFont-Regular.ttf")}

body {font-family: MyFont, serif}
the first slash implies root, so that is the absolute path.
./ would be relative to the current dir
theducks is offline   Reply With Quote