{environments} is for general questions related to (La)TeX environments. For questions about environment subcategories like {lists}, {quoting} environments, or {floats} use the appropriate tag instead.

learn more… | top users | synonyms (3)

1
vote
0answers
41 views

Replace a nested LaTeX command with multiple arguments [closed]

I'd like to replace the LaTeX command \teilseiten{left col width}{left col text}{right col text} by an nested environment. The problem is, that the second and third argument of \teilseiten contains ...
4
votes
1answer
47 views

Need two environments in table

I want to set up a table with the column headings centered, but the data right justified, without using \multicolumn for every single cell in the heading, rather I want to use a locally global ...
1
vote
0answers
54 views

Is this possible in Latex? Creating a new environment for notices in technical documents [closed]

I don't even know how to title my request. I am also not including any code, because I have absolutely no starting point. I'm writing a technical document and once in a while I need to put a ...
2
votes
1answer
52 views

Flexibly start a new page for proof environment

I would like to redefine my proof environment so that if the content of the proof environment is only, say, 3 lines or fewer, then the entire proof environment will just start on a new page. Here is a ...
3
votes
1answer
34 views

Problem with making a “new float” and using \autoref{} command

I'm trying to do a new float called "grafico" with the float package. It works fine, but when I try to do a reference, i.e. \autoref{}, it only shows the float number (e.g. If it's "Gráfico 2.1: blah ...
2
votes
1answer
16 views

Error while nesting two environments

I'm trying to nest two environments: \documentclass{article} \usepackage{environ} \NewEnviron{innerEnviron} {INNER \BODY{} INNER} \newenvironment{outerEnviron} {OUTER \begin{innerEnviron}} ...
2
votes
1answer
58 views

Optional text printed in another colour

I would like to extend the version package to print some optionally added text in a different colour. Something like in the following example: \documentclass{article} \usepackage{version} ...
3
votes
1answer
56 views

newenvironment with braces split between start and end

I'm defining a command for placing figures in the margin. A simple version follows: \documentclass{article} \newcommand{\margin}[1]{\marginpar{#1}} \begin{document} \margin{Figure goes here} ...
4
votes
1answer
49 views

Indentation in newtheorem environment

I already have a personalization of the "newtheorem" environment, as follows: \documentclass[a4paper,10pt]{article} \usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} ...
2
votes
1answer
55 views

Problem with defining new environments: The first word is not shown correctly

In my Latex-file there is the following part for defining new environments for theorem, lemma and so on: Unfortunately, this produces some mistakes. When I write a new theorem, lemma etc. then the ...
1
vote
2answers
471 views

Size of the bullet using \itemize

I was wondering what is the (standard) size of the bullets that appear using the itemize environment: \begin{itemize} \item ABC \end{itemize} Is it \small, \tiny...? Is there any way to ...
3
votes
1answer
36 views

Hide indented amsthm environment using comment package

I use amsthm to define a "Solution" environment. I want to be able to hide it. Following this comment I tried using the comment package: \documentclass{article} \usepackage{amsthm} ...
2
votes
1answer
30 views

How to: print paragraph title centered, and on a shaded line across the page? - Continued

This question is a continuation of: this question Consider the following document \documentclass[landscape]{article} \usepackage[a3paper, textwidth=5cm, margin=1cm,landscape]{geometry} ...
1
vote
1answer
139 views

How to typeset a proof via structural induction

Structural induction differs from "mathmatical" induction in the number of cases: While mathmatical induction requires exactly two cases, structural induction may require many more. A proof via ...
2
votes
1answer
41 views

How do I wrap a macro definition in an environment?

I'm creating a style file, and want to store the body text of the abstract environment so that I can put it on my custom titlepage. I could have required that my users enter the abstract as ...
0
votes
1answer
62 views

code using the same packages of tikzcd works on one project but not other [closed]

I'm using the package \usepackage{tikz-cd}. Note that this code works good: \documentclass{amsart} \usepackage{tikz-cd} \begin{document} \begin{tikzcd} & D \arrow[d,"f"] \arrow[dl, ...
1
vote
1answer
28 views

Issue accessing Auctex environments [closed]

I recently installed AucTex on a new computer, and am having an issue that I do not recall with regards to accessing environments. Using C-c C-e, auto-complete etc., I am only able to access a handful ...
4
votes
2answers
68 views

How to: print paragraph title centered, and on a shaded line across the page?

For a cheat sheet I am making I would like that \paragraph{title} does the following: Centre the text 'title', on a shaded (gray) line across the entire page ( column in my case ), start the actual ...
4
votes
1answer
53 views

Change environment's width

I'm writing my homework and I would like to change the environment's dimensions of \documentclass[10pt,spanish]{article} % INICIO PAQUETES \usepackage{amsmath} \usepackage{graphicx} ...
9
votes
2answers
253 views

How to assign TWO parents to LaTeX counter?

I am working on a own LaTeX (using KOMA-Script) class, based on scrartcl. The document structure is supposed to provide sections and subsections, as well as own environments (exercises, solutions, ...
5
votes
1answer
50 views

How do I pass through options when defining a new environment?

I'm trying to define a new environment that's a customized version of the itemize environment, where any options that I pass to the new environment get passed through to the underlying itemize. For ...
2
votes
1answer
53 views

How to get automatic adjustment of environment names?

On one of my computers, when I start a new environment with Ctrl+E (or edit the name of a different environment), if I start typing something inside the \begin{...} it automatically gets copied to the ...
1
vote
0answers
33 views

Auto-create a list of conjectures from given documents

I have three mathematical documents. I want to auto-create fourth document, which should show all conjectures and problems from the first three documents. I mean that the following should be ...
2
votes
1answer
202 views

Chemmacros: Environments reaction and experimental undefined

I get the following errors and have no idea, why. I just updated all my packages. I am using MikTeX 2.9 on Windows 7 and TeXmaker 4.3. Just spent like an hour searching for an answer and didn't get ...
2
votes
1answer
101 views

Don't understand error of LaTeX after creating a new environment

I'm using the minted-package to color code in a paper I'm writing. In order to change the style of the parts where my code will be displayed later down the road I defined a new enviroment. However, ...
4
votes
1answer
110 views

Customized frame with title over frame

I'm trying to have sections within titled-boxes in my document. My minimum almost-working example is: \documentclass[a4paper]{article} \usepackage{lipsum} ...
4
votes
1answer
44 views

How to nest comment and theorem in one environment?

I'm using comment and amsthm packages for comments and theorems. I'd like to skip some theorems. I've tried to create a new environment with theorem nested in a comment: \documentclass{book} ...
1
vote
1answer
177 views

How to create an environment to dump a longtable sideways after currentpage, which works under pandoc

Sorry for the long title (and even longer question), but this is a rather complex subject and requires a bit of elaboration. Goal: I want to define a pair of latex macros which I can write in the ...
4
votes
3answers
86 views

Creating rule inside environment that is same width as text

I have an environment which left and right skips are set to same value. Inside it I have a text and a rule below that text. I want rule to have exactly same width as text above it. (Similarly to what ...
9
votes
2answers
204 views

Ghost environment

I am trying to do the following. I would like a part of my source to be compiled normally by to generate no output. In particlular, I would like references made to the ghosted parts to be produce the ...
2
votes
2answers
60 views

Environments theorem and proof with enumerate

How I can reproduce exactly the following text using \begin{proposition} \begin{enumerate} \item \item \end{enumerate} \end{proposition} \begin{proof} \begin{enumerate} \item \item ...
9
votes
2answers
216 views

Nested amsmath environments with \newenvironment

Using the amsmath environment, I'd like to create a short-cut for \begin{equation*} \begin{split} ... \end{split} \end{equation*} But saying \newenvironment{eqs} ...
3
votes
1answer
130 views

Creating a Postulate Environment

I understand how to use the theorem environment in LaTex and would like to know if there is a similar environment for postulates or how I can make an environment for postulates on my own.
6
votes
3answers
204 views

How can I modify environments on beamer without knowing their original definition

My question is similar to that. I've also tried this, but didn't work for me. Here is a MWE: \documentclass{beamer} \usepackage{ragged2e} \usepackage{lipsum} \begin{document} \footnotesize ...
3
votes
0answers
47 views

Selective display of an object

I want to write an exercise sheet for students. I would like to gather the questions, the hints, and the proofs at the same place in the .tex file. Then I want to display the questions, the hints and ...
3
votes
1answer
89 views

Increase counter for each line in custom align environment

What is a good way to advance the counter in a custom align environment? I defined the regalign environment below, but to get the counter to advance with each line, I had to define a new command ...
4
votes
3answers
132 views

How do I prevent text overflow when using savebox?

I want to create a custom Definition environment. The environment should use some local commands to declare logical parts of the definition (e.g. assumptions using a command Let). The definition text ...
2
votes
1answer
35 views

How to create two environments that refer to each other in the page margin?

I would like to create two environments: one for exercises and one for their solutions. Each exercise should refer to the page of its corresponding solution and vice versa. The problem is not quite ...
2
votes
1answer
61 views

Spurious horizontal space after \mbox{}\vskip0pt\noindent

How can one avoid the horizontal space (text indentation) created by the new line in the environment defined below? \documentclass{scrartcl} \usepackage[T1]{fontenc} \usepackage[american]{babel} ...
13
votes
2answers
263 views

Automatically replace environment align by equation+aligned combination

I would like to automatically replace the align environment by an equation + aligned combination. Specifically, whenever \begin{align} occurs, it should automatically read it as ...
3
votes
1answer
91 views

Thmtools example & solution environments share numbering with other environments

Following the answer to this question, I defined example and solution environments using the thmtools package, which I want to share numbering with the other environments in my document. Here is my ...
2
votes
1answer
82 views

Typeset math mode environments in scriptstyle

I need to typeset aligned environment in script style. Setting \scriptsize outside of the environment works, but the compiler complains: Command \scriptsize invalid in math mode ... Using ...
6
votes
2answers
199 views

Pass a command as optional argument of environment

Sorry for the beginner question, but I'd like to know if there is a robust way to do what the title says. The following MWE \documentclass{book} \usepackage[demo]{graphicx} ...
4
votes
3answers
157 views

Custom enumerate environment inside Fancybox

I would like to put a enumerate environment (customized with the enumitem package) inside of a shadowbox created from the Fancybox package. Here's my MWE: ...
1
vote
0answers
65 views

How to strike out over an environment and formulas and using local variables in latex?

While I am revising my papers, for the sake of easier tracking and saving the time of the reviewers, and hence shortening the review process (I hope!), I use the following commands \usepackage{ulem} ...
3
votes
2answers
88 views

Why is this environment giving me trouble? (enumitem package)

the next environment definition is giving me some trouble: \newenvironment{properties}{\textbf{\underline{Properties:}}\begin{enumerate}[style=(P_{\arabic*}]}{\end{enumerate}} When I try to use it, I ...
5
votes
1answer
84 views

How do I make text raggedright inside all miniboxes?

I have been looking at re-defining minipage so that it is always raggedright but that looks problematic because of the optional arguments. I have a long document which uses lots of minipages. I ...
3
votes
1answer
86 views

Odd behaviour without whitespace for \newenvironment

I'm very new to latex and am just learning things and want to understand why some code is behaving the way it is. I can't seem to find documentation regarding this specific behaviour. Essentially I'm ...
2
votes
2answers
181 views

How do environments work?

As far as I understand, when I specify \newenvironment{env}{ start }{ end } what LaTeX actually does is to define two macros \env -> start \endenv -> end so that \begin{env} middle ...
3
votes
1answer
117 views

Starting environment with \begin{env} or with \env{}

I have noticed that I can start some LaTex environment in two ways. For the frame environment in Beamer, for example, \begin{frame} % .. frame content .. \end{frame} is equivalent to \frame { % ...