latex2stog: handle optional \begin{environment}[title]