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

I want to create a new environment, from frame environment, but I want to add the command \frametitle so it shows the title of the current section. Anyone have any idea how to do.

share|improve this question
That's no bigger problem however knowing which theme you are using would make things much easier. So maybe you could provide a MWE. – bloodworks Jan 20 '13 at 20:11
up vote 4 down vote accepted

It would be much easier if you can simply put a simple MWE. It's only six lines of code anyway. So here is my guess.


\section{Sec shun 1}
\frame{Dummy frames}
\begin{slide}{My title 1}
Some stufff

\section{Sec shun 2}
\begin{slide}{My title 2}
Some other stufff
\frame{Dummy frames}
share|improve this answer
Thanks, this was the idea I had but did not know the command \insertsection. But I had to delete -#1 of the code, because it show -L after the section title in the output. – juanuni Jan 20 '13 at 20:40
Because it expects an additional frame title. Again if you had given a MWE we wouldn't have this now, would we? – percusse Jan 20 '13 at 21:12
No worries, playing with the code that you have shown me I have achieved to get what I wanted. Thank you again. – juanuni Jan 20 '13 at 21:31

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.