Commits

Eric Knibbe committed e22f8b7 Draft

accounting for backticks

Comments (0)

Files changed (1)

bbedit/reStructuredText.plist

 		<key>String Pattern</key>
 		<string><![CDATA[(?x:
 			(?<![\w~@#$%^&*)\]}>|+=\\;.,!?]):(?!\s)
-			\w(:(?=[a-z0-9])|[-\w.+='" \t])*
+			(\\:|:(?=[a-z0-9])|[^:\r])+
 			(?<!\s):(?!(?P<end>[\w~@#$%^&*([{<|+=]))      | (?# role/directive option/field name)
-			(?<![\w~@#$%^&*)\]}>|+=\\;.,!?])\|(?!\s)
-			(\|(?=(?P>end))|[^|\r])+
-			(?<![\s\\])\|_{0,2}(?!(?P>end))               | (?# substitution)
-			(?<![_~@#$%^&*)\]}>|+=\\;.,!?])\b[a-z0-9]
-			([-_.:+](?=[a-z0-9])|[a-z0-9])*__?(?!(?P>end)) | (?# hyperlink reference)
+			(?<![\w~@#$%^&*)\]}>|+=\\;.,!?`])\|(?!\s)
+			(\|(?=(?P>end)|`)|[^|\r])+
+			(?<![\s\\])\|_{0,2}(?!(?P>end)|`)               | (?# substitution)
+			(?<![_~@#$%^&*)\]}>|+=\\;.,!?`])\b[a-z0-9]
+			([-_+.:](?=[a-z0-9])|[a-z0-9])*__?(?!(?P>end)|`) | (?# hyperlink reference)
 			(?<![\w~@#$%^&*)\]}>|+=\\;.,!?`])`(?!\s)
 			(\\`|[^`])+(?<!\s)`_{0,2}(?!(?P>end))         | (?# phrase reference/interpreted text)
 			(?<![\w~@#$%^&*)\]}>|+=\\;.,!?])_`(?!\s)