-- Determine listings language name from highlighting-kate language name.
toListingsLanguage :: String -> Maybe String
toListingsLanguage lang = (if lang `elem` listingsLangs
                              then Just lang
                              else Nothing) <|>
                             M.lookup (map toLower lang) langToListingsMap
toListingsLanguage :: String -> Maybe String
toListingsLanguage lang = (if lang `elem` listingsLangs
                              then Just lang
                              else Nothing) <|>
                             M.lookup (map toLower lang) langToListingsMap
toListingsLanguage lang = (if lang `elem` listingsLangs
                              then Just lang
                              else Nothing) <|>
                             M.lookup (map toLower lang) langToListingsMap