New answers tagged

2 votes
Accepted

TikZ: Why is a scalebox-ed picture not exactly centered even with the centering option?

I believe the issue is one purely of extra stray spaces introduced at line ends. Adding % to those line ends resolves it in the article class (I could not compile in the OP's document class). \...
user avatar
1 vote

elementary school-like math operation

You say: "Term can be written with siunitx package". It means: it can or may not. I didn't use this package and I did use plain TeX and \halign primitive: \def\unit{g/h} \halign{\llap{#}&...
user avatar
  • 52.2k
0 votes

elementary school-like math operation

I simply used the align* environment. Use & to align at that point. Here is the code: \documentclass{article} \usepackage{mathtools,amssymb} \usepackage{siunitx} \begin{document} \begin{align*}...
user avatar
  • 742
4 votes

elementary school-like math operation

You may use array: \documentclass{article} \usepackage{siunitx,booktabs} \sisetup{per-mode=symbol} \begin{document} \[ \begin{array}{ c % the operation symbol r % the numbers @{\,}% the ...
user avatar
  • 985k
1 vote
Accepted

How do I typeset centered and aligned equations with additional flush left / ragged right labeled intertexts in one single math mode environment?

You can do it with \shortintertext of mathtools and flalign, although I don't think this is really clear for the reader. \documentclass{article} \usepackage{mathtools} \usepackage{showframe,lipsum} % ...
user avatar
  • 985k
1 vote
Accepted

How can I define an environment similar to alignat, but calculates the number of columns automatically like align?

A simple approach is to make a new environment that forwards 99 to alignat: (remark, this is the "standard" method to redefine environment; nevertheless it will not work for some particular ...
user avatar
  • 1,471
0 votes
Accepted

Align text // newcommand

\documentclass{scrartcl} \usepackage[colorlinks]{hyperref} \newlength{\datebox} \settowidth{\datebox}{Correo electrónico y más} \newcommand\NewEntry[2]{\noindent\hangindent\datebox% \makebox[\datebox]...
user avatar
  • 72.9k
2 votes

Align text // newcommand

Perhaps you want something like this? (Based on your usage of \NewEntry, I reduced the number of its arguments to two.) \documentclass{scrartcl} \usepackage{hyperref} \usepackage{newpxtext} \...
user avatar
  • 4,747
0 votes

How to right-align any line or word in a paragraph in any documentclass?

The simpler solution to right align a line is this: \documentclass{article} \begin{document} Here comes some text. Have a nice day. \rightline{Yours sincerely} \end{document}
user avatar
3 votes
Accepted

writing a menu in latex

This is a bit rudimentary, but is it going into the right direction? I'm not a fan of using \subsection for something isn't a subsection, so I removed its use. The dots are generated with \dotfill, ...
user avatar
  • 740
7 votes
Accepted

How to Automatically Center Verse

You asked, Is there a way to center stanzas of verse in a reasonably simple ... way? If the verse package is loaded, the verse environment takes an optional argument, which informs LaTeX about the ...
user avatar
  • 435k
1 vote

vertical alignment when using \underbrace for Matrix

You need to force a width that makes XITS Math to choose the bigger brace. \documentclass{article} \usepackage{mathtools} %\usepackage[no-math]{fontspec} \usepackage{unicode-math} \setmathfont[...
user avatar
  • 985k
9 votes

How can I place two circuit diagrams next to each other?

As Tom said before, please always provide a minimal working example (MWE). Your problem is pretty simple. You have a blank line here: \end{tikzpicture} \begin{tikzpicture} That creates a new ...
user avatar
  • 2,109
8 votes
Accepted

How can I place two circuit diagrams next to each other?

I don't know why you define those nodes that you won't use them. Those will create empty space in your figure. I have deleted them. And notice: If next time you ask a question, please provide a ...
user avatar
  • 1,668
1 vote

Center reaction with chemfig: subscript causes shifting

\documentclass{article} \usepackage{chemfig} \begin{document} \schemestart \chemfig{CH_4} \+ \chemfig{\vphantom{C}-[,.6,,,dotted]M-M-M-[,.6,,,dotted]} \arrow \chemfig{-[,.6,,,dotted]M(-[2]CH_3)-M(-[2]...
user avatar
  • 3,764
1 vote
Accepted

hspace* does vertical space instead of horizontal space in algorithm block

Presumably Require is starting a new paragraph so your \hspace* is not making vertical space it is making a single line paragraph with just a horizontal space You would see the same if you used \...
user avatar
3 votes

Plain TeX simple horizontal alignment in table

Beware that TeX ignores spaces after &, but not before it. If you want to be precise about spacing between columns, you need to avoid those spaces. In the code below the spaces are there, but they'...
user avatar
  • 985k
1 vote
Accepted

Forest - horizontal directory structure

I'm not sure if this is what you want, but since the folder option has downward as its natural direction, you need to change grow'=0 to grow=270. Then to rotate the nodes, add rotate=-90 to your for ...
user avatar
  • 20.1k
4 votes
Accepted

Plain TeX simple horizontal alignment in table

I think you want something like \halign{\hfil#\unskip&${}#{}$&#\unskip\hfil & \quad\hfil #&#\unskip\hfil \cr \multispan{2}{\it Givet}&{} & {}&...
user avatar
0 votes
Accepted

CV symbol position alignment problem

Try this code for \cveventtt using parboxes. Adjust the relative size of the parboxes to your liking. \newcommand{\cveventtt}[4]{% {\large\color{emphasis}#1\par} \smallskip\normalsize \...
user avatar
  • 24.5k
3 votes
Accepted

Two column document in plain TeX

The macros \begmulti...\endmulti from OpTeX or OPmac does multicolumn typsetting in single case: it sets the material between \begmulti...\endmulti into a \vbox with \hsize=column_width and then it ...
user avatar
  • 52.2k
0 votes
Accepted

Indentation Wrong Second line in Titleframe Goettingen theme (Beamer)

You can insert the frame title in a parbox. For this theme, the sidebar has a width of 2 cm, so this \setbeamertemplate{frametitle}{\hspace{-0.4cm}\parbox{\dimexpr\linewidth-2cm}{\insertframetitle}} ...
user avatar
  • 24.5k
3 votes

Indentation in Beamer Frametitle

With that clues, the answer only can be "stop doing whatever you are doing to change the default output": \documentclass[12pt]{beamer} \usetheme{Goettingen} \begin{document} \begin{...
user avatar
  • 72.9k
2 votes
Accepted

Subtables won't center within threeparttable

With use of the talltblr (defined in the tabularray package) your table can be set without nesting subtables in table: \documentclass[12pt]{scrartcl} \usepackage[T1]{fontenc} \usepackage{xcolor} \...
user avatar
  • 251k
0 votes

Alignment of text nodes placed above paths and other issues in tikz qtree

As pure TikZ image. Shorter and simpler code: \documentclass[border = 0.2cm]{standalone} \usepackage{tikz} \usetikzlibrary{arrows.meta, positioning, shapes} \begin{...
user avatar
  • 251k
0 votes

References spilling out of margin in bibliography

In my case \newgeometry solved the problem. Something like this: \newgeometry{top=32mm, bottom=27mm, left=40mm,right=15mm} \bibliography{ref} also you can try this: %SHIFT HORIZONTAL MARGIN ON EVEN/...
user avatar
  • 1
1 vote

Align equations on different rows inside tabularray environment

Like this? One possibility is to split equations in two column and write them directly in the table: \documentclass{report} \usepackage[export]{adjustbox} \usepackage{tabularray} \UseTblrLibrary{...
user avatar
  • 251k

Top 50 recent answers are included