Resources

[Raku CSS Project] / [CSS-Font-Resources] / CSS::Font :: Resources

class CSS::Font::Resources

Lightweight CSS Font Resource Manager

Description

This is lightweight font resource manager, driven by CSS @font-face font descriptors.

Methods

method match

method match(
    @font-face = Code.new
) returns Mu

Return only matching font-descriptors

These are matched and ordered by preference, using the W3C Font Matching Algorithm.

multi method sources

multi method sources(
    Bool :$fallback = Bool::True,
    |c
) returns Mu

Return sources for matching fonts

These matches are ordered by user preference. The fonts themselves can be fetched using the .IO or .Str or Blob methods on the first matching font.

CSS::Font::Resources v0.0.9

CSS Font Resource selection and loading

Authors

  • David Warring

License

Artistic-2.0

Dependencies

CSS::Properties:ver<0.7.5+>Temp::PathLWP::SimpleURI:ver<0.3.3+>

Test Dependencies

Provides

  • CSS::Font::Resources
  • CSS::Font::Resources::Source
  • CSS::Font::Resources::Source::Local
  • CSS::Font::Resources::Source::Url
  • CSS::URI

The Camelia image is copyright 2009 by Larry Wall. "Raku" is trademark of the Yet Another Society. All rights reserved.