Questions tagged [nesting]

{nesting} is about nesting document elements. Use this tag in addition to other tags specifying what should be nested.

Filter by
Sorted by
Tagged with
1 vote
3 answers
62 views

How to define a LaTeX shorthand for nested indentation "contexts"

I am looking for a convenient way to code nestable "contexts" whose extents are displayed through indentation. Each context consists of a sequence of "statements" (i.e. lines) and/...
user avatar
  • 771
1 vote
1 answer
36 views

How to align subequations within table

I would like to reproduce the structure, alignment, and numbering, of the equations in this table: I have tried many combinations of the environments equation, subequation, align, table / tabular, ...
user avatar
  • 13
1 vote
0 answers
31 views

What is the right way of cascading styles using nested environments/macros, while each environment/macro might partially stylize its embedded content?

I have asked similar to this question before, but I think I have to describe it in another way. Need What is the right way of cascading styles using nested environments/macros (much like the way CSS ...
user avatar
  • 365
0 votes
0 answers
23 views

Nested Stand-Alone with flash cards not working

I have made flash cards using the flacards document class, but they are from multiple topics across multiple semesters. I want to be able to have a unique footer for each topic/semester, as well as ...
user avatar
  • 11
0 votes
2 answers
54 views

Passing nested argument specifier to hook

Consider a macro that declares some other document command, but by accepting their body as an own argument (simple indirection) also adds the invocation of itself to some hook as in \...
user avatar
2 votes
2 answers
92 views

escape hashs (#) passed as argument to use them in inner macro

I am using nested macros using the xparse package, my ultimate goal being to have a custom macro factory. I have simplified my current problem here. I want to give a pattern as an argument, like in ...
user avatar
  • 123
0 votes
1 answer
34 views

Nested blockquotes in latex

Within Markdown it is possible to use nested blockquotes, which looks like this: Dorothy followed her through many of the beautiful rooms in her castle. The Witch bade her clean the pots and kettles ...
user avatar
0 votes
0 answers
69 views

Nesting tcolorboxes with listing

I'm trying to build a macro to ouput the content in a tcolorbox. Ultimately, any kind of content can be put in that box (image, tcolorbox, code, ...). However, when using the macro (instead of the ...
user avatar
  • 1,955
0 votes
2 answers
88 views

How can I write nested matrices like this? [closed]

I am reading this Wikipedia article on Kronecker product. How can I use LaTex to write this?
user avatar
  • 201
2 votes
2 answers
284 views

Nested inline math for new command with argument

There exists some consensus on the fact that one shouldn't use $...$, \(...\) or \ensuremath inside of newcommand (or NewDocumentCommand, ...) definitions to wrap passed macro arguments that are to ...
user avatar
0 votes
2 answers
161 views

How to implement \savebox

\documentclass[a4paper,10pt]{article} \usepackage[left=24mm,right=30mm,bottom=25mm,top=25mm]{geometry} \usepackage[utf8]{inputenc} \usepackage{tikz} \usetikzlibrary{shapes.geometric, arrows} \...
user avatar
0 votes
0 answers
42 views

Nesting deluxetable and figure in AASTeX

I'm using AASTeX's two-column style and I was trying to 'combine' a figure and table into one fitted inside a single column. However, the figure doesn't display including the "main figure's" ...
user avatar
  • 3
4 votes
1 answer
93 views

Proof environments inside statements - is it harmful or is it OK?

I discovered that a student of mine uses constructs like \begin{theorem} ...a statement... \begin{proof} ...proof of that statement... \end{proof} \end{theorem} My first reaction was ...
user avatar
0 votes
0 answers
44 views

Combine / nesting \newcommand with \def that are referencing #1, #2, etc in different ways?

I have a polar plot made with TikZ that I used to draw in some old documents. Now I want to use this in my document class instead of having the whole code snippet every place that I am drawing the ...
user avatar
1 vote
1 answer
62 views

coloring bullets in nested lists

I would like to color bullets in my lists (for example, to signify tasks that are done or not/hard or easy, etc.), including in nested lists. I found this and successfully used it. Since I would like ...
user avatar
0 votes
1 answer
65 views

Change symbols of levels of unordered list using outlines

Is it possible to change this latex from outlines package \documentclass{article} \usepackage{outlines} \begin{document} \begin{outline} \1 Level 1 \2 Level 2 \3 Level 3 \end{outline} \end{...
user avatar
  • 172
0 votes
1 answer
51 views

Add third level after itemize then list in nested unordered list

I have a unordered list with 2 levels in the following form: \begin{itemize} \item Level 1 \begin{list}{$\circ$}{} \item Level 2 % Trying to add a third level here \end{itemize} ...
user avatar
  • 172
1 vote
1 answer
113 views

nesting multiframe

I wonder whether the following is possible. I'd like to nest animateinline and multiframe environments to simulate the time dependance of a signal for different parameters. Something like that: \...
user avatar
0 votes
1 answer
55 views

Nesting environment inside new command generating errors

Extreme TeX novice, sorry for the length of the example, I wasn't sure what packages were important to replicate the problems. I was trying to create a simple command that I could use to injected ...
user avatar
  • 103
0 votes
2 answers
396 views

Using nested align* to split a long numerator into multiple lines leads to "Erroneous nesting" error

I am using an align* environment within another align* environment because I have a fraction with a long numerator that I want to split into two lines within the numerator. Here is what I tried: \...
user avatar
  • 2,897
0 votes
1 answer
62 views

numbererd tabluarx inside tabulars

I am generating tex documents automatically (HTML -> pandoc(tex) -> postprocess -> XELATEX), and my general table environment is tabularx (with usage of package ltablex, so these are ...
user avatar
  • 138
0 votes
0 answers
36 views

enumitem ignores level specification?

Consider the code \documentclass{article} \usepackage{enumitem} \newlist{longitemize}{itemize}{20}% \setlist[longitemize,1]{label=\textbullet}% \setlist[longitemize,2]{label=\normalfont \bfseries \...
user avatar
  • 2,013
-1 votes
2 answers
105 views

Tabbing wrong in nested commands [closed]

So, I have two commands defined in my document class like this. \newcommand{\skillgroup}[2]{ \begin{tabbing} \hspace{5mm} \= \kill \sqbullet \>\+ \textbf{#1} \\ \begin{minipage}{\smallertextwidth} ...
user avatar
2 votes
1 answer
1k views

Ordered Nested lists similar to Microsoft WORD numbered nested lists

In LaTeX, by default the numbering styles change depending on the depth of the nested lists as shown below. \begin{enumerate} \item First level item \item First level item \begin{enumerate} ...
user avatar
  • 965
4 votes
1 answer
122 views

Nested enumeration

I'm trying to create a list of the following type: 1a) Apples 1b) Bananas 1c) Oranges 2a) Tomatoes 2b) Carrots 3) Bread 4a) Cake 4b) Cookies I tried to use both ...
user avatar
  • 43
3 votes
2 answers
227 views

Nested Environment in LyX: Theorem with only an enumeration

I've read the following posts but I'm not sure they answer my doubt: Lyx nested environments; Normalizing nested environments for cleaner design (LyX). I am using the AMS theorem environment, and I ...
user avatar
4 votes
2 answers
443 views

How can I typeset a group action?

How would I typeset something that looks like the following? I have tried \begin{align*} \sigma : T^k(V) & \longrightarrow T^k(V) \\ T & \longmapsto \begin{aligned} ...
user avatar
  • 143
2 votes
0 answers
121 views

A typography challenge from over a hundred years ago

I am a newbie in LaTeX. I am now typesetting the formal proof from Begriffsschrift by Frege, which look like this: As seen in the picture, I decide to put all the elements of the proof into a 3x3 ...
user avatar
1 vote
1 answer
69 views

Nested numbered alignement

(disclaimer : yes I have already read : Nested cases, alignment and numbering, no it doesn't help) I am trying to get something like this : and : BUT with the numbering aligned. I got the above ...
user avatar
3 votes
0 answers
70 views

How to cross reference nested enumeration lists?

Within theorems, I have nested enumeration lists: 1.1, 1.2, 1.3, 1.4, etc. 2.1, 2.2, 2.3, 2.4, etc. For referencing to 1.1 to 1.3 and 2.4 I tried to use the usual command \cref{en1-1,en1-2,en1-3,...
user avatar
  • 218
1 vote
1 answer
256 views

Highlighting aligned equation lines using tcolorbox

In my first box I've shown the three lines of math I want to display. I then wish to highlight the first and the last lines according to the design of box A and box B, seen below. Is it possible to ...
user avatar
  • 377
5 votes
2 answers
286 views

Why does nesting some xstring commands causes errors?

Why does combining some command of the xstring package causes errors? e.g. when I compile the following MWE: \documentclass{article} \usepackage{xstring} \begin{document} \section{A} \StrCompare{\...
user avatar
0 votes
1 answer
167 views

How to increase counter on nested subfigure environment?

I would like to add an automatic numbering of nested subfigure environments. I found the following answer, which shows how I can manually add an additional Arabic number to my subsubfigure, but I ...
user avatar
  • 119
2 votes
0 answers
143 views

Is there a way to add a directory to the search path on the fly / not redefine?

Numerous examples (see this one for instance) describe the the use of: \makeatletter \def\input@path{% {<path1>}% {<path2>}% }% \makeatother as way to broaden the compiler's search ...
user avatar
1 vote
0 answers
211 views

Nesting New Fonts: Trying to Use Small Caps

Xelatex. I'm trying to use small caps with the Century Schoolbook font, which doesn't have them. I get "font not found" errors when I try to use system fonts that have small cap variants. That error ...
user avatar
  • 1,657
0 votes
1 answer
267 views

How to display a numbering inside parentheses

I'd like to display the following numbering in LaTex: (n-m) (a)... (b)... where n represents any section number and m the sequential number in this section. It can not be equation numbering ...
user avatar
  • 462
3 votes
0 answers
110 views

Wrapping environment passing optional argument to wrapped environment

I'm trying to create a myframe environment which wraps a Beamer frame environment but sets a default title. Additionally, I want to be able to pass optional arguments to myframe which should then ...
user avatar
  • 985
1 vote
1 answer
170 views

Recursive or nested comment blocks

I know we can comment out a block of text in Latex using \begin{comment} and \end{comment} commands. However, when I call this recursively (or in a nested fashion) as shown below, it fails: \begin{...
user avatar
0 votes
1 answer
77 views

Calling nested indexing macros

Here is my simplified document sample which is failing with the errors mentioned in the comments. I tried to enclose the nested macro with { and } and it didn't work, same with enclosing it with \...
user avatar
1 vote
0 answers
23 views

Is it possible to get a series of nested numbered lists without having a nested enumerate environment?

In particular, I am hoping to accomplish something like your standard outline with text: I. Level 1 II. Level 1 A. Level 2 1. Level 3 2. Level 3 B. Level 2 ...
user avatar
1 vote
1 answer
85 views

shellescape macro nested in another macro

How do I use a shellescape (| echo "stuff") macro as another macros input if there are "bad" characters like _ contained. I will use my full example as reference. The idea is to replace \...
user avatar
2 votes
2 answers
50 views

What's the best method for bracing a list of aligned equations?

I would like to reduce the height of the \left\{ in the following, to make it the same height as the equations: %\usepackage{esdiff} \begin{align*} \mathcal L&= - 0.75 w(S) - 0.25 w(F) + \lambda ...
user avatar
  • 663
4 votes
2 answers
210 views

tikz-cd nested tikzpicture wrong center anchor

I want to place a tikzpicture in a node/cell of a tikz-cd diagram and then paint some more stuff in the inner tikzpicture. However, it seems that the nesting messes up the center anchor. Concretely: ...
user avatar
  • 302
0 votes
0 answers
316 views

How to use \discretionary inside soul's \hl?

\documentclass{article} \usepackage{soul} \usepackage{color} \begin{document} Some \hl{te\discretionary{-}{-}{-}xt}. \end{document} The above does not compile due to Missing { inserted, Improper ...
user avatar
  • 988
0 votes
1 answer
188 views

How to write this underdash? [closed]

I want to write this expression : so, what will be its code? please help...
user avatar
  • 113
2 votes
1 answer
221 views

Text not vertically aligned within tabular with nested tabular

I am trying to vertically align a row heading with a table inside the row. But no matter what I do, the heading remains in the center. I tried using p{'width'}, but that had no change. \documentclass{...
user avatar
4 votes
2 answers
320 views

Renewcommand with ensuremath and brackets

I'm making a .sty file (which is called my-macros.sty and is in my home /texmf directory) where I define some commands that I constantly use. Among these commands, there are the following \newcommand{...
user avatar
  • 273
2 votes
2 answers
395 views

"environ" package and nested environments won't work [duplicate]

I'm trying to make a little style package to make some nice blocks with icons and so on. I'm using environ package + tikz. Actually the document compiles and shows me my boxes but with errors saying ...
user avatar
  • 163
4 votes
3 answers
324 views

Nested alignments

I want to make alignments that look like this: which I have done by using \begin{align} & \frac{dx}{dt} = y \qquad \frac{dy}{dt} = x \\ \implies & \frac{d^2x}{dt^2} = \frac{d}{dt}\...
user avatar
7 votes
2 answers
310 views

LaTeX 2e environment that "knows" the name of surrounding environment

I'd like to have a LaTeX 2e-environment which when occurring inside another environment "knows" the name of the surrounding environment. Is this possible? I know that \@currenvir provides the ...
user avatar

1
2 3 4 5 6