diff options
Diffstat (limited to 'src/output/lines.rs')
-rw-r--r-- | src/output/lines.rs | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/output/lines.rs b/src/output/lines.rs index 6649c29..b61494f 100644 --- a/src/output/lines.rs +++ b/src/output/lines.rs @@ -1,8 +1,16 @@ +use colours::Colours; use file::File; +#[derive(Clone, Copy, Debug, PartialEq)] +pub struct Lines { + pub colours: Colours, +} + /// The lines view literally just displays each file, line-by-line. -pub fn lines_view(files: &[File]) { - for file in files { - println!("{}", file.file_name_view()); +impl Lines { + pub fn view(&self, files: &[File]) { + for file in files { + println!("{}", file.file_name_view(&self.colours)); + } } } |