- Timestamp:
- Feb 26, 2016 12:27:24 PM (9 years ago)
- Branches:
- master, core_shell_microgels, costrafo411, magnetic_model, release_v0.94, release_v0.95, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
- Children:
- 139c528
- Parents:
- 97e6d3c (diff), 960cd80 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent. - Location:
- doc
- Files:
-
- 1 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/_extensions/dollarmath.py
r19dcb933 r103ea45 12 12 import re 13 13 14 _dollar = re.compile(r"(?:^|(?<=\s ))[$]([^\n]*?)(?<![\\])[$](?:$|(?=\s|[.,;\\]))")14 _dollar = re.compile(r"(?:^|(?<=\s|[(]))[$]([^\n]*?)(?<![\\])[$](?:$|(?=\s|[.,;)\\]))") 15 15 _notdollar = re.compile(r"\\[$]") 16 16 … … 51 51 assert replace_dollar(u"dollar\$ escape")==u"dollar$ escape" 52 52 assert replace_dollar(u"dollar \$escape\$ too")==u"dollar $escape$ too" 53 assert replace_dollar(u"spaces $in the$ math")==u"spaces :math:`in the` math" 53 54 assert replace_dollar(u"emb\ $ed$\ ed")==u"emb\ :math:`ed`\ ed" 54 55 assert replace_dollar(u"$first$a")==u"$first$a" 55 56 assert replace_dollar(u"a$last$")==u"a$last$" 57 assert replace_dollar(u"$37")==u"$37" 58 assert replace_dollar(u"($37)")==u"($37)" 59 assert replace_dollar(u"$37 - $43")==u"$37 - $43" 60 assert replace_dollar(u"($37, $38)")==u"($37, $38)" 56 61 assert replace_dollar(u"a $mid$dle a")==u"a $mid$dle a" 62 assert replace_dollar(u"a ($in parens$) a")==u"a (:math:`in parens`) a" 63 assert replace_dollar(u"a (again $in parens$) a")==u"a (again :math:`in parens`) a" 57 64 58 65 if __name__ == "__main__": -
doc/rst_prolog
r19dcb933 r0a4628d 60 60 .. |g/cm^3| replace:: g\ |cdot|\ cm\ :sup:`-3` 61 61 .. |fm^2| replace:: fm\ :sup:`2` 62 .. |Ang*cm^-1| replace:: |Ang|\ |cdot|\ cm\ :sup:`-1`
Note: See TracChangeset
for help on using the changeset viewer.