Added latex mode stuff, why wasn't it in here earlier?