motion-fontawesome 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/fontawesome/credit.txt +2 -0
- data/lib/fontawesome/font_awesome.rb +233 -0
- data/lib/fontawesome/fontawesome-webfont.ttf +0 -0
- data/lib/fontawesome/version.rb +3 -0
- data/lib/motion-fontawesome.rb +14 -0
- metadata +82 -0
@@ -0,0 +1,2 @@
|
|
1
|
+
# Font Awesome
|
2
|
+
The Font Awesome webfont, CSS, and LESS files are licensed under CC BY 3.0. A mention of Font Awesome - http://fortawesome.github.com/Font-Awesome in human-readable source code is considered acceptable attribution (most common on the web). If human readable source code is not available to the end user, a mention in an 'About' or 'Credits' screen is considered
|
@@ -0,0 +1,233 @@
|
|
1
|
+
class FontAwesome
|
2
|
+
# .icon-(.*):before.*\{ content: "\\(.*)"; \}
|
3
|
+
# "$1" => 0x$2,
|
4
|
+
|
5
|
+
def FontAwesome.iconDef
|
6
|
+
@iconDef ||= begin
|
7
|
+
{
|
8
|
+
"glass" => 0xf000,
|
9
|
+
"music" => 0xf001,
|
10
|
+
"search" => 0xf002,
|
11
|
+
"envelope" => 0xf003,
|
12
|
+
"heart" => 0xf004,
|
13
|
+
"star" => 0xf005,
|
14
|
+
"star-empty" => 0xf006,
|
15
|
+
"user" => 0xf007,
|
16
|
+
"film" => 0xf008,
|
17
|
+
"th-large" => 0xf009,
|
18
|
+
"th" => 0xf00a,
|
19
|
+
"th-list" => 0xf00b,
|
20
|
+
"ok" => 0xf00c,
|
21
|
+
"remove" => 0xf00d,
|
22
|
+
"zoom-in" => 0xf00e,
|
23
|
+
"zoom-out" => 0xf010,
|
24
|
+
"off" => 0xf011,
|
25
|
+
"signal" => 0xf012,
|
26
|
+
"cog" => 0xf013,
|
27
|
+
"trash" => 0xf014,
|
28
|
+
"home" => 0xf015,
|
29
|
+
"file" => 0xf016,
|
30
|
+
"time" => 0xf017,
|
31
|
+
"road" => 0xf018,
|
32
|
+
"download-alt" => 0xf019,
|
33
|
+
"download" => 0xf01a,
|
34
|
+
"upload" => 0xf01b,
|
35
|
+
"inbox" => 0xf01c,
|
36
|
+
"play-circle" => 0xf01d,
|
37
|
+
"repeat" => 0xf01e,
|
38
|
+
"refresh" => 0xf021,
|
39
|
+
"list-alt" => 0xf022,
|
40
|
+
"lock" => 0xf023,
|
41
|
+
"flag" => 0xf024,
|
42
|
+
"headphones" => 0xf025,
|
43
|
+
"volume-off" => 0xf026,
|
44
|
+
"volume-down" => 0xf027,
|
45
|
+
"volume-up" => 0xf028,
|
46
|
+
"qrcode" => 0xf029,
|
47
|
+
"barcode" => 0xf02a,
|
48
|
+
"tag" => 0xf02b,
|
49
|
+
"tags" => 0xf02c,
|
50
|
+
"book" => 0xf02d,
|
51
|
+
"bookmark" => 0xf02e,
|
52
|
+
"print" => 0xf02f,
|
53
|
+
"camera" => 0xf030,
|
54
|
+
"font" => 0xf031,
|
55
|
+
"bold" => 0xf032,
|
56
|
+
"italic" => 0xf033,
|
57
|
+
"text-height" => 0xf034,
|
58
|
+
"text-width" => 0xf035,
|
59
|
+
"align-left" => 0xf036,
|
60
|
+
"align-center" => 0xf037,
|
61
|
+
"align-right" => 0xf038,
|
62
|
+
"align-justify" => 0xf039,
|
63
|
+
"list" => 0xf03a,
|
64
|
+
"indent-left" => 0xf03b,
|
65
|
+
"indent-right" => 0xf03c,
|
66
|
+
"facetime-video" => 0xf03d,
|
67
|
+
"picture" => 0xf03e,
|
68
|
+
"pencil" => 0xf040,
|
69
|
+
"map-marker" => 0xf041,
|
70
|
+
"adjust" => 0xf042,
|
71
|
+
"tint" => 0xf043,
|
72
|
+
"edit" => 0xf044,
|
73
|
+
"share" => 0xf045,
|
74
|
+
"check" => 0xf046,
|
75
|
+
"move" => 0xf047,
|
76
|
+
"step-backward" => 0xf048,
|
77
|
+
"fast-backward" => 0xf049,
|
78
|
+
"backward" => 0xf04a,
|
79
|
+
"play" => 0xf04b,
|
80
|
+
"pause" => 0xf04c,
|
81
|
+
"stop" => 0xf04d,
|
82
|
+
"forward" => 0xf04e,
|
83
|
+
"fast-forward" => 0xf050,
|
84
|
+
"step-forward" => 0xf051,
|
85
|
+
"eject" => 0xf052,
|
86
|
+
"chevron-left" => 0xf053,
|
87
|
+
"chevron-right" => 0xf054,
|
88
|
+
"plus-sign" => 0xf055,
|
89
|
+
"minus-sign" => 0xf056,
|
90
|
+
"remove-sign" => 0xf057,
|
91
|
+
"ok-sign" => 0xf058,
|
92
|
+
"question-sign" => 0xf059,
|
93
|
+
"info-sign" => 0xf05a,
|
94
|
+
"screenshot" => 0xf05b,
|
95
|
+
"remove-circle" => 0xf05c,
|
96
|
+
"ok-circle" => 0xf05d,
|
97
|
+
"ban-circle" => 0xf05e,
|
98
|
+
"arrow-left" => 0xf060,
|
99
|
+
"arrow-right" => 0xf061,
|
100
|
+
"arrow-up" => 0xf062,
|
101
|
+
"arrow-down" => 0xf063,
|
102
|
+
"share-alt" => 0xf064,
|
103
|
+
"resize-full" => 0xf065,
|
104
|
+
"resize-small" => 0xf066,
|
105
|
+
"plus" => 0xf067,
|
106
|
+
"minus" => 0xf068,
|
107
|
+
"asterisk" => 0xf069,
|
108
|
+
"exclamation-sign" => 0xf06a,
|
109
|
+
"gift" => 0xf06b,
|
110
|
+
"leaf" => 0xf06c,
|
111
|
+
"fire" => 0xf06d,
|
112
|
+
"eye-open" => 0xf06e,
|
113
|
+
"eye-close" => 0xf070,
|
114
|
+
"warning-sign" => 0xf071,
|
115
|
+
"plane" => 0xf072,
|
116
|
+
"calendar" => 0xf073,
|
117
|
+
"random" => 0xf074,
|
118
|
+
"comment" => 0xf075,
|
119
|
+
"magnet" => 0xf076,
|
120
|
+
"chevron-up" => 0xf077,
|
121
|
+
"chevron-down" => 0xf078,
|
122
|
+
"retweet" => 0xf079,
|
123
|
+
"shopping-cart" => 0xf07a,
|
124
|
+
"folder-close" => 0xf07b,
|
125
|
+
"folder-open" => 0xf07c,
|
126
|
+
"resize-vertical" => 0xf07d,
|
127
|
+
"resize-horizontal" => 0xf07e,
|
128
|
+
"bar-chart" => 0xf080,
|
129
|
+
"twitter-sign" => 0xf081,
|
130
|
+
"facebook-sign" => 0xf082,
|
131
|
+
"camera-retro" => 0xf083,
|
132
|
+
"key" => 0xf084,
|
133
|
+
"cogs" => 0xf085,
|
134
|
+
"comments" => 0xf086,
|
135
|
+
"thumbs-up" => 0xf087,
|
136
|
+
"thumbs-down" => 0xf088,
|
137
|
+
"star-half" => 0xf089,
|
138
|
+
"heart-empty" => 0xf08a,
|
139
|
+
"signout" => 0xf08b,
|
140
|
+
"linkedin-sign" => 0xf08c,
|
141
|
+
"pushpin" => 0xf08d,
|
142
|
+
"external-link" => 0xf08e,
|
143
|
+
"signin" => 0xf090,
|
144
|
+
"trophy" => 0xf091,
|
145
|
+
"github-sign" => 0xf092,
|
146
|
+
"upload-alt" => 0xf093,
|
147
|
+
"lemon" => 0xf094,
|
148
|
+
"phone" => 0xf095,
|
149
|
+
"check-empty" => 0xf096,
|
150
|
+
"bookmark-empty" => 0xf097,
|
151
|
+
"phone-sign" => 0xf098,
|
152
|
+
"twitter" => 0xf099,
|
153
|
+
"facebook" => 0xf09a,
|
154
|
+
"github" => 0xf09b,
|
155
|
+
"unlock" => 0xf09c,
|
156
|
+
"credit-card" => 0xf09d,
|
157
|
+
"rss" => 0xf09e,
|
158
|
+
"hdd" => 0xf0a0,
|
159
|
+
"bullhorn" => 0xf0a1,
|
160
|
+
"bell" => 0xf0a2,
|
161
|
+
"certificate" => 0xf0a3,
|
162
|
+
"hand-right" => 0xf0a4,
|
163
|
+
"hand-left" => 0xf0a5,
|
164
|
+
"hand-up" => 0xf0a6,
|
165
|
+
"hand-down" => 0xf0a7,
|
166
|
+
"circle-arrow-left" => 0xf0a8,
|
167
|
+
"circle-arrow-right" => 0xf0a9,
|
168
|
+
"circle-arrow-up" => 0xf0aa,
|
169
|
+
"circle-arrow-down" => 0xf0ab,
|
170
|
+
"globe" => 0xf0ac,
|
171
|
+
"wrench" => 0xf0ad,
|
172
|
+
"tasks" => 0xf0ae,
|
173
|
+
"filter" => 0xf0b0,
|
174
|
+
"briefcase" => 0xf0b1,
|
175
|
+
"fullscreen" => 0xf0b2,
|
176
|
+
"group" => 0xf0c0,
|
177
|
+
"link" => 0xf0c1,
|
178
|
+
"cloud" => 0xf0c2,
|
179
|
+
"beaker" => 0xf0c3,
|
180
|
+
"cut" => 0xf0c4,
|
181
|
+
"copy" => 0xf0c5,
|
182
|
+
"paper-clip" => 0xf0c6,
|
183
|
+
"save" => 0xf0c7,
|
184
|
+
"sign-blank" => 0xf0c8,
|
185
|
+
"reorder" => 0xf0c9,
|
186
|
+
"list-ul" => 0xf0ca,
|
187
|
+
"list-ol" => 0xf0cb,
|
188
|
+
"strikethrough" => 0xf0cc,
|
189
|
+
"underline" => 0xf0cd,
|
190
|
+
"table" => 0xf0ce,
|
191
|
+
"magic" => 0xf0d0,
|
192
|
+
"truck" => 0xf0d1,
|
193
|
+
"pinterest" => 0xf0d2,
|
194
|
+
"pinterest-sign" => 0xf0d3,
|
195
|
+
"google-plus-sign" => 0xf0d4,
|
196
|
+
"google-plus" => 0xf0d5,
|
197
|
+
"money" => 0xf0d6,
|
198
|
+
"caret-down" => 0xf0d7,
|
199
|
+
"caret-up" => 0xf0d8,
|
200
|
+
"caret-left" => 0xf0d9,
|
201
|
+
"caret-right" => 0xf0da,
|
202
|
+
"columns" => 0xf0db,
|
203
|
+
"sort" => 0xf0dc,
|
204
|
+
"sort-down" => 0xf0dd,
|
205
|
+
"sort-up" => 0xf0de,
|
206
|
+
"envelope-alt" => 0xf0e0,
|
207
|
+
"linkedin" => 0xf0e1,
|
208
|
+
"undo" => 0xf0e2,
|
209
|
+
"legal" => 0xf0e3,
|
210
|
+
"dashboard" => 0xf0e4,
|
211
|
+
"comment-alt" => 0xf0e5,
|
212
|
+
"comments-alt" => 0xf0e6,
|
213
|
+
"bolt" => 0xf0e7,
|
214
|
+
"sitemap" => 0xf0e8,
|
215
|
+
"umbrella" => 0xf0e9,
|
216
|
+
"paste" => 0xf0ea,
|
217
|
+
"user-md" => 0xf200,
|
218
|
+
};
|
219
|
+
end
|
220
|
+
end
|
221
|
+
|
222
|
+
def FontAwesome.icon(type)
|
223
|
+
if iconDef.key?(type)
|
224
|
+
return iconDef[type].chr(Encoding::UTF_8)
|
225
|
+
else
|
226
|
+
return ''
|
227
|
+
end
|
228
|
+
end
|
229
|
+
|
230
|
+
def FontAwesome.fontWithSize(size)
|
231
|
+
return UIFont.fontWithName("FontAwesome", size:size)
|
232
|
+
end
|
233
|
+
end
|
Binary file
|
@@ -0,0 +1,14 @@
|
|
1
|
+
unless defined?(Motion::Project::Config)
|
2
|
+
raise "This file must be required within a RubyMotion project Rakefile."
|
3
|
+
end
|
4
|
+
|
5
|
+
Motion::Project::App.setup do |app|
|
6
|
+
Dir.glob(File.join(File.dirname(__FILE__), 'fontawesome/*.rb')).each do |file|
|
7
|
+
app.files.unshift(file)
|
8
|
+
end
|
9
|
+
|
10
|
+
font_file = File.join(File.dirname(__FILE__), 'fontawesome/fontawesome-webfont.ttf')
|
11
|
+
FileUtils.cp(font_file, './resources/')
|
12
|
+
|
13
|
+
app.fonts << "fontawesome-webfont.ttf"
|
14
|
+
end
|
metadata
ADDED
@@ -0,0 +1,82 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: motion-fontawesome
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
prerelease:
|
6
|
+
platform: ruby
|
7
|
+
authors:
|
8
|
+
- Hiroshi HORIKI(@pchw)
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2012-08-05 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: rake
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '0'
|
22
|
+
type: :runtime
|
23
|
+
prerelease: false
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ! '>='
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '0'
|
30
|
+
- !ruby/object:Gem::Dependency
|
31
|
+
name: rspec
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
33
|
+
none: false
|
34
|
+
requirements:
|
35
|
+
- - ! '>='
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: '0'
|
38
|
+
type: :development
|
39
|
+
prerelease: false
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ! '>='
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: '0'
|
46
|
+
description: ease to use Font Awesome via RubyMotion
|
47
|
+
email:
|
48
|
+
- bump.luv@gmail.com
|
49
|
+
executables: []
|
50
|
+
extensions: []
|
51
|
+
extra_rdoc_files: []
|
52
|
+
files:
|
53
|
+
- lib/motion-fontawesome.rb
|
54
|
+
- lib/fontawesome/credit.txt
|
55
|
+
- lib/fontawesome/font_awesome.rb
|
56
|
+
- lib/fontawesome/version.rb
|
57
|
+
- lib/fontawesome/fontawesome-webfont.ttf
|
58
|
+
homepage: https://github.com/pchw/fontawesome
|
59
|
+
licenses: []
|
60
|
+
post_install_message:
|
61
|
+
rdoc_options: []
|
62
|
+
require_paths:
|
63
|
+
- lib
|
64
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
65
|
+
none: false
|
66
|
+
requirements:
|
67
|
+
- - ! '>='
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: '0'
|
70
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
71
|
+
none: false
|
72
|
+
requirements:
|
73
|
+
- - ! '>='
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
requirements: []
|
77
|
+
rubyforge_project:
|
78
|
+
rubygems_version: 1.8.24
|
79
|
+
signing_key:
|
80
|
+
specification_version: 3
|
81
|
+
summary: ease to use Font Awesome via RubyMotion
|
82
|
+
test_files: []
|