summaryrefslogtreecommitdiff
path: root/helix-tui/src/text.rs
diff options
context:
space:
mode:
Diffstat (limited to 'helix-tui/src/text.rs')
-rw-r--r--helix-tui/src/text.rs16
1 files changed, 8 insertions, 8 deletions
diff --git a/helix-tui/src/text.rs b/helix-tui/src/text.rs
index b23bfd81..4af6b09d 100644
--- a/helix-tui/src/text.rs
+++ b/helix-tui/src/text.rs
@@ -21,7 +21,7 @@
//! ```rust
//! # use helix_tui::widgets::Block;
//! # use helix_tui::text::{Span, Spans};
-//! # use helix_tui::style::{Color, Style};
+//! # use helix_view::graphics::{Color, Style};
//! // A simple string with no styling.
//! // Converted to Spans(vec![
//! // Span { content: Cow::Borrowed("My title"), style: Style { .. } }
@@ -46,8 +46,8 @@
//! Span::raw(" title"),
//! ]);
//! ```
-use crate::style::Style;
use helix_core::line_ending::str_is_line_ending;
+use helix_view::graphics::Style;
use std::borrow::Cow;
use unicode_segmentation::UnicodeSegmentation;
use unicode_width::UnicodeWidthStr;
@@ -92,7 +92,7 @@ impl<'a> Span<'a> {
///
/// ```rust
/// # use helix_tui::text::Span;
- /// # use helix_tui::style::{Color, Modifier, Style};
+ /// # use helix_view::graphics::{Color, Modifier, Style};
/// let style = Style::default().fg(Color::Yellow).add_modifier(Modifier::ITALIC);
/// Span::styled("My text", style);
/// Span::styled(String::from("My text"), style);
@@ -121,7 +121,7 @@ impl<'a> Span<'a> {
///
/// ```rust
/// # use helix_tui::text::{Span, StyledGrapheme};
- /// # use helix_tui::style::{Color, Modifier, Style};
+ /// # use helix_view::graphics::{Color, Modifier, Style};
/// # use std::iter::Iterator;
/// let style = Style::default().fg(Color::Yellow);
/// let span = Span::styled("Text", style);
@@ -211,7 +211,7 @@ impl<'a> Spans<'a> {
///
/// ```rust
/// # use helix_tui::text::{Span, Spans};
- /// # use helix_tui::style::{Color, Style};
+ /// # use helix_view::graphics::{Color, Style};
/// let spans = Spans::from(vec![
/// Span::styled("My", Style::default().fg(Color::Yellow)),
/// Span::raw(" text"),
@@ -265,7 +265,7 @@ impl<'a> From<Spans<'a>> for String {
///
/// ```rust
/// # use helix_tui::text::Text;
-/// # use helix_tui::style::{Color, Modifier, Style};
+/// # use helix_view::graphics::{Color, Modifier, Style};
/// let style = Style::default().fg(Color::Yellow).add_modifier(Modifier::ITALIC);
///
/// // An initial two lines of `Text` built from a `&str`
@@ -319,7 +319,7 @@ impl<'a> Text<'a> {
///
/// ```rust
/// # use helix_tui::text::Text;
- /// # use helix_tui::style::{Color, Modifier, Style};
+ /// # use helix_view::graphics::{Color, Modifier, Style};
/// let style = Style::default().fg(Color::Yellow).add_modifier(Modifier::ITALIC);
/// Text::styled("The first line\nThe second line", style);
/// Text::styled(String::from("The first line\nThe second line"), style);
@@ -369,7 +369,7 @@ impl<'a> Text<'a> {
///
/// ```rust
/// # use helix_tui::text::Text;
- /// # use helix_tui::style::{Color, Modifier, Style};
+ /// # use helix_view::graphics::{Color, Modifier, Style};
/// let style = Style::default().fg(Color::Yellow).add_modifier(Modifier::ITALIC);
/// let mut raw_text = Text::raw("The first line\nThe second line");
/// let styled_text = Text::styled(String::from("The first line\nThe second line"), style);