diff --git a/Cargo.toml b/Cargo.toml index 8170c3c2..19b6d956 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "norad" -version = "0.4.0" +version = "0.5.0" authors = ["Colin Rofls ", "Nikolaus Waxweiler "] license = "MIT/Apache-2.0" edition = "2018" diff --git a/src/font.rs b/src/font.rs index 7c505169..818a1f16 100644 --- a/src/font.rs +++ b/src/font.rs @@ -42,10 +42,6 @@ pub struct Font { pub data_request: DataRequest, } -#[doc(hidden)] -#[deprecated(since = "0.4.0", note = "Renamed to Font")] -pub type Ufo = Font; - /// A version of the [UFO spec]. /// /// [UFO spec]: http://unifiedfontobject.org @@ -82,18 +78,6 @@ impl Font { Font::default() } - /// Create a new `Font` only with certain fields. - #[doc(hidden)] - #[deprecated( - since = "0.4.1", - note = "To load only specific fields, use Font::load_requested_data" - )] - pub fn with_fields(data_request: DataRequest) -> Self { - let mut ufo = Self::new(); - ufo.data_request = data_request; - ufo - } - /// Attempt to load a font object from a file. /// /// `path` must point to a directory with the structure described in @@ -201,14 +185,6 @@ impl Font { Ok(Font { layers, meta, font_info, lib, groups, kerning, features, data_request: request }) } - #[deprecated( - since = "0.4.1", - note = "To load only specific fields, use Font::load_requestd_data" - )] - pub fn load_ufo>(&self, path: P) -> Result { - Font::load_requested_data(path, self.data_request) - } - /// Attempt to save this UFO to the given path, overriding any existing contents. /// /// This may fail; instead of saving directly to the target path, it is a good @@ -308,23 +284,11 @@ impl Font { self.layers.default_layer() } - #[deprecated(since = "0.4.0", note = "use default_layer instead")] - #[doc(hidden)] - pub fn get_default_layer(&self) -> Option<&Layer> { - Some(self.default_layer()) - } - /// Returns a mutable reference to the default layer. pub fn default_layer_mut(&mut self) -> &mut Layer { self.layers.default_layer_mut() } - #[deprecated(since = "0.4.0", note = "use default_layer instead")] - #[doc(hidden)] - pub fn get_default_layer_mut(&mut self) -> Option<&mut Layer> { - Some(self.default_layer_mut()) - } - /// Returns an iterator over all layers in this font object. pub fn iter_layers(&self) -> impl Iterator { self.layers.iter() diff --git a/src/layer.rs b/src/layer.rs index 05291f75..4fbdf87e 100644 --- a/src/layer.rs +++ b/src/layer.rs @@ -447,18 +447,6 @@ impl Layer { } } - #[doc(hidden)] - #[deprecated(since = "0.4.0", note = "renamed to 'iter'")] - pub fn iter_contents(&self) -> impl Iterator> + '_ { - self.iter() - } - - #[doc(hidden)] - #[deprecated(since = "0.4.0", note = "renamed to 'iter_mut'")] - pub fn iter_contents_mut(&mut self) -> impl Iterator { - self.iter_mut() - } - /// Iterate over the glyphs in this layer. pub fn iter(&self) -> impl Iterator> + '_ { self.glyphs.values() diff --git a/src/lib.rs b/src/lib.rs index 5fdbe3e8..bb11230a 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -55,6 +55,3 @@ pub use kerning::Kerning; pub use layer::{Layer, LayerSet}; pub use shared_types::{Color, IntegerOrFloat, NonNegativeIntegerOrFloat, Plist}; pub use write::{QuoteChar, WriteOptions}; - -#[allow(deprecated)] -pub use font::Ufo;