1
0
Fork 0

Provide iced constants for fonts

This commit is contained in:
Robbert van der Helm 2022-03-14 15:56:11 +01:00
parent 95827afc81
commit 93990d604b
2 changed files with 37 additions and 1 deletions

View file

@ -0,0 +1,36 @@
//! Binary assets for use with `nih_plug_iced`.
use crate::Font;
// This module provides a re-export and simple font wrapeprs aroudn the re-exported fonts.
pub use nih_plug_assets::*;
pub const NOTO_SANS_REGULAR: Font = Font::External {
name: "Noto Sans Regular",
bytes: fonts::NOTO_SANS_REGULAR,
};
pub const NOTO_SANS_REGULAR_ITALIC: Font = Font::External {
name: "Noto Sans Regular Italic",
bytes: fonts::NOTO_SANS_REGULAR_ITALIC,
};
pub const NOTO_SANS_LIGHT: Font = Font::External {
name: "Noto Sans Light",
bytes: fonts::NOTO_SANS_LIGHT,
};
pub const NOTO_SANS_LIGHT_ITALIC: Font = Font::External {
name: "Noto Sans Light Italic",
bytes: fonts::NOTO_SANS_LIGHT_ITALIC,
};
pub const NOTO_SANS_BOLD: Font = Font::External {
name: "Noto Sans Bold",
bytes: fonts::NOTO_SANS_BOLD,
};
pub const NOTO_SANS_BOLD_ITALIC: Font = Font::External {
name: "Noto Sans Bold Italic",
bytes: fonts::NOTO_SANS_BOLD_ITALIC,
};

View file

@ -14,8 +14,8 @@ use crate::widgets::ParamMessage;
/// Re-export for convenience.
pub use iced_baseview::*;
pub use nih_plug_assets as assets;
pub mod assets;
pub mod widgets;
mod wrapper;