Skip to content

Commit

Permalink
Use SimpleFigure in Textile writer.
Browse files Browse the repository at this point in the history
  • Loading branch information
argent0 committed Jun 22, 2021
1 parent b2e83a1 commit 4421c88
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/Text/Pandoc/Writers/Textile.hs
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,7 @@ blockToTextile opts (Div attr bs) = do
blockToTextile opts (Plain inlines) =
inlineListToTextile opts inlines

-- title beginning with fig: indicates that the image is a figure
blockToTextile opts (Para [Image attr txt (src,T.stripPrefix "fig:" -> Just tit)]) = do
blockToTextile opts (SimpleFigure attr txt src tit) = do
capt <- blockToTextile opts (Para txt)
im <- inlineToTextile opts (Image attr txt (src,tit))
return $ im <> "\n" <> capt
Expand Down

0 comments on commit 4421c88

Please sign in to comment.