@@ -750,41 +750,10 @@ blocksToInlines bs =
750750 _ -> B.fromList $ Walk.query (:[]) bs
751751
752752adjustSpans :: Lang -> Inline -> Inline
753−adjustSpans lang (RawInline (Format "latex") s)
754− | s == "\\hyphen" || s == "\\hyphen " = Str "-"
755− | otherwise = parseRawLaTeX lang s
753+adjustSpans lang (Span ("",[],[("bibstring",s)]) _) = Str $ resolveKey' lang s
756754adjustSpans _ SoftBreak = Space
757755adjustSpans _ x = x
758756
759−parseRawLaTeX :: Lang -> Text -> Inline
760−parseRawLaTeX lang t@(T.stripPrefix "\\" -> Just xs) =
761− case parseLaTeX lang contents of
762− Right [Para ys] -> f command ys
763− Right [Plain ys] -> f command ys
764− Right [] -> f command []
765− _ -> RawInline (Format "latex") t
766− where (command', contents') = T.break (\c -> c =='{' || c =='\\') xs
767− command = T.strip command'
768− contents = T.drop 1 $ T.dropEnd 1 contents'
769− f "mkbibquote" ils = Span nullAttr [Quoted DoubleQuote ils]
770− f "mkbibemph" ils = Span nullAttr [Emph ils]
771− f "mkbibitalic" ils = Span nullAttr [Emph ils]
772− f "mkbibbold" ils = Span nullAttr [Strong ils]
773− f "mkbibparens" ils = Span nullAttr $
774− [Str "("] ++ ils ++ [Str ")"]
775− f "mkbibbrackets" ils = Span nullAttr $
776− [Str "["] ++ ils ++ [Str "]"]
777− -- ... both should be nestable & should work in year fields
778− f "autocap" ils = Span nullAttr ils
779− -- TODO: should work in year fields
780− f "textnormal" ils = Span ("",["nodecor"],[]) ils
781− f "bibstring" [Str s] = Str $ resolveKey' lang s
782− f "adddot" [] = Str "."
783− f "adddotspace" [] = Span nullAttr [Str ".", Space]
784− f "addabbrvspace" [] = Space
785− f _ ils = Span nullAttr ils
786−parseRawLaTeX _ t = RawInline (Format "latex") t
787−
788757latex' :: Text -> Bib [Block]
789758latex' t = do
790759 lang <- gets localeLang