Refactored filters to simpler form; added default behavior of embedding an empty div/span for unknown latex commands and environments.