Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home for chromium.org
« Groups Home
Shipping a font with an extension?
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  19 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Ziyuan Yao  
View profile  
 More options Apr 22 2012, 3:26 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Sun, 22 Apr 2012 12:26:08 -0700 (PDT)
Local: Sun, Apr 22 2012 3:26 pm
Subject: Shipping a font with an extension?
I've just developed this interesting extension:
https://sites.google.com/site/yaoziyuan/files/chrome_pie.zip?attredir...

However, it requires a font called Charis SIL from:
http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=CharisSIL...

I suppose Chrome doesn't have any built-in way for an extension to
install a font, does it?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Łukasz Łoboda  
View profile  
 More options Apr 23 2012, 5:59 am
From: Łukasz Łoboda <lukasz.w.lob...@gmail.com>
Date: Mon, 23 Apr 2012 11:59:52 +0200
Local: Mon, Apr 23 2012 5:59 am
Subject: Re: [crx] Shipping a font with an extension?

You probably can store fonts in your ext and use

@font-face {
  font-family: "Your italic typeface";
  src: url("type/filename-ital.eot");
  src: local("☺"),
    url("type/filename-ital.woff") format("woff"),
    url("type/filename-ital.otf") format("opentype"),
    url("type/filename-ital.svg#filename-ital") format("svg");
  }

2012/4/22 Ziyuan Yao <yaoziy...@gmail.com>


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Devin  
View profile  
 More options Apr 23 2012, 2:06 pm
From: Devin <devinrho...@gmail.com>
Date: Mon, 23 Apr 2012 11:06:05 -0700 (PDT)
Local: Mon, Apr 23 2012 2:06 pm
Subject: Re: Shipping a font with an extension?
...
and you'll want to generate that code with some javascript like this,
probably injected on document_start

var style = document.createElement('style');
style.innerHTML =
  '@font-face
{                                                                                      '+
  '  font-family: "Your italic
typeface";
'+
  '  src: url("' + chrome.extension.getURL('type/filename-ital.eot') +
' ");                         '+
  '  src:
local("☺"),
'+
  '    url("' + chrome.extension.getURL('type/filename-ital.woff') + '
") format("woff"),            '+
  '    url("' + chrome.extension.getURL('type/filename-ital.otf') + '
") format("opentype"),         '+
  '    url("' + chrome.extension.getURL('type/filename-
ital.svg#filename-ital') + ' ") format("svg");'+
  '}';
document.documentElement.appendChild(style);

On Apr 23, 2:59 am, Łukasz Łoboda <lukasz.w.lob...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 23 2012, 2:13 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Mon, 23 Apr 2012 11:13:47 -0700 (PDT)
Local: Mon, Apr 23 2012 2:13 pm
Subject: Re: Shipping a font with an extension?
I can see this is the so-called WebFont usage.

Unfortunately, my extension requires a font like Charis SIL exactly
because it has good support for rendering Unicode combining diacritics
(see this screenshot: https://plus.google.com/102291835965130378165/posts
), and calling Charis SIL via WebFont seems to have rendering
problems.

For example, view this sample HTML file: http://www.bytecool.com/temp/pie.html

It assumes you have Charis SIL installed locally.

If you modifies this HTML to call Charis SIL as a WebFont, you will
see a different result.

On Apr 23, 5:59 pm, Łukasz Łoboda <lukasz.w.lob...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 23 2012, 2:16 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Tue, 24 Apr 2012 02:16:02 +0800
Local: Mon, Apr 23 2012 2:16 pm
Subject: Re: [crx] Re: Shipping a font with an extension?
Sorry, the screenshot link should be:
https://plus.google.com/102291835965130378165/posts/2NB3J3TY886


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 25 2012, 7:51 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Wed, 25 Apr 2012 16:51:24 -0700 (PDT)
Local: Wed, Apr 25 2012 7:51 pm
Subject: Re: Shipping a font with an extension?
Lukasz, Devin:

I want to tell you I have succeeded using your method. I will put your
names in my extension's Acknowledgments :-)

On Apr 24, 2:06 am, Devin <devinrho...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 26 2012, 11:12 am
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Thu, 26 Apr 2012 08:12:31 -0700 (PDT)
Local: Thurs, Apr 26 2012 11:12 am
Subject: Re: Shipping a font with an extension?
Sorry, Chrome seems to have a problem rendering Charis SIL as a Web
font in small sizes. For example, e+ U+0303 (e with a combining tilde
above) can be shown as e with a macron above in certain small sizes.
Calling Charis SIL as a locally installed font doesn't have this
problem.

On Apr 26, 7:51 am, Ziyuan Yao <yaoziy...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Łukasz Łoboda  
View profile  
 More options Apr 26 2012, 11:17 am
From: Łukasz Łoboda <lukasz.w.lob...@gmail.com>
Date: Thu, 26 Apr 2012 17:17:56 +0200
Local: Thurs, Apr 26 2012 11:17 am
Subject: Re: [crx] Re: Shipping a font with an extension?

could you provide some code? (CSS)

2012/4/26 Ziyuan Yao <yaoziy...@gmail.com>


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Discussion subject changed to "Fwd: [crx] Re: Shipping a font with an extension?" by Ziyuan Yao
Ziyuan Yao  
View profile  
 More options Apr 26 2012, 12:32 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Fri, 27 Apr 2012 00:32:25 +0800
Local: Thurs, Apr 26 2012 12:32 pm
Subject: Fwd: [crx] Re: Shipping a font with an extension?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 26 2012, 12:36 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Thu, 26 Apr 2012 09:36:24 -0700 (PDT)
Local: Thurs, Apr 26 2012 12:36 pm
Subject: Re: Fwd: [crx] Re: Shipping a font with an extension?
A little background about this extension:

"Chrome PIE" automatically adds diacritics to English words on a Web
page to indicate their pronunciations (currently I use American
English pronunciation data from CMU Pronouncing Dictionary). This has
three uses:

1. For English-as-a-second-language (ESL) people to learn correct
English word pronunciations.

2. For native English-speaking children to learn how to read. (See "No
Child Left Behind Act".)

3. Recreational use. Show off a sentence in the PIE form to your
online friends or use it in your commercial campaigns.

Refer to page 21 of my free ebook "Breaking the Language Barrier: A
Game-Changing Approach" (
https://sites.google.com/site/yaoziyuan/publications/books/breaking-t...
) for a chart that illustrates which diacritic stands for which sound
or sound group.

On Apr 27, 12:32 am, Ziyuan Yao <yaoziy...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 26 2012, 1:01 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Thu, 26 Apr 2012 10:01:23 -0700 (PDT)
Local: Thurs, Apr 26 2012 1:01 pm
Subject: Re: Fwd: [crx] Re: Shipping a font with an extension?
Also:

chrome_pie-Andika_local.zip - unpacked "Chrome PIE" extension that
assumes you have installed the "Andika" font locally (the font can be
downloaded from http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=Andika_do...
):
https://sites.google.com/site/yaoziyuan/files/chrome_pie-Andika_local...

chrome_pie-CharisSIL_local.zip - unpacked "Chrome PIE" extension that
assumes you have installed the "Charis SIL" font locally (the font can
be downloaded from http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=CharisSIL...
):
https://sites.google.com/site/yaoziyuan/files/chrome_pie-CharisSIL_lo...

I finally realized that the rendering problems of AndikaW and
CharisSILW are caused by Chrome for Linux. They don't occur in Chrome
for Windows.

On Apr 27, 12:32 am, Ziyuan Yao <yaoziy...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 26 2012, 1:15 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Thu, 26 Apr 2012 10:15:29 -0700 (PDT)
Local: Thurs, Apr 26 2012 1:15 pm
Subject: Re: Fwd: [crx] Re: Shipping a font with an extension?
To see how Chrome for Linux renders Web fonts incorrectly, here is an
example:

In my Chrome 18 in Fedora 16 64-bit, with chrome_pie-CharisSILW.zip,
googling [ bread ] will return a first result like this (page zoomed
at 125%):
https://sites.google.com/site/yaoziyuan/files/CharisSILW-error.png?at...

The tilde (~) above "e" in "Bread" is erroneously rendered as a macron
(-).

However, with chrome_pie-CharisSIL_local.zip, Chrome for Linux can
render it right:
https://sites.google.com/site/yaoziyuan/files/CharisSIL_local-correct...

In Chrome for Windows, both chrome_pie-CharisSILW.zip and chrome_pie-
CharisSIL_local.zip can render it right.

On Apr 27, 1:01 am, Ziyuan Yao <yaoziy...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Devin  
View profile  
 More options Apr 26 2012, 1:48 pm
From: Devin <devinrho...@gmail.com>
Date: Thu, 26 Apr 2012 10:48:29 -0700 (PDT)
Local: Thurs, Apr 26 2012 1:48 pm
Subject: Re: Fwd: [crx] Re: Shipping a font with an extension?
Well that's lame and stupid - there is no reason being local should
cause any change... maybe fiddle with some un-suspecting parts so
you're using the same format/file extension as your local font file.

Thanks for the acknowledgment!

On Apr 26, 10:15 am, Ziyuan Yao <yaoziy...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 26 2012, 1:52 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Thu, 26 Apr 2012 10:52:14 -0700 (PDT)
Local: Thurs, Apr 26 2012 1:52 pm
Subject: Re: Fwd: [crx] Re: Shipping a font with an extension?
No, I tried both the .woff and the .ttf in the @font-face declaration.
They produce the same result.

On Apr 27, 1:48 am, Devin <devinrho...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Ziyuan Yao  
View profile  
 More options Apr 26 2012, 4:13 pm
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Thu, 26 Apr 2012 13:13:44 -0700 (PDT)
Local: Thurs, Apr 26 2012 4:13 pm
Subject: Re: Fwd: [crx] Re: Shipping a font with an extension?
I'm glad to tell you guys that although CharisSILW has such "bread"
problems, other Latin fonts from SIL such as Andika, Doulos and
Gentium Plus seem to work well as a Web font even in Chrome for Linux.

So I will ship one of these as a Web font within my extension so that
there will be at least one good font to use for all OSes.

And therefore you will be in the Acknowledgments list :-)

On Apr 27, 1:15 am, Ziyuan Yao <yaoziy...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Discussion subject changed to "Shipping a font with an extension?" by Ziyuan Yao
Ziyuan Yao  
View profile  
 More options Apr 29 2012, 11:32 am
From: Ziyuan Yao <yaoziy...@gmail.com>
Date: Sun, 29 Apr 2012 08:32:31 -0700 (PDT)
Local: Sun, Apr 29 2012 11:32 am
Subject: Re: Shipping a font with an extension?
My extension's website has been set up:
https://sites.google.com/site/phoneticallyintuitiveenglish/

And you two are in the Acknowledgments list:
https://sites.google.com/site/phoneticallyintuitiveenglish/about-us

On Apr 26, 7:51 am, Ziyuan Yao <yaoziy...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Devin  
View profile  
 More options Apr 30 2012, 5:32 pm
From: Devin <devinrho...@gmail.com>
Date: Mon, 30 Apr 2012 14:32:14 -0700 (PDT)
Local: Mon, Apr 30 2012 5:32 pm
Subject: Re: Shipping a font with an extension?
Cool! I feel special :)

I don't have a deep need/use for it, (well, very rarely) but I'll keep
your project in mind as I meet people in the Valley!

On Apr 29, 8:32 am, Ziyuan Yao <yaoziy...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Mike Bartlett  
View profile  
 More options Oct 9 2012, 12:33 pm
From: Mike Bartlett <mike.bartl...@gmail.com>
Date: Tue, 9 Oct 2012 09:33:11 -0700 (PDT)
Local: Tues, Oct 9 2012 12:33 pm
Subject: Re: Shipping a font with an extension?

Hi, did you manage to get this to work.

I keep getting errors like this in my console:
Failed to load resource
chrome-extension://inhlkhnblpeoaglplgdlehbdlhlgngeh/StagWeb-Light.woff
<chrome-extension://inhlkhnblpeoaglplgdlehbdlhlgngeh/StagWeb-Light.woff>
<chrome-extension://inhlkhnblpeoaglplgdlehbdlhlgngeh/StagWeb-Light.woff>

I have this in my CSS.
@font-face {
font-family: 'StagWeb-Light';
    src: url('chrome-extension://__MSG_@@extension_id__/StagWeb-Light.eot');
    src:
url('chrome-extension://__MSG_@@extension_id__/StagWeb-Light.eot?#iefix')
format('embedded-opentype'),
       url('chrome-extension://__MSG_@@extension_id__/StagWeb-Light.woff')
format('woff'),
       url('chrome-extension://__MSG_@@extension_id__/StagWeb-Light.ttf')
format('truetype'),

 url('chrome-extension://__MSG_@@extension_id__/StagWeb-Light.svg#StagWeb-Li ght')
format('svg');
    font-weight: 300;
    font-style: normal;
    font-stretch: normal;

}

Oddly, in the Resources developer tools, the fonts show up but just
reference the same console error.

Mike


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
PhistucK  
View profile  
 More options Oct 10 2012, 7:13 am
From: PhistucK <phist...@gmail.com>
Date: Wed, 10 Oct 2012 13:12:35 +0200
Local: Wed, Oct 10 2012 7:12 am
Subject: Re: [crx] Re: Shipping a font with an extension?

Did you add the path of the font files to the
web_accessible_resources<http://developer.chrome.com/extensions/manifest.html#web_accessible_r...>key
within manifest.json?

☆*PhistucK*

On Tue, Oct 9, 2012 at 6:33 PM, Mike Bartlett <mike.bartl...@gmail.com>wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »