diff options
author | Christian Duerr <contact@christianduerr.com> | 2020-07-19 20:35:15 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-19 20:35:15 +0000 |
commit | 714bbb769ec1ff4a32e594aa6d67d13b98814caa (patch) | |
tree | 453e5dc8b23b209f8bbac5a288d0b8584aaa8ffc /font/src/ft/fc/config.rs | |
parent | fa79758f5645bff66f8d12797832fa2b57157975 (diff) | |
download | alacritty-714bbb769ec1ff4a32e594aa6d67d13b98814caa.tar.gz alacritty-714bbb769ec1ff4a32e594aa6d67d13b98814caa.zip |
Bump version to 0.5.0-rc2v0.5.0-rc2
Diffstat (limited to 'font/src/ft/fc/config.rs')
-rw-r--r-- | font/src/ft/fc/config.rs | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/font/src/ft/fc/config.rs b/font/src/ft/fc/config.rs deleted file mode 100644 index ac87a284..00000000 --- a/font/src/ft/fc/config.rs +++ /dev/null @@ -1,29 +0,0 @@ -use foreign_types::{foreign_type, ForeignTypeRef}; - -use super::ffi::{FcConfig, FcConfigDestroy, FcConfigGetCurrent, FcConfigGetFonts}; -use super::{FontSetRef, SetName}; - -foreign_type! { - pub unsafe type Config { - type CType = FcConfig; - fn drop = FcConfigDestroy; - } -} - -impl Config { - /// Get the current configuration. - pub fn get_current() -> &'static ConfigRef { - unsafe { ConfigRef::from_ptr(FcConfigGetCurrent()) } - } -} - -impl ConfigRef { - /// Returns one of the two sets of fonts from the configuration as - /// specified by `set`. - pub fn get_fonts(&self, set: SetName) -> &FontSetRef { - unsafe { - let ptr = FcConfigGetFonts(self.as_ptr(), set as u32); - FontSetRef::from_ptr(ptr) - } - } -} |