webfontspecimen 0.3.0 → 0.4

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.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 212684468cc88a57c2de72c7dd4adf4bf69810f7
4
+ data.tar.gz: ddaaca3018127e48f0b62db74607de858ed7b72c
5
+ SHA512:
6
+ metadata.gz: 30fe5096768310820c1db7b3f79221f492427f1f66b2a5aa2e22c8b6099846abba7b60f5cccbc790d5a8e5597b2019c69bb23affaa9ae8e9913eb3fa90872d1c
7
+ data.tar.gz: 19c8186c42a5948fe482bf99e1526aacfcf65b50b8806c517fbe8f2cc79be184f8a9d3c91db5acb9420c46fac06fda1d54ac8520f16f93acb658a995b31f25de
@@ -1,11 +1,13 @@
1
1
  /* Fonts ----------------------------------------------- */
2
2
  $font-type: serif !default;
3
- $font-face: Georgia !default;
4
- $font-stack: $font-face, $font-type !default;
3
+ $font-name: Georgia !default;
4
+ $pretty-font-name: $font-name !default;
5
+ $font-stack: $font-name, $font-type !default;
6
+ $font-style: normal !default;
5
7
 
6
8
  @mixin font-stack {
7
9
  font-family: $font-stack;
8
- font-style: normal;
10
+ font-style: $font-style;
9
11
  }
10
12
 
11
13
  body {
@@ -121,7 +123,7 @@ a:active {
121
123
  -----------------------------------------*/
122
124
  .bodysize {
123
125
  overflow: hidden;
124
- background: #fff image-url("grid.gif") -5px 9px repeat;
126
+ background: #fff inline-image("grid.gif") -5px 9px repeat;
125
127
  }
126
128
  .bodysize table {
127
129
  width: 100%;
@@ -176,7 +178,7 @@ a:active {
176
178
  -----------------------------------------*/
177
179
  .grayscale {
178
180
  clear: both;
179
- background: #fff image-url("black.gif") top right repeat-y;
181
+ background: #fff inline-image("black.gif") top right repeat-y;
180
182
  }
181
183
  .grayscale p span {
182
184
  display: block;
@@ -233,4 +235,25 @@ a:active {
233
235
  }
234
236
  p.upp {
235
237
  text-align: left;
236
- }
238
+ }
239
+
240
+ // Add Font Name to page using CSS Pseudo Classes rather than replacing {FONT NAME}. Hide {FONT NAME} on H1 and Table Head (note: you can't target <title> with pseudo classes).
241
+
242
+ h1 {
243
+ span {
244
+ display: none;
245
+ }
246
+ &:before {
247
+ content: $pretty-font-name;
248
+ }
249
+ }
250
+ table {
251
+ th:first-child {
252
+ span {
253
+ display: none;
254
+ }
255
+ &:before {
256
+ content: $pretty-font-name;
257
+ }
258
+ }
259
+ }
@@ -0,0 +1 @@
1
+ Add your fonts to this folder.
@@ -0,0 +1,62 @@
1
+ /* Welcome to WebFontSpecimen
2
+ * Based on Nice Web Type's tool by the same name
3
+ * http://webfontspecimen.com/ */
4
+
5
+ // Imports -----------------------------------*/
6
+ @import "compass/css3/font-face";
7
+
8
+
9
+ //
10
+ // Web Font Specimen Usage:
11
+ // ========================
12
+ //
13
+ // 1. Add your typeface(s) to your specified "fonts" folder.
14
+ // - This is already specified as "fonts_dir" in your "config.rb" file.
15
+ // - Or link to fonts from google, typekit, or other services
16
+ //
17
+ // 2. For multiple specimens
18
+ // - Duplicate `_type_specimen_1.scss`
19
+ // - add @import "_type_specimen_NEW_NUMBER.scss;" to specimen.scss
20
+ //
21
+ // 3. Add your font name and file path to "$font-name" and "$font-file-name" to "_type_specimen_1.scss"
22
+ // - Optional: add your `$pretty-font-name` (displays on the `specimen.html` page)
23
+ //
24
+ // 4. Make adjustments to "specimen.html"
25
+ // - For multiple specimens duplicate and rename for each font being sure to change the stylesheet link as needed.
26
+ //
27
+ // 5. Enjoy!
28
+ //
29
+
30
+
31
+ // Font Type ---------------------------------*/
32
+ $font-type: serif;
33
+
34
+ /* Standard ----------------------------------*/
35
+ // Font Name i.e. "DroidSerifRegular"
36
+ $font-name: "YourFontsCSSName";
37
+ // File path minus extension i.e "DroidSerif/DroidSerif-Regular-webfont"
38
+ $font-file-name: "type_file";
39
+ $font-weight: normal !default;
40
+ $font-style: normal !default;
41
+
42
+ // Pretty Font name for displaying on the specimen.html page i.e. "Droid Serif Regular"
43
+ // If it's left commented out it will default to $font-name
44
+ // $pretty-font-name: "Your Font's Name";
45
+
46
+ @include font-face(
47
+ $font-name,
48
+ font-files(
49
+ "#{$font-file-name}.woff", woff,
50
+ "#{$font-file-name}.ttf", truetype,
51
+ "#{$font-file-name}.svg##{$font-name}", svg
52
+ ),
53
+ "#{$font-file-name}.eot",
54
+ $font-weight,
55
+ $font-style
56
+ );
57
+
58
+ $font-stack: $font-name, $font-type;
59
+
60
+ // Import WebFontSpecimen -------------------------------------------*/
61
+ // Leave this below your font settings
62
+ @import "webfontspecimen";
@@ -0,0 +1,27 @@
1
+ require 'webfontspecimen'
2
+ # Require any additional compass plugins here.
3
+
4
+
5
+ # Set this to the root of your project when deployed:
6
+ http_path = "/"
7
+ css_dir = "css"
8
+ sass_dir = "sass"
9
+ images_dir = "images"
10
+ javascripts_dir = "javascripts"
11
+ fonts_dir = "fonts"
12
+
13
+ # You can select your preferred output style here (can be overridden via the command line):
14
+ # output_style = :expanded or :nested or :compact or :compressed
15
+
16
+ # To enable relative paths to assets via compass helper functions. Uncomment:
17
+ relative_assets = true
18
+
19
+ # To disable debugging comments that display the original location of your selectors. Uncomment:
20
+ # line_comments = false
21
+
22
+
23
+ # If you prefer the indented syntax, you might want to regenerate this
24
+ # project again passing --syntax sass, or you can uncomment this:
25
+ # preferred_syntax = :sass
26
+ # and then run:
27
+ # sass-convert -R --from scss --to sass sass scss && rm -rf sass && mv scss sass
@@ -1,7 +1,23 @@
1
- stylesheet '_specimen.scss', :media => "screen, projection"
2
- image 'black.gif'
3
- image 'grid.gif'
4
- html 'specimen.html'
1
+ # use a Custom config.rb to add the css and fonts folders
2
+ no_configuration_file!
3
+ skip_compilation!
4
+
5
+ file 'config.rb', :like => :file, :to => "config.rb"
6
+
7
+ # Stylesheets Import
8
+ file 'specimen.scss', :like => :stylesheet, :media => 'screen, projection', :to => 'specimen.scss'
9
+ file '_type_specimen_1.scss', :like => :stylesheet, :media => 'screen, projection', :to => '_type_specimen_1.scss'
10
+
11
+ # Image Import
12
+ file 'black.gif', :like => :image, :to => 'black.gif'
13
+ file 'grid.gif', :like => :image, :to => 'grid.gif'
14
+
15
+ # HTML Import
16
+ file 'specimen.html', :like => :html, :to => 'specimen.html'
17
+
18
+ # Font Import
19
+ # Note: Using :font puts the files in stylesheets/fonts despite setting fonts_dir in config.rb. Adding README.mkdn to create fonts folder (won't be created otherwise)
20
+ file "README.mkdn", :like => :file, :to => "fonts/README.mkdn"
5
21
 
6
22
  description "A Compass port of Nice Web Type's Web Font Specimen tool - http://webfontspecimen.com/"
7
23
 
@@ -12,5 +28,5 @@ or duplicate for multiple specimens.
12
28
 
13
29
  welcome_message %Q{
14
30
  Please refer to the README or 'specimen.html' files for instructions.
15
- }
16
-
31
+ To get started 'cd' into your project and run 'compass compile'.
32
+ }
@@ -7,22 +7,20 @@
7
7
 
8
8
  Using Web Font Specimen =======================================================
9
9
 
10
-
11
10
  1. Add your typeface(s) to your specified "fonts" folder.
12
- - This is specified as "fonts_dir" in your "config.rb" file.
13
- - Or link to fonts from google, typkit, or other services
11
+ - This is already specified as "fonts_dir" in your "config.rb" file.
12
+ - Or link to fonts from google, typekit, or other services
14
13
 
15
- 2. Rename the "_specimen" sass file:
16
- - For single specimens simply remove the "_" prefix
17
- - For multiple specimens duplicate and rename for each font
14
+ 2. For multiple specimens
15
+ - Duplicate `_type_specimen_1.scss`
16
+ - add @import "_type_specimen_NEW_NUMBER.scss;" to specimen.scss
18
17
 
19
- 3. Include your font in the provided specimen.scss "font-face" mixin
18
+ 3. Add your font name and file path to "$font-name" and "$font-file-name" to "_type_specimen_1.scss"
19
+ - Optional: add your `$pretty-font-name` (displays on the `specimen.html` page)
20
+
21
+ 4. Make adjustments to "specimen.html"
22
+ - For multiple specimens duplicate and rename for each font being sure to change the stylesheet link as needed.
20
23
 
21
- 4. Make adjustments to this file
22
- - For multiple specimens duplicate and rename for each font
23
- being sure to change the stylesheet link as needed.
24
- - Search for and replace "{FONT NAME}" with your font name
25
-
26
24
  5. Enjoy!
27
25
 
28
26
  ==============================================================================
@@ -35,7 +33,7 @@
35
33
  <!-- Always force latest IE rendering engine (even in intranet) & Chrome Frame -->
36
34
  <!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=edge;chrome=1"><![endif]-->
37
35
 
38
- <title>{FONT NAME} - Web Font Specimen</title>
36
+ <title>Web Font Specimen</title>
39
37
  <link rel="stylesheet" href="css/specimen.css" type="text/css" media="screen" charset="utf-8">
40
38
 
41
39
  </head>
@@ -47,7 +45,7 @@
47
45
 
48
46
  <!-- NAME OF TYPEFACE -->
49
47
  <div class="grid_16">
50
- <h1>{FONT NAME}</h1>
48
+ <h1><span>{FONT NAME}</span></h1>
51
49
  </div>
52
50
 
53
51
 
@@ -83,7 +81,7 @@
83
81
  <div class="bodysize">
84
82
  <table>
85
83
  <tr>
86
- <th>{FONT NAME}</th>
84
+ <th><span>{FONT NAME}</span></th>
87
85
  <th>Arial <a href="http://www.codestyle.org/servlets/FontStack?stack=Arial,Helvetica&generic=sans-serif">stack</a></th>
88
86
  <th>Times <a href="http://www.codestyle.org/servlets/FontStack?stack=Times+New+Roman,Times&generic=serif">stack</a></th>
89
87
  <th>Georgia <a href="http://www.codestyle.org/servlets/FontStack?stack=Georgia,New+Century+Schoolbook,Nimbus+Roman+No9+L&generic=serif">stack</a></th>
@@ -0,0 +1 @@
1
+ @import "_type_specimen_1.scss";
metadata CHANGED
@@ -1,21 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: webfontspecimen
3
3
  version: !ruby/object:Gem::Version
4
- prerelease: false
5
- segments:
6
- - 0
7
- - 3
8
- - 0
9
- version: 0.3.0
4
+ version: "0.4"
10
5
  platform: ruby
11
6
  authors:
12
7
  - Eric Meyer
8
+ - Mark Reilly
13
9
  autorequire:
14
10
  bindir: bin
15
11
  cert_chain: []
16
12
 
17
- date: 2010-08-15 00:00:00 -06:00
18
- default_executable:
13
+ date: 2013-11-07 00:00:00 Z
19
14
  dependencies:
20
15
  - !ruby/object:Gem::Dependency
21
16
  name: compass
@@ -24,15 +19,13 @@ dependencies:
24
19
  requirements:
25
20
  - - ">="
26
21
  - !ruby/object:Gem::Version
27
- segments:
28
- - 0
29
- - 10
30
- - 0
31
22
  version: 0.10.0
32
23
  type: :runtime
33
24
  version_requirements: *id001
34
- description: A Compass port of Nice Web Type's Web Font Specimen tool
35
- email: eric@oddbird.net
25
+ description: A Compass port of Nice Web Type's (Tim Brown) Web Font Specimen tool http://webfontspecimen.com/
26
+ email:
27
+ - eric@oddbird.net
28
+ - mark@alienresident.net
36
29
  executables: []
37
30
 
38
31
  extensions: []
@@ -45,14 +38,18 @@ files:
45
38
  - stylesheets/_webfontspecimen.scss
46
39
  - stylesheets/wfs/_960.scss
47
40
  - stylesheets/wfs/_base.scss
48
- - templates/project/_specimen.scss
41
+ - templates/project/_type_specimen_1.scss
49
42
  - templates/project/black.gif
43
+ - templates/project/config.rb
50
44
  - templates/project/grid.gif
51
45
  - templates/project/manifest.rb
46
+ - templates/project/README.mkdn
52
47
  - templates/project/specimen.html
53
- has_rdoc: true
48
+ - templates/project/specimen.scss
54
49
  homepage: http://www.oddbird.net/
55
- licenses: []
50
+ licenses:
51
+ - CC BY 3.0
52
+ metadata: {}
56
53
 
57
54
  post_install_message:
58
55
  rdoc_options: []
@@ -61,24 +58,19 @@ require_paths:
61
58
  - lib
62
59
  required_ruby_version: !ruby/object:Gem::Requirement
63
60
  requirements:
64
- - - ">="
61
+ - &id002
62
+ - ">="
65
63
  - !ruby/object:Gem::Version
66
- segments:
67
- - 0
68
64
  version: "0"
69
65
  required_rubygems_version: !ruby/object:Gem::Requirement
70
66
  requirements:
71
- - - ">="
72
- - !ruby/object:Gem::Version
73
- segments:
74
- - 0
75
- version: "0"
67
+ - *id002
76
68
  requirements: []
77
69
 
78
70
  rubyforge_project:
79
- rubygems_version: 1.3.6
71
+ rubygems_version: 2.1.8
80
72
  signing_key:
81
- specification_version: 3
73
+ specification_version: 4
82
74
  summary: A Compass port of Nice Web Type's Web Font Specimen tool
83
75
  test_files: []
84
76
 
@@ -1,51 +0,0 @@
1
- /* Welcome to WebFontSpecimen
2
- * Based on Nice Web Type's tool by the same name
3
- * http://webfontspecimen.com/ */
4
-
5
- // Imports -----------------------------------*/
6
- @import "compass/css3/font-face";
7
-
8
-
9
- //
10
- // Web Font Specimen Usage:
11
- // ========================
12
- //
13
- // 1. Add your typeface(s) to your specified "fonts" folder.
14
- // - This is specified as "fonts_dir" in your "config.rb" file.
15
- // - Or link to fonts from google, typkit, or other services
16
- //
17
- // 2. Rename this file:
18
- // - For single specimens simply remove the "_" prefix
19
- // - For multiple specimens duplicate and rename for each font
20
- //
21
- // 3. Include your font below
22
- //
23
- // 4. Make adjustments to "specimen.html"
24
- // - For multiple specimens duplicate and rename for each font
25
- // being sure to change the stylesheet link as needed.
26
- // - Search for and replace "{FONT NAME}" with your font name
27
- //
28
- // 5. Enjoy!
29
- //
30
-
31
-
32
- // Font Type ---------------------------------*/
33
- $font-type: serif;
34
-
35
- /* Standard ----------------------------------*/
36
- $font-face: "Name Your Font";
37
- @include font-face(
38
- $font-face,
39
- font-files(
40
- "type_file.woff", woff,
41
- "type_file.ttf", truetype,
42
- "type_file.svg#Type-Name", svg
43
- ),
44
- "type_file.eot"
45
- );
46
-
47
- $font-stack: $font-face, $font-type;
48
-
49
- // Import WebFontSpecimen -------------------------------------------*/
50
- // Leave this below your font settings
51
- @import "webfontspecimen";