Class: VER::Buffer::InvalidTrailingWhitespace

Inherits:
Tag
  • Object
show all
Defined in:
lib/ver/buffer/invalid_trailing_whitespace.rb

Constant Summary collapse

NAME =
'invalid.trailing-whitespace'.freeze

Instance Method Summary collapse

Constructor Details

#initialize(buffer, name = NAME) ⇒ InvalidTrailingWhitespace

Returns a new instance of InvalidTrailingWhitespace.



6
7
8
9
10
# File 'lib/ver/buffer/invalid_trailing_whitespace.rb', line 6

def initialize(buffer, name = NAME)
  super

  configure background: '#400'
end

Instance Method Details

#refresh(options = {}) ⇒ Object



12
13
14
# File 'lib/ver/buffer/invalid_trailing_whitespace.rb', line 12

def refresh(options = {})
  buffer.tag_all_matching(self, /[ \t]+$/, options)
end