epaint_default_fonts/lib.rs
1//! A library containing built-in fonts for `epaint`, embedded as bytes.
2//!
3//! This is intended to be consumed through the `epaint` crate.
4
5/// A typeface designed for source code.
6///
7/// Hack is designed to be a workhorse typeface for source code. It has deep
8/// roots in the free, open source typeface community and expands upon the
9/// contributions of the [Bitstream Vera](https://www.gnome.org/fonts/) and
10/// [DejaVu](https://dejavu-fonts.github.io/) projects. The large x-height +
11/// wide aperture + low contrast design make it legible at commonly used source
12/// code text sizes with a sweet spot that runs in the 8 - 14 range.
13///
14/// See [the Hack repository](https://github.com/source-foundry/Hack) for more
15/// information.
16pub const HACK_REGULAR: &[u8] = include_bytes!("../fonts/Hack-Regular.ttf");
17
18/// A typeface containing emoji characters as designed for the Noto font family.
19///
20/// Noto is a collection of high-quality fonts with multiple weights and widths
21/// in sans, serif, mono, and other styles, in more than 1,000 languages and
22/// over 150 writing systems. Noto Emoji contains black-and-white emoji
23/// characters that match Google's emoji designs.
24///
25/// See [Google Fonts](https://fonts.google.com/noto/specimen/Noto+Emoji) for
26/// more information.
27pub const NOTO_EMOJI_REGULAR: &[u8] = include_bytes!("../fonts/NotoEmoji-Regular.ttf");
28
29/// A typeface designed for use by Ubuntu.
30///
31/// The Ubuntu typeface has been specially created to complement the Ubuntu tone
32/// of voice. It has a contemporary style and contains characteristics unique to
33/// the Ubuntu brand that convey a precise, reliable and free attitude.
34///
35/// See [Ubuntu design](https://design.ubuntu.com/font) for more information.
36pub const UBUNTU_LIGHT: &[u8] = include_bytes!("../fonts/Ubuntu-Light.ttf");
37
38/// An experimental typeface that uses standardized
39/// [UNICODE planes](http://en.wikipedia.org/wiki/Plane_(Unicode))
40/// for icon fonts.
41///
42/// The icons in this font are designed to be styled with minimal effort. Each
43/// icon is solid, which is useful for changing icon colors.
44///
45/// See [the `emoji-icon-font` repository](https://github.com/jslegers/emoji-icon-font)
46/// for more information.
47pub const EMOJI_ICON: &[u8] = include_bytes!("../fonts/emoji-icon-font.ttf");