diff --git a/src/progress.rs b/src/progress.rs index 2f296cd..84ef52d 100644 --- a/src/progress.rs +++ b/src/progress.rs @@ -14,6 +14,7 @@ use std::{ /// /// To create a new `progress::Bar` with a max size tuned to your terminal (or `Width+20`, if it cannot be detected), and of the default size, `Bar` implements the `Default` trait: /// ```rust +/// # use termprogress::prelude::*; /// let mut bar = Bar::default(); //Creates a bar of width 50 by default. /// ``` /// @@ -96,7 +97,9 @@ impl Bar progress: 0.0, buffer: String::with_capacity(width), title: String::with_capacity(max_width - width), + #[cfg(feature="size")] fit_to_term: false, + /*output_to: io::stdout(),*/ }; this.update(); this diff --git a/src/spinner.rs b/src/spinner.rs index cad5bff..dabfc6d 100644 --- a/src/spinner.rs +++ b/src/spinner.rs @@ -10,6 +10,7 @@ use super::*; /// To use the spinner you can provide it a `Wheel` (see [[wheel]] module), or it implements the `Default` trait, creating a traditional looking spinner (`|/-\`) /// /// ```rust +/// # use termprogress::prelude::*; /// let mut spin = Spin::default(); //Default new spinner without a title. /// ``` /// @@ -42,6 +43,7 @@ impl Spin /// /// # Example /// ```rust + /// # use termprogress::prelude::*; /// Spin::new(Default::default()); // Create a spinner with the default wheel ('|/-\') /// ``` pub fn new(whl: wheel::Wheel) -> Self