fontrobot 0.1.6 → 0.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.md +5 -7
- data/lib/fontrobot/generator.rb +1 -1
- data/lib/fontrobot/templates/fontrobot.css +1 -1
- data/lib/fontrobot/version.rb +1 -1
- metadata +4 -4
data/README.md
CHANGED
@@ -1,11 +1,9 @@
|
|
1
|
-
FontRobot v0.1.
|
1
|
+
FontRobot v0.1.7
|
2
2
|
==========
|
3
3
|
|
4
4
|
**Generate custom icon webfonts from the comfort of the command line.**
|
5
5
|
|
6
|
-
This is a fork of Fontcustom. I needed a quick fork to work out the kinks using this gem in a large-scale production Rails environment.
|
7
|
-
|
8
|
-
FontRobot is primarily designed to add more control over how the @fontface declaration is created. See command-line options below for more details.
|
6
|
+
This is a fork of Fontcustom. I needed a quick fork to work out the kinks using this gem in a large-scale production Rails environment. FontRobot is primarily designed to add more control over how the @fontface declaration is created. See command-line options below for more details.
|
9
7
|
|
10
8
|
Fontrobot allows you to:
|
11
9
|
|
@@ -14,12 +12,12 @@ Fontrobot allows you to:
|
|
14
12
|
* Create an IE-compatible @font-face declaration
|
15
13
|
* output css files with .scss extension for importing to Sass projects
|
16
14
|
|
17
|
-
Including fonts as data-uris is nice because it avoids Firefox's same-origin policy and they load fast. For best performance, make sure your server gzips all served assets.
|
18
|
-
|
19
|
-
[Original Fontcustom documentation](http://fontcustom.github.com/fontcustom/)
|
15
|
+
Including fonts as data-uris is nice because it avoids Firefox's same-origin policy (CORS) and they load fast. For best performance, make sure your server gzips all served assets.
|
20
16
|
|
21
17
|
**NOTE:** After upgrading, rename or delete your current output directory (or all generated font/css files), as Fontrobot won't be able to clean the directory using the old css template.
|
22
18
|
|
19
|
+
[Original Fontcustom documentation](http://fontcustom.github.com/fontcustom/)
|
20
|
+
|
23
21
|
Installation
|
24
22
|
------------
|
25
23
|
|
data/lib/fontrobot/generator.rb
CHANGED
@@ -120,7 +120,7 @@ module Fontrobot
|
|
120
120
|
if(inline.include?(type))
|
121
121
|
fontpath = File.expand_path(File.join(@output, File.basename(@path)+"."+type))
|
122
122
|
encoded_contents = Base64.encode64(File.read(fontpath)).gsub(/\n/, '') # encode and remove newlines, 1.8.7 compat
|
123
|
-
src = "url(data:application/
|
123
|
+
src = "url(data:application/font-#{type};charset=utf-8;base64," + encoded_contents +") format('#{longtype[type]}')"
|
124
124
|
else
|
125
125
|
src = fontface_strings[type.to_sym]
|
126
126
|
end
|
data/lib/fontrobot/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fontrobot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 21
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 7
|
10
|
+
version: 0.1.7
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Tim Barkow
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2013-
|
18
|
+
date: 2013-07-02 00:00:00 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
21
|
name: json
|