Skip to main content

New answers tagged

6 votes
Accepted

Automatically center the floats with the standalone class?

In the standalone class floats are not floats but simple trivlists. So try with \AddToHook{env/figure/begin}{\AddToHook{cmd/item/before}{\centering}}.
Ulrike Fischer's user avatar
0 votes

Label at left of each align line

I believe flalign environment is what you are looking for \documentclass{article} %leqno \usepackage{mathtools} \begin{document} \begin{flalign} &P(x,y): & f(some) \cdot f(thing) &= ...
Celdor's user avatar
  • 9,694
1 vote
Accepted

Delineating TOC Subsection Entries Horizontally (Instead of Vertically)

This answer replaces the \addcontentsline command as defined by hyperref with \addcontentslinex to align subsections entries horizontally in the table of contents. \addcontentslinex is initially ...
Simon Dispa's user avatar
  • 40.3k
2 votes

How to align comment in algorithm code?

You can set all the elements inside a box of equal width. This can be automated using eqparbox's \eqmakebox[<tag>][<align>]{<stuff>} that sets all <stuff> inside a box of ...
Werner's user avatar
  • 615k
3 votes

How to align comment in algorithm code?

You can use the \makebox[width][position]{text} command to create a box of a specified width, allowing you to control the alignment of the text within it. \documentclass{article} \usepackage[a4paper]{...
Emanuele Nardi's user avatar
3 votes

Recreate classic table of contents with KOMA class

Unfortunately originally you've not shown a minimal working example of what you've tried so far, so following is only a sketch of what can be done. KOMA-Script package tocbasic, which is used by ...
cabohah's user avatar
  • 17.9k
2 votes
Accepted

How to right align \intertext and \shortintertext

You can define a right-aligned \shortintertext in the preamble by \newcommand{\Rshortintertext}[1]{\shortintertext{\hfill #1}} and use it whenever you want to right-align your intertext.
invictus's user avatar
  • 301
1 vote
Accepted

How to align text within the enumext alternatives?

Remember that enumext is a list-based package, so you must set list-indent for the second level in this case, either locally or globally using \setenumext. \documentclass[11pt,twoside,a4paper]{article}...
Pablo González L's user avatar
1 vote

How to bring the equation within the margin

You have failed to indicate which document class you use, which font you employ, what the main document font size is, and how wide the textblock is. (Sorry, but the remark about \marginsize is ...
Mico's user avatar
  • 528k
2 votes

Align TikZ pictures horizontally

This solution uses \resizebox to fit as much as possible in one line. I also used the [baseline=...] option to align the origins precisely. \documentclass{article} \usepackage{tikz} \usetikzlibrary{...
John Kormylo's user avatar
  • 83.9k
7 votes
Accepted

Align TikZ pictures horizontally

Using the b option for minipage will align the plots on the baseline. However, the content is much too wide for the page and the contents are too wide for the minipages.This may be partly due to your ...
cfr's user avatar
  • 219k
2 votes
Accepted

Horizontal alignment of listings in subfigures

You could use minipages to centre the listings: \documentclass{acmart} \usepackage{listings} \lstset{basicstyle=\ttfamily} \usepackage{lstautogobble} \usepackage{subcaption} \begin{document} \begin{...
samcarter_is_at_topanswers.xyz's user avatar
2 votes

Stacking tables

Using tabularray: \documentclass{article} \usepackage{tabularray} \begin{document} \begin{table} \centering \begin{tblr}{hlines={1pt},vlines={1pt},columns={wd=1.5cm},rows={ht=0.5cm}} &&...
Stephen's user avatar
  • 6,230
2 votes

Stacking tables

tabular are positioned by the same code as letters. so just have two tabular and leave a blank line between them, and they will be in separate paragraphs (same as \includegraphics in a figure)
David Carlisle's user avatar
3 votes
Accepted

center text on textwidth in a column of a table

If you want to centre on the page and leave space on the left you need to leave the same space on the right \documentclass[a4paper,12pt]{article} \usepackage{tabularx} \setlength{\parindent}{0pt} \...
David Carlisle's user avatar
0 votes

\tcblistof: How to change horizontal spacing in generated list of theorem

In tcolorbox.sty you'll find \newcommand*\l@tcolorbox{\@dottedtocline{1}{1.5em}{2.3em}} The third parameter of \@dottedtocline controls the distance from the number to the title. We can define a ...
mbert's user avatar
  • 8,819
1 vote

Even horizontal spacing in enumitem inline lists

A tagged PDF compatible alternative using the new enumext package: \documentclass[11pt]{article} \usepackage{enumext} \begin{document} Please express the following numbers in fractions: \begin{...
Pablo González L's user avatar
4 votes
Accepted

Centering a Title within a Bclogo Environment

You can achieve the requirement by modifying the command \bcStyleTitre and the MWE is: \documentclass[12pt]{book} \hoffset 10pt \voffset -55pt \oddsidemargin 17pt \evensidemargin 18pt \topmargin 35pt \...
MadyYuvi's user avatar
  • 15.2k
4 votes

Placing text in align environment results in overflowing equations on other lines

You may want the second line to have f(x) aligned with its right edge and \mathcal{F}(u) aligned with its left edge to the integrals above them. You can realize this with alignedat. The explanation ...
egreg's user avatar
  • 1.2m
2 votes

Aligning category boxes on top of each other in tikz

I went with samcarter_is_at_topanswers.xyz's suggestion and used the nicematrix package The following standalone code does not quite work, since the nicetable seems to define the canvas and ...
Felix Benning's user avatar
6 votes
Accepted

Placing text in align environment results in overflowing equations on other lines

Just drop the alignment tab & in the second equation on the first line; it's not needed. \documentclass{article} \usepackage{amsmath} \begin{document} \begin{align*} \mathcal{F}(u) &= \...
Werner's user avatar
  • 615k

Top 50 recent answers are included