1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
//! SMuFL font and resource files for the [Verovio](https://www.verovio.org/)
//! music notation engraver.
//!
//! Verovio refuses to parse any input until `Resources::Ok()` returns true,
//! which requires the font data on disk at the path passed to
//! `Toolkit::SetResourcePath`. This crate bundles the resource tree at compile
//! time and offers [`extract`] to stage it onto a real filesystem so Verovio
//! can read it.
//!
//! The bundled contents are an exact mirror of the `data/` directory in the
//! Verovio source tree pinned by the `verovio-sys` crate. Both Bravura
//! (mandatory) and Leipzig (eager-loaded) are included, plus the optional
//! Gootville, Leland, Petaluma, and Liberation fonts.
use ;
use io;
use Path;
/// Bundled resource directory — a compile-time snapshot of Verovio's
/// `data/`.
pub const DATA: =
include_dir!;
/// Extract all bundled resource files into `dest`. The destination is
/// expected to already exist (e.g. a freshly-created tempdir). Any files
/// already present at the same paths are overwritten.
/// SMuFL font families bundled in this crate, as Verovio's `font`
/// option understands them. Useful for populating a font picker in a UI
/// without hard-coding the list at the call site.
///
/// The first entry (Bravura) is Verovio's default and the SMuFL
/// reference font.
pub const AVAILABLE_FONTS: & = &;