
Code markup does not allow brackets
Reported by Bil Kleb | March 11th, 2009 @ 04:31 AM | in 4.2.0
Textism and RedCloth 3.0.4 do not interpret the square bracketed
portion of @[project]_dff.skjd@
while RedCloth 4.1.9
does?
RedCloth 3.0.4:
irb(main):001:0> require 'rubygems'
=> true
irb(main):002:0> gem 'RedCloth', '=3.0.4'
=> true
irb(main):003:0> require 'redcloth'
=> true
irb(main):004:0> RedCloth.new('@[project]_dff.skjd@').to_html
=> "<p><code>[project]_dff.skjd</code></p>"
RedCloth 4.1.9
irb(main):001:0> require 'rubygems'
=> true
irb(main):002:0> gem 'RedCloth', '=4.1.9'
=> true
irb(main):003:0> require 'redcloth'
=> true
irb(main):004:0> RedCloth.new('@[project]_dff.skjd@').to_html
=> "<p><code lang=\"project\">_dff.skjd</code></p>"
If this is intentional new behavior, how does one markup a
square bracketed phrase as ?
Comments and changes to this ticket
-
Jason Garber March 17th, 2009 @ 04:44 AM
- Milestone set to 4.2.0
- Tag changed from backward compatibility, code to backward compatibility, code, explicit_square_brackets
- State changed from new to open
It's not intentional. I'll check it out.
-
Ion Balan March 17th, 2009 @ 05:24 PM
It seems my problem is related to the same bug described here
irb(main):001:0> require 'rubygems' => true irb(main):002:0> require 'redcloth' => true irb(main):003:0> RedCloth.new("|[first]|{second}|").to_html => "<table>\n\t<tr>\n\t\t<td lang=\"[first\">[first]]</td>\n\t\t<td style=\"second;\">second}</td>\n\t</tr>\n</table>"
-
Jason Garber March 23rd, 2009 @ 11:30 AM
This is a significant problem. I'd like to give it high priority.
-
Jason Garber May 19th, 2009 @ 05:08 PM
Ion, what are you expecting from your table example? Proper lang and style attributes and empty cells or no handling of lang/class/style within table cells?
-
Jason Garber May 19th, 2009 @ 05:09 PM
(from [ae8b81ba481ce1f3fc304610d0d47d8d7470fbd3]) Remove lang/class/style attribute parsing from inline code. [#124] http://github.com/jgarber/redcloth/commit/ae8b81ba481ce1f3fc304610d...
-
Ion Balan May 19th, 2009 @ 05:38 PM
Hello Jason,
as i understand textile (from http://hobix.com/textile/), in order to interpret curly and angel brackets as style or lang block, a dot at the end is required.
By example, this is a valid lang declaration:[en].
, but this is not:
[en]
so, i expect:
|[first] text| ==> <td>[first] text</td>
, but [first]. text| ==> <td lang='first'>text</td>Thanks a lot for your work!
-
Jason Garber May 20th, 2009 @ 04:39 PM
- State changed from open to resolved
Fixed! I had to seriously refactor the handling of attributes, but that was long overdue anyway.
-
Bodaniel Jeanes July 3rd, 2009 @ 07:53 AM
Jason, now with this change how does one set the lang if they were RELYING on this functionality? Also other plugins such as CodeRay use this to hook into RedCloth to highlight based on the language.
What about Ion's suggestion of treating it as a lang/style selector if followed by a period?
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
RedCloth is a Ruby library for converting Textile into HTML
People watching this ticket
Referenced by
-
124 Code markup does not allow brackets (from [ae8b81ba481ce1f3fc304610d0d47d8d7470fbd3]) Remove ...