Class: Kramdown::Converter::RTL
- Inherits:
-
Html
- Object
- Html
- Kramdown::Converter::RTL
- Defined in:
- lib/jekyll-markright.rb
Instance Method Summary collapse
- #add_code_tags(code) ⇒ Object
- #convert_codeblock(el, indent) ⇒ Object
- #convert_codespan(el, indent) ⇒ Object
Instance Method Details
#add_code_tags(code) ⇒ Object
36 37 38 39 |
# File 'lib/jekyll-markright.rb', line 36 def (code) code = code.sub(/<pre>/,'<pre><code dir="ltr">') code = code.sub(/<\/pre>/,"</code></pre>") end |
#convert_codeblock(el, indent) ⇒ Object
22 23 24 25 26 27 |
# File 'lib/jekyll-markright.rb', line 22 def convert_codeblock(el, indent) if not el.attr['dir'] el.attr['dir'] = 'ltr' end return super(el, indent) end |
#convert_codespan(el, indent) ⇒ Object
29 30 31 32 33 34 |
# File 'lib/jekyll-markright.rb', line 29 def convert_codespan(el, indent) if not el.attr['dir'] el.attr['dir'] = 'ltr' end return super(el, indent) end |