[Docs] Document the font-files() helper function.

This commit is contained in:
Chris Eppstein 2010-05-03 21:25:43 -07:00
parent 45785b7561
commit 023d176453
3 changed files with 38 additions and 3 deletions

View File

@ -17,5 +17,6 @@ layout: core
All Helpers:
* [elements-of-type](/docs/reference/compass/helpers/display/)
* [enumerate](/docs/reference/compass/helpers/enumerate/)
* [elements-of-type()](/docs/reference/compass/helpers/display/)
* [enumerate()](/docs/reference/compass/helpers/enumerate/)
* [font-files()](/docs/reference/compass/helpers/font-files/)

View File

@ -0,0 +1,35 @@
---
title: Compass Font Files Helper
crumb: Font Files
framework: compass
meta_description: Helper function for listing fonts.
layout: core
classnames:
- reference
- core
- helpers
---
%h1 Compass Font Files Helper
#font-files.helper
%h3
%a(href="#font-files")
font-files([<span class="arg">$font</span>, <span class="arg">$format</span>]*)
.details
%p
The <code>font-files</code> function takes any even number of arguments.
For each pair of arguments, the first is the path to the font file
relative to your project's font directory and the second is the format of
that font.
%p
This helper is used with the <a href="/docs/reference/compass/css3/font_face/#mixin-font-face"><code>font-face</code> mixin</a>
and is what makes it possible to pass any number of font files.
%p
<a href="http://www.w3.org/TR/css3-fonts/#font-reference-the-src-descriptor">W3C Reference</a>
.examples
%h4 Examples
%ul
%li
%a(href="/docs/examples/compass/css3/font-face/") Font-face Example

View File

@ -7,5 +7,4 @@ module Compass::SassExtensions::Functions::FontFiles
end
Sass::Script::String.new(files.join(", "))
end
end