Skip to content

Commit

Permalink
Merge pull request #709 from Ducasse/dev
Browse files Browse the repository at this point in the history
Support for $
  • Loading branch information
Ducasse authored Apr 15, 2024
2 parents ff61360 + 1b30bd1 commit 4f1f5ab
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/Microdown-LaTeXExporter-Tests/MicLaTeXWriterTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,18 @@ $$'
'\end{equation}'
]

{ #category : 'tests - math' }
MicLaTeXWriterTest >> testMathInLine [

self
parseInlined: 'Similarly, let $f_{w,C}$ be the number of documents in corpus $C$ that contain word $w$:'


andCheckWeGet:

'Similarly, let $f_{w,C}$ be the number of documents in corpus $C$ that contain word $w$:'
]

{ #category : 'tests - formats' }
MicLaTeXWriterTest >> testMonospace [

Expand Down
7 changes: 7 additions & 0 deletions src/Microdown-LaTeXExporter/MicLaTeXWriter.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,13 @@ MicLaTeXWriter >> visitMath: aMicMathEnvironment [
canvas raw: aMicMathEnvironment body. canvas newLine ]
]

{ #category : 'blocks - table' }
MicLaTeXWriter >> visitMathInline: aMicMathInline [

canvas raw: '$', aMicMathInline bodyString, '$'

]

{ #category : 'blocks - inline' }
MicLaTeXWriter >> visitMonospace: aMonospace [
canvas command
Expand Down
1 change: 1 addition & 0 deletions src/Microdown/MicMathInlineBlock.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,6 @@ MicMathInlineBlock class >> openingDelimiter [

{ #category : 'visiting' }
MicMathInlineBlock >> accept: aVisitor [

^ aVisitor visitMathInline: self
]

0 comments on commit 4f1f5ab

Please sign in to comment.