TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Question 1. When I type \begin{document} What keyboard shortcut can I use to so TexShop/Kile/WinEDT will automatically type the following: \end{document}

Question 2. How to do the following in WinEDT/Kile, I alrealdy know texshop


moon & 456456456423423534 & 2342523
sun  & 234324             & 3453
share|improve this question

In WinEdt:

  1. Type } after \begin{document}, that is: type


    You can also use > after \begin{something} to change the environment name to something else. For example, typing > after begin{tabbing} in the following example


    prompts you for inserting a new environment name. If you insert tabular you get


    Moreover, the string \end{{ triggers environment completion. It searches for the last opened environment and closes it.

  2. See Harish Kumar's answer to your question Which text editor to make tables scripts human readable

share|improve this answer

In TeXShop, if you turn on Command Completion, TeXShop will automatically complete environments. For example, type:




will appear. ESC is the standard key for command completion.

In the preferences you can change this to TAB if you prefer.

Additionally, Control-⌘-C will close the current environment. (Also available from the Source menu).

share|improve this answer

If you use the autocompletion feature in Kile, you will get \end{document} automatically. What I mean by that, is that when you start typing a command, you'll get a list of possible completions. Choose the appropriate one, and hit enter.

enter image description here

If you do not have this autocompletion feature, you can turn it on in the settings (Settings --> Configure Kile), under Kile --> Complete:

enter image description here

Alternatively, you can go to Settings --> Configure Kile, look under LaTeX --> Environments in the left panel, and check the box for "Automatically complete \begin{env} with \end{env}". Write \begin{environment} and hit enter -- \end{environment} will be added.

enter image description here

share|improve this answer

As a complement to Torbjørn T.'s answer, if have autocomplete enabled in Kile but for some reason you you need to close an environment manually, you can do it with the combination Ctrl+Alt+E,C (i.e. first the three keys, then the one).

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.