textmate / latex.tmbundle

TextMate support for LaTeX
97 stars 64 forks source link

triggers such as "thm" duplicate user's environment name #173

Closed scoskey closed 6 years ago

scoskey commented 6 years ago

This is not a bug at all, but a usage consideration.

The package allows one to write "thm" followed by ctrl+< to obtain a \begin{theorem}\end{theorem} environment. The environment automatically includes a \label{...}. The cursor is inserted in the label, the label is not selected for potential deletion.

  1. Do users want to provide a label for every theorem?

  2. I have long used the theorem name "thm", as in \newtheorem{thm}{Theorem}. This means I want this same command to create \begin{thm}\end{thm}. I suppose one might consider my particular choice to be deprecated by the advent of your editor macros, but I'm not sure.

https://github.com/textmate/latex.tmbundle/blob/b06ddd1f4e969c3ae4188b68a0b8302bb91aeb28/Support/config/latex.config#L129

sanssecours commented 6 years ago

Hi Samuel,

you can configure “Insert”→“Command Based on Current Word“ to your liking via the command “Edit Configuration File“. For more information please take a look at the section “Inserting Commands and Environments“ in the Help document (also available in TextMate via “Bundles”→“LaTeX”→“Help”).

scoskey commented 6 years ago

Ok, understood!