Class: String
- Inherits:
-
Object
- Object
- String
- Defined in:
- lib/filechooser/string-class.rb,
lib/filechooser/highline-module.rb
Constant Summary collapse
- VERBOTENE_ZEICHEN =
\ must be protected, therefore \!
%w[< > : " \\ / | * ? [ ] = % $ + , ;]
Instance Method Summary collapse
-
#style(st) ⇒ Object
to simplify the use of Highline Color Scheme ( “ in string st is being protected).
- #verboten? ⇒ Boolean
Instance Method Details
#style(st) ⇒ Object
to simplify the use of Highline Color Scheme ( “ in string st is being protected)
9 10 11 12 13 14 |
# File 'lib/filechooser/highline-module.rb', line 9 def style(st) # to simplify the use of Highline Color Scheme ( " in string st is being protected) a="<%= color(\"" b=self.gsub('"','\"') c="\""+", #{st})%>" return a+b+c end |
#verboten? ⇒ Boolean
7 8 9 10 |
# File 'lib/filechooser/string-class.rb', line 7 def verboten? VERBOTENE_ZEICHEN.each{|z| return true if self.index(z)} return false end |