parent_url
stringlengths
41
46
parent_score
stringlengths
1
4
parent_body
stringlengths
25
35.5k
parent_user
stringlengths
37
42
parent_title
stringlengths
12
150
accepted
bool
2 classes
body
stringlengths
4
36.7k
score
stringlengths
1
4
user
stringlengths
37
42
answer_id
stringlengths
1
6
__index_level_0__
int64
0
322k
https://tex.stackexchange.com/questions/687901
1
I have a general question which I couldn't solve so far. It came up a few days ago, while I was trying to redefine the different parts of the footer of the [`scrlayer-scrpage` package](https://tex.stackexchange.com/questions/687594/how-to-find-macros-to-adjust-footer-lefoot-cefoot-etc-with-scrlayer-scrpage) (this still isn't solved for me). But i want to understand it in general. So far, I've read a lot of (basic) documentation (source2e, scrlayer-scrpage.dtx etc.) and still couldn't figure it out: In some command/environment-definitons there appear "elements" which have no backslash at the start of the name. For example the elements `even`, `left` and `foot` in the definition of the `\lefoot` command from `scrlayer-scrpage`: ``` $ latexdef -p scrlayer-scrpage -f lefoot \lefoot first defined in "scrlayer-scrpage.sty". \lefoot: macro:->\sls@renewelement {even}{left}{foot} ``` or the element `labelitem` (inside the curly brackets, first word) in the general definition of the `itemize` environment: ``` $ latexdef -f itemize \itemize is defined by (La)TeX. \itemize: macro:->\ifnum \@itemdepth >\thr@@ \@toodeep \else \advance \@itemdepth \@ne \edef \@itemitem {labelitem\romannumeral \the \@itemdepth }\expandafter \list \csname \@itemitem \endcsname {\def \makelabel ##1{\hss \llap {##1}}}\fi ``` How can i find out what they mean/how they are defined? So far, i have no real clue. I'm aware that the answer may be really simple, but right now I am at a loss... Thanks for all replies!
https://tex.stackexchange.com/users/297560
Function of "Elements" without Backslash in Command-Definitions
true
The `labelitem` in `\itemize` is literally just a string of characters. From `latex.ltx` you find ``` \def\itemize{% \ifnum \@itemdepth >\thr@@\@toodeep\else \advance\@itemdepth\@ne \edef\@itemitem{labelitem\romannumeral\the\@itemdepth}% \expandafter \list \csname\@itemitem\endcsname {\def\makelabel##1{\hss\llap{##1}}}% \fi} ``` The line `\edef\@itemitem{labelitem\romannumeral\the\@itemdepth}` sets the macro `\@itemitem` to take the value of the string `labelitem` followed by the lowercase Roman numeral representation of the current "depth" of the list. So if have a nested list and the second level is an `itemize`, you have `\@itemdepth` is equal to 2, in which case the line becomes `\edef\@itemitem{labelitemii}`. In other words, the macro `\@itemitem` is defined to be the string `labelitemii`. Now this by itself is not that useful, but if you scan down a couple lines, you find that it issues `\csname\@itemitem\endcsname` which expands to `\csname labelitemii\endcsname` in our example, which is equivalent to calling `\labelitemii` (that's the purpose of `\csname ... \endcsname`). This is an example of how you can build *variable names* programmatically in TeX (in many other programming languages something similar would perhaps be handled by using an "array" or a "dictionary", which concepts are absent in TeX). --- The `\sls@renewelement{even}{left}{foot}` functions similarly; basically it makes `\lefoot{SOMETHING}` equal to `\sls@renewelement{even}{left}{foot}{SOMETHING}`, and the definition of `\sls@renewelement{A}{B}{C}{SOMETHING}` builds an internal variable/macro whose name incorporates the strings `A`, `B`, and `C` (more precisely, in the case of `\lefoot` you get a macro named `\sls@ps@scrheadings@even@left@foot`) and sets it equal to `SOMETHING`.
3
https://tex.stackexchange.com/users/119
687903
319,129
https://tex.stackexchange.com/questions/687911
2
I admit that I am new to regex expressions. The `l3regex` module has a function `\regex_match:` that tests whether the regex (1st arg) matches any part of the token list (2nd arg). I'm curious if there is a function that tests whether the regex matches the entire, whole token list instead of a partial submatch(es). For example, let's say that I have a function that tests whether the input takes the form of either exactly 1 digit or exactly 2 digits. To knowledge, my first example function will correctly test whether this is true, but I feel this should be easier. (`ERROR` is just a placeholder error message.) My second example function will unfortunately set that the regex matches any token list with at least 1 digit, even if the token list cannot any non-digits (e.g. a letter). ``` \documentclass{article} \begin{document} \ExplSyntaxOn %first example function %\cs_new:Nn \mymodule_checkiftwodigits:n %{ % \str_set:Nx \l_tmpa_str { #1 } % \int_compare:nNnT { \str_count:N \l_tmpa_str } > { 2 } % { ERROR } % \str_map_inline:Nn \l_tmpa_str % { % \regex_match:nnTF { \d } { ##1 } % { MATCH } % { NO~ MATCH } % } %} %second example function \cs_new:Nn \mymodule_checkiftwodigits:n { \regex_match:nnTF { \d{1,2} } { #1 } { MATCH } { NO~ MATCH } } %\mymodule_checkiftwodigits:n {abc } \mymodule_checkiftwodigits:n {123}%incorrectly matches \par \mymodule_checkiftwodigits:n {1a}%incorrectly matches \par \mymodule_checkiftwodigits:n {abc}%correct %i understand that the \regex_match: function is working as intended. \ExplSyntaxOff \end{document} ```
https://tex.stackexchange.com/users/278534
l3regex regex whole match
true
If this was a standard (PCRE) regex, I would suggest anchoring the start and end, i.e. `^\d{1,2}$`. After a brief test, anchoring also works in l3regex. The code you want is: ``` \cs_new:Nn \mymodule_checkiftwodigits:n { \regex_match:nnTF { ^\d{1,2}$ } { #1 }% first parameter changed { MATCH } { NO~ MATCH } } ``` When I put this change into your document, it comes up with `NO MATCH` 3 times. Adding in a line `\mymodule_checkiftwodigits:n {56}` results in `MATCH`.
2
https://tex.stackexchange.com/users/244233
687912
319,131
https://tex.stackexchange.com/questions/687896
2
How does one turn the circular degree symbol \textdegree > > ° > > > into an equilateral triangle degree symbol? I am just very curious about this, I only know how to type up basic mathematics.
https://tex.stackexchange.com/users/298504
Triangle instead of circle in degrees
false
> > I was interested in an alternative symbol for the hypothetical > scenario where one full turn is defined to be something other than 360 > units. > > > Besides using other fonts, you may also draw your own symbols and use them like chracters. The code below: * uses `tikz` and one of its libraries `shapes.geometric`, which provides a `star` shape * the star can have other than 5 points and can degrade into a pentagon with its default of 5 beams * to simplify use I introduced a shortcut `\turn` * inside it simply draws and rescales the star `\tikz[scale=.5,transform shape]{\node[star,draw,star point height=7pt]{};}` * to highlight some typographical effects the document simply repeats some text for the star and the triangle ``` \documentclass[10pt,a4paper]{article} % ~~~ cfor reating visuals ~~~~~~~~~ \usepackage{tikz} \usetikzlibrary{shapes.geometric} % ~~~ shortcut ~~~~~~~~~~ \newcommand\turn[0]{\tikz[scale=.5,transform shape]{\node[star,draw,star point height=7pt]{};}} % ~~~ document ~~~~~~~~~~~~~~~~ \begin{document} Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. Some text using $15^{\turn}$. \bigskip Some text using $15^\triangle$. Some text using $15^\triangle$. Some text using $15^\triangle$. Some text using $15^\triangle$. Some text using $15^\triangle$. Some text using $15^\triangle$. Some text using $15^\triangle$. Some text using $15^\triangle$. Some text using $15^\triangle$. \end{document} ```
3
https://tex.stackexchange.com/users/245790
687921
319,133
https://tex.stackexchange.com/questions/600500
1
I am writing a book using the `dgruyter` package for style and the `covington` package for creating linguistic examples. Unfortunately, the examples are not obeying the margins and font sizes as defined in the style. Anyone know how to troubleshoot? Example code: ``` \documentclass[openany,nenglish]{book} \usepackage[medium,print]{dgruyter} \usepackage{lipsum} \usepackage{covington} \begin{document} \chapter{First chapter} \section{First section} \lipsum[2] \trigloss [ex,fsi={\normalfont\itshape}]{Bäne ekada eran?} {bəne eka=da era-n} {2.sg.poss language=nom cop.where-prs.sgS} {What (where) is your language?} \lipsum[2] \end{document} ```
https://tex.stackexchange.com/users/243539
Setting font size and margins for examples using covington and dgruyter
false
As of covington 2.1: ``` \setexampleoptions{leftmargin={8pt}} ``` With older versions (and still supported): ``` \setlength\exampleind{8pt} ``` (also documented in the `covington` manual)
1
https://tex.stackexchange.com/users/19291
687928
319,138
https://tex.stackexchange.com/questions/687935
4
I'm running a minimal, up-to-date TeX Live installation on Windows 11. I am trying to use `biblatex` and `biber` for bibliography management. The problem I am experiencing is that I must run `pdflatex` thrice to clear all warnings. I know that this is expected behaviour for *`bibtex`*; but my understanding was that *`biblatex`* only requires a single `pdflatex-biber-pdflatex` run to work. I have provided a MWE below with the contents of the two files, `demo.tex` and `refs.bib`: demo.tex -------- ``` \documentclass{article} \usepackage[backend=biber]{biblatex} \addbibresource{refs.bib} \begin{document} According to Smith \cite{smith99}, blah blah blah. \printbibliography \end{document} ``` refs.bib -------- ``` @book{smith99, title = {Clever Book Title}, author = {John Smith}, publisher = {Smith Publishing}, year = {1999} } ``` Here is my approach: I first run the command `pdflatex demo.tex`, and the terminal outputs these warnings: ``` LaTeX Warning: Citation 'smith99' on page 1 undefined on input line 6. LaTeX Warning: Empty bibliography on input line 8. LaTeX Warning: There were undefined references. Package biblatex Warning: Please (re)run Biber on the file: (biblatex) demo (biblatex) and rerun LaTeX afterwards. ``` Then, I run `biber demo` as instructed. There are no errors. Then, I run `pdflatex demo.tex` again, only to see the following warnings: ``` LaTeX Warning: There were undefined references. Package biblatex Warning: Please rerun LaTeX. ``` Which is odd, as the output PDF looks fine - it has the in-text numeric citation as well as the bibliography. When I run `pdflatex demo.tex` (for the third time), there are no warnings in the output. This behaviour is consistent across trials. I have tried running `pdflatex` without the file extension (`pdflatex demo`); I have tried different keys instead of `smith99`; I have tried other source types such as `online` or `article`, all to no avail. Both files are located in the folder `C:\demo`, and there are no other files in this directory. I have tried to isolate the problem as much as I possibly can, but `biblatex` tells me to rerun LaTeX every single time. I have also tried running `latexmk -pdf demo.tex`, and it runs `pdflatex-biber-pdflatex-pdflatex`. What is causing this problen? Any help is greatly appreciated. Thank you.
https://tex.stackexchange.com/users/298526
Package biblatex Warning: Please rerun LaTeX
false
Let's see, what happens while running LaTeX and Biber in your case: 1. While the first LaTeX run, LaTeX and `biblatex` do not have any information about the reference `smith99` and therefore LaTeX reports an undefined citation and an empty bibliography. `biblatex` warns to first run Biber and rerun LaTeX afterwards. But while this run, it also writes a `bcf` file with information about the requires resource and cite requests. 2. While the Biber run, it reads the `bcf` file and uses the information about cites and resources to generate a `bbl` file. 3. While this LaTeX run, `biblatex` reads the `bbl` file and uses the information to generate an often already valid PDF. But it cannot read some information like the reference context or the md5 checksum of the `bbl` file from the `aux` file (because Biber has not changed the `aux` file). So it reports, that there could still be changes, e.g., because the assumed reference context could be wrong. While the LaTeX run, it also writes a valid md5 checksum of the `bbl` file and some other information like the reference context to the `aux` file. 4. While this LaTeX run, `biblatex` can already compare the md5 checksum from the `aux` file with the md5 checksum of the found `bbl` file and the other information like the reference context. So (together with all references are found in the `bcf` file) now it knows, that no more LaTeX runs are needed. So as you can see, the last LaTeX run is not always needed to get a valid PDF, but it is at least needed, to make `biblatex` *knows*, that no more LaTeX (or Biber) run is needed. But this is not *always* the case. There could be a scenario, where step 4 is really needed to get a valid PDF.
6
https://tex.stackexchange.com/users/277964
687938
319,142
https://tex.stackexchange.com/questions/687935
4
I'm running a minimal, up-to-date TeX Live installation on Windows 11. I am trying to use `biblatex` and `biber` for bibliography management. The problem I am experiencing is that I must run `pdflatex` thrice to clear all warnings. I know that this is expected behaviour for *`bibtex`*; but my understanding was that *`biblatex`* only requires a single `pdflatex-biber-pdflatex` run to work. I have provided a MWE below with the contents of the two files, `demo.tex` and `refs.bib`: demo.tex -------- ``` \documentclass{article} \usepackage[backend=biber]{biblatex} \addbibresource{refs.bib} \begin{document} According to Smith \cite{smith99}, blah blah blah. \printbibliography \end{document} ``` refs.bib -------- ``` @book{smith99, title = {Clever Book Title}, author = {John Smith}, publisher = {Smith Publishing}, year = {1999} } ``` Here is my approach: I first run the command `pdflatex demo.tex`, and the terminal outputs these warnings: ``` LaTeX Warning: Citation 'smith99' on page 1 undefined on input line 6. LaTeX Warning: Empty bibliography on input line 8. LaTeX Warning: There were undefined references. Package biblatex Warning: Please (re)run Biber on the file: (biblatex) demo (biblatex) and rerun LaTeX afterwards. ``` Then, I run `biber demo` as instructed. There are no errors. Then, I run `pdflatex demo.tex` again, only to see the following warnings: ``` LaTeX Warning: There were undefined references. Package biblatex Warning: Please rerun LaTeX. ``` Which is odd, as the output PDF looks fine - it has the in-text numeric citation as well as the bibliography. When I run `pdflatex demo.tex` (for the third time), there are no warnings in the output. This behaviour is consistent across trials. I have tried running `pdflatex` without the file extension (`pdflatex demo`); I have tried different keys instead of `smith99`; I have tried other source types such as `online` or `article`, all to no avail. Both files are located in the folder `C:\demo`, and there are no other files in this directory. I have tried to isolate the problem as much as I possibly can, but `biblatex` tells me to rerun LaTeX every single time. I have also tried running `latexmk -pdf demo.tex`, and it runs `pdflatex-biber-pdflatex-pdflatex`. What is causing this problen? Any help is greatly appreciated. Thank you.
https://tex.stackexchange.com/users/298526
Package biblatex Warning: Please rerun LaTeX
false
The information you found on this site are partly deprecated. In particular [this answer](https://tex.stackexchange.com/a/13513) dates back to 2011 and indeed testing your example with a TL2013 installation confirms at that time there was no prompting at end of second run for one more run. But since then biblatex has evolved. Generally speaking anyhow 3 LaTeX runs is often needed: for example a `\tableofcontents` will typeset material only on second run. In `article` class this will quite probably cause a shift of material due to the injected TOC (less likely with `chapter` class as it uses a chapter-like rendering, doing a `\cleardoublepage`, and also the page numbering style can change from roman to arabic, so extra stuff in TOC does not cause page numbers of document to change). Generally speaking, any thing which happens on second run only as a result of first run having stored data in auxiliary files is susceptible to shift page numbering for some references, hence a third run is often necessary. Only simple documents need only 2 runs, not to speak of 1 run.
2
https://tex.stackexchange.com/users/293669
687940
319,144
https://tex.stackexchange.com/questions/687935
4
I'm running a minimal, up-to-date TeX Live installation on Windows 11. I am trying to use `biblatex` and `biber` for bibliography management. The problem I am experiencing is that I must run `pdflatex` thrice to clear all warnings. I know that this is expected behaviour for *`bibtex`*; but my understanding was that *`biblatex`* only requires a single `pdflatex-biber-pdflatex` run to work. I have provided a MWE below with the contents of the two files, `demo.tex` and `refs.bib`: demo.tex -------- ``` \documentclass{article} \usepackage[backend=biber]{biblatex} \addbibresource{refs.bib} \begin{document} According to Smith \cite{smith99}, blah blah blah. \printbibliography \end{document} ``` refs.bib -------- ``` @book{smith99, title = {Clever Book Title}, author = {John Smith}, publisher = {Smith Publishing}, year = {1999} } ``` Here is my approach: I first run the command `pdflatex demo.tex`, and the terminal outputs these warnings: ``` LaTeX Warning: Citation 'smith99' on page 1 undefined on input line 6. LaTeX Warning: Empty bibliography on input line 8. LaTeX Warning: There were undefined references. Package biblatex Warning: Please (re)run Biber on the file: (biblatex) demo (biblatex) and rerun LaTeX afterwards. ``` Then, I run `biber demo` as instructed. There are no errors. Then, I run `pdflatex demo.tex` again, only to see the following warnings: ``` LaTeX Warning: There were undefined references. Package biblatex Warning: Please rerun LaTeX. ``` Which is odd, as the output PDF looks fine - it has the in-text numeric citation as well as the bibliography. When I run `pdflatex demo.tex` (for the third time), there are no warnings in the output. This behaviour is consistent across trials. I have tried running `pdflatex` without the file extension (`pdflatex demo`); I have tried different keys instead of `smith99`; I have tried other source types such as `online` or `article`, all to no avail. Both files are located in the folder `C:\demo`, and there are no other files in this directory. I have tried to isolate the problem as much as I possibly can, but `biblatex` tells me to rerun LaTeX every single time. I have also tried running `latexmk -pdf demo.tex`, and it runs `pdflatex-biber-pdflatex-pdflatex`. What is causing this problen? Any help is greatly appreciated. Thank you.
https://tex.stackexchange.com/users/298526
Package biblatex Warning: Please rerun LaTeX
false
rerun messages don't need to be correct. E.g. this here issues a rerun message too: ``` \documentclass{article} \begin{document} \section{test}\label{test} \end{document} ``` LaTeX does detect here that the labels have changed, but doesn't check if this label is actually used and so if the change is relevant. Something similar happens in your example with biblatex (and also with other packages issuing rerun messages): it assumes wrongly that another compilation is needed. One could naturally try to refine such tests and catch these cases. The question is if it is worth the trouble: with a small document you save a compilation, but in real documents a second or third compilation is needed anyway and so you don't gain anything by making the tests more complicated (and slower).
4
https://tex.stackexchange.com/users/2388
687948
319,148
https://tex.stackexchange.com/questions/687946
0
Hi there i am going to post a MWE code, which probably has a few packages that arent needed for the MWE version but are used in my main file. I need to adjust 3 things in the generated table. The script which i am using has a a certain font for the numbers. This doesnt really bother me except for in Tables... and i cant find a way to fix it. Do you have any suggestions? Should i maybe use the same font for number as for the letters? Then i wouldnt need to put $$ around every number. But i dont wnat to change the font which is used in the Equation environment 1. In the caption the word "Table" has to be in bold 2. In the caption the number "1" after the world "Table" should be in an $$ environment. 3. Is there a way to make all values of the Table be in the $$ environment? My only solution right now is to put manually a $$ around every value. --- ``` \documentclass{article} \usepackage{amsmath} \usepackage{varwidth} \usepackage {caption} \usepackage{tabularray} \usepackage{array} \usepackage{multirow} \usepackage{pdflscape} \usepackage{rotating} \usepackage{amssymb} \usepackage[cochineal]{newtxmath} \usepackage[no-math]{fontspec} \setmainfont{Cochineal}[ Numbers={Proportional,OldStyle}, Style=Swash ] \DeclareSymbolFont{operators}{\encodingdefault}{\familydefault}{m}{n} \DeclareRobustCommand{\lfstyle}{\addfontfeatures{Numbers=Lining}} \DeclareTextFontCommand{\textlf}{\lfstyle} \DeclareRobustCommand{\tlfstyle}{\addfontfeatures{Numbers={Tabular,Lining}}} \DeclareTextFontCommand{\texttlf}{\tlfstyle} \AtBeginEnvironment{tabular}{% \tlfstyle } \AtBeginEnvironment{tabularx}{% \tlfstyle } \setsansfont[ Path = fonts/, BoldFont = Roboto-Bold.otf, ItalicFont = Roboto-Italic.otf, BoldItalicFont = Roboto-BoldItalic.otf, Scale = 0.83 ]{Roboto-Regular.otf} \renewcommand{\familydefault}{\rmdefault} \defaultfontfeatures{Ligatures=TeX} \begin{document} \begin{longtblr}[ caption = {Gitterschnittergebnisse der raumtemperaturgehärteten Proben PUA 2403 X, Y, Z, AA, AB und AC bei}, label = {tblr:GT RT}, ] {width=\linewidth,colspec={X[1,c]|X[1,c]|X[1,c]|X[1,c]|X[1,c]|X[1,c]|X[1,c]|X[1,c]}} \hline \textbf{PUA Nr.} & \textbf{Substrat} & \textbf{Blech Nr.} & \textbf{GT Nr. 1} & \textbf{GT Nr. 2} & \textbf{GT Nr. 3} & \textbf{Mittelwert} & \textbf{Stabw. S}\\ \hline \SetCell[r=4]{c} \rotatebox[origin=c]{90}{2403 X}& Oxsilan & 4 & 0 & 0 & 0 & 0 & 0\\\hline &Fe Phosphatiert & 1 &1 & 0 & 0 & 0 & 0 \\\hline &Zn Phosphatiert & 2 & 0 & 0 & 0 & 0 & 0 \\\hline &Gestrahltes Aluminium & 2 & 0 & 0 & 0 & 0 & 0 \\ \hline \end{longtblr} \end{document} ``` Thank you very much
https://tex.stackexchange.com/users/293330
How to adjust certain things in the Longtable
false
I fixed the problem Nr. 3 "Is there a way to make all values of the Table be in the $$ environment? My only solution right now is to put manually a $$ around every value." Solution: I added the command ``` \DeclareRobustCommand{\lfstyle}{\addfontfeatures{Numbers=Lining}} \DeclareTextFontCommand{\textlf}{\lfstyle} \DeclareRobustCommand{\tlfstyle}{\addfontfeatures{Numbers={Tabular,Lining}}} \DeclareTextFontCommand{\texttlf}{\tlfstyle} \AtBeginEnvironment{longtblr}{% \tlfstyle } ```
0
https://tex.stackexchange.com/users/293330
687950
319,149
https://tex.stackexchange.com/questions/687935
4
I'm running a minimal, up-to-date TeX Live installation on Windows 11. I am trying to use `biblatex` and `biber` for bibliography management. The problem I am experiencing is that I must run `pdflatex` thrice to clear all warnings. I know that this is expected behaviour for *`bibtex`*; but my understanding was that *`biblatex`* only requires a single `pdflatex-biber-pdflatex` run to work. I have provided a MWE below with the contents of the two files, `demo.tex` and `refs.bib`: demo.tex -------- ``` \documentclass{article} \usepackage[backend=biber]{biblatex} \addbibresource{refs.bib} \begin{document} According to Smith \cite{smith99}, blah blah blah. \printbibliography \end{document} ``` refs.bib -------- ``` @book{smith99, title = {Clever Book Title}, author = {John Smith}, publisher = {Smith Publishing}, year = {1999} } ``` Here is my approach: I first run the command `pdflatex demo.tex`, and the terminal outputs these warnings: ``` LaTeX Warning: Citation 'smith99' on page 1 undefined on input line 6. LaTeX Warning: Empty bibliography on input line 8. LaTeX Warning: There were undefined references. Package biblatex Warning: Please (re)run Biber on the file: (biblatex) demo (biblatex) and rerun LaTeX afterwards. ``` Then, I run `biber demo` as instructed. There are no errors. Then, I run `pdflatex demo.tex` again, only to see the following warnings: ``` LaTeX Warning: There were undefined references. Package biblatex Warning: Please rerun LaTeX. ``` Which is odd, as the output PDF looks fine - it has the in-text numeric citation as well as the bibliography. When I run `pdflatex demo.tex` (for the third time), there are no warnings in the output. This behaviour is consistent across trials. I have tried running `pdflatex` without the file extension (`pdflatex demo`); I have tried different keys instead of `smith99`; I have tried other source types such as `online` or `article`, all to no avail. Both files are located in the folder `C:\demo`, and there are no other files in this directory. I have tried to isolate the problem as much as I possibly can, but `biblatex` tells me to rerun LaTeX every single time. I have also tried running `latexmk -pdf demo.tex`, and it runs `pdflatex-biber-pdflatex-pdflatex`. What is causing this problen? Any help is greatly appreciated. Thank you.
https://tex.stackexchange.com/users/298526
Package biblatex Warning: Please rerun LaTeX
false
Just for comparison. If you are using OpTeX, then you need only two runs: `optex`-`optex` and no external program (like Biber) is needed. I used exactly the same `refs.bib` file as given in your question. And I prepared following `demo.tex` file: ``` \fontfam[lm] According to Smith \cite[smith99], blah blah blah. \usebib/s (iso690) refs \bye ``` Before the first run of `optex`, there is no `demo.ref` file (the `*.ref` file is something similar like LaTeX's `aux`, `toc`, `lof`, `lot`, `bbl` etc. files together, but it is only single file for all purposes). The first run of OpTeX reports: ``` This is LuaTeX, Version 1.17.0 (TeX Live 2023) restricted system commands enabled. (./demo.tex This is OpTeX (Olsak's Plain TeX), version <1.12+ May 2023> (/home/olsak/texmf/tex/optex/base/f-lmfonts.opm FONT: [Latin Modern] -- \LMfonts (TeX Gyre fonts based on Computer Modern) ...) WARNING l.3: {} \cite [smith99] unknown. Try to TeX me again. (/home/olsak/texmf/tex/optex/base/usebib.opm) (/home/olsak/texmf/tex/optex/base/bib-iso690.opm) (./refs.bib) OpTeX: Sorting \_citelist (en) ... WARNING l.5: Missing field "address" in [smith99]. WARNING l.5: Missing field "isbn" in [smith99]. [1...] WARNING l.7: Try to rerun, demo.ref file was created. Output written on demo.pdf (1 page, 9699 bytes). Transcript written on demo.log. ``` After this first run the pdf output looks like: > > According to Smith [??], blah blah blah. > > > [1] Smith, John. Clever Book Title. Smith Publishing, 1999. > > > It means that the `\cite` macro did know nothing about the `[smith99]` label and it printed ?? only. Moreover, it added the `[smith99]` label to the `\_citelist`. Then the macro `\usebib` reads the `refs.bib` file, finds the `[smith99]` label here (and maybe others used cite-labels in the document and accumulated in the `\_citelist` macro), then it sorts the `\_citelist` and finally it prints the `\_citelist` by formatting rules declared in the bib style file `bib-iso690.opm`. When printing, the numbers are assigned to the labels, so OpTeX knows, that `[smith99]` has the number 1. This information is saved to the `demo.ref` file. The second run starts by reading the `demo.ref` file and then the document is created. All needed information is known and the result is: ``` This is LuaTeX, Version 1.17.0 (TeX Live 2023) restricted system commands enabled. (./demo.tex This is OpTeX (Olsak's Plain TeX), version <1.12+ May 2023> (./demo.ref) (/home/olsak/texmf/tex/optex/base/f-lmfonts.opm FONT: [Latin Modern] -- \LMfonts (TeX Gyre fonts based on Computer Modern) ...) (/home/olsak/texmf/tex/optex/base/usebib.opm) (/home/olsak/texmf/tex/optex/base/bib-iso690.opm) (./refs.bib) OpTeX: Sorting \_citelist (en) ... WARNING l.5: Missing field "address" in [smith99]. WARNING l.5: Missing field "isbn" in [smith99]. [1...] Output written on demo.pdf (1 page, 9699 bytes). Transcript written on demo.log. ``` > > According to Smith [1], blah blah blah. > > > [1] Smith, John. Clever Book Title. Smith Publishing, 1999. > > > The md5sum checking of the `demo.ref` file is done at the end of the second run, but this file isn't changed, so we have no warning like this: ``` WARNING l.7: Try to rerun, demo.ref file was changed. ``` We can see only warnings about missing fields `address` and `isbn` because they are mandatory when `@book` entry is printed via `bib-iso690` style file.
1
https://tex.stackexchange.com/users/51799
687957
319,151
https://tex.stackexchange.com/questions/420304
3
I am trying to run some latex files on a new computer. I am using an external hard drive that is a direct copy of my previous computer so the files all should be fine, however I am getting the error: ``` Sorry, but "MiKTeX Compiler Driver" did not succeed. The log file hopefully contains the information to get MiKTeX going again: C:/Users/******/AppData/Local/MiKTeX/2.9/miktex/log/texify.log You may want to visit the MiKTeX project page, if you need help. ``` I have found lots of threads on this, but none of the solutions given have worked for me. I have tried deleting aux files and re-running, I have tried running from command prompt, I have tried uninstalling and reinstalling MiKTeX, I have tried running initexmf --mkmaps --verbose from the command prompt. The log file it directs me too reads as follows: ``` 2018-03-15 11:36:30,425Z INFO texify - starting with command line: "C:\Program Files\MiKTeX 2.9\miktex\bin\x64\texify.exe" --pdf --synctex=1 --clean warwickthesis.tex 2018-03-15 11:36:49,382Z FATAL texify - BibTeX failed for some reason. 2018-03-15 11:36:49,382Z FATAL texify - Info: 2018-03-15 11:36:49,382Z FATAL texify - Source: Programs\MiKTeX\texify\mcd.cpp 2018-03-15 11:36:49,382Z FATAL texify - Line: 1286 ``` I have since tried running just pdflatex - this works but obviously does not create references etc. Running just bibtex does not work and returns this in the blg file: ``` This is BibTeX, Version 0.99dThe top-level auxiliary file: warwickthesis.aux The style file: unsrt.bst Database file #1: library.bib Repeated entry---line 1242 of file library.bib : @article{Takishita2015 : , I'm skipping whatever remains of this entry Repeated entry---line 1396 of file library.bib : @article{Grassie2005 : , I'm skipping whatever remains of this entry Warning--I didn't find a database entry for "Haidemenopoulos2016" Warning--I didn't find a database entry for "Hughes2015" Warning--I didn't find a database entry for "Blitz1997" Warning--I didn't find a database entry for "Bieber1998" Warning--I didn't find a database entry for "Tian2005" Warning--I didn't find a database entry for "Mina1997" Warning--I didn't find a database entry for "Drinkwater2006" Warning--I didn't find a database entry for "Grimberg2006" Warning--I didn't find a database entry for "Edwards2008a" Warning--I didn't find a database entry for "Gros1999" Warning--I didn't find a database entry for "Hughes2014" Warning--I didn't find a database entry for "Honarvar2013" Warning--I didn't find a database entry for "Alvarez-Arenas2013" Warning--I didn't find a database entry for "Kang2017" ... etc (few more of these) Warning--empty journal in Ewert2013 Warning--can't use both author and editor fields in Achenbach1999 Warning--empty journal in Blake1990 Warning--empty note in Thring2018 (There were 2 error messages) ``` This is odd as the references are in my library created by Mendeley and the referencing works fine on a different computer. Any suggestions?
https://tex.stackexchange.com/users/157235
Sorry, but "MiKTeX Compiler Driver" did not succeed. FATAL texify - BibTeX failed for some reason
false
I had the same problem and after reading the comments, was because this 3 issues: 1. I wrote in the main: ``` \begin{thebibliography}{99} \bibliography{nameofbib} \bibliographystyle{abbrv} \end{thebibliography} ``` instead just the second line. 2. There were comments in the bib. 3. There were blank lines in the bib. Thanks all you guys
0
https://tex.stackexchange.com/users/298551
687973
319,155
https://tex.stackexchange.com/questions/687978
0
How do you use minted to render a code block in teletype font (monospace fixed width font) and all text is the same color (probably black)? What would you write if you wanted all text to be black inside of the code-block (no syntax highlighting. We do **not** want: ``` \usemintedstyle{perldoc} \usemintedstyle{colorful} ``` --- ``` \documentclass{article} \usepackage{minted} \usepackage{xcolor} \colorlet{myblack}{black!50!white} \begin{document} \section*{Minted styles with non-italic comments} \subsection*{Light theme} \subsubsection*{\texttt{perldoc}} \usemintedstyle{perldoc} \begin{minted}[linenos]{r} int main(): // Generate data const unsigned arraySize = 32768; // arraySize = 32768 // arraySize = const(unsigned(arraySize)) Array<int> data = Array<int>(arraySize); for (unsigned k = 0; k < arraySize; ++k) data[k] = k; // semi-colon ; and new line \n is redundant // \n\r; ... three consecutive infix operators // \r\n; ... three consecutive infix operators // \n; ... two consecutive infix operator // ; ... one consecutive infix operator // \n ... one consecutive infix operator //TO DO: randomize order // TO DO: TEST TIME FOR LINEAR Searchinf for // arraySize/2 data.sort(); // Equivalent to: // sort(data); // sort<<Array<int>>>(data); // sort<type(data)>(data); // TO DO: Binary Search Uni<float> start = Unitized<float>(clock(), "seconds"); Uni<float> current = Unitized<float>(clock(), "seconds"); // `Uni` is sub_sequence alias of `Unitized` // all sequence are allowed provided that // not exist two labels in current scope // such that alias is subsequence of both labels Uni<unsigned> = Uni<unsigned>duration(5, "min"); // most case-insensitive sub-sequences of "min" are allowed // as string inputs to the Unitized template constructor while (current - start < ideal_duration): // TO DO: // run binary search // count number of binary searches were done // ENGLISH: // promote integer to Unitized<insigned>("seconds") current = clock(); actual_duration = finish - start average_time = count/actual_duration // colon `:` at end of loop preamble // is redundant // // the following two things are the same // for():for() // for()for() // // the following two things are the same // pow:(10, 99) // pow(10, 99) // // colon is an infix delimieter (and comma, space, etc...) // // transition from alphanumeric chars to non-alphanumeric // is implicit infix delimeter // // `for` is a functor // --------------- // for(x)(y) // --------------- // f = for(x) // f(y) // --------------- std::cout << average_time << '\n'; //std::cout similar to // disp() // display() // print() // printf() // fprintf() \end{minted} \end{document} ```
https://tex.stackexchange.com/users/178952
How do you use minted to render a code block in monospaced font with all black text?
false
You could use the `bw` style for a black and white result (run `pygmentize -L styles` to get a list of all the default styles available): ``` % !TeX program = txs:///arara % arara: pdflatex: {synctex: on, interaction: nonstopmode, shell: yes} \documentclass{article} \usepackage{minted} \usepackage{xcolor} \colorlet{myblack}{black!50!white} %\selectcolormodel{gray} \begin{document} \section*{Minted styles with non-italic comments} \subsection*{Light theme} \subsubsection*{\texttt{perldoc}} \usemintedstyle{bw} \begin{minted}[linenos]{r} int main(): // Generate data const unsigned arraySize = 32768; // arraySize = 32768 // arraySize = const(unsigned(arraySize)) Array<int> data = Array<int>(arraySize); for (unsigned k = 0; k < arraySize; ++k) data[k] = k; // semi-colon ; and new line \n is redundant // \n\r; ... three consecutive infix operators // \r\n; ... three consecutive infix operators // \n; ... two consecutive infix operator // ; ... one consecutive infix operator // \n ... one consecutive infix operator //TO DO: randomize order // TO DO: TEST TIME FOR LINEAR Searchinf for // arraySize/2 data.sort(); // Equivalent to: // sort(data); // sort<<Array<int>>>(data); // sort<type(data)>(data); // TO DO: Binary Search Uni<float> start = Unitized<float>(clock(), "seconds"); Uni<float> current = Unitized<float>(clock(), "seconds"); // `Uni` is sub_sequence alias of `Unitized` // all sequence are allowed provided that // not exist two labels in current scope // such that alias is subsequence of both labels Uni<unsigned> = Uni<unsigned>duration(5, "min"); // most case-insensitive sub-sequences of "min" are allowed // as string inputs to the Unitized template constructor while (current - start < ideal_duration): // TO DO: // run binary search // count number of binary searches were done // ENGLISH: // promote integer to Unitized<insigned>("seconds") current = clock(); actual_duration = finish - start average_time = count/actual_duration // colon `:` at end of loop preamble // is redundant // // the following two things are the same // for():for() // for()for() // // the following two things are the same // pow:(10, 99) // pow(10, 99) // // colon is an infix delimieter (and comma, space, etc...) // // transition from alphanumeric chars to non-alphanumeric // is implicit infix delimeter // // `for` is a functor // --------------- // for(x)(y) // --------------- // f = for(x) // f(y) // --------------- std::cout << average_time << '\n'; //std::cout similar to // disp() // display() // print() // printf() // fprintf() \end{minted} \end{document} ```
1
https://tex.stackexchange.com/users/36296
687980
319,158
https://tex.stackexchange.com/questions/687978
0
How do you use minted to render a code block in teletype font (monospace fixed width font) and all text is the same color (probably black)? What would you write if you wanted all text to be black inside of the code-block (no syntax highlighting. We do **not** want: ``` \usemintedstyle{perldoc} \usemintedstyle{colorful} ``` --- ``` \documentclass{article} \usepackage{minted} \usepackage{xcolor} \colorlet{myblack}{black!50!white} \begin{document} \section*{Minted styles with non-italic comments} \subsection*{Light theme} \subsubsection*{\texttt{perldoc}} \usemintedstyle{perldoc} \begin{minted}[linenos]{r} int main(): // Generate data const unsigned arraySize = 32768; // arraySize = 32768 // arraySize = const(unsigned(arraySize)) Array<int> data = Array<int>(arraySize); for (unsigned k = 0; k < arraySize; ++k) data[k] = k; // semi-colon ; and new line \n is redundant // \n\r; ... three consecutive infix operators // \r\n; ... three consecutive infix operators // \n; ... two consecutive infix operator // ; ... one consecutive infix operator // \n ... one consecutive infix operator //TO DO: randomize order // TO DO: TEST TIME FOR LINEAR Searchinf for // arraySize/2 data.sort(); // Equivalent to: // sort(data); // sort<<Array<int>>>(data); // sort<type(data)>(data); // TO DO: Binary Search Uni<float> start = Unitized<float>(clock(), "seconds"); Uni<float> current = Unitized<float>(clock(), "seconds"); // `Uni` is sub_sequence alias of `Unitized` // all sequence are allowed provided that // not exist two labels in current scope // such that alias is subsequence of both labels Uni<unsigned> = Uni<unsigned>duration(5, "min"); // most case-insensitive sub-sequences of "min" are allowed // as string inputs to the Unitized template constructor while (current - start < ideal_duration): // TO DO: // run binary search // count number of binary searches were done // ENGLISH: // promote integer to Unitized<insigned>("seconds") current = clock(); actual_duration = finish - start average_time = count/actual_duration // colon `:` at end of loop preamble // is redundant // // the following two things are the same // for():for() // for()for() // // the following two things are the same // pow:(10, 99) // pow(10, 99) // // colon is an infix delimieter (and comma, space, etc...) // // transition from alphanumeric chars to non-alphanumeric // is implicit infix delimeter // // `for` is a functor // --------------- // for(x)(y) // --------------- // f = for(x) // f(y) // --------------- std::cout << average_time << '\n'; //std::cout similar to // disp() // display() // print() // printf() // fprintf() \end{minted} \end{document} ```
https://tex.stackexchange.com/users/178952
How do you use minted to render a code block in monospaced font with all black text?
false
First off, *don't* indent verbatim-like environments, because that indentation would be preserved in the output. Second, if you don't want special formatting, use `Verbatim`. ``` \documentclass{article} \usepackage{minted} \usepackage{fancyvrb} \usepackage{xcolor} \begin{document} \section*{Minted styles with non-italic comments} \begin{minted}[style=bw,linenos]{r} int main(): // Generate data const unsigned arraySize = 32768; // arraySize = 32768 // arraySize = const(unsigned(arraySize)) Array<int> data = Array<int>(arraySize); for (unsigned k = 0; k < arraySize; ++k) data[k] = k; // semi-colon ; and new line \n is redundant // \n\r; ... three consecutive infix operators // \r\n; ... three consecutive infix operators // \n; ... two consecutive infix operator // ; ... one consecutive infix operator // \n ... one consecutive infix operator \end{minted} \section*{Simple verbatim} \begin{Verbatim}[linenos] int main(): // Generate data const unsigned arraySize = 32768; // arraySize = 32768 // arraySize = const(unsigned(arraySize)) Array<int> data = Array<int>(arraySize); for (unsigned k = 0; k < arraySize; ++k) data[k] = k; // semi-colon ; and new line \n is redundant // \n\r; ... three consecutive infix operators // \r\n; ... three consecutive infix operators // \n; ... two consecutive infix operator // ; ... one consecutive infix operator // \n ... one consecutive infix operator \end{Verbatim} \end{document} ``` If you insist with `minted` and you want *all* listings to use `bw`, just issue `\usemintedstyle{bw}` in the preamble.
1
https://tex.stackexchange.com/users/4427
687981
319,159
https://tex.stackexchange.com/questions/687960
7
I changed to using `subfigure` inside figure. Now when I include more than 13 figures in one document, tex4ht gives ``` ! LaTeX Error: Counter too large. ``` Same document compiles OK with lualatex. I made MWE below to show this. I am using TL 2022 ``` \documentclass[12pt,titlepage]{article} \errorcontextlines=500 \usepackage{graphicx} \usepackage{subcaption} \usepackage{forloop} \newcommand{\R}{\begin{figure} \centering \begin{subfigure}{0.45\textwidth} \centering \includegraphics[width=\textwidth]{example-image-a} \caption{Solution plot} \end{subfigure}% \begin{subfigure}{0.45\textwidth} \centering \includegraphics[width=\textwidth]{example-image-b} \caption{Phase plot} \end{subfigure}% \end{figure}} \begin{document} %13 figures OK. 14 figure fails \newcounter{x} \forloop{x}{1}{\value{x} < 15}{%change this to 14 it works \R } \end{document} ``` Command used is ``` make4ht -ulm default -a debug index.tex "mathjax,htm" ``` gives ``` make4ht -ulm default -a debug index.tex "mathjax,htm" [INFO] mkparams: Output dir: [INFO] mkparams: Compiler: dvilualatex [INFO] mkparams: Latex options: -jobname='index' [INFO] mkparams: tex4ht.sty: xhtml,mathjax,htm,charset=utf-8 [INFO] mkparams: tex4ht: -cmozhtf -utf8 [INFO] mkparams: build_file: index.mk4 [INFO] mkparams: Output format: html5 [STATUS] make4ht: Conversion started [STATUS] make4ht: Input file: index.tex [INFO] make4ht: Using configuration file: /home/me/.config/make4ht/config.lua [INFO] mkutils: Using build file /home/me/.config/make4ht/config.lua [INFO] mkutils: Load extension common_domfilters [INFO] mkutils: Cannot open config file index.mk4 [INFO] make4ht-lib: setting param correct_exit [INFO] make4ht-lib: setting param correct_exit [INFO] make4ht-lib: setting param correct_exit [INFO] make4ht-lib: setting param ext [INFO] make4ht-lib: Adding: ext dvi [INFO] htlatex: LaTeX call: dvilualatex --interaction=errorstopmode -jobname='index' '\makeatletter\def\HCode{\futurelet\HCode\HChar}\def\HChar{\ifx"\HCode\def\HCode"##1"{\Link##1}\expandafter\HCode\else\expandafter\Link\fi}\def\Link#1.a.b.c.{\AddToHook{class/before}{\RequirePackage[#1,html]{tex4ht}}\let\HCode\documentstyle\def\documentstyle{\let\documentstyle\HCode\expandafter\def\csname tex4ht\endcsname{#1,html}\def\HCode####1{\documentstyle[tex4ht,}\@ifnextchar[{\HCode}{\documentstyle[tex4ht]}}}\makeatother\HCode xhtml,mathjax,htm,charset=utf-8,html5.a.b.c.\input "\detokenize{index.tex}"' This is LuaTeX, Version 1.15.1 (TeX Live 2023/dev) restricted system commands enabled. LaTeX2e <2022-11-01> patch level 1 L3 programming layer <2023-01-24> (./index.tex (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/tex4ht.sty) (/usr/local/texlive/2022/texmf-dist/tex/latex/base/article.cls Document Class: article 2022/07/02 v1.4n Standard LaTeX document class (/usr/local/texlive/2022/texmf-dist/tex/latex/base/size12.clo)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/usepackage.4ht) (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/graphicx.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/keyval.sty) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/graphics-hooks.4ht) (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/graphics.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/trig.sty) (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics-cfg/graphics.cfg) (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics-def/dvips.def))) (/usr/local/texlive/2022/texmf-dist/tex/latex/caption/subcaption.sty (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/caption-hooks.4ht) (/usr/local/texlive/2022/texmf-dist/tex/latex/caption/caption.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/caption/caption3.sty))) (/usr/local/texlive/2022/texmf-dist/tex/latex/forloop/forloop.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/base/ifthen.sty)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/tex4ht.4ht :::::::::::::::::::::::::::::::::::::::::: TeX4ht info is available in the log file :::::::::::::::::::::::::::::::::::::::::: ) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/tex4ht.sty l.864 --- TeX4ht warning --- nonprimitive \everypar --- --- needs --- tex4ht index --- (./index.tmp) (./index.xref) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht) (index.4tc) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/latex.4ht (/usr/local/texlive/2022/texmf-dist/tex/latex/base/fontenc.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/lm/t1lmr.fd)) (/usr/local/texlive/2022/texmf-dist/tex/generic/kastrup/binhex.tex) (/usr/local/texlive/2022/texmf-dist/tex/latex/base/tuenc.def) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/tuenc-luatex.4ht (/usr/local/texlive/2022/texmf-dist/tex/luatex/luatexbase/luatexbase.sty (/usr/local/texlive/2022/texmf-dist/tex/luatex/ctablestack/ctablestack.sty)) (/usr/local/texlive/2022/texmf-dist/tex/lualatex/luacode/luacode.sty (/usr/local/texlive/2022/texmf-dist/tex/generic/iftex/ifluatex.sty (/usr/local/texlive/2022/texmf-dist/tex/generic/iftex/iftex.sty))) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/mathjax-latex-4ht.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/fontmath.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/article.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/graphicx.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/graphics.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/dvips.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/subcaption.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/caption.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/ifthen.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/latex/l3backend/l3backend-dvips.def) (./index.aux) (/usr/local/texlive/2022/texmf-dist/tex/latex/base/ts1cmr.fd)17 nil [1] [2] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- 18 nil [3] [4] [5] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [6] [7] [8] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [9] [10] [11] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [12] [13] [14] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [15] [16] [17] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [18] [19] [20] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [21] [22] [23] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [24] [25] [26] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [27] [28] [29] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [30] [31] [32] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [33] [34] [35] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [36] [37] [38] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [39] [40] [41] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- ! LaTeX Error: Counter too large. See the LaTeX manual or LaTeX Companion for explanation. Type H <return> for immediate help. ... \GenericError ... \endgroup \@alph ...\or v\or w\or x\or y\or z\else \@ctrerr \fi \caption@labelformat@parens ...{\nobreakspace }(#2 ) \cap:ref #1->\cur:lbl {}#1 \Tag {\float:cnt cAp\capt:cnt }{\cur:th \:currentl... <argument> ...cap:ref {\csname fnum@\@subcaptype \endcsname } {\global \let \caption@tem... \sbox #1#2->\setbox #1\hbox {\color@setgroup #2 \color@endgroup } \caption@@@make ...tempa {gobble\caption@tempb }}} \ifdim \wd \@tempboxa =\z@... <argument> ...norespaces \caption@makeanchor {Solution plot}} } \sbox #1#2->\setbox #1\hbox {\color@setgroup #2 \color@endgroup } \caption@slc ...empboxa {\caption@@@make {#1}{#2}} \ifdim \wd \@tempboxa >\ca... <argument> ...eline \caption@multiline }{\caption@multiline } \caption@calcmargin \capti... \caption@box@none #1#2->#2 \caption@@make@ ...#2}}\caption@make@rightmargin } \caption@endhook \caption@@make ...ingroup \caption@@make@ {#1}{#2} \endgroup \caption@@make@e... \@makecaption ...@@make {\cap:ref {#1}}{\cptC: #2} \cptD: \caption@make@below <argument> ...norespaces \caption@makeanchor {Solution plot}} \par \caption@nobreak \cap... \caption@setfloatcapt #1->#1 \@caption ...page \@minipagetrue \@minipagefalse } \caption@end \R ...h ]{example-image-a}\caption {Solution plot} \end {subfigure}\begin {s... <argument> \R \par \addtocounter {x}{1}\forloop [1]{x}{\value {x}}{\value {x} < 15}{ \R \ \@firstoftwo #1#2->#1 l.30 } ? ``` Since I need to include 1,000's of figures, this limitation will not work for me. I think the problem started when I changed to using `\begin{subfigure}`. It seems there is limitation of number of subfigures in tex4ht in one document? I need to see if I can find a workaround. The question is: Why does the above fail in tex4ht and not in lualatex/pdf? ps. I am using the same setup as shown in [htlatex-and-subfigures](https://tex.stackexchange.com/questions/255826/htlatex-and-subfigures) in order to have side-by-side subfigures. This was from 2015. It works OK now in TL 2022 as is, but it fails when more than 13 figures are loaded. Link to [tex4ht bug tracking](https://puszcza.gnu.org.ua/bugs/index.php?603)
https://tex.stackexchange.com/users/14594
13 figures OK, 14 figures gives ! LaTeX Error: Counter too large. only with tex4ht and subfigure
false
The command to reset the subfigure counter would be `\setcounter{subfigure}{0}`. Placing it just after the `\begin{figure}` allows this to compile. Another fix is that it appears the bug doesn't happen if you add a `\caption` outside of the subfigure, but within the figure.
2
https://tex.stackexchange.com/users/107497
687995
319,163
https://tex.stackexchange.com/questions/687960
7
I changed to using `subfigure` inside figure. Now when I include more than 13 figures in one document, tex4ht gives ``` ! LaTeX Error: Counter too large. ``` Same document compiles OK with lualatex. I made MWE below to show this. I am using TL 2022 ``` \documentclass[12pt,titlepage]{article} \errorcontextlines=500 \usepackage{graphicx} \usepackage{subcaption} \usepackage{forloop} \newcommand{\R}{\begin{figure} \centering \begin{subfigure}{0.45\textwidth} \centering \includegraphics[width=\textwidth]{example-image-a} \caption{Solution plot} \end{subfigure}% \begin{subfigure}{0.45\textwidth} \centering \includegraphics[width=\textwidth]{example-image-b} \caption{Phase plot} \end{subfigure}% \end{figure}} \begin{document} %13 figures OK. 14 figure fails \newcounter{x} \forloop{x}{1}{\value{x} < 15}{%change this to 14 it works \R } \end{document} ``` Command used is ``` make4ht -ulm default -a debug index.tex "mathjax,htm" ``` gives ``` make4ht -ulm default -a debug index.tex "mathjax,htm" [INFO] mkparams: Output dir: [INFO] mkparams: Compiler: dvilualatex [INFO] mkparams: Latex options: -jobname='index' [INFO] mkparams: tex4ht.sty: xhtml,mathjax,htm,charset=utf-8 [INFO] mkparams: tex4ht: -cmozhtf -utf8 [INFO] mkparams: build_file: index.mk4 [INFO] mkparams: Output format: html5 [STATUS] make4ht: Conversion started [STATUS] make4ht: Input file: index.tex [INFO] make4ht: Using configuration file: /home/me/.config/make4ht/config.lua [INFO] mkutils: Using build file /home/me/.config/make4ht/config.lua [INFO] mkutils: Load extension common_domfilters [INFO] mkutils: Cannot open config file index.mk4 [INFO] make4ht-lib: setting param correct_exit [INFO] make4ht-lib: setting param correct_exit [INFO] make4ht-lib: setting param correct_exit [INFO] make4ht-lib: setting param ext [INFO] make4ht-lib: Adding: ext dvi [INFO] htlatex: LaTeX call: dvilualatex --interaction=errorstopmode -jobname='index' '\makeatletter\def\HCode{\futurelet\HCode\HChar}\def\HChar{\ifx"\HCode\def\HCode"##1"{\Link##1}\expandafter\HCode\else\expandafter\Link\fi}\def\Link#1.a.b.c.{\AddToHook{class/before}{\RequirePackage[#1,html]{tex4ht}}\let\HCode\documentstyle\def\documentstyle{\let\documentstyle\HCode\expandafter\def\csname tex4ht\endcsname{#1,html}\def\HCode####1{\documentstyle[tex4ht,}\@ifnextchar[{\HCode}{\documentstyle[tex4ht]}}}\makeatother\HCode xhtml,mathjax,htm,charset=utf-8,html5.a.b.c.\input "\detokenize{index.tex}"' This is LuaTeX, Version 1.15.1 (TeX Live 2023/dev) restricted system commands enabled. LaTeX2e <2022-11-01> patch level 1 L3 programming layer <2023-01-24> (./index.tex (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/tex4ht.sty) (/usr/local/texlive/2022/texmf-dist/tex/latex/base/article.cls Document Class: article 2022/07/02 v1.4n Standard LaTeX document class (/usr/local/texlive/2022/texmf-dist/tex/latex/base/size12.clo)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/usepackage.4ht) (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/graphicx.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/keyval.sty) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/graphics-hooks.4ht) (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/graphics.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics/trig.sty) (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics-cfg/graphics.cfg) (/usr/local/texlive/2022/texmf-dist/tex/latex/graphics-def/dvips.def))) (/usr/local/texlive/2022/texmf-dist/tex/latex/caption/subcaption.sty (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/caption-hooks.4ht) (/usr/local/texlive/2022/texmf-dist/tex/latex/caption/caption.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/caption/caption3.sty))) (/usr/local/texlive/2022/texmf-dist/tex/latex/forloop/forloop.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/base/ifthen.sty)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/tex4ht.4ht :::::::::::::::::::::::::::::::::::::::::: TeX4ht info is available in the log file :::::::::::::::::::::::::::::::::::::::::: ) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/tex4ht.sty l.864 --- TeX4ht warning --- nonprimitive \everypar --- --- needs --- tex4ht index --- (./index.tmp) (./index.xref) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht) (index.4tc) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/latex.4ht (/usr/local/texlive/2022/texmf-dist/tex/latex/base/fontenc.sty (/usr/local/texlive/2022/texmf-dist/tex/latex/lm/t1lmr.fd)) (/usr/local/texlive/2022/texmf-dist/tex/generic/kastrup/binhex.tex) (/usr/local/texlive/2022/texmf-dist/tex/latex/base/tuenc.def) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/tuenc-luatex.4ht (/usr/local/texlive/2022/texmf-dist/tex/luatex/luatexbase/luatexbase.sty (/usr/local/texlive/2022/texmf-dist/tex/luatex/ctablestack/ctablestack.sty)) (/usr/local/texlive/2022/texmf-dist/tex/lualatex/luacode/luacode.sty (/usr/local/texlive/2022/texmf-dist/tex/generic/iftex/ifluatex.sty (/usr/local/texlive/2022/texmf-dist/tex/generic/iftex/iftex.sty))) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/mathjax-latex-4ht.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/fontmath.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/article.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/graphicx.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/graphics.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/dvips.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/subcaption.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/caption.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/ifthen.4ht (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/unicode.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html4-math.4ht) (/usr/local/texlive/2022/texmf-dist/tex/generic/tex4ht/html5.4ht)) (/usr/local/texlive/2022/texmf-dist/tex/latex/l3backend/l3backend-dvips.def) (./index.aux) (/usr/local/texlive/2022/texmf-dist/tex/latex/base/ts1cmr.fd)17 nil [1] [2] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- 18 nil [3] [4] [5] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [6] [7] [8] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [9] [10] [11] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [12] [13] [14] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [15] [16] [17] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [18] [19] [20] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [21] [22] [23] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [24] [25] [26] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [27] [28] [29] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [30] [31] [32] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [33] [34] [35] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [36] [37] [38] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- l.30 --- TeX4ht warning --- File `"example-image-b.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- b.xbb" (no BoundingBox) --- [39] [40] [41] l.30 --- TeX4ht warning --- File `"example-image-a.xbb"' not found --- l.30 --- TeX4ht warning --- Cannot determine size of graphic in "example-image- a.xbb" (no BoundingBox) --- ! LaTeX Error: Counter too large. See the LaTeX manual or LaTeX Companion for explanation. Type H <return> for immediate help. ... \GenericError ... \endgroup \@alph ...\or v\or w\or x\or y\or z\else \@ctrerr \fi \caption@labelformat@parens ...{\nobreakspace }(#2 ) \cap:ref #1->\cur:lbl {}#1 \Tag {\float:cnt cAp\capt:cnt }{\cur:th \:currentl... <argument> ...cap:ref {\csname fnum@\@subcaptype \endcsname } {\global \let \caption@tem... \sbox #1#2->\setbox #1\hbox {\color@setgroup #2 \color@endgroup } \caption@@@make ...tempa {gobble\caption@tempb }}} \ifdim \wd \@tempboxa =\z@... <argument> ...norespaces \caption@makeanchor {Solution plot}} } \sbox #1#2->\setbox #1\hbox {\color@setgroup #2 \color@endgroup } \caption@slc ...empboxa {\caption@@@make {#1}{#2}} \ifdim \wd \@tempboxa >\ca... <argument> ...eline \caption@multiline }{\caption@multiline } \caption@calcmargin \capti... \caption@box@none #1#2->#2 \caption@@make@ ...#2}}\caption@make@rightmargin } \caption@endhook \caption@@make ...ingroup \caption@@make@ {#1}{#2} \endgroup \caption@@make@e... \@makecaption ...@@make {\cap:ref {#1}}{\cptC: #2} \cptD: \caption@make@below <argument> ...norespaces \caption@makeanchor {Solution plot}} \par \caption@nobreak \cap... \caption@setfloatcapt #1->#1 \@caption ...page \@minipagetrue \@minipagefalse } \caption@end \R ...h ]{example-image-a}\caption {Solution plot} \end {subfigure}\begin {s... <argument> \R \par \addtocounter {x}{1}\forloop [1]{x}{\value {x}}{\value {x} < 15}{ \R \ \@firstoftwo #1#2->#1 l.30 } ? ``` Since I need to include 1,000's of figures, this limitation will not work for me. I think the problem started when I changed to using `\begin{subfigure}`. It seems there is limitation of number of subfigures in tex4ht in one document? I need to see if I can find a workaround. The question is: Why does the above fail in tex4ht and not in lualatex/pdf? ps. I am using the same setup as shown in [htlatex-and-subfigures](https://tex.stackexchange.com/questions/255826/htlatex-and-subfigures) in order to have side-by-side subfigures. This was from 2015. It works OK now in TL 2022 as is, but it fails when more than 13 figures are loaded. Link to [tex4ht bug tracking](https://puszcza.gnu.org.ua/bugs/index.php?603)
https://tex.stackexchange.com/users/14594
13 figures OK, 14 figures gives ! LaTeX Error: Counter too large. only with tex4ht and subfigure
true
It seems that the `subfigure` counter doesn't reset at the beginning of each figure. Each `subfigure` environment updates it and prints as an alphabetic label. Once you run out of the letters in alphabet, you get this error, which is why you get this error once you use more than 26 subfigures. You can reset it automatically using this configuration file `subcaption.4ht`: ``` % subcaption.4ht (2021-07-04-09:13), generated from tex4ht-4ht.tex % Copyright 2021 TeX Users Group % % This work may be distributed and/or modified under the % conditions of the LaTeX Project Public License, either % version 1.3c of this license or (at your option) any % later version. The latest version of this license is in % http://www.latex-project.org/lppl.txt % and version 1.3c or later is part of all distributions % of LaTeX version 2005/12/01 or later. % % This work has the LPPL maintenance status "maintained". % % The Current Maintainer of this work % is the TeX4ht Project <http://tug.org/tex4ht>. % % If you modify this program, changing the % version identification would be appreciated. \immediate\write-1{version 2021-07-04-09:13} \NewConfigure{subfigure}{2} \ConfigureEnv{subfigure}{\a:subfigure}{\b:subfigure}{}{} \ConfigureEnv{subtable}{\a:subfigure}{\b:subfigure}{}{} \AddToHook{env/figure/begin}{\setcounter{subfigure}{0}} \AddToHook{env/table/begin}{\setcounter{subtable}{0}} \Hinput{subcaption} \endinput ``` The important code is this: ``` \AddToHook{env/figure/begin}{\setcounter{subfigure}{0}} \AddToHook{env/table/begin}{\setcounter{subtable}{0}} ``` It resets the counters for each figure and table, because `table` can have the same issue as `figure`. This is the result:
7
https://tex.stackexchange.com/users/2891
687996
319,164
https://tex.stackexchange.com/questions/687983
1
I'm a LaTeX beginner, so be patient with me. I want to add a blank page after the title page, without showing a page number. I want to suppress page numbers in the front matter only. I added `\thispagestyle{empty}`, but it doesn't give me the desired solution :( ``` \documentclass[12pt]{book} \usepackage[width=4.375in, height=7.0in, top=1.0in, papersize={5.5in,8.5in}]{geometry} \usepackage[pdftex]{graphicx} \usepackage{amsmath} \usepackage{amssymb} \usepackage{tipa} \usepackage{textcomp} \usepackage{fancyhdr} \pagestyle{fancy} \renewcommand{\chaptermark}[1]{\markboth{#1}{}} \renewcommand{\sectionmark}[1]{\markright{\thesection\ #1}} \fancyhf{} \fancyhead[LE,RO]{\bfseries\thepage} \fancyhead[LO]{\bfseries\rightmark} \fancyhead[RE]{\bfseries\leftmark} \renewcommand{\headrulewidth}{0.5pt} \renewcommand{\footrulewidth}{0pt} \addtolength{\headheight}{0.5pt} \setlength{\footskip}{0in} \renewcommand{\footruleskip}{0pt} \fancypagestyle{plain}{% \fancyhead{} \renewcommand{\headrulewidth}{0pt} } % %\parindent 0in \parskip 0.05in % \begin{document} \frontmatter % \chapter*{\Huge \center New Metaphysics } \thispagestyle{empty} %{\hspace{0.25in} \includegraphics{./ru_sun.jpg} } \section*{\huge \center Suresh Emre} \newpage \subsection*{\center \normalsize Copyright \copyright 2009 by Author} \subsection*{\center \normalsize All rights reserved.} \subsection*{\center \normalsize ISBN \dots} \subsection*{\center \normalsize \dots Publications} % \chapter*{\center \normalsize ...} % \tableofcontents % \mainmatter % \chapter{Subjectivation and Objectivation} % your text here In human history no philosopher or sage explained the cosmic mystery and the spiritual reality more rationally than Shrii Shrii Anandamurti (1921-1990) \cite{baba_books} \cite{anandamitra}. His rational outlook is truly inspiring. % \chapter{Description of the Principle} % your text here % \chapter{Creation of Cosmos as Objectivation} % your text here % \chapter{More on Cosmic Subjectivation} % your text here % \chapter{More on Multiplicity} % your text here % \chapter{Curvature} % your text here % \chapter{Creation of the Physical Universe} % your text here % \chapter{An Example from the Later Stages} % your text here % \backmatter % \begin{thebibliography}{99} \bibitem{baba_books} Books of Shrii Shrii Anandamurti (Prabhat Ranjan Sarkar): \\ http://shop.anandamarga.org/ \bibitem{anandamitra} Avtk. Ananda Mitra Ac., \emph{The Spiritual Philosophy of Shrii Shrii Anandamurti: A Commentary on Ananda Sutram}, Ananda Marga Publications (1991) \\ ISBN: 81-7252-119-7 \end{thebibliography} \end{document} ```
https://tex.stackexchange.com/users/298558
How to remove the page numbers in the front matter only
true
As soon as the document class was clearly identified as `book`, it became possible to offer a suggestion. `book` subdivides the document content into three distinct parts: `\frontmatter`, `\mainmatter`, and `\backmatter`, At each of these transitions, certain global changes are applied. At `\mainmatter`, the format of page numbers is changed from \roman`to`\arabic`, and the counter is reset to 1. Thus, declaring `\pagestyle{empty}` after `\frontmatter` is applied will be overridden safely at `\mainmatter`.
2
https://tex.stackexchange.com/users/579
688001
319,167
https://tex.stackexchange.com/questions/687857
1
According to [this answer](https://tex.stackexchange.com/a/287984/18401), `/pgf/number format/read comma as period` should be enough to plot data from data files which are using the comma as decimal separator instead of the period. But, as shown by the following MCE: ``` \begin{filecontents*}[overwrite]{data-periods.dat} x y 1.5 1 2.5 10 3.5 100 \end{filecontents*} \begin{filecontents*}[overwrite]{data-commas.dat} x y 2,5 1 3,5 10 4,5 100 \end{filecontents*} \documentclass{article} \usepackage{pgfplots} \pgfplotsset{compat=1.18} \begin{document} \begin{tikzpicture} \begin{axis} \addplot table [x=x,y=y] {data-periods.dat} ; \addplot table [x=x,y=y,/pgf/number format/read comma as period] {data-commas.dat} ; \end{axis} \end{tikzpicture} \end{document} ``` it doesn't work when processed with `lualatex` (it works like a charm with `pdflatex` and `xelatex`), the second plot being dropped because of: ``` NOTE: coordinate (--,--,--) [--](was (2,5,1,--) [--]) has been dropped because of a coordinate filter. NOTE: coordinate (--,--,--) [--](was (3,5,10,--) [--]) has been dropped because of a coordinate filter. NOTE: coordinate (--,--,--) [--](was (4,5,100,--) [--]) has been dropped because of a coordinate filter. Package pgfplots Warning: the current plot has no coordinates (or all have been filtered away) on input line 36. ``` Am I missing something? Edit ---- It's worth pointing out that the issue doesn't arise with `tikz`'s `datavisualization` library: the following MCE compiles like a charm with lualatex (LuaHBTeX, Version 1.17.0 (TeX Live 2023)). ``` \documentclass{article} \usepackage{tikz} \usetikzlibrary{datavisualization} \begin{document} \begin{tikzpicture} \datavisualization [school book axes, visualize as line] data [separator=\space] { x y 0.5 0 1.5 1 2.5 1 3.5 0 }; \end{tikzpicture} \pgfset{/pgf/number format/read comma as period} \begin{tikzpicture} \datavisualization [school book axes, visualize as line] data [separator=\space] { x y 0,5 0 1,5 1 2,5 1 3,5 0 }; \end{tikzpicture} \end{document} ```
https://tex.stackexchange.com/users/18401
pgf's 'read comma as period' doesn't work as expected with pgfplots and lualatex
true
The Manual for Package pgfplots (v1.18.1), sec. 6.3.1 "LUA" reads > > If you use `compat=1.12` (or newer) and compile your documents by means of `lualatex`, pgfplots activates its `lua backend`. This switch reduces the time to generate output files, especially for 3D plots. > > > `/pgfplots/lua backend=true|false` (initially `true`) > > > If `lua backend` is active and the document is processed by means of `lualatex`, `pgfplots` activates scalability and performance improvements which result in the same output as without it, but with less time and with a smarter memory management. > > > But as OP's example shown, `lua backend` doesn't always result in the same output as without it. `lua backend` will load an un-documented tikz-pgf library `luamath`, which replaces `pgfmath` math expression parser with a lua-based new one. Unfortunately, this lua-based parser doesn't support `/pgf/number format/read comma as period`. `tikz` itself doesn't load `luamath` by default, hence it's less likely that the same problem is found in (simple or natural) `tikz` examples. I've reported this to `pgf` see its [issue #1263](https://github.com/pgf-tikz/pgf/issues/1263). Below is a patch copied from my comment under [`pgfplots` issue #452](https://github.com/pgf-tikz/pgfplots/issues/452), which essentially reported the same problem as the current tex-sx question. Please note that I know very little about `pgfplots` internals, hence the patch below is very specific to the case in hand. It's not a general solution to the root problem "`luamath` doesn't support `/pgf/number format/read comma as period`." ``` % !TeX program = lualatex \begin{filecontents}[noheader,force]{data-periods.dat} x y 1.5 1 2.5 10 3.5 100 \end{filecontents} \begin{filecontents}[noheader,force]{data-commas.dat} x y 2,5 1 3,5 10 4,5 100 \end{filecontents} \documentclass{article} \usepackage{pgfplots} \pgfplotsset{compat=1.18} \makeatletter \def\pgfplots@LUA@survey@point{% \ifpgfmathparsenumber@comma@as@period % Assume each point is a single number without any math function calls. % Only then is reading comma as period unambiguous. \edef\pgfplots@loc@TMPa{pgfplots.texSurveyPoint(% gsub("\pgfplots@current@point@x", ",", "."),% gsub("\pgfplots@current@point@y", ",", "."),% gsub("\pgfplots@current@point@z", ",", "."),% "\pgfplots@current@point@meta")}% \pgfplotsutil@directlua{% gsub = string.gsub \pgfplots@loc@TMPa }% \else \edef\pgfplots@loc@TMPa{pgfplots.texSurveyPoint(% "\pgfplots@current@point@x",% "\pgfplots@current@point@y",% "\pgfplots@current@point@z",% "\pgfplots@current@point@meta")}% \pgfplotsutil@directlua{\pgfplots@loc@TMPa}% \fi % increase \pgfplots@current@point@coordindex: \advance\c@pgfplots@coordindex by1 }% \makeatother \begin{document} \begin{tikzpicture} \begin{axis} \addplot table [x=x,y=y] {data-periods.dat} ; \addplot table [x=x,y=y,/pgf/number format/read comma as period] {data-commas.dat} ; \end{axis} \end{tikzpicture} \end{document} ```
2
https://tex.stackexchange.com/users/79060
688009
319,170
https://tex.stackexchange.com/questions/688000
2
For my template I want to create possibility to define a number of authors and automatically create a respective number of variables/commands which save the name of any author and make it able to print them later. The code has to be in the preamble. For creating different variables/commands of the kind `\varname{...}` which can be printed with `\printvarname`, I, rather randomly, found the following code [here on tex.SE](https://tex.stackexchange.com/questions/47437/resettable-variables) which works fine: ``` \makealetter \newcommand{\NewVariable}[1]{% \expandafter\newcommand\csname #1\endcsname[1]{\@namedef{@#1}{##1}} \@namedef{@#1}{} \expandafter\newcommand\csname print#1\endcsname{% \ifthenelse{\equal{\csname @#1\endcsname}{}}{}{\csname @#1\endcsname}} } \makeatother ``` Now I want to create a loop which automatically creates a predefined number of these commands of the syntax `\authorone`, `\authortwo` etc. For the definition of the numbers of authors I use a simple command: `\newcommand{\setauthors}[1]{\def\numauthors{#1}}`. One problem seems to be that a commandname can't take integers, but i need integers to define the number of authors. So i use the `fmtcount` package to convert them into words. I tried different approaches from this website (`foreach`, `@for`, `xintFor`), but couldn't get one to work properly. Here is a MWE with some approaches. I commented my test loops and added a simple example how it should be used: ``` \documentclass[% ]{article} \usepackage[T1]{fontenc} \usepackage{ifthen} \makeatletter % command to set multiple persistent variables with content \newcommand{\NewVariable}[1]{% \expandafter\newcommand\csname #1\endcsname[1]{\@namedef{@#1}{##1}} \@namedef{@#1}{} \expandafter\newcommand\csname print#1\endcsname{% \ifthenelse{\equal{\csname @#1\endcsname}{}}{}{\csname @#1\endcsname}} } \makeatother \usepackage{pgffor} \usepackage{fmtcount} % to convert integers in words: e.g. 1 into one \usepackage{xinttools} \newcommand{\setauthors}[1]{\def\numauthors{#1}} \setauthors{3} %set number of authors %\foreach \x in {1,...,\numauthors}{% % \NewVariable{author\numberstringnum{\x}} % } %\xintFor #1 in {\xintSeq{1}{\numauthors}} \do {\NewVariable{author\numberstringnum{#1}}} % also tried the starred version \xintFor* %\makeatletter % I know the definition of a range from 1 to \numauthors is not correct, its just a placeholder %\@for\authorcount:1,...,\numauthors\do{\NewVariable{author\numberstringnum{\authorcount}}} %\makeatother \NewVariable{authorone} % example for defined variable/command and how it should work \authorone{Jimmy Buckets} \begin{document} \printauthorone \end{document} ``` There seem to be much more variants of loops from other packages (also `expl3` versions, which I understand even less), but I would prefer a solution with a minimum on required extra packages. Nevertheless, in the end it's important that it works. The future user should only add a number to `\setauthors` and fill out the generated author variables. All other stuff should be automated. It may also be an option to asign the authornumber to an array first... I guess it's an expansion problem of the nested commands (`NewVariable`, `numberstring...`, *loop*). Unfortunately, the expansion sequence/order still remains a sealed book for me, because it differs so much from most programming languages I'm (a little bit) used to. **EDIT** To use @Alans great answer including the orcid. The `expl3` command `\cs_new_protected:Nn \l_lukeflo_get_orcid:n` for creating a valid Orcid works better using a pre-defined command for getting the Orcid link including the symbol: ``` \usepackage{orcidlink} \newcommand{\orcidid}[1]{\orcidlink{#1}\space\href{https://orcid.org/#1}{#1}} ... \cs_new_protected:Nn \l_lukeflo_get_orcid:n { \tl_set:Nx \l_tmpa_tl {\seq_item:Nn \l_lukeflo_orcid_seq {#1}} \orcidid{\l_tmpa_tl}\par } ``` Otherwise, `href` will add an unnecessary `.pdf` extension to the link. See my comments below Alans answer. I am already grateful for your help
https://tex.stackexchange.com/users/297560
How to use loop for creating defined number of newcommands counting authors
false
**Problem 1:** You use the package fmtcount whose macros don't work in the preamble due to multi-language support where language is to be detected at the begin of the document-environment. **Problem 2:** pgffor's `\foreach` does every iteration in a local scope, so macro-definitions don't survive outside `\foreach`. **Problem 3:** You need to handle the circumstance that `\NewVariable` doesn't expand its argument when passing it to the replacement-text of a `\newcommand` where it is not carried out immediately but at the time when the command defined in terms of `\newcommand` is carried out. **Problem 4:** The snippet ``` \@namedef{@#1}{} \expandafter\newcommand\csname print#1\endcsname{% \ifthenelse{\equal{\csname @#1\endcsname}{}}{}{\csname @#1\endcsname}} ``` seems somewhat pointless: The control-sequence coming from `\csname @#1\endcsname` is initialized empty. The `\print...`-command via `\ifthenelse` checks whether that control-sequence delivers emptiness and if so via branching delivers emptiness, which could as well come from expanding that control-sequence, without checking. ;-) --- --- I understand that you prefer commands to strings denoting names of variables: Commands are not affected by things like `\uppercase`/`lowercase` while strings denoting names of variables might be. (E.g. `\uppercase` might turn a variablename-string "author 1" into "AUTHOR 1", which might be a problem.) --- If you don't mind defining variables inside the document-environment, you can try s.th. like this: ``` \documentclass[% ]{article} \usepackage{xinttools} \usepackage{fmtcount} \FCloadlang{english} % command to set multiple persistent variables with content \makeatletter \@ifdefinable\NewVariable{% \DeclareRobustCommand{\NewVariable}[1]{% \expandafter\@NewVariable \csname #1\expandafter\endcsname \csname @#1\expandafter\endcsname \csname print#1\endcsname {#1}% }% }% \newcommand\@NewVariable[4]{% \newcommand#1[1]{\renewcommand*{#2}{##1}}% \newcommand*#2{}% % In the \else-branch you could have an error-message about undefined variable #4. \newcommand*#3{\ifdefined#2\else\expandafter\@gobble\fi#2}% }% \makeatother \begin{document} \newcommand{\setauthors}[1]{\def\numauthors{#1}}% \setauthors{3}% set number of authors \xintFor* #1 in {\xintSeq{1}{\numauthors}} \do {% \storenumberstringnum{scratchy}{#1}% \NewVariable{author\FMCuse{scratchy}}% }% \authorone{Me} \authortwo{myself} \authorthree{I} \printauthorone, {\printauthortwo} and \printauthorthree. \end{document} ``` But I don't like this because this way names of control sequences depend on the language in use while introducing variables so that you need to ensure proper language setting whenever introducing another variable. --- If you don't mind having strings denoting variable-names and loading the package textcase and using that package's command `\NoCaseChange` for preventing `\MakeUppercase`/`\MakeLowercase` changing letter-casing of names of variables in those edge situations where this might be needed, then you can do s.th. like this: ``` \documentclass{article} \makeatletter %%=============================================================================== %% Obtain control sequence token from name of control sequence token: %%=============================================================================== %% \CsNameToCsToken<stuff not in braces>{NameOfCs} %% -> <stuff not in braces>\NameOfCs %% (<stuff not in braces> may be empty.) \@ifdefinable\CsNameToCsToken{% \long\def\CsNameToCsToken#1#{\romannumeral\InnerCsNameToCsToken{#1}}% }% \newcommand\InnerCsNameToCsToken[2]{% \expandafter\Exchange\expandafter{\csname#2\endcsname}{\@stopromannumeral#1}% }% \@ifdefinable\@stopromannumeral{\chardef\@stopromannumeral=`\^^00}% \newcommand\Exchange[2]{#2#1}% \makeatother \CsNameToCsToken\newcommand*{Author 1}{Me} \CsNameToCsToken\newcommand*{Author 2}{MYSELF} \CsNameToCsToken\newcommand*{Author 3}{I} \begin{document} \CsNameToCsToken{Author 1}, \MakeLowercase{\CsNameToCsToken{Author 2}} and \CsNameToCsToken{Author 3}. \CsNameToCsToken\renewcommand*{Author 1}{Myself} \CsNameToCsToken\renewcommand*{Author 2}{I} \CsNameToCsToken\renewcommand*{Author 3}{me} \CsNameToCsToken{Author 1}, \CsNameToCsToken{Author 2} and \CsNameToCsToken{Author 3}. \end{document} ``` --- If you need to maintain a database with records of data for each author, consider using the package [datatool](https://ctan.org/pkg/datatool).
1
https://tex.stackexchange.com/users/118714
688010
319,171
https://tex.stackexchange.com/questions/413112
2
I am looking for a way, to draw lines in a given matrix, that connect two chosen entries. So, for example I would like to use ``` \begin{pmatrix} 1 & 2 \\ 3 & 4\end{pmatrix} ``` to initiate the 2x2-matrix with entries 1,2,3,4 and draw a line from 1 to 4 and a line from 3 to 2 within or rather over this matrix. I would also be interested in drawing such lines in a matrix, whose entries simply are dots. Thanks a lot!
https://tex.stackexchange.com/users/153906
How to connect entries of a matrix with lines?
false
With `{NiceTabular}` of `nicematrix`. ``` \documentclass{article} \usepackage{nicematrix} \usepackage{tikz} \begin{document} $\begin{pNiceMatrix} 1 & 2 \\ 3 & 4 \CodeAfter \tikz \draw (1-1) -- (2-2) (1-2) -- (2-1) ; \end{pNiceMatrix}$ \end{document} ```
1
https://tex.stackexchange.com/users/163000
688020
319,173
https://tex.stackexchange.com/questions/133206
6
So I basically create all my tables in Excel and then transfer to Texnic Center by using the Excel2LaTeX addin for Excel. I am not too familiar with adjusting the outputted code to my own likings. For example, I have the following table (directly from Excel2LaTeX): ``` \begin{table}[htbp] \centering \caption{Add caption} \begin{tabular}{ccccccc} \toprule Dependent variable: & $CoJPoD_{system|sov}$ & & $\Delta$$CoJPoD_{system|sov}$ & & $CoJPoD_{sov|system}$ & \\ \midrule & & & & & & \\ & \textbf{(1)} & \textbf{(2)} & \textbf{(3)} & \textbf{(4)} & \textbf{(5)} & \textbf{(6)} \\ & & & & & & \\ Constant & -11.116*** & -10.045*** & -6.668*** & -5.597*** & 13.194*** & 13.938*** \\ & (-2.934) & (-3.540) & (-2.939) & (-3.000) & (3.584) & (3.556) \\ Market Ret (6 months) (\%) & 0.001*** & & 0.001*** & & 0.000 & \\ & (3.022) & & (3.645) & & (-0.016) & \\ Market Vol (6 months) (\%) & 0.008 & & 0.009 & & 0.008 & \\ & (0.686) & & (1.127) & & (0.458) & \\ Market Ret (1 month) (\%) & & 0.013** & & 0.010** & & -0.021*** \\ & & (2.010) & & (2.171) & & (-2.723) \\ Market Vol (1 month) (\%) & & -1.949*** & & -1.629*** & & -0.051 \\ & & (-4.682) & & (-5.221) & & (-0.063) \\ Log GDP & 0.913*** & 0.826*** & 0.550*** & 0.463*** & -1.180*** & -1.242*** \\ & (2.882) & (3.470) & (2.919) & (2.943) & (-3.824) & (-3.764) \\ Debt/GDP (\%) & 0.004*** & 0.004*** & 0.002* & 0.002 & 0.004* & 0.004* \\ & (2.796) & (2.825) & (1.953) & (1.949) & (1.750) & (1.730) \\ Reserve/Debt (\%) & 0.0689** & 0.071** & 0.043** & 0.045* & 0.075** & 0.072** \\ & (2.478) & (2.322) & (2.101) & (1.919) & (2.371) & (2.325) \\ Term Spread (\%) & 0.0423*** & 0.041*** & 0.038*** & 0.037*** & 0.012 & 0.015** \\ & (6.244) & (6.984) & (7.033) & (7.261) & (1.312) & (2.154) \\ VSTOXX (\%) & 0.004*** & 0.003*** & 0.003*** & 0.002*** & 0.008*** & 0.007868*** \\ & (4.853) & (4.192) & (4.389) & (3.737) & (7.545) & (7.848) \\ & & & & & & \\ Bank fixed effects & Yes & Yes & Yes & Yes & Yes & Yes \\ No. of observations & 620 & 620 & 620 & 620 & 620 & 620 \\ Adjusted $R^2$ & 0.728 & 0.719 & 0.774 & 0.760 & 0.822 & 0.822 \\ \bottomrule \end{tabular} \label{tab:addlabel} \end{table} ``` Basically, the table is too wide to fit onto a portrait page (I do not want to use landscape). I see that there is quite a wide gap between each column, is there a way for me to reduce the gap between columns? Thanks.
https://tex.stackexchange.com/users/29810
How to make width of columns in table smaller
false
For guys looking for center align while shrinking margins, add: ``` \usepackage{array} \newcolumntype{C}[1]{>{\centering\let\newline\\\arraybackslash\hspace{0pt}}m{#1}} \begin{table} \begin{tabular}{C{1cm}C{1cm}} test for this & test for this \end{tabular} \end{table} ```
0
https://tex.stackexchange.com/users/232970
688021
319,174
https://tex.stackexchange.com/questions/688017
2
I am using fbox together with minipage, inside the minipage I have multicols and enumerate environments. Its not a big issue but I noticed the boxes are not aligned on the right. I tried using \linewidth instead of \textwidth but I still get the same results. Any ideas or suggestions on how to align the boxes on both the left and the right? Below is the MWE. ``` \documentclass[a4paper]{exam} \usepackage{multicol} \begin{document} \small \subsection*{Answer sheet} \noindent\textsc{Name:} $\rule{2.9in}{0.15mm}$\hfill\textsc{Student Number:} $\rule{1.5in}{0.15mm}$ \vspace{2mm} \\ \noindent\textsc{Instructor:} $\rule{2.6in}{0.15mm} $\hfill\textsc{Class Section: }$\rule{1.5in}{0.15mm}$ \normalsize \newline \\ \fbox{ \begin{minipage}{0.5\textwidth} \vspace{1mm} \textbf{Part 1. Matching type.} \begin{multicols}{2} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}}% \fbox{ \begin{minipage}{0.5\textwidth} \vspace{1mm} \textbf{Part 2. True or False.} \begin{multicols}{2} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}} \newline \fbox{ \begin{minipage}{1.0\textwidth} \vspace{1mm} \textbf{Part 3. Multiple Choice.} \begin{multicols}{3} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}} \newline \fbox{ \begin{minipage}{1.0\textwidth} \vspace{1mm} \textbf{Part 4. Problem 1. Fill in the blanks.} \begin{enumerate} \item [(a)] \item [(b)] \item [(c)] \item [(d)] \item [(e)] \end{enumerate} \vspace{1mm} \end{minipage} } \newline \fbox{ \begin{minipage}{1.0\textwidth} \vspace{1mm} \textbf{Part 4. Problem 2. Fill in the blanks.} \begin{enumerate} \item [(a)] \item [(b)] \item [(c)] \item [(d)] \item [(e)] \item [(f)] \end{enumerate} \vspace{1mm} \end{minipage} } \end{document} ```
https://tex.stackexchange.com/users/202354
Right alignment of minipages inside fbox
false
Not a guru solution, only a trial and error one: Code (little corrections of proposed code): ``` \documentclass[a4paper]{exam} \usepackage{multicol} \begin{document} \small \subsection*{Answer sheet} \noindent\textsc{Name:} $\rule{2.9in}{0.15mm}$\hfill\textsc{Student Number:} $\rule{1.5in}{0.15mm}$ \vspace{2mm} \\ \noindent\textsc{Instructor:} $\rule{2.6in}{0.15mm} $\hfill\textsc{Class Section: }$\rule{1.5in}{0.15mm}$ \normalsize \newline \\ \fbox{ \begin{minipage}{7.98cm} \vspace{1mm} \textbf{Part 1. Matching type.} \begin{multicols}{2} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}}% \fbox{ \begin{minipage}{7.98cm} \vspace{1mm} \textbf{Part 2. True or False.} \begin{multicols}{2} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}} \newline \fbox{ \begin{minipage}{16.31 cm} \vspace{1mm} \textbf{Part 3. Multiple Choice.} \begin{multicols}{3} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}} \newline \fbox{ \begin{minipage}{16.2cm} \vspace{1mm} \textbf{Part 4. Problem 1. Fill in the blanks.} \begin{enumerate} \item [(a)] \item [(b)] \item [(c)] \item [(d)] \item [(e)] \end{enumerate} \vspace{1mm} \end{minipage} } \newline \fbox{ \begin{minipage}{16.2cm} \vspace{1mm} \textbf{Part 4. Problem 2. Fill in the blanks.} \begin{enumerate} \item [(a)] \item [(b)] \item [(c)] \item [(d)] \item [(e)] \item [(f)] \end{enumerate} \vspace{1mm} \end{minipage} } \end{document} ```
2
https://tex.stackexchange.com/users/24644
688029
319,178
https://tex.stackexchange.com/questions/688017
2
I am using fbox together with minipage, inside the minipage I have multicols and enumerate environments. Its not a big issue but I noticed the boxes are not aligned on the right. I tried using \linewidth instead of \textwidth but I still get the same results. Any ideas or suggestions on how to align the boxes on both the left and the right? Below is the MWE. ``` \documentclass[a4paper]{exam} \usepackage{multicol} \begin{document} \small \subsection*{Answer sheet} \noindent\textsc{Name:} $\rule{2.9in}{0.15mm}$\hfill\textsc{Student Number:} $\rule{1.5in}{0.15mm}$ \vspace{2mm} \\ \noindent\textsc{Instructor:} $\rule{2.6in}{0.15mm} $\hfill\textsc{Class Section: }$\rule{1.5in}{0.15mm}$ \normalsize \newline \\ \fbox{ \begin{minipage}{0.5\textwidth} \vspace{1mm} \textbf{Part 1. Matching type.} \begin{multicols}{2} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}}% \fbox{ \begin{minipage}{0.5\textwidth} \vspace{1mm} \textbf{Part 2. True or False.} \begin{multicols}{2} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}} \newline \fbox{ \begin{minipage}{1.0\textwidth} \vspace{1mm} \textbf{Part 3. Multiple Choice.} \begin{multicols}{3} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}} \newline \fbox{ \begin{minipage}{1.0\textwidth} \vspace{1mm} \textbf{Part 4. Problem 1. Fill in the blanks.} \begin{enumerate} \item [(a)] \item [(b)] \item [(c)] \item [(d)] \item [(e)] \end{enumerate} \vspace{1mm} \end{minipage} } \newline \fbox{ \begin{minipage}{1.0\textwidth} \vspace{1mm} \textbf{Part 4. Problem 2. Fill in the blanks.} \begin{enumerate} \item [(a)] \item [(b)] \item [(c)] \item [(d)] \item [(e)] \item [(f)] \end{enumerate} \vspace{1mm} \end{minipage} } \end{document} ```
https://tex.stackexchange.com/users/202354
Right alignment of minipages inside fbox
true
* Mini pages width widths are to big. At defining them you should considered `\fboxsep` and `\fboxrule` and accordingly reduce thair widths- * Code lines (in MWE marked by `<---`) at end of `\end{minipage}}` and `\fbox{` should be terminated by `%` \end{minipage}}. Considering above mentioned, your MWE should be: ``` \documentclass[a4paper]{exam} \usepackage{multicol} \begin{document} \small \subsection*{Answer sheet} \noindent\textsc{Name:} $\rule{2.9in}{0.15mm}$\hfill\textsc{Student Number:} $\rule{1.5in}{0.15mm}$ \vspace{2mm} \\ \noindent\textsc{Instructor:} $\rule{2.6in}{0.15mm} $\hfill\textsc{Class Section: }$\rule{1.5in}{0.15mm}$ \normalsize \newline \\ \fbox{% \begin{minipage}{\dimexpr0.5\textwidth-2\fboxsep-2\fboxrule} \vspace{1mm} \textbf{Part 1. Matching type.} \begin{multicols}{2} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}}% <--- \fbox{% <--- \begin{minipage}{\dimexpr0.5\textwidth-2\fboxsep-2\fboxrule} % <--- \vspace{1mm} \textbf{Part 2. True or False.} \begin{multicols}{2} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}}% <--- \newline \fbox{% <--- \begin{minipage}{\dimexpr\textwidth-2\fboxsep-2\fboxrule}% <--- \vspace{1mm} \textbf{Part 3. Multiple Choice.} \begin{multicols}{3} \begin{enumerate} \item \item \item \item \item \item \item \item \item \item \item \item \item \item \item \end{enumerate} \end{multicols} \vspace{1mm} \end{minipage}}% <--- \newline \fbox{% <--- \begin{minipage}{\dimexpr\textwidth-2\fboxsep-2\fboxrule}% <--- \vspace{1mm} \textbf{Part 4. Problem 1. Fill in the blanks.} \begin{enumerate} \item [(a)] \item [(b)] \item [(c)] \item [(d)] \item [(e)] \end{enumerate} \vspace{1mm} \end{minipage}}% <--- \newline \fbox{% <--- \begin{minipage}{\dimexpr\textwidth-2\fboxsep-2\fboxrule}% <--- \vspace{1mm} \textbf{Part 4. Problem 2. Fill in the blanks.} \begin{enumerate} \item [(a)] \item [(b)] \item [(c)] \item [(d)] \item [(e)] \item [(f)] \end{enumerate} \vspace{1mm} \end{minipage}} \end{document} ```
2
https://tex.stackexchange.com/users/18189
688032
319,180
https://tex.stackexchange.com/questions/688019
0
I am using amsart class with default left equation numbering. I need to write an equation with number on the left and comment on the right as follows. ``` qwer = asdf1 by Lemma A (1) = asdf2 since B = C = asdf3. ``` The command `\tag` changes numbering into comments, which is not what I want. Is there something like `\rtag` that makes comments on the right? Thank you.
https://tex.stackexchange.com/users/257513
Placing equation number on the left, tag on the right
false
Maybe I misunderstand your question but this could work: ``` \documentclass{amsart} \usepackage{amsmath} \begin{document} \begin{align} qwer &= asdf1 &&\text{by Lemma A}\notag\\ &=asdf2 &&\text{since } B = C\\ &= asdf3.\notag \end{align} \end{document} ``` It produces:
0
https://tex.stackexchange.com/users/17360
688035
319,181
https://tex.stackexchange.com/questions/688036
3
I want to have a theorem environment with an additional required argument: ``` \begin{mylemma}{text1, text2} It holds that True. \end{mylemma} \begin{mylemma}{text1, text2}[Name] It holds that True. \end{mylemma} ``` The output should look like this: **Lemma 1.1** [*text1, text2*]. It holds that True. **Lemma 1.2** (*Name*) [*text1, text2*]. It holds that True. I tried using the answers provided [here](https://tex.stackexchange.com/questions/613866/theorem-like-environment-with-optional-title), [here](https://tex.stackexchange.com/questions/289082/second-optional-argument-for-theorem), [here](https://tex.stackexchange.com/questions/83446/how-can-i-make-a-custom-theorem-for-a-definition) and [here](https://tex.stackexchange.com/questions/12913/customizing-theorem-name), but got none to work. The closest I got was the following: ``` \documentclass{book} \usepackage{amsmath, amsthm} \usepackage{thmtools} \declaretheoremstyle[% within=chapter,% notefont=\normalfont\itshape,% notebraces={}{},% ]{mystyle} \declaretheorem[style=mystyle,name=Lemma]{mydef} \newenvironment{mylemma}[2] {\begin{mydef}[{(}#2{)\ [}#1{]}]} {\end{mydef}} \begin{document} \begin{mylemma}{text1, text2}{Name} It holds that True. \end{mylemma} \end{document} ``` This allows me to use `\begin{mylemma}{text1, text2}{Name}\end{mylemma}`, but the argument I want to be optional is now required. Also, it would be nice to be able to write the following instead of defining new environments so verbosely: ``` \newtheoremstyle{mystyle}{}...{} \theoremstyle{mystyle} \newtheorem{mylemma}[theorem]{Lemma} \newtheorem{mytheorem}[theorem]{Theorem} \newtheorem{mycorollary}[theorem]{Corollary} \newtheorem{myproposition}[theorem]{Proposition} ``` and then being able to use each environment like specified above. I tried to adapt the answer provided [here](https://tex.stackexchange.com/questions/289082/second-optional-argument-for-theorem) for that, but apart from then having two *optional* arguments, I got an error possibly related to other packages I use (`Package ntheorem Error: Theorem style plain already defined. ...rfont ##1\ ##2\ (##3)\theorem@separator}}`). Edit: a MWE for that modification: ``` \documentclass{book} \usepackage{amsmath, amsthm} \usepackage{mathtools, xparse} \usepackage{ntheorem} \makeatletter \newtheoremstyle{mystyle} {\isastyleaux{##1}{##2}} {\isastyleaux{##1}{##2}[##3]} \NewDocumentCommand\isastyleaux{mmou\ignorespaces o} {\item[\theorem@headerfont\hskip\labelsep #1\ #2% \IfValueT{#3}{\normalfont\itshape (#3)}% \IfValueT{#5}{\normalfont\itshape [#5]}% .\theorem@separator]#4\ignorespaces} \makeatother \theoremstyle{mystyle} \newtheorem{mylemma}{Lemma} \begin{document} \begin{mylemma}[text1, text2][Name] It holds that True. \end{mylemma} \end{document} ```
https://tex.stackexchange.com/users/131328
Add argument to theorem environment
true
Define an inner theorem and a new environment. ``` \documentclass{article} % define it to your liking \newtheorem{mylemmainner}{Lemma}[section] \NewDocumentEnvironment{mylemma}{mo} {% \IfNoValueTF{#2}{\mylemmainner\textup{[#1]}}{\mylemmainner[#2]\textup{[#1]}} \ignorespaces } {\endmylemmainner} \begin{document} \section{Test} \begin{mylemma}{text1, text2} This is the text of the statement. \end{mylemma} \begin{mylemma}{text1, text2}[Name] This is the text of the statement. \end{mylemma} \end{document} ``` Here's how to move the period after the part in square brackets, with `amsthm` (but not `ntheorem` and you shouldn't load both). ``` \documentclass{article} \usepackage{amsthm} \newtheoremstyle{witharg} {} % ABOVESPACE {} % BELOWSPACE {\itshape} % BODYFONT {0pt} % INDENT (empty value is the same as 0pt) {\bfseries} % HEADFONT {} % HEADPUNCT {5pt plus 1pt minus 1pt} % HEADSPACE % CUSTOM-HEAD-SPEC {\thmname{#1} \thmnumber{#2}\thmnote{ (#3)} \textnormal{[\theoremarg].}} \newcommand{\theoremarg}{} \theoremstyle{witharg} \newtheorem{mylemmainner}{Lemma}[section] \NewDocumentEnvironment{mylemma}{mo} {% \renewcommand{\theoremarg}{#1}% \IfNoValueTF{#2}{\mylemmainner}{\mylemmainner[#2]}\ignorespaces } {\endmylemmainner} \begin{document} \section{Test} \begin{mylemma}{text1, text2} This is the text of the statement. \end{mylemma} \begin{mylemma}{text1, text2}[Name] This is the text of the statement. \end{mylemma} \end{document} ```
4
https://tex.stackexchange.com/users/4427
688037
319,182
https://tex.stackexchange.com/questions/1319
976
If you were asked to show examples of beautifully typeset documents in TeX & friends, what would you suggest? Preferably documents available online (I'm aware I could go to a bookstore and find many such documents called 'books'). Extra bonus for documents whose LaTeX source is available. This is not an idle question. Seeing great examples of any craft is both educational and inspiring, let alone explaining why we prefer TeX to Word or other text editors. For instance, I like how Philipp Lehman's [Font Installation Guide](https://texdoc.org/serve/fontinstallationguide/0) looks. I don't know enough LaTeX to realize how much customization was done, but the ToC looks polished. Your nominations, please ...
https://tex.stackexchange.com/users/564
Showcase of beautiful typography done in TeX & friends
false
Tom Lehrer has put his [songs](https://tomlehrersongs.com/) in the public domain. I have typeset a book from his lyrics (and actually orderd a printed copy). The book is based on the [memoir class](https://ctan.org/pkg/memoir) and the font is a Palatino clone provided by the [New PX font package](https://ctan.org/pkg/newpx). Everything is set on a grid. The [full pdf](https://nuntius35.gitlab.io/res/TomLehrer_Songs.pdf) and the [LaTeX source code](https://gitlab.com/nuntius35/tom_lehrer) is available online.
5
https://tex.stackexchange.com/users/100823
688045
319,185
https://tex.stackexchange.com/questions/687484
1
I'm using `chapterbib` for a long document and the creation of bibliographies for each chapter works fine. Each chapter is in its own file that gets `included`. Is there any option to split the chapter files by, e.g., section? Using `input` does not work as it seems and nesting `includes` is forbidden. Any known workaround? Could `cbunit` or `cbinput` solve this? I'm not sure how they'd work here. Thanks! EDIT - MWE: * `./main.txt` ``` \documentclass[a4paper,10pt,twoside,onecolumn,openright,final,titlepage]{book} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{tocbibind} %\usepackage[rootbib]{chapterbib} \usepackage[sectionbib]{chapterbib} \bibliographystyle{plain} \usepackage[english]{babel} \usepackage[pagebackref=true]{hyperref} \usepackage{blindtext} \renewcommand*{\backref}[1]{} % Internally redefine backref in order to display \renewcommand*{\backrefalt}[4]{[{\small% the pages a reference was cited \ifcase #1 Not cited.% \or Cited on page~#2.% \else Cited on pages #2.% \fi% }]} \begin{document} \tableofcontents \include{chapters/chpt_1} \include{chapters/chpt_2} \chapter{Bibliography} %Don't add a section to the toc \renewcommand{\addcontentsline}[3]{} %Don't add a title to the bibliography \renewcommand{\bibname}{} \bibliography{mybib} \end{document} ``` * `./chapters/chpt_1.tex`: ``` \chapter{Test} \section{First} \blindtext[10] \cite{mathworld:AssociatedLaguerrePolynomial} \section{Second} \blindtext[8] \cite{mathworld:AssociatedLegendreDifferentialEquation,mathworld:AssociatedLaguerrePolynomial} \bibliographystyle{plain} \bibliography{../mybib} ``` * `./chapters/chpt_2.tex` ``` \chapter{Test} \section{First} \blindtext[10] \cite{Weisstein} \section{Second} \blindtext[8] \cite{Weissteina} \section{Third} \blindtext[6] \cite{Weissteinb} \bibliographystyle{plain} \bibliography{../mybib} ``` * `mybib.bib` ``` % Encoding: UTF-8 @Misc{mathworld:AssociatedLaguerrePolynomial, Title = {{Associated Laguerre Polynomial. From MathWorld---A Wolfram Web Resource \url{http://mathworld.wolfram.com/AssociatedLaguerrePolynomial.html}}}, Author = {Weisstein, Eric W.}, Note = {Last visited on 16/03/2016} } @Misc{mathworld:AssociatedLegendreDifferentialEquation, Title = {{Associated Legendre Differential Equation. From MathWorld---A Wolfram Web Resource \url{http://mathworld.wolfram.com/AssociatedLegendreDifferentialEquation.html}}}, Author = {Weisstein, Eric W.}, Note = {Last visited on 16/03/2016} } @Misc{Weisstein, author = {Weisstein, Eric W.}, note = {Last visited on 16/03/2016}, title = {{Wigner 3j-Symbol. From MathWorld---A Wolfram Web Resource \url{http://mathworld.wolfram.com/Wigner3j-Symbol.html}}}, } @Misc{Weissteina, author = {Weisstein, Eric W.}, note = {Last visited on 16/03/2016}, title = {{Wigner 6j-Symbol. From MathWorld---A Wolfram Web Resource \url{http://mathworld.wolfram.com/Wigner6j-Symbol.html}}}, } @Misc{Weissteinb, author = {Weisstein, Eric W.}, note = {Last visited on 16/03/2016}, title = {{Wigner 9j-Symbol. From MathWorld---A Wolfram Web Resource \url{http://mathworld.wolfram.com/Wigner9j-Symbol.html}}}, } ``` To compile: 1. `pdflatex main.tex` generates the chapter `aux` files 2. `cd chapters; bibtex chpt_1.aux; bibtex chpt_2.aux; cd -` 3. comment out `sectionbib`; uncomment `rootbib` 4. `pdflatex main.tex; bibtex main.aux; pdflatex main.tex; pdflatex main.tex` This get's us a two entry bibliograpgy in chapter 1, a three entry bibliograpgy in chapter 2, and a five entry bibliograpgy at the end. For ease of writing - and versioning - I'd like to have each section of each chapter in its own tex-file - if that makes sense.
https://tex.stackexchange.com/users/118150
chapterbib with subfiles for sections
true
There are two packages that might help out in this situation: `subfiles` and `import`. My preference goes to `import`, so I used that package to answer your question. To get an error free compilation I had to alter a few things in your example: 1. The package `chapterbib` is still available on CTAN, but not in my TeX distribution of MikTeX. So I replaced that by the much powerful package `biblatex` using the `biber` engine to sort the citiations. 2. In your `bib` file you used *@Misc*. That uppercase **M** isn't recognised by `biblatex`, so I changed that to the lowercase **m**. 3. References to pages can be entered as option in the `\cite` or `\parencite` commands in texts. 4. Per chapter biobliography can be obtained using the `\begin{refsection} <chapter content> \end{refsection}` structure. The `import` package provides two commands (and aliases) to divide a long document into subdocuments. It allows for subdividing a subdocument as well. That is what I did in the next MWE's. MWE of main.tex file: ``` \documentclass[a4paper,10pt,twoside,onecolumn,openright,final,titlepage]{book} \usepackage{import} \usepackage[style=alphabetic, backend=biber]{biblatex} \addbibresource{refer.bib} % \usepackage[english]{babel} \usepackage{hyperref} \usepackage{blindtext} \begin{document} \tableofcontents \import{chapter1/}{chapter1} \import{chapter2/}{chapter2} \printbibliography[heading=bibintoc] \end{document} ``` MWE of the first chapter (the second chapter has the same structure), stored in `./chapter1/chapter1.tex`: ``` \begin{refsection} \chapter{Test} \subimport{sections}{section1} \subimport{sections}{section1} \subimport{sections}{section3} \printbibliography[heading=subbibintoc, title=Chapter bibliography] \end{refsection} ``` A MWE of section one as an example of the structure of all sections, stored in `./chapter1/sections/section1.tex`: ``` \section{First} \blindtext[10] \cite{mathworld:AssociatedLaguerrePolynomial} ``` As you can see in the provided MWE examples, there is a structure in the way chapters and sections are organised. That structure reflects the folder organisation in which those files are stored. The main document is in a top folder. The chapter files are stored in their respective subfolders (chapter1, chapter2, ...) to that top folder. The sections are stored in a subfolder sections to each chapter folder. In the main file each chapter is imported using the command: `\import{chapterx}{chapterx}`. The first *chapterx* refers to the folder containing the .tex file *chapterx* (the second one). The command `\subimport{sections}{sectiony}` uses the same convention: first the folder where the file is stored. **Note** Answer is partly modified according to the comments given by Sylvain Rigal. The comment about `regsection=chapter` didn't work as expected, so the remark give in point 4 is maintained.
3
https://tex.stackexchange.com/users/189383
688048
319,187
https://tex.stackexchange.com/questions/688047
0
I have the following MWE, where I use the package `algorithm2e` to print algorithms. However, I like the captions of the algorithms to be placed on the top (how to do this was already answered in [this question](https://tex.stackexchange.com/questions/147747/algorithm2e-caption-above-code)). The placement of the caption works fine. Unfortunately, the `hyperref` anchor is placed in the wrong place. When I click the link, the page jumps to the bottom line "Return" of the algorithm. How can I make it jump such that the caption is the first line on the display? ``` \documentclass{article} \usepackage[boxed]{algorithm2e} % https://tex.stackexchange.com/questions/147747/algorithm2e-caption-above-code \makeatletter \renewcommand{\@algocf@capt@boxed}{above} % formerly {bottom} \makeatother \usepackage[linkcolor=red]{hyperref} \begin{document} Algorithm~\ref{algo:myalgo}. \begin{algorithm} Do something.\\ Calculate something.\\ Erase something.\\ Return. \caption{The caption} \label{algo:myalgo} \end{algorithm} \end{document} ```
https://tex.stackexchange.com/users/108056
Wrong anchor of algorithm2e with caption on top
true
You could try something like this: ``` \documentclass{article} \usepackage[boxed]{algorithm2e} \usepackage{etoolbox} % https://tex.stackexchange.com/questions/147747/algorithm2e-caption-above-code \makeatletter \renewcommand{\@algocf@capt@boxed}{above} % formerly {bottom} \renewcommand{\algocf@caption@boxed}{\vskip\AlCapSkip\MakeLinkTarget[topalgocf]{algocf}\box\algocf@capbox}% \patchcmd\algocf@caption@algo {\hyper@refstepcounter{algocf}} {\hyper@refstepcounter{algocf}\xdef\@currentHref{top\@currentHref}}{}{\fail} \makeatother \usepackage[linkcolor=red]{hyperref} \begin{document} Algorithm~\ref{algo:myalgo}. \begin{algorithm} Do something.\\ Calculate something.\\ Erase something.\\ Return. \caption{The caption}\label{algo:myalgo} \end{algorithm} \end{document} ```
0
https://tex.stackexchange.com/users/2388
688050
319,188
https://tex.stackexchange.com/questions/688040
1
I need two boxes in one line which each contains a text on the left side and a QR code on its right. As this, I started with: ``` \documentclass[a4paper]{article} \usepackage{xcolor} \usepackage{qrcode} \begin{document} \fcolorbox{black}{white}{% \begin{minipage}[t]{3cm} \noindent Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text \end{minipage} \hspace{1cm} \begin{minipage}[t]{2cm} \qrcode{https://www.wetteronline.de/wetter/duisburg} \end{minipage} } \hfill \fcolorbox{black}{white}{% \begin{minipage}[t]{3cm} \noindent Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text \end{minipage} \hspace{1cm} \begin{minipage}[t]{2cm} \qrcode{https://www.wetteronline.de/wetter/duisburg} \end{minipage} } \end{document} ``` But this generates two problems for me: 1. The text has a lot of space on top inside each of the boxes. I want the boxes to be filled with the text and the QR code without any additional space on top. 2. both boxes are places not in a single line, they are placed mid on the page and one at top and one bellow. Can anyone hint how to place the boxes and remove the unwanted space before the text? I use pdflatex to create my pdf.
https://tex.stackexchange.com/users/118649
text boxes with QR code, allignement problems
true
The `\qrcode` is set with its reference point (almost) vertically centered. You can use `adjustbox` to move it. ``` \documentclass[a4paper]{article} \usepackage{xcolor} \usepackage{qrcode} \usepackage{adjustbox} \begin{document} The baseline \_\qrcode{https://www.wetteronline.de/wetter/duisburg}\_ \bigskip \fbox{% \begin{minipage}[t]{3cm} Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text Some dummy text \end{minipage}\hspace{1cm}% \adjustbox{valign=t}{\qrcode{https://www.wetteronline.de/wetter/duisburg}}% } \end{document} ```
1
https://tex.stackexchange.com/users/4427
688051
319,189
https://tex.stackexchange.com/questions/687506
0
How can I customize the score accurately as a 1.0 is not able to recognize. Look in MWE I like show points **1.0 and 2.0**, if points is major 1.001 show in points questions, how change this ``` \documentclass[a4paper]{article} \usepackage{tikz} \usepackage{needspace} \usepackage[no-files]{xsim} \newcommand*\circled[2]{\tikz[baseline=(char.base)]{ \node[shape=circle,fill,inner sep=2pt, text=white] (char) {#1};}} %%%%%-Custom Xsim exercises %%%%% \DeclareExerciseEnvironmentTemplate{custom} {%\item[\GetExerciseProperty{counter}] \Needspace*{0\baselineskip} \noindent \circled{\XSIMmixedcase{\GetExerciseProperty{counter}}}~~~% \noindent \IfInsideSolutionF{% \GetExercisePropertyT{points}{ % notice the space (% \printgoal{\PropertyValue} \IfExerciseGoalSingularTF{points} {%\XSIMtranslate{point} } %{\XSIMtranslate{points}}% )% } }} {\vspace{\baselineskip}} \xsimsetup{ collect = false, exercise/within = section, exercise/template = custom, exercise/the-counter = \arabic{exercise}, } \begin{document} \begin{exercise}[points=1.0] Example 1 \end{exercise} \begin{exercise}[points=1.001] Example 1 \end{exercise} \begin{exercise}[points=2.0] Example 2 \end{exercise} \begin{exercise}[points=1.5] Example 3 \end{exercise} \end{document} ```
https://tex.stackexchange.com/users/14285
Points question xsim package precision decimal
false
``` \documentclass{article} \usepackage{tikz} \usepackage{needspace} \usepackage[no-files]{xsim} \xsimsetup{ goal-print={\pgfmathprintnumber[fixed zerofill,precision=1]{#1}} } \newcommand*\circled[2]{\tikz[baseline=(char.base)]{ \node[shape=circle,fill,inner sep=2pt, text=white] (char) {#1};}} %%%%%-Custom Xsim exercises %%%%% \DeclareExerciseEnvironmentTemplate{custom} {%\item[\GetExerciseProperty{counter}] \Needspace*{0\baselineskip} \noindent \circled{\XSIMmixedcase{\GetExerciseProperty{counter}}}~~~% \noindent \IfInsideSolutionF{% \GetExercisePropertyT{points}{ % notice the space (% \printgoal{\PropertyValue} \IfExerciseGoalSingularTF{points} {\XSIMtranslate{point} } {\XSIMtranslate{points} }% )% } }} {\vspace{\baselineskip}} \xsimsetup{ collect = false, exercise/within = section, exercise/template = custom, exercise/the-counter = \arabic{exercise}, } \begin{document} \begin{exercise}[points=1.0] Example 1 \end{exercise} %\begin{exercise}[points=1.001] % Example 1 %\end{exercise} \begin{exercise}[points=2.0] Example 2 \end{exercise} \begin{exercise}[points=1.5] Example 3 \end{exercise} \end{document} ```
0
https://tex.stackexchange.com/users/14285
688052
319,190
https://tex.stackexchange.com/questions/688044
1
I put the title of my examples in a single table cell to create a look of half a box around it with the following code ``` \newtheorem*{example}{\begin{tabular}{r|}example\\\hline\end{tabular}} ``` How can I do something similar for section titles? I tried: ``` \makeatletter \renewcommand\section{\begin{tabular}{r|}\\\hline\end{tabular}} \makeatother ``` but this doesn't work. A minimal working example: ``` \documentclass[a4paper,11pt]{book} \usepackage{amsthm} \usepackage{amssymb} \usepackage{amsmath} \usepackage{array} \newcolumntype{L}{>{\raggedright\arraybackslash}p{0.5\linewidth}} \renewcommand{\arraystretch}{1.5} \renewcommand{\headrulewidth}{0pt} \setlength\arrayrulewidth{1pt} \theoremstyle{definition} \newtheorem*{example}{\begin{tabular}{r|}example\\\hline\end{tabular}} \usepackage{xpatch} \makeatletter \xpatchcmd{\@thm}{\thm@headpunct{.}}{\thm@headpunct{}}{}{} \makeatother \begin{document} \section*{first} \begin{example} content \end{example} \end{document} ```
https://tex.stackexchange.com/users/283579
How to change the layout of section titles
true
You could use the `titlesec` package to redefine the layout of the section heading: ``` \documentclass[a4paper,11pt]{book} \usepackage{amsthm} \usepackage{amssymb} \usepackage{amsmath} \usepackage{array} \newcolumntype{L}{>{\raggedright\arraybackslash}p{0.5\linewidth}} \renewcommand{\arraystretch}{1.5} %\renewcommand{\headrulewidth}{0pt} \setlength\arrayrulewidth{1pt} \theoremstyle{definition} \newtheorem*{example}{\begin{tabular}{r|}example\\\hline\end{tabular}} \usepackage{xpatch} \makeatletter \xpatchcmd{\@thm}{\thm@headpunct{.}}{\thm@headpunct{}}{}{} \makeatother \usepackage[explicit]{titlesec} \titleformat{\section}{\bfseries}{\thesection}{.5em}{\begin{tabular}{r|}#1\\\hline\end{tabular}} \begin{document} \section*{first} \begin{example} content \end{example} \end{document} ```
4
https://tex.stackexchange.com/users/36296
688053
319,191
https://tex.stackexchange.com/questions/688031
0
If I want to make text bold in Overleaf I can select the text and hit Ctrl+B to turn it from `my text` into `\textbf{my text}`. If I want to do the same with another command such as `\section{}` I need to, annoyingly, type `\section{`, delete the additional `}` which automatically appears, tab to the end, then type `}` in the correct position. I am wondering if there is functionality in Overleaf to automatically put selected text inside of any given command such as `\section{}`. For instance, any way of creating a custom keyboard shortcut which wraps selected text inside a specific command. In Sublime text, for instance, I could achieve this functionality be recording a macro which adds any text around a selected text snippet, and then bind a key to that macro.
https://tex.stackexchange.com/users/145550
Keyboard shortcut to wrap text in a command in Overleaf
true
According to the support team of Overleaf, this functionality is not yet available (2023-06-08).
0
https://tex.stackexchange.com/users/145550
688058
319,192
https://tex.stackexchange.com/questions/688000
2
For my template I want to create possibility to define a number of authors and automatically create a respective number of variables/commands which save the name of any author and make it able to print them later. The code has to be in the preamble. For creating different variables/commands of the kind `\varname{...}` which can be printed with `\printvarname`, I, rather randomly, found the following code [here on tex.SE](https://tex.stackexchange.com/questions/47437/resettable-variables) which works fine: ``` \makealetter \newcommand{\NewVariable}[1]{% \expandafter\newcommand\csname #1\endcsname[1]{\@namedef{@#1}{##1}} \@namedef{@#1}{} \expandafter\newcommand\csname print#1\endcsname{% \ifthenelse{\equal{\csname @#1\endcsname}{}}{}{\csname @#1\endcsname}} } \makeatother ``` Now I want to create a loop which automatically creates a predefined number of these commands of the syntax `\authorone`, `\authortwo` etc. For the definition of the numbers of authors I use a simple command: `\newcommand{\setauthors}[1]{\def\numauthors{#1}}`. One problem seems to be that a commandname can't take integers, but i need integers to define the number of authors. So i use the `fmtcount` package to convert them into words. I tried different approaches from this website (`foreach`, `@for`, `xintFor`), but couldn't get one to work properly. Here is a MWE with some approaches. I commented my test loops and added a simple example how it should be used: ``` \documentclass[% ]{article} \usepackage[T1]{fontenc} \usepackage{ifthen} \makeatletter % command to set multiple persistent variables with content \newcommand{\NewVariable}[1]{% \expandafter\newcommand\csname #1\endcsname[1]{\@namedef{@#1}{##1}} \@namedef{@#1}{} \expandafter\newcommand\csname print#1\endcsname{% \ifthenelse{\equal{\csname @#1\endcsname}{}}{}{\csname @#1\endcsname}} } \makeatother \usepackage{pgffor} \usepackage{fmtcount} % to convert integers in words: e.g. 1 into one \usepackage{xinttools} \newcommand{\setauthors}[1]{\def\numauthors{#1}} \setauthors{3} %set number of authors %\foreach \x in {1,...,\numauthors}{% % \NewVariable{author\numberstringnum{\x}} % } %\xintFor #1 in {\xintSeq{1}{\numauthors}} \do {\NewVariable{author\numberstringnum{#1}}} % also tried the starred version \xintFor* %\makeatletter % I know the definition of a range from 1 to \numauthors is not correct, its just a placeholder %\@for\authorcount:1,...,\numauthors\do{\NewVariable{author\numberstringnum{\authorcount}}} %\makeatother \NewVariable{authorone} % example for defined variable/command and how it should work \authorone{Jimmy Buckets} \begin{document} \printauthorone \end{document} ``` There seem to be much more variants of loops from other packages (also `expl3` versions, which I understand even less), but I would prefer a solution with a minimum on required extra packages. Nevertheless, in the end it's important that it works. The future user should only add a number to `\setauthors` and fill out the generated author variables. All other stuff should be automated. It may also be an option to asign the authornumber to an array first... I guess it's an expansion problem of the nested commands (`NewVariable`, `numberstring...`, *loop*). Unfortunately, the expansion sequence/order still remains a sealed book for me, because it differs so much from most programming languages I'm (a little bit) used to. **EDIT** To use @Alans great answer including the orcid. The `expl3` command `\cs_new_protected:Nn \l_lukeflo_get_orcid:n` for creating a valid Orcid works better using a pre-defined command for getting the Orcid link including the symbol: ``` \usepackage{orcidlink} \newcommand{\orcidid}[1]{\orcidlink{#1}\space\href{https://orcid.org/#1}{#1}} ... \cs_new_protected:Nn \l_lukeflo_get_orcid:n { \tl_set:Nx \l_tmpa_tl {\seq_item:Nn \l_lukeflo_orcid_seq {#1}} \orcidid{\l_tmpa_tl}\par } ``` Otherwise, `href` will add an unnecessary `.pdf` extension to the link. See my comments below Alans answer. I am already grateful for your help
https://tex.stackexchange.com/users/297560
How to use loop for creating defined number of newcommands counting authors
true
Your stated goal in the question and in comments is to reduce the complexity of the markup that the users of your package or class need to use. To my mind then, creating multiple different command names is very counterintuitive from a user's point of view. So here's an approach that achieves the same goal, but with maximally simple user syntax: commands to enter authors, affiliations, and emails as simple comma delimited lists, some formatting commands implemented with a key-value setup command (which may or may not need to be user facing) and a command to print the elements. I've used `expl3` methods which are built into the LaTeX kernel, so there are no extra packages involved. This answer is intended to show the kind of thing that can be quite easily done with these methods. In this example, the only user-facing commands that are required are the `\authors`, `\affiliations`, and `\emails` commands. The rest may or may not need to be user facing depending on your actual use case. Since authors often have multiple affiliations, they can be entered as a list surrounded by braces. I've also added an `\orcids` command and shown code to produce the ORCID logo and link. ``` \documentclass{article} \usepackage{orcidlink} \ExplSyntaxOn % First define three sequences for storing the data \seq_new:N \l_lukeflo_authors_seq \seq_new:N \l_lukeflo_email_seq \seq_new:N \l_lukeflo_affil_seq \seq_new:N \l_lukeflo_orcid_seq % Now set up some keys for modifying the output if needed \keys_define:nn{mypackage}{ author.tl_set:N = \l_lukeflo_authformat_tl, affil.tl_set:N = \l_lukeflo_affilformat_tl, email.tl_set:N = \l_lukeflo_emailformat_tl, } % User command to set the formatting keys. \NewDocumentCommand{\authorSetup}{m}{ \keys_set:nn {mypackage} {#1}} % Set up the defaults \authorSetup{author=\itshape,affil={},email=\ttfamily} % User command to enter authors (comma separated) \NewDocumentCommand{\authors}{m}{ \seq_set_from_clist:Nn \l_lukeflo_authors_seq {#1} } % User command to enter affiliations (comma separated; multiple affiliations with {}) \NewDocumentCommand{\affiliations}{m}{ \seq_set_from_clist:Nn \l_lukeflo_affil_seq {#1} } % User command to enter emails \NewDocumentCommand{\emails}{m}{ \seq_set_from_clist:Nn \l_lukeflo_email_seq {#1} } \NewDocumentCommand{\orcids}{m}{ \seq_set_from_clist:Nn \l_lukeflo_orcid_seq {#1} } % internal command to map print affiliations \cs_new_protected:Nn \lukeflo_get_affils:n { \clist_set:Nx \l_tmpa_clist {\seq_item:Nn \l_lukeflo_affil_seq {#1}} \clist_map_inline:Nn \l_tmpa_clist {\l_lukeflo_affilformat_tl {##1}\par} } \cs_new_protected:Nn \lukeflo_get_orcid:n { \tl_set:Nx \l_tmpa_tl {\seq_item:Nn \l_lukeflo_orcid_seq {#1}} \orcidlink{\l_tmpa_tl}\space\l_lukeflo_emailformat_tl \href{https\c_colon_str//orcid.org/\l_tmpa_tl/}{\l_tmpa_tl}\par } % internal command to print an author/affiliations/email block \cs_new_protected:Nn \lukeflo_map_author_info:nn { {\parindent=0pt {\l_lukeflo_authformat_tl\seq_item:Nn \l_lukeflo_authors_seq {#1}\par} {\lukeflo_get_affils:n {#1}} {\l_lukeflo_emailformat_tl\seq_item:Nn \l_lukeflo_email_seq {#1}\par} {\lukeflo_get_orcid:n {#1}} \vspace{\baselineskip} } } % User command to print all the author blocks \NewDocumentCommand \printauthors {} { \seq_map_indexed_function:NN \l_lukeflo_authors_seq \lukeflo_map_author_info:nn } \ExplSyntaxOff \authors{Margaret Atwood, Zadie Smith, Madeleine Thien} \affiliations{University of Toronto,{New York University,Columbia University},Brooklyn College} \emails{ma@utoronto.ca, zs@nyu.edu,mt@brooklyn.cuny.edu} \orcids{0000-0000-0000-0000,0000-0000-0000-0000,0000-0000-0000-0000} \begin{document} \printauthors \authorSetup{author=\bfseries} \printauthors \end{document} ```
3
https://tex.stackexchange.com/users/2693
688070
319,195
https://tex.stackexchange.com/questions/688066
2
Please help me set a centered, bold, larger font size Title in tcolorbox: mwe: ``` \documentclass{book} \usepackage[most]{tcolorbox} \begin{document} \begin{tcolorbox}[colback=black!5, colframe=black!5, title={Top Title}, coltitle=black, fonttitle=\bfseries\Large, sharp corners, enhanced, breakable, ] My box. \end{tcolorbox} \end{document} ```
https://tex.stackexchange.com/users/34449
How to center title and set title font in a tcolorbox
true
`halign title` determines the horizontal alignment for the title. ``` \documentclass{book} \usepackage[most]{tcolorbox} \begin{document} \begin{tcolorbox}[colback=black!5, colframe=black!5, title={Top Title}, coltitle=black, fonttitle=\bfseries\Huge, halign title=flush center, sharp corners, enhanced, breakable, ] My box. \end{tcolorbox} \end{document} ```
4
https://tex.stackexchange.com/users/1952
688074
319,197
https://tex.stackexchange.com/questions/688064
2
Code is kicking out this warning: `Package xcolor Warning: Incompatible color definition on input line 97.` Colors are being used in 3 ways in this maths worksheet: 1. draw yellow highlighted box to enclose the final answer Ex: `\colorbox{yellow}{$x=\dfrac{\log{34}}` 2. apply color to certain exponents and log bases Ex: `$\textcolor{red}{\cancel{log_4}}(5x+15)=\textcolor{red}{\cancel{log_4}}(35)$` 3. using tikz, draw blue arrow to indicate transition to next step of solution procedure. Ex: `$5^{x-3}=35 \tikz[baseline=-0.65ex]\draw[arr] (0,0) -- ++ (1,0); \log 5^{x-3} = \log 35$` (h/t @zarko) After searching several tex.stack posts, I tried inserting `usepackage{xcolor}` immediately before `\usepackage{tikz}`. This edit failed to remove warning message. Your assistance in resolving this issue is deeply appreciated! FYI: **Using exam class because it provides `printanswers` and `%printanswers`** (i.e. don't print answers) commands. mwe ``` \documentclass[12pt]{exam} \usepackage[a4paper,margin=0.5in,include head]{geometry} \printanswers % un-comment to print solutions. \renewcommand{\solutiontitle}{} \usepackage{amsmath} \usepackage{cancel} \usepackage{framed} \usepackage{bm} \usepackage{multicol} \usepackage[nice]{nicefrac} \usepackage{tasks} \usepackage{tikz} \usetikzlibrary{arrows.meta} \tikzset{arr/.style = {blue,-{Triangle[angle=60:1pt 3]}, thick, shorten <=2mm, shorten >=2mm} } \pagestyle{head} \header{\textbf{ Algebra II: TEST 4 REVIEW (Unit 14: Logarithms)}} {} {} \newcommand{\pagetop}{% } \newlength{\lwidth}% added <<<<< \settowidth{\lwidth}{(99)\enspace} % added \settasks{after-item-skip=1em, after-skip=2cm, label-width=\lwidth, % changed <<<<<<<<< item-indent=0pt, % changed <<<<<<<<<< %label-format = \bfseries, %add \bf to make numbers bold <<<<<<<<<< label=(\arabic*), % label-offset = -\lwidth,% added <<<<< item-format = \hspace{\lwidth},% added <<<<< column-sep=2em, % changed <<<<<<<<< } \makeatletter \renewcommand{\fullwidth}[1]{% \vbox{% \leftskip=-\lwidth \rightskip=0pt \advance\linewidth\@totalleftmargin% \@totalleftmargin=0pt% #1}% \nobreak } \makeatother \newlength{\SolutionSpace} \ifthenelse{\boolean{printanswers}} {\setlength{\SolutionSpace}{5cm} \colorsolutionboxes \definecolor{SolutionBoxColor}{gray}{0.8}}% solutions are printed {\setlength{\SolutionSpace}{0cm} \colorsolutionboxes \definecolor{SolutionBoxColor}{gray}{1}}% solutions are not being printed %********************************************* \begin{document} %definition for bigskip = 1 line to replace all \bigskip \def\bigskip{\vskip\bigskipamount} \begin{tasks} [style=enumerate](2) \task![]\fullwidth{\textbf{Solve for $x$. If necessary, round answers to 2 decimal places.}} %%% Prob #1 \task $2 \bm{\cdot}5^{x-3}-7=61$ \begin{solutionorbox}[\SolutionSpace] $2 \bm{\cdot}5^{x-3}=68$\bigskip $\dfrac{\cancel{2}\bm{\cdot}5^{x-3}}{\cancel{2}} =\dfrac{68}{2}$\bigskip $5^{x-3}=35 \tikz[baseline=-0.65ex]\draw[arr] (0,0) -- ++ (1,0); \log 5^{x-3} = \log 35$\bigskip $(x-3)\log5=\log{34}$\bigskip $\dfrac{(x-3)\cancel{\log5}}{\cancel{\log5}}=\dfrac{\log{34}}{\log5}$\bigskip $x-3=\dfrac{\log{34}}{\log5}$\hphantom{(}\hphantom{(}\hphantom{(} \colorbox{yellow}{$x=\dfrac{\log{34}}{\log5}+3\approx5.19$} \end{solutionorbox} %%% Prob #2 \task $\log_4(x+3)+\log_45=\log_4{35}$ \vspace{.25cm} \begin{solutionorbox}[\SolutionSpace] $\log_4(x+3)(5)=\log_4(35)$\bigskip $\textcolor{red}{\cancel{log_4}}(5x+15)=\textcolor{red}{\cancel{log_4}}(35)$\bigskip $5x+15=35$\bigskip $5x=20$\hphantom{(}\hphantom{(}\hphantom{(} \colorbox{yellow}{$x=4$} \end{solutionorbox} %%% Prob #3 \task $\log_4(3x+4)=3$\vspace{.25cm} \begin{solutionorbox}[\SolutionSpace] Hint: If $\log_{\textcolor{red}{a}}N=\textcolor{blue}{x}$, then $\textcolor{red}{a}^{\textcolor{blue}{x}}=N$.\bigskip $4^3=3x+4 \tikz[baseline=-0.65ex]\draw[arr] (0,0) -- ++ (1,0);64=3x+4$\bigskip $3x=60$\bigskip \colorbox{yellow}{$x=20$} \end{solutionorbox} \end{tasks} \end{document} ```
https://tex.stackexchange.com/users/184615
Exam Class + \xcolor + \tikz conflict: incompatible color def
true
A (very) minimal working example would be: ``` \documentclass{exam} \usepackage{xcolor} \printanswers \colorsolutionboxes \definecolor{SolutionBoxColor}{gray}{0.8} \begin{document} \begin{solutionorbox} Foo \end{solutionorbox} \end{document} ``` What you get is a warning that does not really do any harm. The reason you get this warning is that the `exam` package uses a command syntax that is specific to the `color` package. The `xcolor` package understands this syntax as well, but it favours a different, newer syntax. You can solve this by adding a few lines to your preamble: ``` \documentclass{exam} \usepackage{xcolor} \renewcommand{\colorfbox}[2]{% \colorlet{currentColor}{.}% {\color{#1}\fbox{\color{currentColor}#2}}% } \printanswers \colorsolutionboxes \definecolor{SolutionBoxColor}{gray}{0.8} \begin{document} \begin{solutionorbox} Foo \end{solutionorbox} \end{document} ``` (Thanks to Ulrike Fischer for confirming this!) --- What is the reason for this? The culprit is this definition in the file `exam.cls` (stripped off the comments): ``` \newcommand{\colorfbox}[2]{% \expandafter\let\csname\string\color@saved@color\endcsname\current@color% {\color{#1}\fbox{\color{saved@color}#2}}% } ``` It is meant to create a box around something and to draw the frame of the box in a certain color while keeping the contents of the box in the color that has been used outside of the box. The defintion makes use of a syntax that works well if the `color` package is loaded. Using the `xcolor` package, the current color can be more easily accessed via the color name `.`. So, the above could be rewritten as: ``` \newcommand{\colorfbox}[2]{% \colorlet{currentColor}{.}% {\color{#1}\fbox{\color{currentColor}#2}}% } ``` A warning about an "incompatible color definition" is issued when the `xcolor` package is loaded and TeX stumbles over some color definition that is stored in a command that starts with `\color@`. The original defintion of `\colorfbox` defines such a command and hence the warning is issued every time this command is used. The rewritten code solves this problem.
2
https://tex.stackexchange.com/users/47927
688076
319,198
https://tex.stackexchange.com/questions/24599
288
In the preamble I have: ``` \documentclass[a4paper,11pt]{article} \usepackage{fontspec} \setmainfont{Arial} ``` What can be inferred about the real font `pt` size for the following? `\tiny`, `\scriptsize`, `\footnotesize`, `\small`, `\normalsize`, `\large`, `\Large`, `\LARGE`, `\huge`, `\Huge`
https://tex.stackexchange.com/users/6825
What point (pt) font size are \Large etc.?
false
You can also read the source code: <https://github.com/TeX-Live/texlive-source/blob/f0c6b9ed37a37c0bbe826ef90c1e64dd7b6b618e/utils/asymptote/base/size11.asy#L2> found with the GitHub search feature you have another file for size10
0
https://tex.stackexchange.com/users/183372
688081
319,201
https://tex.stackexchange.com/questions/688072
1
pdftex sets the box in the mwe below correctly with a centered, large, bold title. However with tex4ebook it is neither centered nor bold and large. Please help me set a centered, bold, larger font size Title in tcolorbox using tex4ebook to make epub format. mwe: ``` \documentclass{book} \usepackage[most]{tcolorbox} \begin{document} \begin{tcolorbox}[colback=black!5, colframe=black!5, title={Top Title}, coltitle=black, fonttitle=\bfseries\Huge\centering, % in epub is not centered, bold, or big sharp corners, enhanced, breakable, ] My box. \end{tcolorbox} \end{document} ```
https://tex.stackexchange.com/users/34449
tex4ebook/tex4ht epub: tcolorbox How to center title and set title font
true
You can style the `tcolorbox` title using CSS. Try this configuration file, `config.cfg`: ``` \Preamble{xhtml} \Css{.tcolorbox-title{text-align:center;font-weight:bold;font-size: 1.4rem;}} \begin{document} \EndPreamble ``` Compile using: ``` $ tex4ebook -c config.cfg sample.tex ``` This is the result:
1
https://tex.stackexchange.com/users/2891
688095
319,207
https://tex.stackexchange.com/questions/688090
0
All chapters begin a new page by default. I want to remove this break between two short chapters. By the nopagebreak doesn't work. What can be the cause? Is there another way to do that? I don't give all my code there, but I can write some details if needed.
https://tex.stackexchange.com/users/297914
\nopagebreak doesn't work between two chapters
false
As said, chapter insert a `\clearpage`, so a simple approach is place the chapter title in a group where this command if redefined to just make a paragraph break, some ornament or whatever that you want. After the group, the old definition of `\clearpage` is still in effect, so next chapters will start in new pages. ``` \documentclass{book} \usepackage{lipsum} \begin{document} \chapter{Uno}\lipsum[1] \chapter{Dos}\lipsum[2] \begingroup \def\clearpage{\par} \chapter{Tres}\lipsum[3] \endgroup \chapter{Cuatro}\lipsum[4] \end{document} ```
1
https://tex.stackexchange.com/users/11604
688099
319,208
https://tex.stackexchange.com/questions/688063
1
I don't understand Overleaf's two complaints with the following code. It says that it has inserted a missing `{` and a missing `}`. Would someone please explain? ``` %%%%% Preamble %%% Document class, packages \documentclass{book} \usepackage{fancyhdr} \usepackage{titlesec} %%% Fancy headers \fancyhf{} \pagestyle{fancy} \renewcommand\headrulewidth{0pt} \renewcommand{\chaptermark}[1]{\markboth{#1}{}} \fancyhead[LE]{\thepage \hspace{1cm} \leftmark} \renewcommand\sectionmark[1]{\markboth{#1}{}} \fancyhead[RO]{\leftmark \hspace{1cm} \thepage} %%% Section formatting % Chapters \titleformat{\chapter}[display] {\normalfont\fillast} {{\Huge \uppercase\romannumeral\thechapter}} {1ex minus .1ex} {\large \thispagestyle{empty}} \titlespacing{\chapter} {3pc}{*3}{*2}[3pc] %%%%% Document \begin{document} \chapter{Lorem ipsum} \end{document} ```
https://tex.stackexchange.com/users/277990
Supposed missing brackets
true
`\uppercase\romannumeral\thechapter` is wrong: `\uppercase` ***needs*** to see a brace delimiting the tokens to be converted to uppercase. You might do it with correct syntax as ``` \uppercase\expandafter{\romannumeral\thechapter} ``` but why doing this instead of ``` \renewcommand{\thechapter}{\Roman{chapter}} ``` and using just `\thechapter` when you want to print the chapter number in Roman numerals?
2
https://tex.stackexchange.com/users/4427
688100
319,209
https://tex.stackexchange.com/questions/688112
0
``` \documentclass{article} \usepackage[many]{tcolorbox} \usepackage{lipsum} \tcbset{myoption/.style={colback=blue!20}} \newcommand{\bubble}[1]{% \begin{tcolorbox}[myoption] #1 \end{tcolorbox} } \begin{document} \bubble{\lipsum[1][1-2]} \end{document} ``` I have this code from here. I would like to define my own environment and use the macro inside it. ``` \begin{document} \begin{myenvironment} \bubble{\lipsum[1-2]} \end{myenvironment} \end{document} ```
https://tex.stackexchange.com/users/298558
\newenvironment{myenvironment} with tcolorbox that takes an argument
true
Depends of what you want to put inside this environment but here is a first example. ``` %%%%%%% preamble %%%%%%%% \usepackage{enumerate,enumitem} %for lists \usepackage[most]{tcolorbox} \newtcolorbox{specifications}[1][]{% enhanced, width=0.9\textwidth ,center, colback=blue!5!white,colframe=blue!85!black, attach boxed title to top center={yshift=-3mm,yshifttext=-1mm},title=\textbf{Specifications}, boxed title style={colframe=blue!85!black,colback=blue!85!black},#1} %%%%%%% document %%%%%%%% \begin{specifications} This project deals with synthesing and characterizing lanthanide-based MOFs to investigate if these materials can be used as platforms for detecting selected VOCs. The tasks to be completed are listed below. \begin{enumerate}[label=\textbullet] \item Read literature on MOFs \item Plan the experimental work \item Carry out the syntheses of different lanthanide-based MOF \item Characterize synthesized MOF \item Investigate the porosity, stability, and luminescent properties of the synthesized MOFs \end{enumerate} \end{specifications} ``` Here is the result. For some reason, if caption for your environment is needed here is one posibility. The next example shows a way to include code which can be listed in a "List of codes". ``` %%%%%%%%%% preamble %%%%%%%%%%%%% \usepackage[most]{tcolorbox} %for box \usepackage[table,dvipsnames]{xcolor} \usepackage{newfloat} %create floating environment (such as Figure, Table, ...) \usepackage{capt-of} %caption for non-floating environement / breakable envir. %% list of codes (for matlab codes) %listofcodes \DeclareFloatingEnvironment[name={Code},fileext={loc},listname={List of Codes}]{code} \usepackage{listings} %IT in latex \usepackage{matlab-prettifier} %upgrade of listings specific to matlab code %%%%%%%%%% document %%%%%%%%%%%%% \captionof{code}{Matlab code for TGA computations}\label{code:TGA_calculations} % place the caption \begin{tcolorbox}[breakable,arc=0mm,left=1pt, right=1pt, boxrule=1mm,colback=BrickRed!5!white,colframe=BrickRed!85!black] \begin{lstlisting}[language=Matlab, numbers=left, style=Matlab-editor] %code \end{lstlisting} \end{tcolorbox} ``` Here is the result. The `breakable` option allows the environment to be displayed on several pages. I think the second one can be optimized in one `\newenvironment` like the first one but it just was to give examples. If you want to try other things, you can try reading the [manual of `tcolorbox`](https://ctan.org/pkg/tcolorbox?lang=en). The section "Technical Overview and Customization" can be helpful for your problem. Good luck
2
https://tex.stackexchange.com/users/283811
688116
319,219
https://tex.stackexchange.com/questions/687799
2
I'd like to include the TeX engine name and version in a document, Is there markup to capture those? I tried this ``` \documentclass{article} \usepackage{expl3} \usepackage{hyperref} \usepackage{listings} \ExplSyntaxOn \newcommand* \enginedetails { \c_sys_engine_exec_str \c_space_tl \c_sys_engine_version_str \c_space_tl (\c_sys_engine_format_str) } \ExplSyntaxOff \begin{document} \lstset{language=Rexx, extendedchars=true, frame=trbl} \title{Unicode Case and Width Issues} \author{Shmuel (Seymour J.) Metz} \thanks { This is a working document for the Rexx Language Association (RexxLA). It is written in \LaTeX \fmtversion and was rendered \today using \enginedetails{}. } \maketitle \end{document} ``` and got > > Undefined control sequence. } > > > with the line number of the closing } on the /thanks.
https://tex.stackexchange.com/users/110591
Markup to query engine and version
false
I downloaded a more recent expl3 and that resolved the problem. However, I also wanted the command to be robust, so I used \NewDocumentCommand. ``` \documentclass{article} \usepackage{xparse} \ExplSyntaxOn \NewDocumentCommand\enginedetails{}% {% { \c_sys_engine_exec_str \c_space_tl \c_sys_engine_version_str \c_space_tl (\c_sys_engine_format_str) } } \ExplSyntaxOff \begin{document} \enginedetails \end{document} ```
0
https://tex.stackexchange.com/users/110591
688117
319,220
https://tex.stackexchange.com/questions/688118
3
So, I've been searching around and I came across a few examples that will allow you to valign two cells in a certain way, but I'm trying to align three, so that the first it at the top, the middle is in the middle, and the third is at the bottom. Here is what I've been messing with, but I'm obviously not understanding something important. Any help would be greatly appreciated. ``` \documentclass{book} \usepackage{lipsum} \begin{document} \begin{tabular}{cp{2.8in}c} \multicolumn{1}{b{0.2in}}{\Huge{``}} & \multicolumn{1}{m{2.8in}}{\lipsum[1]} & \Huge{"} \\ \end{tabular} \end{document} ```
https://tex.stackexchange.com/users/240055
Is there any way to vertically align each cell in a row differently?
true
That's not easily possible. But there's a way around it: Insert the quotes at the start and end manually, with some overlap into the adjacent columns. ``` \documentclass{article} \usepackage{lipsum} \begin{document} \begin{tabular}{ c p{2.8in} c} \hphantom{\Huge ``} & % Just for appropriate horizontal space \raisebox{-.5\normalbaselineskip}[0pt][0pt]{\makebox[0pt][r]{\Huge ``\hspace{2\tabcolsep}}}% \lipsum*[1]% \hfill\raisebox{-\normalbaselineskip}[0pt][0pt]{\makebox[0pt][l]{\hspace{2\tabcolsep}\Huge ''}} & \hphantom{\Huge ''}% Just for appropriate horizontal space \end{tabular} \end{document} ``` You don't need a `tabular` structure for this, since the placement of the quotes rely on the content, so could also be set in a `\parbox`, say.
3
https://tex.stackexchange.com/users/5764
688119
319,221
https://tex.stackexchange.com/questions/688118
3
So, I've been searching around and I came across a few examples that will allow you to valign two cells in a certain way, but I'm trying to align three, so that the first it at the top, the middle is in the middle, and the third is at the bottom. Here is what I've been messing with, but I'm obviously not understanding something important. Any help would be greatly appreciated. ``` \documentclass{book} \usepackage{lipsum} \begin{document} \begin{tabular}{cp{2.8in}c} \multicolumn{1}{b{0.2in}}{\Huge{``}} & \multicolumn{1}{m{2.8in}}{\lipsum[1]} & \Huge{"} \\ \end{tabular} \end{document} ```
https://tex.stackexchange.com/users/240055
Is there any way to vertically align each cell in a row differently?
false
`tblr` environment from `tabularray` package has a feature-rich more-intuitive *key=value(s)* interface. Example: MWE ``` \documentclass{book} \usepackage{lipsum} \usepackage{xcolor} \usepackage{tabularray} \begin{document} \begin{tblr}{ % vlines,hlines, colspec={Q[h,r]X[j,m,3.5in,bg={blue!5}]Q[f,l]}, column{1}={fg={red},rightsep={0pt}}, column{3}={fg={red},leftsep={0pt}}, } {\Huge{``}} & \lipsum[1] & \Huge{"} \\ \end{tblr} \end{document} ``` --- Note - *slight edit* `\Huge` is a switch and does not take parameters. It can be set in the column spec. ``` \begin{tblr}{ % vlines,hlines, colspec={Q[h,r]X[j,3.5in,bg={blue!5}]Q[f,l]}, column{1}={font={\Huge},fg={red},rightsep={0pt}}, column{3}={font={\Huge},fg={red},leftsep={0pt}}, } `` & \lipsum[1] & " \\ \end{tblr} ```
2
https://tex.stackexchange.com/users/182648
688122
319,224
https://tex.stackexchange.com/questions/688118
3
So, I've been searching around and I came across a few examples that will allow you to valign two cells in a certain way, but I'm trying to align three, so that the first it at the top, the middle is in the middle, and the third is at the bottom. Here is what I've been messing with, but I'm obviously not understanding something important. Any help would be greatly appreciated. ``` \documentclass{book} \usepackage{lipsum} \begin{document} \begin{tabular}{cp{2.8in}c} \multicolumn{1}{b{0.2in}}{\Huge{``}} & \multicolumn{1}{m{2.8in}}{\lipsum[1]} & \Huge{"} \\ \end{tabular} \end{document} ```
https://tex.stackexchange.com/users/240055
Is there any way to vertically align each cell in a row differently?
false
With `{NiceTabular}` of `nicematrix`. ``` \documentclass{book} \usepackage{nicematrix} \usepackage{lipsum} \begin{document} \begin{NiceTabular}{cp{2.8in}c} \Block[T]{}{\Huge ``} & \multicolumn{1}{m{2.8in}}{\lipsum[1]} & \Block[B]{}{\raisebox{-\normalbaselineskip}[0pt][0pt]{\Huge "}} \end{NiceTabular} \end{document} ```
3
https://tex.stackexchange.com/users/163000
688124
319,225
https://tex.stackexchange.com/questions/688110
3
The word `category` gets automatically hyphenated as `cate-gory` by latex, but with the prefix `$\infty$-`, it doesn't. It still works by manually writing `$\infty$-cate\-gory`, but putting `\hyphenation{$\infty$-cate-gory}` in the preamble apparently gets ignored by lualatex, and gives an error message with pdflatex. Is there a way to automate the hyphenation of words with math prefixes like `$\infty$-category`? EDIT: Here is something that works that I found on the arxiv. But it forces me to write something else instead of the usual hyphen, and I would prefer a solution where I can just write an ordinary hyphen. ``` \documentclass{article} \usepackage[shortcuts]{extdash} \newcommand\oo[1]{$\infty$\=/} \begin{document} This is a sufficiently long line of text with many words and ending in \oo-category. Or without the newcommand: This is a sufficiently long line of text with many words and ending in $\infty$\=/category. \end{document} ```
https://tex.stackexchange.com/users/193342
how to automatically permit hyphenation of the word "category" in "$\infty$-category"
false
Not really an answer, and I am afraid it might not help you, but too long for a comment, and it might help someone else. I wonder if there is a simple and clean way to do this in pdftex or luatex. In luametatex, a more flexible hyphenation setup is implemented. One can use `\hyphenationmode` (see [the luametatex manual](http://www.pragma-ade.com/general/manuals/luametatex.pdf)) to set it up (or use the defaults that seem to work well). In lang-ini.mkxl, in a ConTeXt distribution, one can find something like ``` \permanent \integerdef \completehyphenationcode \numexpr \normalhyphenationcode % \discretionary + \automatichyphenationcode % - + \explicithyphenationcode % \- + \syllablehyphenationcode % pattern driven + \uppercasehyphenationcode % replaces \uchyph + \compoundhyphenationcode % replaces \compoundhyphenmode % \strictstarthyphenationcode % replaces \hyphenationbounds (strict = original tex) % \strictendhyphenationcode % replaces \hyphenationbounds (strict = original tex) + \automaticpenaltyhyphenationcode % replaces \hyphenpenaltymode (otherwise use \exhyphenpenalty) + \explicitpenaltyhyphenationcode % replaces \hyphenpenaltymode (otherwise use \exhyphenpenalty) + \permitgluehyphenationcode % turn glue into kern in \discretionary + \permitallhyphenationcode % okay, let's be even more tolerant + \permitmathreplacehyphenationcode % and again we're more permissive + \forcehandlerhyphenationcode % kick in the handler (could be an option) + \feedbackcompoundhyphenationcode % feedback compound snippets + \ignoreboundshyphenationcode % just in case we have hyphens at the edges + \collapsehyphenationcode % collapse -- and --- \relax \permanent \integerdef \partialhyphenationcode \numexpr \ignoreboundshyphenationcode % just in case we have hyphens at the edges % + \explicithyphenationcode % \- + \collapsehyphenationcode % collapse -- and --- \relax \permanent\protected\def\dohyphens {\hyphenationmode\completehyphenationcode} \permanent\protected\def\nohyphens {\hyphenationmode\partialhyphenationcode} ``` Hyphenations are on by default, but following the code above, we can switch them off by `\nohyphens`. Of course, one can have a more granular setup as well by setting the different bits (one can switch one with `\bitwiseflip`). Here is a small example where we change the hyphenation setting locally (to prohibit the wanted hyphenation, therefore in red): ``` \starttext % \showhyphens{category} \typ{\showhyphens{category}} \typ{languages > hyphenation > show: cat[-||]e[-||]gory} \blank \hsize 1.4cm \blackrule[width=\hsize]\par $\infty$-category \blank \hsize 7cm \blackrule[width=\hsize]\par Oh, it's like that, it's like that {\red\nohyphens$\infty$-category.} Yeah, it's like that, it's like that $\infty$-category. Woah-oh-oh, oh-oh-oh. \stoptext ```
1
https://tex.stackexchange.com/users/52406
688125
319,226
https://tex.stackexchange.com/questions/657106
1
I am writing my master's degree thesis in English. Although, I have to include abstract in Greek and I would like also to include it at the table of contents. Below the main code of tex is portrayed. Tex ``` \documentclass[hidelinks,12pt]{article} \usepackage[utf8]{inputenc} \usepackage[greek,english]{babel} \usepackage{textgreek} \usepackage{cmbright} \usepackage{ucs} \usepackage{babel} \usepackage{graphicx} \usepackage{natbib} \usepackage{caption} \usepackage{float} \usepackage{titlesec} \usepackage{hyperref} \usepackage[a4paper,width=150mm,top=25mm,bottom=25mm,bindingoffset=6mm]{geometry} \usepackage{fancyhdr} \usepackage{soul} \usepackage{xcolor} \usepackage{caption} \usepackage{ragged2e} \usepackage{indentfirst} \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amssymb} \pagestyle{fancy} %\title{Modern Investment Strategies in Hedge Funds} %\author{Nikolaos Minas} %\date{September 2022} \begin{document} %\begin{titlepage} \include{Titlepage} %\clearpage\thispagestyle{empty} %\end{titlepage} %\maketitle %\newpage \tableofcontents \fancyhead{} \fancyhead[RO,LE]{Modern Investment Strategies in Hedge Funds} \fancyfoot{} \fancyfoot[LE,RO]{\thepage} \fancyfoot[CO,RE]{Nikolaos Minas - MXAN2016} \captionsetup{singlelinecheck=false,labelsep=period,font=footnotesize,labelfont={bf}} \newpage \addcontentsline{toc}{section}{Abstract} \include{Introduction} \include{Chapter1} \include{Chapter2} \include{Chapter3} \include{Chapter4} \include{Chapter5} \bibliography{ref} \bibliographystyle{apalike} \end{document} ``` Tex Introduction contains the script in both english and greek.However, in Greek the font is not the same as in English whereas several letters are missing. Any ideas ? ``` \section*{Abstract} The scope of this dissertation is to prepare a thorough analysis of the hedge funds industry in order to examine the size and the performance of the market. This analysis was conducted by both a literature review and an empirical analysis of publicly available data and more specifically from Hedge Funds Research database. Examination of the hedge fund industry was conducted by calculating Sharpe Ratio, Sortino Ratio, Value at Risk as well as by applying a linear regression using the Jensen model. \paragraph{} Our conclusions indicate that the aggregate performance of hedge funds throughout the period of 2010-2021 presented a notable decline, a fact which is observed in both literature review and the empirical analysis. The dissertation is divided into five chapters for better understanding. Initially, Chapter 1 is an introductory to the Hedge Funds, its characteristics, and their limitations as an asset class. Chapter 2 provides a thorough description of each hedge fund strategy. Chapter 3 indicates a literature review among the size and performance of hedge funds. Next comes Chapter 4 which presents the empirical analysis applied in order to determine the performance of hedge funds. Finally, Chapter 5 concludes the thesis and presents the main outcomes as well as its limitations and the suggestions for possible future research. \newpage \section*{\textbf{Περίληψη}} \paragraph{} O σκοπός της παρούσας μεταπτυχιακής εργασίας είναι η ανάλυση των Hedge Funds ως προς τόσο το μέγεθός τους σαν επενδυτικό προϊόν όσο και οι επιδόσεις τους. Για την ανάλυση λήφθηκε υπόψιν τόσο η υφιστάμενη βιβλιογραφία, όσο και μια ανάλυση δεδομένων τα οποία προέκυψαν από την βάση δεδομένων Hedge Funds Research Database. Η εν λόγω ανάλυση βασίστηκε στον προσδιορισμό των Sharpe Ratio Sortino Ratio, Value at Risk, καθώς και της εφαρμογής μιας γραμμικής παλινδρόμησης βάσει του μοντέλου του Jensen. \paragraph{} Από την παρούσα έρευνα ως κύριο συμπέρασμα προέκυψε το γεγονός ότι τα hedge funds από το 2010 έως το 2021 παρουσιάζουν μια σημαντική πτώση ως προς την απόδοσή τους, γεγονός που αντικατοπτρίζεται τόσο στην βιβλιογραφική όσο και στην εμπειρική έρευνα. Η παρούσα μεταπτυχιακή έργασία χωρίζεται σε πέντε κεφάλαια με σκοπό την καλύτερη κατανόηση του αντικείμένου που πραγματεύεται η παρούσα για τον εκάστοτε αναγνώστη. Το πρώτο κεφάλαιο αποτελείται από μια εισαγωγή ως προς τα Hedge Funds, τα χαρακτηριστικά τους καθώς και τους περιορισμούς που τα διακατέχουν. Στη συνέχεια το δεύτερο κεφάλαιο παρουσιάζει μια αναλυτική αναφορά ως προς τις κύριες στρατηγικές των Hedge Funds. Το τρίτο κεφάλαιο αναλύει την βιβλιογραφική ανασκόπηση και καταλήγει στον προσδιορισμό τόσο του μεγέθους των Hedge Funds όσο και της αποδοτικότητάς τους. Επόμενο είναι το τέταρτο κεφάλαιο, στο οποίο γίνεται αναφορά στην ανάλυση δεδομένων για τον προσδιορισό των αποδόσεων των hedge funds. Τέλος, το κεφάλαιο 5 ολοκληρώνει την παρούσα έρευνα και παρουσιάζει τα κύρια συμπεράσματα που προέκυψαν, τους περιορισμούς καθώς και ορισμένες προτάσεις του συγγραφέα για τυχόν μελλοντική έρευνα. ```
https://tex.stackexchange.com/users/279991
Greek Language Issue
false
A working minimal example for pdfLaTeX. * With pdfLaTeX, you need to protext Latin letters in Greek text! Wrap non-Greek words in `\ensureascii{ }` or use LuaTeX and Unicode fonts. * In a mixed-language document under pdfLaTeX, Greek sections in the ToC are tricky and may interfere with indexing (makeindex, xindy...). Changing to Greek language only *inside* the `\section` or `\addcontentsline` command should help. Switching to LuaTeX helps, too. * Font setup is a stub, the fonts do not match. Main document: ``` \documentclass[]{book} % \usepackage[utf8]{inputenc} % not required since 2018 \usepackage[greek,english]{babel} % \usepackage{textgreek} % not required, conflicts possible \usepackage{cmbright} % select a font that also supports Greek % (alternatively, use \DeclareFontfamilySubstitution to set up % a matching Greek text font) \usepackage{gfsneohellenic} % \usepackage{ucs} % conflict % \usepackage{babel} % already loaded \usepackage{graphicx} % [...] % packages not required for the minimal example \begin{document} \tableofcontents \newpage \include{Introduction} % [...] % add your chapters. \end{document} ``` And Introduction.tex ``` \addcontentsline{toc}{section}{Abstract} \section*{Abstract} The scope of this dissertation is to prepare a thorough analysis of the hedge funds industry … Our conclusions indicate that the aggregate performance of hedge funds throughout the period of 2010-2021 presented a notable decline, … \newpage \addcontentsline{toc}{section}{\foreignlanguage{greek}{Περίληψη}} \selectlanguage{greek} \section*{Περίληψη} % Warning: With pdfLaTeX, you need to protext Latin letters in Greek text! % Wrap non-Greek words in \ensureascii{ } % or use LuaTeX and Unicode fonts. O σκοπός της παρούσας μεταπτυχιακής εργασίας είναι η ανάλυση των \ensureascii{Hedge Funds} ως προς τόσο το μέγεθός τους σαν επενδυτικό προϊόν όσο και οι επιδόσεις τους. Για την ανάλυση λήφθηκε υπόψιν τόσο η υφιστάμενη βιβλιογραφία, όσο και μια ανάλυση δεδομένων τα οποία προέκυψαν από την βάση δεδομένων \ensureascii{Hedge Funds Research Database}. Η εν λόγω ανάλυση βασίστηκε στον προσδιορισμό των \ensureascii{Sharpe Ratio Sortino Ratio, Value at Risk}, καθώς και της εφαρμογής μιας γραμμικής παλινδρόμησης βάσει του μοντέλου του Jensen. Από την παρούσα έρευνα ως κύριο συμπέρασμα προέκυψε το γεγονός ότι τα \ensureascii{hedge funds} από το 2010 έως το 2021 … \selectlanguage{english} ```
-1
https://tex.stackexchange.com/users/288060
688126
319,227
https://tex.stackexchange.com/questions/238338
3
I want to write a text in Greek and there are some non-greek names. I used the following code: ``` \begin{frame}{Ιστορική αναδρομή} Το 1926 ο $\textenglish{David Hilbert }$ ισχυρίζεται ότι κάθε υπολογίσιμη συνάρτηση είναι πρωταρχικά αναδρομική. $ \\ \\ $ \end{frame} ``` I used the following package: ``` \usepackage[english,greek]{babel} ``` But I get the following error: ``` Undefined control sequence. \beamer@doifinframe ...-Το 1926 ο \textenglish {David Hilbert } ισχυ�... l.66 \end{frame} The control sequence at the end of the top line of your error message was never \def'ed. If you have misspelled it (e.g., `\hobx'), type `I' and the correct spelling (e.g., `I\hbox'). Otherwise just continue, and I'll forget about whatever was undefined. ``` What have I done wrong?? What could I change??
https://tex.stackexchange.com/users/76036
How can I write a non-greek name in a greek text?
false
Alternatively, especially for abbreviations and other text in a Latin script in an unspecified language, you can use `\ensureascii`, e.g., `\ensureascii{SNCF}`. Or use LuaLaTeX and a Unicode font that contains Latin and Greek letters. For details, read the [babel-greek](https://www.ctan.org/pkg/babel-greek) documentation.
2
https://tex.stackexchange.com/users/288060
688128
319,229
https://tex.stackexchange.com/questions/688098
1
I have some unnumbered pages in a document before pages that are numbered. I'd like to add the unnumbered pages to the table of contents, but without their page number. Here is an exemple: ``` \documentclass{report} \usepackage{hyperref} \usepackage{glossaries} \makeglossaries \begin{document} %%%% UNNUMBERED PAGES %%%% \setcounter{page}{-100} % Makes the unnumbered pages far below 0 to avoid glossary to point at them instead of the numbered pages \tableofcontents % Generates the table of contents \thispagestyle{empty} % No page number on the table of contents page \newpage \printglossary[type=main,title={Technical vocabulary}] % Generates the glossary \addcontentsline{toc}{chapter}{TECHNICAL VOCABULARY} % Makes the glossary appear in the table of content \thispagestyle{empty} % No page number on the glossary page \newglossaryentry{yp} % Glossary entry example to make it appear { name=yeepee, description={The glossary appears!} } %%%% NUMBERED PAGES %%%% \newpage \setcounter{page}{1} % Page numbering begins here \chapter{Introduction} \gls{yp} \end{document} ``` In this document, I'd like to add "Technical vocabulary" to the table of contents without making "-99" appear in it. Anyone knows how to do this? Thanks!
https://tex.stackexchange.com/users/298628
Generating a table of content line without related page number
true
You can simply use a `\thepage`, that does not show the page number. Often `\pagenumbering{gobble}` is used, but this would result in page anchor duplicates. So I prefer a definition that still gives a page number for `hyperref`, e.g. ``` \renewcommand*{\thepage}{\texorpdfstring{}{\Roman{page}}} ``` or ``` \renewcommand*{\thepage}{\texorpdfstring{}{F-\arabic{page}}} ``` But there are some other issues with your code. For example, if the glossary would have more than one page, the ToC entry would be the one of the last page (or even the next one) instead of the first. Also all the `\thispagestyle{empty}` are not needed and could also be too late. ``` \documentclass{report} \usepackage{hyperref} \usepackage[automake]{glossaries}% run makeindex automatically \makeglossaries \begin{document} %%%% UNNUMBERED PAGES %%%% \renewcommand*{\thepage}{\texorpdfstring{}{F-\arabic{page}}}% F = frontmatter, % but you can use whatever you want. \tableofcontents % Generates the table of contents \clearpage \phantomsection \addcontentsline{toc}{chapter}{TECHNICAL VOCABULARY} % Makes the glossary % appear in the table of content with the % first page of the glossary! \printglossary[type=main,title={Technical vocabulary}] % Generates the glossary \newglossaryentry{yp} % Glossary entry example to make it appear { name=yeepee, description={The glossary appears!} } %%%% NUMBERED PAGES %%%% \chapter{Introduction} \pagenumbering{arabic} \gls{yp} \end{document} ``` These are the three pages of the document: and here are the bookmarks: To change the `F-` in the bookmarks you can change the second argument of `\texorpdfstring` in the (temporary) redefinition of `\thepage`. To change the page number in `F-2`, e.g., start it with `F-1` you can change the `page` counter. Such changes will not effect the table of contents, as long as the first argument of `\texorpdfstring` is empty. I've also added option `automake` to run `makeindex` automatically. But if you like to use running `makeglossaries` manually instead, feel free to remove the option.
0
https://tex.stackexchange.com/users/277964
688132
319,230
https://tex.stackexchange.com/questions/180275
2
Is it possible to compile the following example using pdfLaTeX showing the correct font for greek text, and not the default CMR? ``` \documentclass[a4paper]{article} \usepackage[english,greek]{babel} \usepackage[iso-8859-7]{inputenc} \usepackage{tgheros} \usepackage[T1]{fontenc} \begin{document} \section{Εισαγωγή} Αυτό είναι ελληνικό κείμενο. \selectlanguage{english} this is latin text. \selectlanguage{greek} και αυτό είναι ελληνικό κείμενο. \[ a = b + \gamma \] \end{document} ```
https://tex.stackexchange.com/users/34575
Writing greek text in LaTeX
false
tex-gyre-heros does not support Greek under pdfLaTeX. Under Xe/LuaTeX, only the base letters are present, accented letters and other symbols are missing. The simplest solution would be to switch to a sans-serif font that supports the Greek "LGR" font encoding like <https://www.ctan.org/pkg/gfsneohellenic> or <https://www.ctan.org/pkg/gofonts>. Another option is to set up a substitute just for Greek with the `\DeclareFontfamilySubstitution` command added to the LaTeX kernel in the 2020 release, see [ltnews31](https://www.latex-project.org/news/latex2e-news/ltnews31.pdf). The third option would be to use LuaTeX with a Helvetica variant that supports Greek or with language-specific fonts set up via Babel or Polyglossia.
1
https://tex.stackexchange.com/users/288060
688136
319,232
https://tex.stackexchange.com/questions/249334
0
Need to use utf8 natural greek symbols in pdflatex. For modern letters I use package `textalpha`, var greek symbols i workout through replacement and do not know how to do this correctly. Now the text is : ``` \documentclass[12pt]{article} \usepackage[utf8]{inputenc} \usepackage{textalpha} % GREEK Symbols var \DeclareUnicodeCharacter{03F0}{$\varkappa$} \DeclareUnicodeCharacter{03D1}{$\vartheta$} \usepackage{amssymb} % \for varkappa \begin{document} α β γ δ ε ζ η θ ι κ λ μ ν ξ ο π ρ ς σ τ υ φ χ ψ ω Α Β Γ Δ Ε Ζ Η Θ Ι Κ Λ Μ Ν Ξ Ο Π Ρ Σ Τ Υ Φ Χ Ψ Ω ϑ ϰ \end{document} ``` It works but IF THE TEXT WILL BE JUST ``` $ϑ ϰ$ ``` it does not work. So in math mode the replacement of var greek symbols does not work. Can somebody help me? The questions are really 2: * is it any package for standard greek symbols instead of textalpha for text and math mode simultaneously? * what latex commands are for var greek symbols for text mode? Then we can use `\ifmmode` or `\TextOrMath` in `\DeclareUnicodeCharacter` for text to be correct. They are in math mode: `\varepsilon` ε `\varkappa` ϰ `\varphi` φ `\varpi` ϖ `\varrho` ϱ `\varsigma` ς `\vartheta` ϑ
https://tex.stackexchange.com/users/79349
To replace "var" greek symbols correctly
false
The [alphabeta](http://mirrors.ctan.org/language/greek/greek-fontenc/alphabeta-doc.pdf) package from [greek-fontenc](https://www.ctan.org/pkg/greek-fontenc) supports the use of literal Greek characters in text and math mode under 8-bit TeX (pdflatex). It extends "textalpha", so you may simply replace ``` - \usepackage{textalpha} + \usepackage[keep-semicolon,normalize-symbols]{alphabeta} ``` As the symbol variants have no semantic meaning in text and are have no separate code-points in the "LGR" font encoding,the distinction is lost in text mode. Select a font that contains your preferred letter shapes.
2
https://tex.stackexchange.com/users/288060
688137
319,233
https://tex.stackexchange.com/questions/687971
0
I am facing a problem when trying to get the maximum value of a table with large numbers. Here are two small MWE: With this simple comparison, I get the larger of two numbers: ``` \documentclass[tikz]{standalone} \usepackage{pgfplots} \pgfplotsset{compat = newest} \begin{document} \pgfkeys{/pgf/fpu=true,/pgf/fpu/output format=fixed} \pgfmathsetmacro\a{100000} \pgfmathsetmacro\b{200000} \pgfmathparse{\a > \b ? \a: \b} \edef\c{\pgfmathresult} Larger number: \c \pgfkeys{/pgf/fpu=false} \end{document} ``` However, if I put that comparison inside a `.code` handler in `\pgfplotsset`, I get a 'Dimension too large' Error. ``` \documentclass[tikz]{standalone} \usetikzlibrary{calc} \usepackage{pgfplots} \usepackage{pgfplotstable} \pgfplotsset{compat = newest} \usepgfplotslibrary{groupplots,dateplot} \begin{document} \begin{tikzpicture} \pgfplotsset{% test/.code={% \pgfkeys{/pgf/fpu=true,/pgf/fpu/output format=fixed} \pgfmathsetmacro\a{100000} \pgfmathsetmacro\b{200000} \pgfmathparse{\a > \b ? \a: \b} \edef\c{\pgfmathresult} Larger number: \c \pgfkeys{/pgf/fpu=false} } } \begin{axis}[test] \end{axis} \end{tikzpicture} \end{document} ``` It seems like the invocation of the fpu library has not worked here. Can you help me with this?
https://tex.stackexchange.com/users/272334
Invoke PGF/FPU inside \pgfplotsset
false
A direct workaround is just doing the calculation before `axiz` environment, possibly inside the outer `tikzpicture` environment. ``` \documentclass[tikz, margin=5pt]{standalone} % \usetikzlibrary{calc} \usepackage{pgfplots} % \usepackage{pgfplotstable} \pgfplotsset{compat = 1.18} % \usepgfplotslibrary{groupplots,dateplot} \usepackage{etoolbox} \begin{document} \begin{tikzpicture} \pgfkeys{/pgf/fpu=true,/pgf/fpu/output format=fixed} \pgfmathsetmacro\c{max(100000,200000)} \pgfkeys{/pgf/fpu=false} \begin{axis}[ymax=\c/10000] % ymax is set to 20 successfully \addplot coordinates {(1,1) (2,2)}; \end{axis} \end{tikzpicture} \end{document} ``` **Update** If the calculation result (`\c` in example above) is used only once, simply use ``` \begin{axis}[ymax={max(100000,200000)/10000}] ```
0
https://tex.stackexchange.com/users/79060
688138
319,234
https://tex.stackexchange.com/questions/69901
60
I want to write a sentence like "physics (from ancient greek φύσις)". But I don't know how to typeset the character "ύ" properly. Also I am not sure, if it is a good idea simply to use math-mode here to typeset the greek letters. So, what's the best way to typeset the ancient greek word φύσις? **Edit:** I should add that I just copied the word from wikipedia in this case, so the `xelatex` or `babel` solutions work very well since I can just copy the greek word into my latex source. But I don't know how I can insert those greek letters directly with my normal german keyboard layout.
https://tex.stackexchange.com/users/4011
How to typeset greek letters
false
If you just need a few words copied from somewhere, the simple pdfLaTeX solution is loading "textalpha": ``` \documentclass{article} \usepackage{textalpha} \begin{document} physics (from ancient greek φύσις) \end{document} ``` For Greek text with proper hyphenation and upcasing, use Babel with the Greek option and mark up Greek text parts with `\foreignlanguage{greek}{φύσις}`. You may use a selection of input methods, e.g. * literal Unicode: φύσις * LICR: \textphi'\textupsilon\textsigma\textiota\textfinalsigma For text marked up as Greek also * a [Latin transliteration](http://mirrors.ctan.org/macros/latex/contrib/babel-contrib/greek/babel-greek-doc.html##lgr-latin-transliteration): `\ensuregreek{f'usis}` * a mix: `\ensuregreek{φ\'uσ\textiotaς}`
2
https://tex.stackexchange.com/users/288060
688140
319,236
https://tex.stackexchange.com/questions/657106
1
I am writing my master's degree thesis in English. Although, I have to include abstract in Greek and I would like also to include it at the table of contents. Below the main code of tex is portrayed. Tex ``` \documentclass[hidelinks,12pt]{article} \usepackage[utf8]{inputenc} \usepackage[greek,english]{babel} \usepackage{textgreek} \usepackage{cmbright} \usepackage{ucs} \usepackage{babel} \usepackage{graphicx} \usepackage{natbib} \usepackage{caption} \usepackage{float} \usepackage{titlesec} \usepackage{hyperref} \usepackage[a4paper,width=150mm,top=25mm,bottom=25mm,bindingoffset=6mm]{geometry} \usepackage{fancyhdr} \usepackage{soul} \usepackage{xcolor} \usepackage{caption} \usepackage{ragged2e} \usepackage{indentfirst} \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amssymb} \pagestyle{fancy} %\title{Modern Investment Strategies in Hedge Funds} %\author{Nikolaos Minas} %\date{September 2022} \begin{document} %\begin{titlepage} \include{Titlepage} %\clearpage\thispagestyle{empty} %\end{titlepage} %\maketitle %\newpage \tableofcontents \fancyhead{} \fancyhead[RO,LE]{Modern Investment Strategies in Hedge Funds} \fancyfoot{} \fancyfoot[LE,RO]{\thepage} \fancyfoot[CO,RE]{Nikolaos Minas - MXAN2016} \captionsetup{singlelinecheck=false,labelsep=period,font=footnotesize,labelfont={bf}} \newpage \addcontentsline{toc}{section}{Abstract} \include{Introduction} \include{Chapter1} \include{Chapter2} \include{Chapter3} \include{Chapter4} \include{Chapter5} \bibliography{ref} \bibliographystyle{apalike} \end{document} ``` Tex Introduction contains the script in both english and greek.However, in Greek the font is not the same as in English whereas several letters are missing. Any ideas ? ``` \section*{Abstract} The scope of this dissertation is to prepare a thorough analysis of the hedge funds industry in order to examine the size and the performance of the market. This analysis was conducted by both a literature review and an empirical analysis of publicly available data and more specifically from Hedge Funds Research database. Examination of the hedge fund industry was conducted by calculating Sharpe Ratio, Sortino Ratio, Value at Risk as well as by applying a linear regression using the Jensen model. \paragraph{} Our conclusions indicate that the aggregate performance of hedge funds throughout the period of 2010-2021 presented a notable decline, a fact which is observed in both literature review and the empirical analysis. The dissertation is divided into five chapters for better understanding. Initially, Chapter 1 is an introductory to the Hedge Funds, its characteristics, and their limitations as an asset class. Chapter 2 provides a thorough description of each hedge fund strategy. Chapter 3 indicates a literature review among the size and performance of hedge funds. Next comes Chapter 4 which presents the empirical analysis applied in order to determine the performance of hedge funds. Finally, Chapter 5 concludes the thesis and presents the main outcomes as well as its limitations and the suggestions for possible future research. \newpage \section*{\textbf{Περίληψη}} \paragraph{} O σκοπός της παρούσας μεταπτυχιακής εργασίας είναι η ανάλυση των Hedge Funds ως προς τόσο το μέγεθός τους σαν επενδυτικό προϊόν όσο και οι επιδόσεις τους. Για την ανάλυση λήφθηκε υπόψιν τόσο η υφιστάμενη βιβλιογραφία, όσο και μια ανάλυση δεδομένων τα οποία προέκυψαν από την βάση δεδομένων Hedge Funds Research Database. Η εν λόγω ανάλυση βασίστηκε στον προσδιορισμό των Sharpe Ratio Sortino Ratio, Value at Risk, καθώς και της εφαρμογής μιας γραμμικής παλινδρόμησης βάσει του μοντέλου του Jensen. \paragraph{} Από την παρούσα έρευνα ως κύριο συμπέρασμα προέκυψε το γεγονός ότι τα hedge funds από το 2010 έως το 2021 παρουσιάζουν μια σημαντική πτώση ως προς την απόδοσή τους, γεγονός που αντικατοπτρίζεται τόσο στην βιβλιογραφική όσο και στην εμπειρική έρευνα. Η παρούσα μεταπτυχιακή έργασία χωρίζεται σε πέντε κεφάλαια με σκοπό την καλύτερη κατανόηση του αντικείμένου που πραγματεύεται η παρούσα για τον εκάστοτε αναγνώστη. Το πρώτο κεφάλαιο αποτελείται από μια εισαγωγή ως προς τα Hedge Funds, τα χαρακτηριστικά τους καθώς και τους περιορισμούς που τα διακατέχουν. Στη συνέχεια το δεύτερο κεφάλαιο παρουσιάζει μια αναλυτική αναφορά ως προς τις κύριες στρατηγικές των Hedge Funds. Το τρίτο κεφάλαιο αναλύει την βιβλιογραφική ανασκόπηση και καταλήγει στον προσδιορισμό τόσο του μεγέθους των Hedge Funds όσο και της αποδοτικότητάς τους. Επόμενο είναι το τέταρτο κεφάλαιο, στο οποίο γίνεται αναφορά στην ανάλυση δεδομένων για τον προσδιορισό των αποδόσεων των hedge funds. Τέλος, το κεφάλαιο 5 ολοκληρώνει την παρούσα έρευνα και παρουσιάζει τα κύρια συμπεράσματα που προέκυψαν, τους περιορισμούς καθώς και ορισμένες προτάσεις του συγγραφέα για τυχόν μελλοντική έρευνα. ```
https://tex.stackexchange.com/users/279991
Greek Language Issue
false
There are several things to fix, but here's the idea. ``` \documentclass[hidelinks,12pt]{book} %\usepackage[utf8]{inputenc}% not needed \usepackage[greek,english]{babel} %\usepackage{textgreek}% not needed \usepackage{cmbright} %\usepackage{ucs}% obsolete \usepackage{graphicx} \usepackage{natbib} \usepackage{caption} %\usepackage{float}% don't use [H] \usepackage{titlesec} \usepackage{geometry} \usepackage{fancyhdr} \usepackage{soul} \usepackage{xcolor} \usepackage{ragged2e} \usepackage{indentfirst} \usepackage{amsmath} %\usepackage{amsfonts} \usepackage{amssymb} \usepackage{hyperref} \geometry{ a4paper, width=150mm, top=25mm, bottom=25mm, bindingoffset=6mm, headheight=15pt, % <- as asked by fancyhdr } \DeclareFontFamilySubstitution{LGR}{\rmdefault}{neohellenic} \pagestyle{fancy} \fancyhead{} \fancyhead[RO,LE]{Modern Investment Strategies in Hedge Funds} \fancyfoot{} \fancyfoot[LE,RO]{\thepage} \fancyfoot[CO,RE]{Nikolaos Minas - MXAN2016} \captionsetup{singlelinecheck=false,labelsep=period,font=footnotesize,labelfont={bf}} %\title{Modern Investment Strategies in Hedge Funds} %\author{Nikolaos Minas} %\date{September 2022} \begin{document} %\begin{titlepage} %\include{Titlepage} %\clearpage\thispagestyle{empty} %\end{titlepage} %\maketitle %\newpage \tableofcontents \cleardoublepage \section*{Abstract} \addcontentsline{toc}{section}{Abstract} The scope of this dissertation is to prepare a thorough analysis of the hedge funds industry in order to examine the size and the performance of the market. This analysis was conducted by both a literature review and an empirical analysis of publicly available data and more specifically from Hedge Funds Research database. Examination of the hedge fund industry was conducted by calculating Sharpe Ratio, Sortino Ratio, Value at Risk as well as by applying a linear regression using the Jensen model. Our conclusions indicate that the aggregate performance of hedge funds throughout the period of 2010-2021 presented a notable decline, a fact which is observed in both literature review and the empirical analysis. The dissertation is divided into five chapters for better understanding. Initially, Chapter 1 is an introductory to the Hedge Funds, its characteristics, and their limitations as an asset class. Chapter 2 provides a thorough description of each hedge fund strategy. Chapter 3 indicates a literature review among the size and performance of hedge funds. Next comes Chapter 4 which presents the empirical analysis applied in order to determine the performance of hedge funds. Finally, Chapter 5 concludes the thesis and presents the main outcomes as well as its limitations and the suggestions for possible future research. \clearpage \section*{\foreignlanguage{greek}{Περίληψη}} \addcontentsline{toc}{section}{\foreignlanguage{greek}{Περίληψη}} \begin{otherlanguage}{greek} O σκοπός της παρούσας μεταπτυχιακής εργασίας είναι η ανάλυση των \foreignlanguage{english}{Hedge Funds} ως προς τόσο το μέγεθός τους σαν επενδυτικό προϊόν όσο και οι επιδόσεις τους. Για την ανάλυση λήφθηκε υπόψιν τόσο η υφιστάμενη βιβλιογραφία, όσο και μια ανάλυση δεδομένων τα οποία προέκυψαν από την βάση δεδομένων \foreignlanguage{english}{Hedge Funds Research Database}. Η εν λόγω ανάλυση βασίστηκε στον προσδιορισμό των \foreignlanguage{english}{Sharpe Ratio Sortino Ratio}, \foreignlanguage{english}{Value at Risk}, καθώς και της εφαρμογής μιας γραμμικής παλινδρόμησης βάσει του μοντέλου του Jensen. Από την παρούσα έρευνα ως κύριο συμπέρασμα προέκυψε το γεγονός ότι τα \foreignlanguage{english}{hedge funds} από το 2010 έως το 2021 παρουσιάζουν μια σημαντική πτώση ως προς την απόδοσή τους, γεγονός που αντικατοπτρίζεται τόσο στην βιβλιογραφική όσο και στην εμπειρική έρευνα. Η παρούσα μεταπτυχιακή έργασία χωρίζεται σε πέντε κεφάλαια με σκοπό την καλύτερη κατανόηση του αντικείμένου που πραγματεύεται η παρούσα για τον εκάστοτε αναγνώστη. Το πρώτο κεφάλαιο αποτελείται από μια εισαγωγή ως προς τα \foreignlanguage{english}{Hedge Funds}, τα χαρακτηριστικά τους καθώς και τους περιορισμούς που τα διακατέχουν. Στη συνέχεια το δεύτερο κεφάλαιο παρουσιάζει μια αναλυτική αναφορά ως προς τις κύριες στρατηγικές των \foreignlanguage{english}{Hedge Funds}. Το τρίτο κεφάλαιο αναλύει την βιβλιογραφική ανασκόπηση και καταλήγει στον προσδιορισμό τόσο του μεγέθους των Hedge Funds όσο και της αποδοτικότητάς τους. Επόμενο είναι το τέταρτο κεφάλαιο, στο οποίο γίνεται αναφορά στην ανάλυση δεδομένων για τον προσδιορισό των αποδόσεων των hedge funds. Τέλος, το κεφάλαιο 5 ολοκληρώνει την παρούσα έρευνα και παρουσιάζει τα κύρια συμπεράσματα που προέκυψαν, τους περιορισμούς καθώς και ορισμένες προτάσεις του συγγραφέα για τυχόν μελλοντική έρευνα. \end{otherlanguage} \end{document} ```
2
https://tex.stackexchange.com/users/4427
688144
319,237
https://tex.stackexchange.com/questions/688153
2
Is there a way to have pages of fixed width (e.g. width of A4 or letter format) and arbitrary height? What I mean by that is that you write the content normally and at some point you insert something like `\pagebreak` and a new page starts? The page is as high as needed to fit the content in between `\pagebreak`s.
https://tex.stackexchange.com/users/163534
Page of arbitrary height
true
I think You fix the `geometry` of first page in the preamble. Then fix the `newgeometry` of the second page just before the `\newpage`. Then... But You: 1. need to know the lenght of each page 2. have the paper to print this?
0
https://tex.stackexchange.com/users/24644
688162
319,241
https://tex.stackexchange.com/questions/688160
0
I'm using a macro to build a table dynamically, but I can't manage to color the cell with `SetCell` dynamically using a counter. The colors are defined like `color@1`, `color@2`, ... and I'm using a counter to loop through the values to build the table content and color the cells. This is a stripped version of the whole project I'm working on, so I can't change the syntax of the colors. Here is a non-NWE : ``` \documentclass[]{article} \usepackage{babel} \usepackage{xcolor} \usepackage{graphicx} % Enhanced Picture \usepackage{chngcntr} % Change counters \usepackage{etoolbox} % Class manipulation \usepackage{tabularray} % New table style \UseTblrLibrary{functional} % Storing table data in macro \UseTblrLibrary{counter} % BEamer splitting tables \definecolor{BXcolor}{rgb}{0.5, 0.0, 0.13} \colorlet{BXcolorFG}{white} % Color for the gradations \definecolor{color@1}{RGB}{255, 221, 0} \colorlet{color@2}{orange} \definecolor{color@3}{RGB}{255, 0, 0} \definecolor{color@4}{RGB}{35, 35, 35} \colorlet{colorEmpty}{black!10} % Colors for the text above the gradations \colorlet{colorFG@}{cyan} \colorlet{colorFG@1}{black} \colorlet{colorFG@2}{black} \colorlet{colorFG@3}{black} \colorlet{colorFG@4}{white} \newcount\tableLines \newcounter{tableLine} \newcommand\storeTableData[1]{ \setcounter{tableLine}{0}%\the\numexpr4-#1} \def\tabledata{} \tableLines=4 \loop \addto\tabledata{ \stepcounter{tableLine} \def\tablelinecolor{\arabic{tableline}} test & \SetCell{color@\arabic{tableline}} \textcolor{color@\arabic{tableLine}}{Test} & Test \\ } \advance \tableLines -1 \ifnum \tableLines>0\relax \repeat }% \IgnoreSpacesOn \prgNewFunction \printTableData {} { % Simple function to return the content of the macro inside the table \prgReturn {\tlUse \tabledata} } \IgnoreSpacesOff \newcommand{\displayTable}[1]{% % Build the table data \storeTableData{#1} % Draw the table \begin{tblr}[evaluate=\printTableData]{Q[c,m]Q[c,m]X[l]} Test & Test & TEst \\ \printTableData \end{tblr} } \begin{document} \displayTable{test} \end{document} ``` I'm getting this error: ``` ! Package xcolor Error: Undefined color `color@\arabic {tableline}'. ``` This makes me thing that the macro `\arabic{tableline}` is not expanded to its content. How can I solve this ?
https://tex.stackexchange.com/users/28926
Macro to define color within SetCell
true
Using (value of) counter `rownum` provided by `tabularray` in stead of counter `tableLine`: ``` \addto\tabledata{% test & \SetCell{ bg=color@\inteval{\arabic{rownum}-1}, fg=colorFG@\inteval{\arabic{rownum}-1} } Test & Test \\ } ``` It seems the `counter` library from `tabularray` package is not as powerful as expected. Full example ``` \documentclass[]{article} \usepackage{babel} \usepackage{xcolor} \usepackage{graphicx} % Enhanced Picture \usepackage{chngcntr} % Change counters \usepackage{etoolbox} % Class manipulation \usepackage{tabularray} % New table style \UseTblrLibrary{functional} % Storing table data in macro \UseTblrLibrary{counter} % BEamer splitting tables \definecolor{BXcolor}{rgb}{0.5, 0.0, 0.13} \colorlet{BXcolorFG}{white} % Color for the gradations \definecolor{color@1}{RGB}{255, 221, 0} \colorlet{color@2}{orange} \definecolor{color@3}{RGB}{255, 0, 0} \definecolor{color@4}{RGB}{35, 35, 35} \colorlet{colorEmpty}{black!10} % Colors for the text above the gradations \colorlet{colorFG@}{cyan} \colorlet{colorFG@1}{black} \colorlet{colorFG@2}{black} \colorlet{colorFG@3}{black} \colorlet{colorFG@4}{white} \newcount\tableLines \newcounter{tableLine} \newcommand\storeTableData[1]{ \setcounter{tableLine}{0}%\the\numexpr4-#1} \def\tabledata{} \tableLines=4 \loop \addto\tabledata{% test & \SetCell{ bg=color@\inteval{\arabic{rownum}-1}, fg=colorFG@\inteval{\arabic{rownum}-1} } Test & Test \\ } \advance \tableLines -1\relax \ifnum \tableLines>0\relax \repeat }% \IgnoreSpacesOn \prgNewFunction \printTableData {} { % Simple function to return the content of the macro inside the table \prgReturn {\tlUse \tabledata} } \IgnoreSpacesOff \newcommand{\displayTable}[1]{% % Build the table data \storeTableData{#1} % Draw the table \begin{tblr}[evaluate=\printTableData]{Q[c,m]Q[c,m]X[l]} Test & Test & TEst \\ \printTableData \end{tblr} } \begin{document} \displayTable{test} \end{document} ``` **Update** `\SetCell` in first cell of each row ``` \addto\tabledata{% \SetCell{ bg=color@\inteval{\arabic{rownum}-1}, fg=colorFG@\inteval{\arabic{rownum}-1} } test & Test & Test \\ } ```
4
https://tex.stackexchange.com/users/79060
688163
319,242
https://tex.stackexchange.com/questions/660612
0
I am trying to put a Verilog code listing in my document, but it returns a Latex error when processing the comment lines, here is the MWE: ``` \documentclass[12pt,letterpaper,twoside]{book} \usepackage[spanish]{babel} \usepackage{listings} \renewcommand{\lstlistingname}{Listado} \begin{lstlisting}[language=Verilog] /*Descripción estructural de un multiplexor 2 a 1*/ //interfaz I/O del módulo module mux(f,a,b,sel); \end{lstlisting} ``` These are the compiling errors I get: ! LaTeX Error Invalid UTF-8 byte "B3. ! LaTeX Error ! LaTeX Error Invalid UTF-8 byte sequence (�\expandafter) If I erase the lines of comments the document compiles fine. After some research, I have used \UseRawInputEncoding command as suggested here: [Package inputenc Error: Invalid UTF-8 byte 147](https://tex.stackexchange.com/questions/429190/package-inputenc-error-invalid-utf-8-byte-147) but when I do it my environment does not process the accented letters, so I need to put the literal command \'{a}. Given that I have 50+ pages in the document, seems like a chore to hunt down every accent in it, is there a more efficient way to do this? (addendum: the encoding command \usepackage[utf8]{inputenc} doesn't work either)
https://tex.stackexchange.com/users/282317
lstlisting environment doesn't compile because code comments
false
I ran into the same problem and was able to bypass it by using luatex instead of xetex.
0
https://tex.stackexchange.com/users/110591
688165
319,243
https://tex.stackexchange.com/questions/636760
0
I have a huge problem, I don't know what happened but suddenly Greek characters are not shown in the PDF file after the compilation! I even did copy-paste in old TeX codes that worked fine and now Greek characters are not shown in the internal PDF viewer and the PDF file! I removed and reinstalled TeX Live and TeXstudio, but it did not help. Do you have any idea why I started facing this problem? I use Ubuntu, if this matters. ``` \documentclass{article} \usepackage{ucs} \usepackage[utf8x]{inputenc} \usepackage[greek,english]{babel} \newcommand{\en}{\selectlanguage{english}} \newcommand{\gr}{\selectlanguage{greek}} \begin{document} \en Α line of text in English. \gr Μια γραμμή κειμένου στα Ελληνικά. \end{document} ```
https://tex.stackexchange.com/users/265202
Greek characters not shown in pdf file!
false
If Greek characters "suddenly" dissapear, without change to the source file, the most likely cause is compiling with `xelatex` or `lualatex` instead of `pdflatex`. The default font with Xe/LuaTeX is "Latin Modern" which, in line with its name, supports the Latin script but not Greek. You will have to set up a different font for the complete document with "fontspec" or for the Greek text parts with "babel" or "polyglossia". The Babel guide has a short section on "Selecting fonts". Unfortunately, missing characters are not reported on the console. However, there are warnings like ``` Missing character: There is no ι (U+03B9) in font [lmroman10-regular]:+tlig;! Missing character: There is no α (U+03B1) in font [lmroman10-regular]:+tlig;! Missing character: There is no γ (U+03B3) in font [lmroman10-regular]:+tlig;! ``` in the `.log` file.
0
https://tex.stackexchange.com/users/288060
688169
319,245
https://tex.stackexchange.com/questions/106790
10
I am writing my master’s thesis with the [`ulthese`](http://www.ctan.org/pkg/ulthese) class, which is now part of MiKTeX and TeX Live. This class is based on memoir and is fairly flexible, but assumes the use of pdfTeX and sets the font encoding to `T1`. Furthermore, the University requires the use of Computer Modern/Latin Modern or a standard PostScript font (e.g. Times or Palatino). My thesis is primarily in French, with citations in English and polytonic Greek. With `inputenc`’s `utf8` option, the `babel` package, and the `textalpha` package from the `lgrx` bundle my bases seem to be covered. I have decided to use Palatino as the main text font (with the `mathpazo` package) and, because this font family does not cover extended greek, the CB Greek fonts are automatically used instead in `babel`’s `\textgreek` commands and `{otherlanguage}{polutonikogreek}` environments. I have no problem with CB Greek in itself, but it does not blend optimally with Palatino and I would like to use another font’s extended Greek characters. I know that the Type 1 version of Libertine has polytonic Greek (I have checked the `.pfb` files in FontForge), but I do not know how to use Libertine’s glyphs in the appropriate environments. In fact, I have made a test in which I only used Libertine throughout the document instead of Palatino/Mathpazo, but still Libertine’s Greek was not used and the CB fonts were substituted. My question is: how can I automatically switch to another font inside `babel`’s commands and environments on a per-language basis? I am looking for something similar to `polyglossia`’s `\newfontfamily\greekfont[Script=Greek,⟨...⟩]{⟨font⟩}`. I know that the `lgrx` bundle offers a `substitutefont` package, but I am not sure whether that is what I need, as I do not yet understand what the package does exactly. If there is no “high-level” solution, will I have to use LaTeX’s font-related commands? If there is no readily available method to use Libertine’s extended Greek, I could be content with Kerkis, which is already set up for automatic use and has many niceties, but I would be very happy if I could use Libertine. What is more, even if I were to use Kerkis for Greek text I would still need to (and *want* to) use Palatino for the main text, so the switch to Kerkis would have to be confined to Greek environments and commands. Here follows a minimal working example compiled with a fully updated MacTeX 2012 on OS X 10.8, with pdfTeX. Some commands and options in the preamble are specific to `ulthese` and I include them to show the complete use case (for example, I use `ulthese`’s specific `hypperef` color setup and I use `hyperref`’s `unicode` option in order to get polytonic Greek text to display correctly in PDF bookmarks). ``` \documentclass[12pt,nonatbib,english,polutonikogreek,francais]{ulthese} \usepackage[utf8]{inputenc} \usepackage{textalpha} \usepackage[osf]{mathpazo} \usepackage{microtype} \chapterstyle{southall} \setsecheadstyle{\Large\mdseries} \setsubsecheadstyle{\large\mdseries} \setsubsubsecheadstyle{\mdseries\scshape} \usepackage[unicode]{hyperref} \hypersetup{colorlinks,allcolors=ULlinkcolor} \frenchbsetup{% CompactItemize=false, ThinSpaceInFrenchNumbers=true } \titre{Un mémoire sur la philosophie grecque} \auteur{Un étudiant en philosophie} \programme{Maîtrise en Philosophie} \annee{9999} \MA \begin{document} \chapter{Introduction à la \textgreek{φύσις} et autres} Pour les Grecs, la \textgreek{φύσις} a plusieurs sens. D’ailleurs, c’est le cas de plusieurs mots. \begin{otherlanguage}{polutonikogreek} σύμψηφός σοί εἰμι, ἔφη, τούτου τοῦ νόμου, καί μοι ἀρέσκει. \end{otherlanguage} \end{document} ```
https://tex.stackexchange.com/users/25493
Specifying a different font for polytonic Greek in pdfTeX with Babel
false
Nowadays,a simple `\usepackage{libertine}` does the trick. To combine fonts, the NFSS font framework for 8-bit TeX provides `\DeclareFontFamilySubstitution` (see [LaTeX News, Issue 31](https://www.latex-project.org/news/latex2e-news/ltnews31.pdf)). ``` \documentclass{article} \usepackage[greek,english]{babel} \usepackage{libertine} \DeclareFontFamilySubstitution{LGR}{\rmdefault}{artemisia} \begin{document} A line of text in English. \foreignlanguage{greek}{Μια γραμμή κειμένου στα Ελληνικά.} \end{document} ```
1
https://tex.stackexchange.com/users/288060
688172
319,246
https://tex.stackexchange.com/questions/687958
0
I have a simple LaTex file like the one below: ``` \documentclass{book} \usepackage{xepersian} \settextfont{B Zar} \makeatletter \bidi@patchcmd{\Hy@org@chapter}{% \addcontentsline{toc}{chapter}% {\protect\numberline{\thechapter}#1}% }{% \addcontentsline{toc}{chapter}% {\protect\numberline{\chaptername~\tartibi{chapter}}#1}% }{}{} \makeatother \begin{document} \tableofcontents \chapter{سلم} \section{یبسیبسیب} \chapter{بثیبسیب} \section{یبسیبسیب} \end{document} ``` But chapters in the table of content are still with numbers. I also changed to file to the one below, but nothing changed. ``` \documentclass{book} \usepackage{xepersian} \settextfont{B Zar} \def\@chapter[#1]#2{\ifnum \c@secnumdepth >\m@ne \if@mainmatter \refstepcounter{chapter}% \typeout{\@chapapp\space\thechapter.}% \addcontentsline{toc}{chapter}% {\protect\numberline{\chaptername~\tartibi{chapter}}#1}% \else \addcontentsline{toc}{chapter}{#1}% \fi \else \addcontentsline{toc}{chapter}{#1}% \fi \chaptermark{#1}% \addtocontents{lof}{\protect\addvspace{10\p@}}% \addtocontents{lot}{\protect\addvspace{10\p@}}% \if@twocolumn \@topnewpage[\@makechapterhead{#2}]% \else \@makechapterhead{#2}% \@afterheading \fi} \begin{document} \tableofcontents \chapter{سلم} \section{یبسیبسیب} \chapter{بثیبسیب} \section{یبسیبسیب} \end{document} ```
https://tex.stackexchange.com/users/298541
Can not change chapter number to tartibi in table of content
true
The `\Hy@org@chapter` is an hyperref macro. But even loading `hyperref` the patch attempt fails because original definition does not look like the one your provide (you could have used last argument to activate the "fail" branch to signal the problem). As per the second approach it seems to work, but you need `\makeatletter/\makeatother`.
1
https://tex.stackexchange.com/users/293669
688177
319,248
https://tex.stackexchange.com/questions/688182
0
i intent to create the command `\graphEdge` to streamline drawing graphs edges, it would take a list of arguments separated by `,` the function would then divide the arguments and iterate on it, creating a new `\draw` for each minus the last one. On the mwe there is some very rough idea of the function implementation, and an example of usage. MWE --- ``` \documentclass{standalone} \usepackage{xparse} \usepackage{tikz} \NewDocumentCommand\graphEdge{ s % #1 - dashed > {\SplitList{,}} o % #2 - position options > {\SplitList{,}} o % #3 - draw options >{\SplitList{,}} m % #4 - annotations >{\SplitList{,}} m % #5 - nodes }{ % i = interator \IfValueT{#5[i+1]}{ \draw[->,\IfBooleanT{#1}{dashed,}\IfValueT{#3[i]}{#3[i]}]% (#5[i]-x) --node[sloped,\IfValueTF{#2[i]}{#2[i]}{above}] {\(#4[i]\)}% (#5[i+1]-x); } } \begin{document} \begin{tikzpicture} % ======================= Nodes ====================== % % 1,2,3 \node (1-x) at (0, 0) {1}; \node (2-x) at (1, 1) {2}; \node (3-x) at (2, 1) {3}; \node (4-x) at (1,-1) {4}; % ======================= Edges ====================== % % \graphEdge{A,B}{1,2,3} \draw[->] (1-x) --node[sloped,above]{\(A\)} (2-x); \draw[->] (2-x) --node[sloped,above]{\(B\)} (3-x); % \graphEdge*{C,D}{1,4,3} \draw[->,dashed] (1-x) --node[sloped,above]{\(C\)} (4-x); \draw[->,dashed] (4-x) --node[sloped,above]{\(D\)} (3-x); \end{tikzpicture} \end{document} ```
https://tex.stackexchange.com/users/241136
Creating an edge command with iteration
true
You can use `l3clist`'s `\clist_item:nn` to access elements in a list directly, since it will be returned with an `\unexpanded`, we can safely use the `.expanded` handler to allow fore more than one option per item (otherwise, it would try to find the key `blue, '` in the example below). The elements of `#4` is used directly as the list for one `\foreach` loop where `\i` counts from 1 and `\j` counts from 2, though you can just use `\i + 1` and `l3clist` will evaluate that for you. Instead of setting `above` by default, I'm using `auto = left` which can be `swap`ped to `auto = right` by using the `'` key. (Although, you can set `above` and just define `'/.style = below` just for your nodes.) Code ---- ``` \documentclass[tikz]{standalone} \ExplSyntaxOn \NewDocumentCommand\graphEdge{ s % #1 - dashed o % #2 - position options o % #3 - draw options m % #4 - annotations m % #5 - nodes }{ \foreach[count=\i,count=\j from 2]\VALUE in {#4} \draw[ ->, \IfBooleanT{#1}{dashed}, style/.expanded=\IfValueT{#3}{\clist_item:nn{#3}{\i}}] (\clist_item:nn{#5}{\i}-x) to node[ sloped, auto=left, style/.expanded=\IfValueT{#2}{\clist_item:nn{#2}{\i}}]{\(\VALUE\)} (\clist_item:nn{#5}{\i+1}-x); } \ExplSyntaxOff \begin{document} \begin{tikzpicture} \node (1-x) at (0, 0) {1}; \node (2-x) at (1, 1) {2}; \node (3-x) at (2, 1) {3}; \node (4-x) at (1,-1) {4}; \graphEdge{A,B}{1,2,3} \graphEdge*[', {blue, '}][, bend right]{C,D}{1,4,3} \end{tikzpicture} \end{document} ``` Output ------ --- Here's the same example with the `graphs` library, unfortunatley I ran into [a bug where `name suffix` does not consider the target node properly](https://github.com/pgf-tikz/pgf/issues/1251). The proposed fix is included in the code below. Code ---- ``` \documentclass[tikz]{standalone} \usetikzlibrary{graphs, quotes} \tikzset{math node/.style={execute at begin node=$, execute at end node=$}} \makeatletter % https://github.com/pgf-tikz/pgf/issues/1251#issuecomment-1486886842 \def\tikz@@to@or@edge@@coordinate(#1){\tikz@scan@one@point\tikz@to@use@last@coordinate@as@target(#1)\tikz@to@or@edge@function} \def\tikz@to@use@last@coordinate@as@target#1{\iftikz@shapeborder\edef\tikztotarget{\tikz@shapeborder@name}\else\edef\tikztotarget{\the\tikz@lastx,\the\tikz@lasty}\fi} \makeatother \newcommand*\graphEdges[2][]{% \path[name suffix=-x,#1]graph[ use existing nodes,edge quotes={sloped,auto=left,math node}]{#2};} \begin{document} \begin{tikzpicture} \node (1-x) at (0, 0) {1}; \node (2-x) at (1, 1) {2}; \node (3-x) at (2, 1) {3}; \node (4-x) at (1,-1) {4}; \graphEdges{ 1 ->["A"] 2 ->["B"] 3, {[edge = dashed] 1 ->["C"' bend right] 4 ->["D"' blue] 3, } } \end{tikzpicture} \end{document} ```
1
https://tex.stackexchange.com/users/16595
688187
319,250
https://tex.stackexchange.com/questions/688170
0
I am stuck on the following: > > How to color the nodes of a graph in tikz with various colors? > > > I have written the following code: ``` \begin{figure} \centering \begin{tikzpicture} \node[shape=circle,draw=black] (0) at (0,0) {$0$}; \node[shape=circle,draw=black] (4) at (6,0) {$4$}; \node[shape=circle,draw=black] (1) at (3,-1) {$1$}; \node[shape=circle,draw=black] (2) at (3,-2) {$2$}; \node[shape=circle,draw=black] (3) at (3,-3) {$3$}; \node[shape=circle,draw=black] (5) at (3,1) {$5$}; \node[shape=circle,draw=black] (6) at (3,2) {$6$}; \node[shape=circle,draw=black] (7) at (3,3) {$7$}; \draw (0) -- (1); \draw (0) -- (2); \draw (0) -- (3); \draw (0) -- (4); \draw (0) -- (5); \draw (0) -- (6); \draw (0) -- (7); \draw (4) -- (1); \draw (4) -- (2); \draw (4) -- (3); \draw (4) -- (5); \draw (4) -- (6); \draw (4) -- (7); \end{tikzpicture} \end{figure} ``` I want to color the nodes as red, yellow, etc. Also I want to color the edges as red, yellow etc. But I am stuck on how to color the vertices in one figure and the edges in the other figure with different colors. **Note:** Please let me know how I can modify the existing code to add the colors to the vertices. Please dont suggest a different code altogether. Can someone please help me out?
https://tex.stackexchange.com/users/184856
Coloring the vertices in my graph
false
Have a look to this: ``` \documentclass{article} \usepackage{tikz} \begin{document} \begin{figure} \centering \begin{tikzpicture} \node[shape=circle,draw=black,fill=red] (0) at (0,0) {$0$}; \node[shape=circle,draw=black,fill=yellow] (4) at (6,0) {$4$}; \node[shape=circle,draw=black] (1) at (3,-1) {$1$}; \node[shape=circle,draw=black] (2) at (3,-2) {$2$}; \node[shape=circle,draw=black] (3) at (3,-3) {$3$}; \node[shape=circle,draw=black] (5) at (3,1) {$5$}; \node[shape=circle,draw=black] (6) at (3,2) {$6$}; \node[shape=circle,draw=black] (7) at (3,3) {$7$}; \draw[color=red] (0) -- (1); \draw[color=yellow] (0) -- (2); \draw[color=blue] (0) -- (3); \draw[color=purple] (0) -- (4); \draw[color=brown] (0) -- (5); \draw[color=pink] (0) -- (6); \draw[color=green] (0) -- (7); \draw[color=purple] (4) -- (1); \draw[color=brown] (4) -- (2); \draw[color=pink] (4) -- (3); \draw[color=green] (4) -- (5); \draw[color=red] (4) -- (6); \draw[color=yellow](4) -- (7); \end{tikzpicture} \end{figure} \end{document} ``` Which produce the following master peace:
2
https://tex.stackexchange.com/users/183803
688191
319,254
https://tex.stackexchange.com/questions/687657
0
I would like to justify text in lstlisting. If the line gets too long, there doesn't seem to be any way to automatically add a new line. Is there a way to justify text?
https://tex.stackexchange.com/users/209343
Justify text lstlisting
false
This is the best solution I have figured out. Let see if it fits you: ``` \documentclass{article} \usepackage{listings} \usepackage{xcolor} \lstset{ basicstyle=\ttfamily, columns=fullflexible, frame=single, breaklines=true, postbreak=\mbox{\textcolor{red}{$\hookrightarrow$}\space}, } \begin{document} \begin{lstlisting} Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. \end{lstlisting} \end{document} ``` Or without the arrows: ``` \documentclass{article} \usepackage{listings} \lstset{ basicstyle=\ttfamily, columns=fullflexible, frame=single, breaklines=true, } \begin{document} \begin{lstlisting} Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. \end{lstlisting} \end{document} ```
0
https://tex.stackexchange.com/users/183803
688193
319,255
https://tex.stackexchange.com/questions/688181
1
I usually use `$\circ$` for elementwise/pointwise product of vectors/matrices/functions. * I find `$\cdot$` unsuitable: it is often used for the dot product, so is ambiguous. * `$f \circ g$` is also ambiguous when working with functions, since it can mean composition. * The machine learning community seems to use `$\odot$` for this, and I think it makes the equations hard to read. Compare the sizes of the other operators to `$\odot$`: ``` $$a + a - a * a \times a \div a \cdot a \circ a \odot a$$ ``` I'd like to adjust `$\odot$` to take up roughly similar amounts of space and ink as `$+-*\times\div\circ\cdot$`, while also exactly matching their vertical centering and horizontal padding. Bonus points if this adjustment does not require importing any new latex packages, so could be tossed into Markdown Latex in a pinch. So far I've found `\op{{}_{{}^{\text{$\odot$}}}}`, which looks horrific in code, but renders as `$a\op{{}_{{}^{\text{$\odot$}}}} b$`. It's close but doesn't get the write vertical centering.
https://tex.stackexchange.com/users/28304
Smaller `\odot` for elementwise/pointwise product
true
You can use `\circ` with `\cdot` in the middle. ``` \documentclass{article} \usepackage{amsmath} \makeatletter \DeclareRobustCommand{\pdot}{\mathbin{\mathpalette\pdot@\relax}} \newcommand{\pdot@}[2]{% \ooalign{% $\m@th#1\circ$\cr \hidewidth$\m@th#1\cdot$\hidewidth\cr }% } \makeatother \begin{document} $x\pdot y$ (pdot) $x\odot y$ (odot) \end{document} ```
2
https://tex.stackexchange.com/users/4427
688197
319,257
https://tex.stackexchange.com/questions/688186
0
I have to change my counter level from 4 to 2 and now the theorems increase the section counter. I am using amsmath and amsthm packages, my old counter code is: ``` \usepackage{amssymb,amsmath,amsthm,mathrsfs} \theoremstyle{definition} % Defi style \newtheorem{defi}[subsubsection]{Definition} % defi \newtheorem{bei}[subsubsection]{Beispiel} % beispiel \theoremstyle{theorem} % Satz style \newtheorem{satz}[subsubsection]{Satz} % Satz = Theorem \newtheorem{lem}[subsubsection]{Lemma} % lemma \newtheorem{kor}[subsubsection]{Korollar} % korollar \newtheorem{prin}[subsubsection]{Prinzip} % prinzip \theoremstyle{remark} % bemerkung style \newtheorem*{bem}{Bemerkung} % bemerkung ``` I would like to have the following count: ``` 1 Chapter 1.1 Section 1.1 Definition 1.1.1 Subsection 1.2 Definition 1.3 Theorem 1.4 Example 1.5 Definition 1.1.2 Subsection 1.6 Theorem 1.2 Section 2 Chapter 2.1 Theorem 2.1 Section ... ``` The counter should be continuous and should not affect the chapter counter. Thanks in advance!!!
https://tex.stackexchange.com/users/297952
Theorem counter overwrites the (sub)section counter
true
You may want to double check your documentation. It's `\newtheorem{internaleName}[sharedCounter]{displayedText}[parentCounter]`. With `\newtheorem{internaleName}[subsubsection]{displayedText}`, you're saying you want the theorem to share the same counter as the subsubsections, so that they get incremented with each use. Instead, you want `\newtheorem{defi}{Definition}[chapter]`, so that the counter starts over with each chapter (and the numbering is `chapterNumber.defiNumber`). Subsequent commands would then be `\newtheorem{bei}[defi]{Beispiel}` so that it uses the same counter.
2
https://tex.stackexchange.com/users/107497
688199
319,258
https://tex.stackexchange.com/questions/688201
3
I'm pretty new to LaTeX. I'm trying to write a pretty simple graphic into a presentation with an aspect ratio of 16:9. I'm using the beamer package and the TikZ package, and this is what I have, which runs fine. ``` \documentclass[aspectratio=169]{beamer} \usepackage[utf8]{inputenc} \usepackage{tikz} \usetikzlibrary{tikzmark, arrows.meta} \begin{document} \begin{frame}[aspectratio=169] \[ \begin{tikzpicture}[baseline=(m.center), every node/.append style={font=\small}] \node (m) at (-6,0) { $\begin{bmatrix} 0 & d_{1,2} & \cdots & d_{1,n} \\ d_{2,1} & 0 & \cdots & d_{2,n} \\ \vdots & \vdots & \ddots & \vdots \\ d_{n,1} & d_{n,2} & \cdots & 0 \\ \end{bmatrix}$ }; \pause \node (eq) at (-.5, 0) { $\begin{aligned} \pi_1 &= \{S^1_1, S^1_2, \ldots, S^1_{q_1}\} \\ \pi_2 &= \{S^2_1, S^2_2, \ldots, S^2_{q_2}\} \\ \vdots \\ \pi_B &= \{S^B_1, S^B_2, \ldots, S^B_{q_B}\} \\ \end{aligned}$ }; \draw[->, thick, shorten >=5pt, shorten <=5pt] (m.east) -- (eq.west) node[midway, above, font=\tiny] {sampling} node[midway, below, font=\tiny] {EPA distribution}; \pause \node (pi_est) at (4.5, 1.5) {$\pi_{\text{estimate}}$}; \node (pngs) at (4.5, -2) {$\textbf{IMAGES}$}; \draw[->, thick, shorten >=5pt, shorten <=5pt] (eq.east) -- (pi_est.west) node[midway, sloped, above, font=\tiny] {estimation} node[midway, sloped, below, font=\tiny] {SALSO}; \draw[->, thick, shorten >=5pt, shorten <=5pt] (eq.east) -- (pngs.west) node[midway, sloped, above, font=\tiny] {Uncertainty Quantification}; \end{tikzpicture} \] \end{frame} \end{document} ``` Like I said, it runs fine and produces exactly what I want, but at the \end{frame} line it throws me a warning that says "Package keyval Error: aspectratio undefined". Anybody know what's wrong with my code? Thanks!
https://tex.stackexchange.com/users/298698
What does the "Package keyval Error: aspectratio undefined" error mean?
false
`aspectratio` is only a class option. You must not use it as frame option. What you get is not a warning, it is an error. The code does not run "fine". You should never ignore errors. After an error, latex only recovers enough to syntax check the rest of the document, producing something which might or might not be a valid pdf. The solution is simple: remove the invalid frame option from your code: ``` \documentclass[aspectratio=169]{beamer} \usepackage[utf8]{inputenc} \usepackage{tikz} \usetikzlibrary{tikzmark, arrows.meta} \begin{document} \begin{frame} \[ \begin{tikzpicture}[baseline=(m.center), every node/.append style={font=\small}] \node (m) at (-6,0) { $\begin{bmatrix} 0 & d_{1,2} & \cdots & d_{1,n} \\ d_{2,1} & 0 & \cdots & d_{2,n} \\ \vdots & \vdots & \ddots & \vdots \\ d_{n,1} & d_{n,2} & \cdots & 0 \\ \end{bmatrix}$ }; \pause \node (eq) at (-.5, 0) { $\begin{aligned} \pi_1 &= \{S^1_1, S^1_2, \ldots, S^1_{q_1}\} \\ \pi_2 &= \{S^2_1, S^2_2, \ldots, S^2_{q_2}\} \\ \vdots \\ \pi_B &= \{S^B_1, S^B_2, \ldots, S^B_{q_B}\} \\ \end{aligned}$ }; \draw[->, thick, shorten >=5pt, shorten <=5pt] (m.east) -- (eq.west) node[midway, above, font=\tiny] {sampling} node[midway, below, font=\tiny] {EPA distribution}; \pause \node (pi_est) at (4.5, 1.5) {$\pi_{\text{estimate}}$}; \node (pngs) at (4.5, -2) {$\textbf{IMAGES}$}; \draw[->, thick, shorten >=5pt, shorten <=5pt] (eq.east) -- (pi_est.west) node[midway, sloped, above, font=\tiny] {estimation} node[midway, sloped, below, font=\tiny] {SALSO}; \draw[->, thick, shorten >=5pt, shorten <=5pt] (eq.east) -- (pngs.west) node[midway, sloped, above, font=\tiny] {Uncertainty Quantification}; \end{tikzpicture} \] \end{frame} \end{document} ```
7
https://tex.stackexchange.com/users/36296
688202
319,260
https://tex.stackexchange.com/questions/688196
1
I would like to merge nodes [Bye1 and Bye2] as Bye 3 in the following MWE. ``` \documentclass[tikz,border=10pt]{standalone} \usepackage[edges]{forest} \begin{document} \begin{forest} forked edges, for tree={ l sep+=5pt, inner sep=1.5pt, grow'=east, font=\sffamily, edge+={darkgray, line width=1pt}, draw=darkgray, align=center, anchor=children}, before packing={where n children=3{calign child=2, calign=child edge}{}}, before typesetting nodes={where content={}{coordinate}{}}, where level<=0{line width=1pt}{line width=1pt}, [Testing [Hello, ] [Bye, [Bye1] [Bye2] ] ] \end{forest} \end{document} ```
https://tex.stackexchange.com/users/176106
How to merge two nodes as one in forest?
true
Make the `Bye3` node a child of `Bye2` and then `\draw` the missing edge. You can set `y` for `Bye3` to be the same as for `Bye` using `before drawing tree={y=y("!uu")}`. ``` \documentclass[tikz,border=10pt]{standalone} \usepackage[edges]{forest} \begin{document} \begin{forest} forked edges, for tree={ l sep+=5pt, inner sep=1.5pt, grow'=east, font=\sffamily, edge+={darkgray, line width=1pt}, draw=darkgray, align=center, anchor=children}, before packing={where n children=3{calign child=2, calign=child edge}{}}, before typesetting nodes={where content={}{coordinate}{}}, where level<=0{line width=1pt}{line width=1pt}, [Testing [Hello] [Bye, [Bye1, name=B1] [Bye2 [Bye3, name=B3, before drawing tree={y=y("!uu")}] ] ] ] \draw[darkgray, line width=1pt] (B1.east)--++(\forestoption{fork sep},0)|-(B3); \end{forest} \end{document} ```
2
https://tex.stackexchange.com/users/125871
688205
319,262
https://tex.stackexchange.com/questions/685345
0
Where can I find a table which shows the LaTeX commands for each Unicode Character if such a command exists? For example the LaTeX command for `∈` is `\in`
https://tex.stackexchange.com/users/178952
Where can I find a table which shows the LaTeX commands for each Unicode Character?
false
The list of math-mode symbols is [“Symbols Defined by Unicode-Math.”](http://mirrors.ctan.org/macros/unicodetex/latex/unicode-math/unimath-symbols.pdf) Many of the symbols listed under the Body Text section of [“The Comprehensive LaTeX Symbols List”](http://tug.ctan.org/info/symbols/comprehensive/symbols-a4.pdf) will map to Unicode if `fontspec` is loaded. In particular, those listed under LaTeX and `textcomp` are now enabled by the LaTeX kernel. Others require an additional package, such as `textalpha` for Greek or `tipauni` for the International Phonetic Alphabet. In text mode, most Unicode symbols can be entered into the UTF-8 source. LuaTeX and XeTeX should just work, if you select a font that supports all the characters you use. PDFLaTeX only supports precomposed characters, not combining accents, and generally requires you to load [an 8-bit font encoding that contains the character.](https://www.latex-project.org/help/documentation/encguide.pdf) You can define any missing Unicode symbol yourself, with the `newunicodechar` package. Finally, you can also request a given Unicode codepoint with `^^^^12ab`, `\char"12AB` or `\symbol{"12AB}`.
2
https://tex.stackexchange.com/users/61644
688208
319,263
https://tex.stackexchange.com/questions/688211
1
I've searched the site, and ended up using `footmisc` with `moderncv` to use footnotes, but the footnotes start at 0 ... not 1. I would like something like a dagger, but none of those solutions on the site worked. At the very least, I'd like it to start at 1. Here is a minimal example: ``` \documentclass[10pt,a4paper,sans]{moderncv} % possible options include font size ('10pt', '11pt' and '12pt'), paper size ('a4paper', 'letterpaper', 'a5paper', 'legalpaper', 'executivepaper' and 'landscape') and font family ('sans' and 'roman') \renewcommand{\familydefault}{\sfdefault} % to set the default font; use '\sfdefault' for the default sans serif font, '\rmdefault' for the default roman one, or any tex font name % modern themes \moderncvstyle{banking} % style options are 'casual' (default), 'classic', 'oldstyle' and 'banking' \moderncvcolor{black} % color options 'blue' (default), 'orange', 'green', 'red', 'purple', 'grey' and 'black' % character encoding \usepackage[utf8]{inputenc} % adjust the page margins \usepackage[margin=0.63in]{geometry} \setlength{\footskip}{5pt} \usepackage{import} \nopagenumbers{} % personal data \name{}{} \phone[mobile]{} \email{} \social{} \homepage{} %---------------------------------------------------------------------------------- % content %---------------------------------------------------------------------------------- \usepackage{footmisc} \begin{document} \cventry{}{}{}{}{} { \textbf{Relevant Courses Completed by Summer 2025:} Algorithms and Complexity\footref{class_disclaimer}, Programming Languages\footref{class_disclaimer}, Computer Networking, Real Analysis, Abstract Algebra\footref{class_disclaimer}, Digital Circuit Design \& Implementation, Compiler Construction, Probability Theory, Computer Security } \enlargethispage{\footskip} \footnotetext{\label{class_disclaimer}Enrolled Fall 2025} \end{document} ```
https://tex.stackexchange.com/users/295684
Footnotes starting at 0, not 1
false
You're using the `\footref` command improperly. You need to have at least one proper footnote containing the label and then use `\footref` for all the identical footnote markers you need. You can change the set of symbols used by creating a new set with `\DefineFNsymbols*`: ``` \documentclass[10pt,a4paper,sans]{moderncv} % possible options include font size ('10pt', '11pt' and '12pt'), paper size ('a4paper', 'letterpaper', 'a5paper', 'legalpaper', 'executivepaper' and 'landscape') and font family ('sans' and 'roman') \renewcommand{\familydefault}{\sfdefault} % to set the default font; use '\sfdefault' for the default sans serif font, '\rmdefault' for the default roman one, or any tex font name % modern themes \moderncvstyle{banking} % style options are 'casual' (default), 'classic', 'oldstyle' and 'banking' \moderncvcolor{black} % color options 'blue' (default), 'orange', 'green', 'red', 'purple', 'grey' and 'black' % character encoding \usepackage[utf8]{inputenc} % adjust the page margins \usepackage[margin=0.63in]{geometry} \setlength{\footskip}{5pt} \usepackage{import} \nopagenumbers{} % personal data \name{}{} \phone[mobile]{} \email{} \social{} \homepage{} %---------------------------------------------------------------------------------- % content %---------------------------------------------------------------------------------- \usepackage[symbol]{footmisc} \DefineFNsymbols*{cv}{\dagger\ddagger\S\P\|% {\dagger\dagger}{\ddagger\ddagger}} \setfnsymbol{cv} \begin{document} \cventry{}{}{}{}{} { \textbf{Relevant Courses Completed by Summer 2025:} Algorithms and Complexity\footnotemark, Programming Languages\footref{class_disclaimer}, Computer Networking, Real Analysis, Abstract Algebra\footref{class_disclaimer}, Digital Circuit Design \& Implementation, Compiler Construction, Probability Theory, Computer Security } \enlargethispage{\footskip} \footnotetext{\label{class_disclaimer}Enrolled Fall 2025} \end{document} ```
0
https://tex.stackexchange.com/users/2693
688212
319,265
https://tex.stackexchange.com/questions/652372
1
My MWE is, ``` \documentclass{article} \usepackage{glossaries} \makeglossaries \newglossaryentry{latex} { name=latex, description={Is a markup language specially suited for scientific documents} } \begin{document} should show below, but doesnt. \printglossaries \end{document} ``` produces the following PDF document with the text ('should show below, but doesnt. ') but no glossary. The glossary package has been installed/reinstalled. I am using WinEdt11 and PDFTeXify.
https://tex.stackexchange.com/users/63077
Very basic glossaries not working on MWE
false
Surprisingly, it is still not working when I cite the glossary entry in the text body: ``` \documentclass{article} \usepackage{glossaries} \makeglossaries \newglossaryentry{latex} { name=latex, description={Is a markup language especially suited for scientific documents} } \begin{document} \printglossaries You should cite the glossary entry: \gls{latex} % Reference the glossary entry \end{document} ``` However, when I add the `glossaries-extra` with the `automake` option, you get what you are looking for: ``` \documentclass{article} \usepackage{glossaries} \usepackage[nonumberlist,automake]{glossaries-extra} % nonumberlist avoids numbering the lsit \makeglossaries \newglossaryentry{latex} { name=latex, description={Is a markup language especially suited for scientific documents} } \begin{document} You should cite the glossary entry: \gls{latex} % Reference the glossary entry \printglossaries \end{document} ``` A little bit more customizable working example is: ``` \documentclass{article} \usepackage[nogroupskip,nonumberlist,symbols]{glossaries} \usepackage[automake]{glossaries-extra} \makeglossaries \newglossaryentry{latex} { name=latex, description={Is a markup language especially suited for scientific documents} } \begin{document} You should cite the glossary entry: \gls{latex} % Reference the glossary entry \printglossary[style=long,nonumberlist,title={List of abbreviations and acronyms\vspace{-0.3cm}}] \pagebreak \end{document} ```
0
https://tex.stackexchange.com/users/222785
688215
319,266
https://tex.stackexchange.com/questions/688216
1
Here is an example: ``` \documentclass[10pt,a4paper,sans]{moderncv} % possible options include font size ('10pt', '11pt' and '12pt'), paper size ('a4paper', 'letterpaper', 'a5paper', 'legalpaper', 'executivepaper' and 'landscape') and font family ('sans' and 'roman') \renewcommand{\familydefault}{\sfdefault} % to set the default font; use '\sfdefault' for the default sans serif font, '\rmdefault' for the default roman one, or any tex font name % modern themes \moderncvstyle{banking} % style options are 'casual' (default), 'classic', 'oldstyle' and 'banking' \moderncvcolor{black} % color options 'blue' (default), 'orange', 'green', 'red', 'purple', 'grey' and 'black' % character encoding \usepackage[utf8]{inputenc} % adjust the page margins \usepackage[margin=0.63in]{geometry} \usepackage{import} \nopagenumbers{} % personal data \name{Firstname}{Lastname} \phone[mobile]{+1 (111) 111-1111} \email{myemail@gmail.com} \social{https://www.linkedin.com/in/mylinkedin} \homepage{mywebsite.com} \pagenumbering{gobble} %---------------------------------------------------------------------------------- % content %---------------------------------------------------------------------------------- \begin{document} \makecvtitle \end{document} ``` My question is simple: How can I bring the title up closer to the top of the page so that there is less white space at the very top?
https://tex.stackexchange.com/users/295684
How to bring entire title area up?
false
If your resume is only one page long, you can adjust the `top` margin using [`geometry`](//ctan.org/pkg/geometry): ``` \usepackage[margin=0.63in,top=0.5in]{geometry} ``` `margin` sets all the margins, followed by a smaller specification just for the `top`. --- If your resume is more than one page long and you only want to achieve this for the first page, then insert a negative `\vspace` ([starred version, since you're at the top of the page](https://tex.stackexchange.com/q/33370/5764)): ``` \vspace*{-0.5in} \makecvtitle ```
0
https://tex.stackexchange.com/users/5764
688217
319,267
https://tex.stackexchange.com/questions/688181
1
I usually use `$\circ$` for elementwise/pointwise product of vectors/matrices/functions. * I find `$\cdot$` unsuitable: it is often used for the dot product, so is ambiguous. * `$f \circ g$` is also ambiguous when working with functions, since it can mean composition. * The machine learning community seems to use `$\odot$` for this, and I think it makes the equations hard to read. Compare the sizes of the other operators to `$\odot$`: ``` $$a + a - a * a \times a \div a \cdot a \circ a \odot a$$ ``` I'd like to adjust `$\odot$` to take up roughly similar amounts of space and ink as `$+-*\times\div\circ\cdot$`, while also exactly matching their vertical centering and horizontal padding. Bonus points if this adjustment does not require importing any new latex packages, so could be tossed into Markdown Latex in a pinch. So far I've found `\op{{}_{{}^{\text{$\odot$}}}}`, which looks horrific in code, but renders as `$a\op{{}_{{}^{\text{$\odot$}}}} b$`. It's close but doesn't get the write vertical centering.
https://tex.stackexchange.com/users/28304
Smaller `\odot` for elementwise/pointwise product
false
Using `\scalerel`: ``` \documentclass{article} \usepackage{amsmath} \usepackage{scalerel} \newcommand*{\pdot}{\mathbin{\scalerel*{\boldsymbol\odot}{\circ}}} \begin{document} $x\pdot y$ (pdot) $x\odot y$ (odot) \end{document} ``` --- **EDIT:** Using `\scalebox`: ``` \documentclass{article} \usepackage{amsmath} \usepackage{graphicx} \newcommand*{\centerodot}[1]{\boldsymbol{\vcenter{\hbox{\scalebox{#1}{\odot}}}}} \newcommand*{\pdot}[1][.5]{\mathbin{{\centerodot{#1}}}} \begin{document} $x\pdot y$ (pdot) $x\odot y$ (odot) \end{document} ``` The size of the `centered odot` can be adjusted by modifying the default scaling factor in the scalebox; .5 in this case.
2
https://tex.stackexchange.com/users/94293
688222
319,270
https://tex.stackexchange.com/questions/688176
0
Let me start of by saying I'm pretty new to LaTeX. I'm writing my master's thesis and the following problem has popped up: I'm writing in **XeLaTeX**. As I'm setting my chapters to get the general outline of the thesis I sometimes have to use the \*-sign after `\chapter`, not necessarily because I don't want them in the ToC (as a matter of fact, they need to be in it), but I don't want the 'chapter 1'-text on the page itself nor should they be numbered. I'm also using the `\fancyhdr`-package and this is where it starts to get a bit more complicated. This is part of the code: ``` \documentclass[11pt,twoside]{report} \usepackage{lipsum} \usepackage{xcolor} \usepackage{fontspec} %needed to write in Arial \usepackage[british]{babel} %language \usepackage{graphicx} % Required for inserting images \graphicspath{{images/}} \usepackage{hyperref} \usepackage{titlesec} \assignpagestyle{\chapter}{fancy} \linespread{1.3} % equal to 1.5 line-width (mandatory) \usepackage{caption} \usepackage{subcaption} \usepackage[a4paper,%width=150mm, top=30mm,bottom=40mm, left=21.2mm, right=21.2mm, heightrounded]{geometry} %header and footer \usepackage{fancyhdr} \pagestyle{fancy} \fancyhead{} \fancyhead[RO,LE]{\leftmark} \fancyhead[LO,RE]{\rightmark} \fancyfoot{} \fancyfoot[RO,LE]{\thepage} \fancyfoot[C]{Thesis Title} \renewcommand{\headrulewidth}{0.4pt} \renewcommand{\footrulewidth}{0.4pt} %due to little errors the following correction: \setlength{\headheight}{13.59999pt} %for compensation, see next line \addtolength{\topmargin}{-1.59999pt} \begin{document} \setmainfont{Arial} %\input{chapters/titlepage} < \input-files are empty at this moment in time. I was just getting the outline of the file. There is an ocasional \lipsum (see Introduction); I've now just placed it in the code. \chapter*{Preface} \addcontentsline{toc}{chapter}{Preface} %\input{chapters/preface} \chapter*{Societal outreach} \addcontentsline{toc}{chapter}{Societal outreach} %\input{chapters/societal outreach} \tableofcontents \addcontentsline{toc}{chapter}{Contents} \chapter*{Abstract} \addcontentsline{toc}{chapter}{Abstract} %\input{chapters/abstract} \chapter{Introduction} %\input{chapters/introduction} \lipsum[2] \end{document} ``` Now what does that do? it makes a header called 'CONTENTS' of the page of the ToC and the page that starts the abstract. Something that I don't want. It would be fine if both headers are empty (i.e. the way the header of Societal outreach is). Does anyone know a workaround? Thanks in advance!
https://tex.stackexchange.com/users/298682
Problem with the header of the ToC and following page using \fancyhdr
false
After a chat with you guys, I found a solution for my problem: I defined the plain-pagestyle to my liking and then applied them to everything up until the introduction. the extra code in the preamble is: ``` \fancypagestyle{plain}{ \pagestyle{fancy} \fancyhead{} \fancyfoot{} \fancyfoot[RO,LE]{\thepage} \fancyfoot[C]{Thesis Title} } \assignpagestyle{\chapter}{plain} ```
0
https://tex.stackexchange.com/users/298682
688223
319,271
https://tex.stackexchange.com/questions/687411
1
This is essentially a modified question of [1](https://tex.stackexchange.com/questions/148563/how-can-i-streamline-insertion-of-latex-math-mode-symbols-in-auctex) but with math fonts instead. What I want is an AucTex command to add to my `.emacs` to do the following: If I'm outside a math environment like `equation` or outside a pair of dollar signs `$`, If I press ``1 C`, `$\mathbb{C}$@` is inserted in the buffer where `@` denotes the position of the cursor. However, if I'm inside a math environment or inside a a pair of dollar signs, only `\mathbb{C}@` is inserted. I want ``2 C` to do the same as ``1 C` but with `\mathcal` instead. The insertion of math fonts is very common, so this would save a bit of time. I tried modifying the answer of @[giordano](https://tex.stackexchange.com/users/31416/giordano) but I couldn't do it.
https://tex.stackexchange.com/users/12484
How can I streamline insertion of math fonts in AucTeX?
false
Maybe you can use the font specifier facility provided by AUCTeX: When you're in math mode and you press `C-c C-f C-a`, it inserts `\mathcal{@}` and if you mark a portion of text, say `C`, and hit the keystroke, it inserts `\mathcal{C@}` (`@` donates the cursor position). You get the same thing for `\mathbb` by hitting `C-c C-f C-b`. The keystrokes are stored in `LaTeX-font-list` which is pre-defined like this: ``` (defcustom LaTeX-font-list '((?\C-a "" "" "\\mathcal{" "}") (?\C-b "\\textbf{" "}" "\\mathbf{" "}") (?\C-c "\\textsc{" "}") (?\C-e "\\emph{" "}") (?\C-f "\\textsf{" "}" "\\mathsf{" "}") (?\C-i "\\textit{" "}" "\\mathit{" "}") (?\C-l "\\textulc{" "}") (?\C-m "\\textmd{" "}") (?\C-n "\\textnormal{" "}" "\\mathnormal{" "}") (?\C-r "\\textrm{" "}" "\\mathrm{" "}") (?\C-s "\\textsl{" "}" "\\mathbb{" "}") (?\C-t "\\texttt{" "}" "\\mathtt{" "}") (?\C-u "\\textup{" "}") (?\C-w "\\textsw{" "}") (?\C-d "" "" t)) "Font commands used with LaTeX2e. See `TeX-font-list'.") ```
1
https://tex.stackexchange.com/users/76063
688226
319,273
https://tex.stackexchange.com/questions/688204
0
I am using author-date citations in biblatex-chicago with `cmsdate=both` to show the original year of publication. My document looks like: ``` \documentclass[12pt]{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{lmodern} \usepackage[english]{babel} \usepackage[backend=biber,authordate,cmsdate=both]{biblatex-chicago} \addbibresource{sources.bib} \usepackage[citecolor=blue]{hyperref} \begin{document} \autocite{Locke} \end{document} ``` using the bib file: ``` @book{Locke, author = "John Locke", date = 1980, origdate = 1690, title = "Second Treatise of Government", publisher = "Hackett", address = "Indianapolis, IN", } ``` gives me `(Locke [1690] 1980)`, where the years are hyperlinked to the references page. There seems to be two overlapping hyperlink borders on my citation, however. One around the entirety of `[1690] 1980` and a second one around `1690` only. This is not a huge problem, since both hyperlinks lead to the same citation, but the overlapping borders do look strange on a pdf document. Is there a way to keep only hyperlink around `[1690] 1980` only? (Or if not, around `1690` and `1980` separately?)
https://tex.stackexchange.com/users/298699
Two hyperlinks appear when using cmsdate=both
false
you could disable the internal link: ``` \documentclass[12pt]{article} \usepackage[T1]{fontenc} \usepackage{lmodern} \usepackage[english]{babel} \usepackage[backend=biber,authordate,cmsdate=both]{biblatex-chicago} \addbibresource{sources.bib} \usepackage[citecolor=blue]{hyperref} \makeatletter \AtBeginDocument{% \def\Hy@colorlink#1{\begingroup \long\def\blx@bibhyperref[##1]##2{##2}}} \makeatother \begin{document} \autocite{Locke} \end{document} ```
1
https://tex.stackexchange.com/users/2388
688229
319,274
https://tex.stackexchange.com/questions/688231
0
What's the LaTeX font most near Word's Footlight MT Light font? Word's font Footlight MT Light can be viewed here: <https://learn.microsoft.com/en-us/typography/font-list/footlight-mt>
https://tex.stackexchange.com/users/298723
Word's Footlight MT Light font in LaTeX
true
lualatex (or xelatex) can use the same system-installed fonts as other applications: ``` \documentclass{article} \usepackage{fontspec} \setmainfont{Footlight MT Light} \begin{document} Hello World. \end{document} ``` The font only has one style but if needed you can tell `fontspec`to use the same font but with faked features, mechanically making bold and slant ``` \documentclass{article} \usepackage{fontspec} \setmainfont[ BoldFont={Footlight MT Light}, ItalicFont={Footlight MT Light}, BoldItalicFont={Footlight MT Light}, BoldFeatures={FakeBold=2}, ItalicFeatures={FakeSlant=0.5}, BoldItalicFeatures={FakeBold=2,FakeSlant=0.5} ] {Footlight MT Light} \begin{document} Hello World. \textit{Hello World.} \textbf{Hello World.} \textit{\textbf{Hello World.}} \end{document} ```
3
https://tex.stackexchange.com/users/1090
688233
319,275
https://tex.stackexchange.com/questions/688238
0
I'm trying to use the \acro command to define acronyms in my LaTeX document, but I'm encountering an "Undefined control sequence" error. Here's a simplified version of my code: ``` \documentclass{report} \usepackage{acro} \begin{document} \chapter*{Liste des abréviations} \acro{CMS}{\emph{Content Management System}} \medskip \acro{baas}{\emph{Backend As A Service}} \medskip \acro{API}{\emph{Application Programming Interface}} \medskip \end{document} ``` I've included the acro package in the preamble, but I'm still getting the error. How can I fix this issue and successfully use the \acro command to define my acronyms? Any help or suggestions would be greatly appreciated. Thank you!
https://tex.stackexchange.com/users/294476
Undefined control sequence error for \acro command in LaTeX
true
To use the `acro` package you must define the acronyms in the preamble via the command `\DeclareAcronym{<ID>}{short=short text, long=long text}`. Please read the [acro manual](http://mirrors.ctan.org/macros/latex/contrib/acro/acro-manual.pdf) page #4 (*acro for the impatient*) To print the full list as an unnumbered chapter use `\printacronyms[display=all, name=Liste des abréviations]` The example shows the use of the `\ac{<id>}` command and the like in a document. ``` \documentclass{report} \usepackage{acro} \DeclareAcronym{cms}{short= C.M.S. , long=Content Management System} \DeclareAcronym{baas}{short= B. as S. , long=Backend As A Service} \DeclareAcronym{api}{short=API , long=Application Programming Interface} \begin{document} \begin{tabular}{ll} first time & \ac{cms} \\ second time & \ac{cms} \\ long & \acl{cms} \\ short & \acs{cms} \\ full & \acf{cms} \end{tabular} \printacronyms[display=all, name=Liste des abréviations] %Printing the full list \end{document} ```
3
https://tex.stackexchange.com/users/161015
688242
319,279
https://tex.stackexchange.com/questions/687952
1
I'm looking for software that can convert a circuit jpg/png file to Circuitikz (Latex) codes, just like the [image2latex-matrix](https://github.com/blaisewang/img2latex-mathpix) tool. Thank you
https://tex.stackexchange.com/users/298540
Is there any tool to convert a circuit diagram to circuitikz latex code?
true
This would be a *very* difficult task, although I understand that the software that does the same with formulas can help. Circuits geometry can be very complex, and extracting the structure from a pixmap is not trivial. So the answer is: ***No, not at this time.*** You can try some [GUI approach](https://tex.stackexchange.com/questions/26972/what-gui-applications-are-there-to-assist-in-generating-graphics-for-tex?noredirect=1&lq=1), but again, there is little of it specifically though for outputting a decent `circuitikz` code.
1
https://tex.stackexchange.com/users/38080
688243
319,280
https://tex.stackexchange.com/questions/688106
1
Is there a good way to make it so that the proof end marker (i.e., the `\qedsymbol`) looks one way for proofs of theorems, and a different way for proofs of lemmas? I know I could locally change the definition of `\qedsymbol` anytime a lemma proof comes up, but I'm wondering if there's a way to do this automatically, without manually redefining `\qedsymbol` each time. **Edit (Further Clarification):** Here's an alternate phrasing of my question: I have ``` \theoremstyle{definition} \newtheorem{theorem}{Theorem} \newtheorem{lemma}[theorem]{Lemma} ``` in my header to make `theorem` and `lemma` environments. I want it to be the case that `\begin{proof} \end{proof}` environments after theorems have different endmarkers when compared to `\begin{proof} \end{proof}` environments after lemmas. Is there a way I could do this? For example, is there a way I can easily make some sort of separate `lemmaproof` environment which has a different endmarker than the default `proof` environment?
https://tex.stackexchange.com/users/118947
What is the best way to have different thm environments have different proof end markers?
true
You can use LaTeX3's hook management tools to tap into execution of code after the end of environments. For example, ``` \AddToHook{env/theorem/after}{<stuff>} ``` would execute `<stuff>` `after` the `theorem` `env`ironment. This way you can update `\qedsymbol` after every specific theorem-like environment. ``` \documentclass{article} \usepackage{amsthm} \theoremstyle{definition} \newtheorem{theorem}{Theorem} \newtheorem{lemma}[theorem]{Lemma} % Default \qedsymbol is \openbox % Make any subsequent proof have unique \qedsymbol \AddToHook{env/theorem/after}{\renewcommand\qedsymbol{\openbox}} \AddToHook{env/lemma/after}{\renewcommand\qedsymbol{$\clubsuit$}} \begin{document} % Theorem \begin{theorem} This is a theorem. \end{theorem} \begin{proof} This is a proof of the theorem. \end{proof} % Lemma \begin{lemma} This is a lemma. \end{lemma} \begin{proof} This is a proof of the lemma. \end{proof} \begin{proof} This is a different proof of the lemma. \end{proof} % Theorem \begin{theorem} This is a theorem. \end{theorem} \begin{proof} This is a proof of the theorem. \end{proof} \end{document} ``` --- If you're interested in a theorem-style specific environment, you can use something like this: ``` \NewDocumentEnvironment{lemmaproof}{ }{% \RenewDocumentCommand{\qedsymbol}{}{$\clubsuit$}% proof-specific \qedsymbol \proof }{% \endproof } ``` The above updates `\qedsymbol` locally, inside the newly-defined `lemmaproof`, while still allowing the use of the `proof` environment's optional argument.
2
https://tex.stackexchange.com/users/5764
688247
319,283
https://tex.stackexchange.com/questions/688240
1
The entry in the bib file is: ``` @article{singhsetal2003, title={On the use of modified randomization device for estimating the prevalence of a sensitive attribute}, author={Singh, S and Horn, S and Singh, R and Mangat, NS}, journal={Statistics in transition}, volume={6}, number={4}, pages={515--522}, year={2003} } ``` I am citing it as `\cite{singhsetal2003}` which produces the citation Singh, Horn, Singh and Mangat (2003) instead of Singh et al. (2003), as intended. The other citations are correctly produced with et al. Any idea what is wrong here? ETA: I'm using ``` \catcode`'=9 \catcode``=9 \bibliography{bib2022} \bibliographystyle{agsm} ``` ETA: I am using TexLive 2023 with TexStudio editor. Here's a minimal working example: ``` \documentclass[12pt,a4paper,twoside,openright]{book} \usepackage[authoryear]{natbib} \begin{document} \cite{singhsetal2021} \bibliography{bib2022} \bibliographystyle{agsm} \end{document} ```
https://tex.stackexchange.com/users/267015
BibTex not citing one particular entry in et al. format
false
(too long for a comment, hence posted as an answer) I am *unable* to replicate the issue you say you're experiencing if I load either the `natbib` or the `har2nat` citation management package. ``` \documentclass{article} % or some other suitable document class % create a test bib file "on the fly": \begin{filecontents}[overwrite]{mybib.bib} @article{singhsetal2003, title = {On the use of modified randomization device for estimating the prevalence of a sensitive attribute}, author = {Singh, S and Horn, S and Singh, R and Mangat, NS}, journal = {Statistics in Transition}, volume = {6}, number = {4}, pages = {515--522}, year = {2003} } \end{filecontents} \usepackage{natbib} \bibliographystyle{agsm} \begin{document} \citet{singhsetal2003} \bibliography{mybib} \end{document} ```
0
https://tex.stackexchange.com/users/5001
688249
319,284
https://tex.stackexchange.com/questions/688250
1
I have a custom command `\goal{}` ``` \newcounter{goalcounter}[section] \newcommand\goal{\refstepcounter{goalcounter}{\textbf{Goal \thesection.\thegoalcounter}}} ``` Say in Section 1, I have `Our first \goal{} is to have fun`, which is rendered as `Our first Goal 1.1 is to have fun`. I want to reference this goal later, in another section as ``` Section 2 Recall that our Goal 1.1 in an earlier section was to have fun. ``` How do I do this? In other words, how do I access the section number where the goal was created, to reference it later. Currently, I just label as `\goal{\label{goal11}}` and then later reference as `... our Goal 1.\cref{goal11} in ...`. Is there a better way? Thanks a lot.
https://tex.stackexchange.com/users/298729
Print the Section Number while Referencing Custom Command
true
When using `\label`, the latest stepped counter (via `\refstepcounter`) is stored. Specifically, `\the<cntr>` for the counter `<cntr>`. So, you need to define the section numbering as part of the goal number in this way: ``` \renewcommand{\thegoalcounter}{\thesection.\arabic{goalcounter}} ```
0
https://tex.stackexchange.com/users/5764
688252
319,285
https://tex.stackexchange.com/questions/688251
3
I'm trying to draw a tree with `tikz` I've tried this: ``` \documentclass{report} \usepackage{tikz} \begin{document} \begin{tikzpicture}[nodes={draw, circle}] \path (0, 0) node (1a) {5}; (-2, -1) node (2a) {12}; \draw (1a)--(2a) \end{tikzpicture} \end{document} ``` I get `! Package pgf Error: No shape named `2a' is known.` How can I fix it? I would also like to tweak the links. If I omit the `\draw` part, only the first node is drawn. How can I draw 2 nodes without any link? Is there any way to draw with a thicker line?
https://tex.stackexchange.com/users/209343
Error drawing tree tikz
true
You are terminating the `\path` with a semicolon after making the `1a` node but not starting a new path, so the second `node` invocation does nothing. If you check the log the error is preceded by ``` Missing character: There is no ( in font nullfont! Missing character: There is no - in font nullfont! Missing character: There is no 2 in font nullfont! Missing character: There is no , in font nullfont! Missing character: There is no - in font nullfont! Missing character: There is no 1 in font nullfont! Missing character: There is no ) in font nullfont! Missing character: There is no n in font nullfont! Missing character: There is no o in font nullfont! Missing character: There is no d in font nullfont! Missing character: There is no e in font nullfont! Missing character: There is no ( in font nullfont! Missing character: There is no 2 in font nullfont! Missing character: There is no a in font nullfont! Missing character: There is no ) in font nullfont! Missing character: There is no 1 in font nullfont! Missing character: There is no 2 in font nullfont! Missing character: There is no ; in font nullfont! ! Package pgf Error: No shape named `2a' is known. ``` indicating the `(-2, -1) node (2a) {12};` line is trying to be printed rather than parsed. You also need a semicolon to terminate the `\draw` command. ``` \documentclass{report} \usepackage{tikz} \begin{document} \begin{tikzpicture}[nodes={draw, circle}] \path (0, 0) node (1a) {5} (-2, -1) node (2a) {12}; \draw (1a)--(2a); \end{tikzpicture} \end{document} ``` Depending on your use case though ``` \documentclass{report} \usepackage{tikz} \begin{document} \begin{tikzpicture}[nodes={draw, circle}] \node (1a) at (0, 0) {5}; \node (2a) at (-2, -1) {12}; \draw (1a)--(2a); \end{tikzpicture} \end{document} ``` might be easier to write.
5
https://tex.stackexchange.com/users/106162
688255
319,286
https://tex.stackexchange.com/questions/688251
3
I'm trying to draw a tree with `tikz` I've tried this: ``` \documentclass{report} \usepackage{tikz} \begin{document} \begin{tikzpicture}[nodes={draw, circle}] \path (0, 0) node (1a) {5}; (-2, -1) node (2a) {12}; \draw (1a)--(2a) \end{tikzpicture} \end{document} ``` I get `! Package pgf Error: No shape named `2a' is known.` How can I fix it? I would also like to tweak the links. If I omit the `\draw` part, only the first node is drawn. How can I draw 2 nodes without any link? Is there any way to draw with a thicker line?
https://tex.stackexchange.com/users/209343
Error drawing tree tikz
false
You have a semicolon after the first line of your `\path` command, so the next line doesn't belong to the path at all. So remove that semicolon and you get what you want. However, given the title of the question, if you are drawing trees, you really should use one of the tree drawing packages. The `forest` package is by far the best for this. I've added an example of how to draw a tree of the sort you seem to be constructing with `forest`. ``` \documentclass{report} \usepackage{tikz} \usepackage{forest} \begin{document} \begin{tikzpicture}[nodes={draw, circle}] \path (0, 0) node (1a) {5} (-2, -1) node (2a) {12}; \draw[very thick] (1a)--(2a); \end{tikzpicture} \forestset{my tree/.style={for tree={draw,circle,align=center,minimum size=2em,inner sep=1pt,s sep=1cm,edge={very thick}}}} \begin{forest}my tree [5 [12 [6 ] [7 ] ] [13 ] ] \end{forest} \end{document} ```
3
https://tex.stackexchange.com/users/2693
688257
319,287
https://tex.stackexchange.com/questions/427755
0
I'm trying to compile a LaTeX project with a rather complex document structure and obviously run into issues with `openout_any`. I've been reasoning that it's a bad idea to change that variable for LaTeX globally. On Linux I could run `openout_any=a pdflatex mydocument.tex` to apply it to that run only, however I'm actually using Windows (7), where that as far as I'm aware won't work. I already checked `pdflatex -help` and found no mention of a flag that would do any changes to `openout_any` for the run. Can anyone tell me a way to actually accomplish that short-time change?
https://tex.stackexchange.com/users/105538
Replacing openout_any=a pdflatex myfile.tex on Windows?
false
I came across this question because I wanted to know how to set openout\_any from command line. So I describe my solution and an alternative way to achieve the desired result, here. So your question is part of my answer: ``` openout_any=a pdflatex ../../../source/latex/file.ins ``` can be used inside the `doc/latex/file` folder together with the following content in `docstrip.cfg`: ``` \BaseDirectory{../../..} \UseTDS ``` At least with pdfTeX 3.141592653-2.6-1.40.24 this can be changed to the following command: pdflatex --cnf-line=openout\_any=a file.ins A better solution would be to use point $TEXMFOUTPUT to a common a directory which contains all generated files. It can also be given on as parameter to the parameter `--cnf-line` and avoids changing `openout_any` at all. A complete shell script could be ``` #!/bin/sh -x TEXMFOUTPUT="$(realpath ../../..)" cat >docstrip.cfg << EOF \BaseDirectory{$TEXMFOUTPUT} \UseTDS EOF pdflatex --cnf-line=TEXMFOUTPUT="${TEXMFOUTPUT}" file.ins ``` For batch scripts this would be similar.
0
https://tex.stackexchange.com/users/25948
688259
319,288
https://tex.stackexchange.com/questions/688254
0
I am making a beamer presentation and would like to know if there is a bibliography style that shows: 1st and 2nd author (and et al if there are more), and the year of publication.
https://tex.stackexchange.com/users/193150
Citation style that sets Author (with et al if greater or equal 3), Date
true
You could use `maxcitenames` option for the standard Biblatex style. For instance: ``` \usepackage[style=authoryear, maxcitenames=2]{biblatex} ``` This should do it. There are many Mord options to adjust the outcome. E.g. `min/maxbibnames`, `min/maxcitenames` etc.
1
https://tex.stackexchange.com/users/297560
688265
319,289
https://tex.stackexchange.com/questions/186235
18
I'm writing a piece whose bibliography with some technical reports, presentation, manuals, and just websites. In the .bib file, I need to decide whether to use 'howpublished' fields, or 'url' fields for the addresses of where these are at When should I use which of them? Note: I currently use the `abbrv` bibliography style, but I'd like a more general answer .
https://tex.stackexchange.com/users/5640
In BibTex, when should I use 'howpublished' and when 'url '?
false
I use this format `howpublished = {\url{your_link}}` for a clickable link in the bibliography, for example: ``` @misc{wslib2019, title={{WordStream Library}}, author={Nguyen, Huyen N.}, howpublished = {\url{https://github.com/huyen-nguyen/wordstream-library}}, year = {2019} } ```
0
https://tex.stackexchange.com/users/151275
688280
319,296
https://tex.stackexchange.com/questions/688287
0
The package `\usepackage{titling}` allows me to set the `\title` in the preamble, and call the title in my paper using `\thetitle`. I was wondering if there was something similar regarding figures and figure numbers. For example, if I add a figure into the middle of my essay, I need to go through the text and changing all instances of "Figure X" into "Figure Y", and "Figure Y" into "Figure Z" etc. Is there a way to associate figure numbers with a command, so that I can call the figure number, by doing something along the lines of `some text \somecommand some text`, where using `\somecommand` will become "Figure X", depending on the figure's number? I am using `\usepackage{graphicx}` to add images: ``` \begin{figure}[h] \centering \includegraphics{image.png} \caption{Caption.} \end{figure} ```
https://tex.stackexchange.com/users/298699
Variable for Figure Number
false
You don't need to hardcode the figure numbers by hand. Instead, you can put a label in your figure with, `\label{myLabel}` command in your figure environment. Then, you can cite your figure with `\ref{myLabel}` command throughout the document, this command gives you the number of the figure. Example: ``` \begin{figure}[h] \centering \includegraphics{image.png} \caption{Caption.} \label{myLabel} \end{figure} According to Figure~\ref{myLabel},... ``` This code will give an output like "According to Figure X,..." after the figure environment, where X will be the desired figure number. And if you insert/delete figures in the middle of the document, LaTeX recalculates the figure numbers automatically. Note that `~` character is used before the `\ref` command to put an unbreakable space between "Figure" and its number. You can check <https://www.overleaf.com/learn/latex/Referencing_Figures> for more information.
4
https://tex.stackexchange.com/users/287806
688292
319,301
https://tex.stackexchange.com/questions/688295
1
The following example creates 5 pages. Page 1 contains the `\part`, page 3 only shows the `\part`'s `\label`, and page 5 shows the `\chapter`. If I do not load `showkeys` then naturally, only 3 pages are created, the first for `\part` and the third for `\chapter`. ``` \documentclass{scrbook} \usepackage{showkeys} \begin{document} \part{First part}\label{part1} \chapter{Chapter one}\label{chap1} \end{document} ``` Is there an easy way to force the label shown for `\part` onto the same page as the `\part` itself so that no extra two pages are added?
https://tex.stackexchange.com/users/28449
Using the `showkeys` package adds two new pages after the `\part` page to show only the label key
true
Place the `\label` in the argument (which is safer for many things, not just `showkeys`) ``` \documentclass{scrbook} \usepackage{showkeys} \begin{document} \part{First part\label{part1}} \chapter{Chapter one\label{chap1}} \end{document} ```
1
https://tex.stackexchange.com/users/1090
688296
319,303
https://tex.stackexchange.com/questions/87441
3
I recently started learning LaTeX and though I found answers for almost all of my questions by looking online (and especially here), there is still one more thing I would like to be able to do but can't for the article I am writing: I would like to be able to specify the dimensions and the "subdimensions" below a matrix. To be clearer, let us take the following example: ``` $ D = \underbracket{\begin{pmatrix} D_1 & 0 & 0 & & & \\ 0 & \ddots & & & {\textrm{\huge 0}} & \\ 0 & 0 & D_n & & & \\ & & & & & \\ & \textrm{\huge 0} & & & {\textrm{\huge 0}} & \\ & & & & & \\ \end{pmatrix}}_N $ ``` this gives a nice matrix whith the dimension N specified as a bracket under the matrix. That is fine, however I would like to add a second bracket to specify the smaller dimension n of the inner block matrix right below the matrix (and possibly above the first main bracket) which is shorter, i.e. I would like it to extend from 1 to n and not all the way below the matrix. I am open to any solution, but the simpler the better for me :)
https://tex.stackexchange.com/users/23425
Specify dimensions of block matrices in Latex
false
Here is what you can do with `{pNiceMatrix}` of `nicematrix`. ``` \documentclass{article} \usepackage{nicematrix} \begin{document} $D = \begin{pNiceMatrix}[margin,columns-width=auto,nullify-dots] D_1 & 0 & 0 & \Block{3-3}<\LARGE>{0} & & \\ 0 & \Ddots & 0 \\ 0 & 0 & D_n \\ \\ \Block{3-3}<\LARGE>{0} & & & \Block{3-3}<\LARGE>{0} \\ \\ \\ \CodeAfter \UnderBrace{1-1}{3-3}{n} \UnderBrace[yshift=2mm]{7-1}{7-6}{N} \end{pNiceMatrix}$ \end{document} ```
0
https://tex.stackexchange.com/users/163000
688304
319,307
https://tex.stackexchange.com/questions/688279
0
I'm trying to use the CMU `\lambda` in my document because I prefer its appearance over the one from `newtxmath`. I had a similar sentiment about `\sum`, but I was able to find a [post](https://tex.stackexchange.com/a/187313/213708) that replaces the sum symbol. I tried looking into the font tables but couldn't make heads or tails over them, even after consulting the documentation. I'm just not sure what is the code for lambda; it seems "50 is \sum. Below is the MWE. ``` \documentclass[11pt,a4paper]{article} \usepackage[english]{babel} \usepackage[utf8]{inputenc} \usepackage{amsmath} \usepackage{amsfonts,theorem} \usepackage{amssymb} \usepackage{newtxtext} \usepackage{newtxmath} \usepackage{fonttable} \DeclareSymbolFont{cmlargesymbols}{OMX}{cmex}{m}{n} \DeclareSymbolFont{mdsymbols} {OMS}{mdput}{m}{n} \DeclareSymbolFont{mdlargesymbols}{OMX}{mdput}{m}{n} \DeclareMathDelimiter{\lbrace}{\mathopen}{mdsymbols}{"66}{mdlargesymbols}{"08} \DeclareMathDelimiter{\rbrace}{\mathclose}{mdsymbols}{"67}{mdlargesymbols}{"09} \DeclareMathSymbol{\braceld}{\mathord}{mdlargesymbols}{"7A} \DeclareMathSymbol{\bracerd}{\mathord}{mdlargesymbols}{"7B} \DeclareMathSymbol{\bracelu}{\mathord}{mdlargesymbols}{"7C} \DeclareMathSymbol{\braceru}{\mathord}{mdlargesymbols}{"7D} \let\sum\relax \DeclareMathSymbol{\sum}{\mathop}{cmlargesymbols}{"50} % \let\lambda\relax % \DeclareMathSymbol{\lambda}{\mathop}{cmlargesymbols}{???} \makeatletter \def\downbracefill{$\m@th \setbox\z@\hbox{$\braceld$}% \braceld\leaders\vrule \@height\ht\z@ \@depth\z@\hfill\braceru \bracelu\leaders\vrule \@height\ht\z@ \@depth\z@\hfill\bracerd$} \def\upbracefill{$\m@th \setbox\z@\hbox{$\braceld$}% \bracelu\leaders\vrule \@height\ht\z@ \@depth\z@\hfill\bracerd \braceld\leaders\vrule \@height\ht\z@ \@depth\z@\hfill\braceru$} \makeatother \let\textbraceleft\relax \let\textbraceright\relax \DeclareRobustCommand{\textbraceleft}{% {\fontfamily{mdput}\fontencoding{OMS}\selectfont\char"66}} \DeclareRobustCommand{\textbraceright}{% {\fontfamily{mdput}\fontencoding{OMS}\selectfont\char"67}} \begin{document} \fonttable{cmr12} \Huge \[ \sum_{n=1}^{\infty} \int_{-\infty}^{\infty} \lambda \] \end{document} ```
https://tex.stackexchange.com/users/213708
How to use Computer Modern lambda with newtxmath package?
true
``` \documentclass{article} \pagestyle{empty} \usepackage{newtxtext} \usepackage{newtxmath} \usepackage{amsmath} \DeclareSymbolFont{cmlargesymbols}{OMX}{cmex}{m}{n} \let\sum\relax \DeclareMathSymbol{\sum}{\mathop}{cmlargesymbols}{"50} \DeclareSymbolFont{cmletters}{OML}{cmm}{m}{it} \SetSymbolFont{cmletters}{bold}{OML}{cmm}{b}{it} \DeclareSymbolFontAlphabet{\mathnormal}{cmletters} \DeclareMathSymbol{\lambda}{\mathord}{cmletters}{"15} \begin{document} \begin{equation*} \sum_{n=1}^{\infty} \int_{-\infty}^{\infty} \lambda \end{equation*} \end{document} ```
1
https://tex.stackexchange.com/users/238422
688307
319,310
https://tex.stackexchange.com/questions/688299
1
This error is linked to “/usr/local/texlive/2022/texmf-dist/tex/latex/etoolbox/etoobox.sty, 1003” by the system. I do not know what this really means though I do find such definitions in a file of texlive 2023 with the same path installed in my computer’s C: drive. The detailed information of this errors reads as follows: ``` Or name \end... illegal, see p.192 of the manual. See the LaTeX manual or LaTeX Companion for explanation. Type H <return> for immediate help. ... l.1003 \edef#1{\the\numexpr#2}} Here is how much of TeX's memory you used: 23676 strings out of 477679 459511 string characters out of 5829514 763038 words of memory out of 5000000 42069 multiletter control sequences out of 15000+600000 470967 words of font info for 31 fonts, out of 8000000 for 9000 1141 hyphenation exceptions out of 8191 98i,1n,94p,437b,79s stack positions out of 10000i,1000n,20000p,200000b,200000s No pages of output. ``` The following is the working environment: ``` % if your latex compiler failed to compile, uncomment the command below: %\RequirePackage[2020-02-02]{latexrelease} \documentclass{clv3} \usepackage{hyperref} \usepackage{xcolor} \usepackage{linguex} \usepackage{booktabs} \usepackage{multirow} \usepackage{tabularx} \usepackage{xltabular} \usepackage{makecell} \usepackage{metalogo} \usepackage{array} \usepackage{tabto} \usepackage{booktabs} \usepackage[linguistics]{forest} \usepackage{tabto} \usepackage{amssymb} \let\oldemptyset\emptyset \let\emptyset\varnothing \definecolor{darkblue}{rgb}{0, 0, 0.5} \hypersetup{colorlinks=true,citecolor=darkblue, linkcolor=darkblue, urlcolor=darkblue} \bibliographystyle{compling} \usepackage{CJKutf8} \usepackage{linguex} \begin{document} content ... \end {document} ``` The system now fails to compile. Hope this is the (only) cause for it. Thanks for your help in advance.
https://tex.stackexchange.com/users/298759
LaTeX Error: Command \numdef already defined
true
It's quite simple. The `clv3` class does ``` \def\numdefname{Definition} \newtheorem{numdef}{\numdefname} ``` but `etoolbox` also wants to define `\numdef`. It's easy to fix this by aliasing the `numdef` environment, but there's a worse problem: the class also redefines `\document`, which is a very *bad thing*: see [Problem with Computational Linguistic Template - COLI - CLV3.cls](https://tex.stackexchange.com/q/627415/4427) ``` % save the kernel \document and \enddocument \let\latexdocument\document \let\latexenddocument\enddocument %%% \documentclass{clv3} % restore the original \let\document\latexdocument \let\enddocument\latexenddocument % add to the standard hooks \makeatletter \AtBeginDocument{% \if@filesw \immediate\openout\@mainqry=\jobname.qry \fi } \AtEndDocument{% \ifx\@biography\@empty\else{\par\ifbrief\vskip10pt\fi\biofont\noindent\@biography\par}\fi \immediate\closeout\@mainqry %\ifquery % \process@queries\clearpage %\else \ifodd\c@page\clearpage\thispagestyle{empty}\null\clearpage\else\clearpage\fi %\fi %\ifquery\clearpage\else\ifodd\c@page\clearpage\thispagestyle{empty}\null\clearpage\else\clearpage\fi\fi } \makeatother % alias numdef to cnumdef \NewCommandCopy{\cnumdef}{\numdef} \NewCommandCopy{\endcnumdef}{\endnumdef} \let\numdef\relax \let\endnumdef\relax \usepackage{xcolor} \usepackage{linguex} \usepackage{booktabs} \usepackage{multirow} \usepackage{tabularx} \usepackage{xltabular} \usepackage{makecell} \usepackage{metalogo} \usepackage{array} \usepackage{tabto} \usepackage{booktabs} \usepackage[linguistics]{forest} \usepackage{tabto} \usepackage{amssymb} \usepackage{CJKutf8} \usepackage{linguex} \usepackage{hyperref} \let\oldemptyset\emptyset \let\emptyset\varnothing \definecolor{darkblue}{rgb}{0, 0, 0.5} \hypersetup{colorlinks=true,citecolor=darkblue, linkcolor=darkblue, urlcolor=darkblue} \bibliographystyle{compling} \begin{document} content ... \end {document} ``` Note the placement of `\usepackage{hyperref}`, which should come last.
0
https://tex.stackexchange.com/users/4427
688309
319,311
https://tex.stackexchange.com/questions/687594
1
I'm still working on a Latex-template for my institution. So far everything runs fine and the former questions i asked here helped me a lot. Now, i want to adjust the different parts of the journals footer to meet the expected layout. I have a working solution using `\parbox` inside my `\lofoot`, `\cofoot` etc. commands that makes the footer contents show up as wanted. The authors should appear on the left side with a linebreak if there are several, the title should appear always right of the author section, also flushedright to the right margin of the textbody, also with a linebreak if needed (see MWE below). But i figured the fitting widths out only using trial and error. That's not how it should be (I'm kind of a perfectionist ;) ) Thus, i wanted to find out which macros inside the `scrlayer-scrpage` package define those commands and to adjust/renew them that they fit my needs. But, so far, i wasn't able to receive these informations. When i run `latexdef -p scrlayer-scrpage lefoot` inside the terminal or use `\meaning\lefoot` inside my document, for example, i get the phrase `macro:->\sls@renewelement {even}{left}{foot}`. So far, so good, but i couldn't figure out how to find the definition of the element `foot` (Running `latexdef` on `foot` produced only that it's `undefined` since `foot` is no command, running it on `sls@renewelement` didn't help either). I also searched inside the **.sty** file directly without a result. If i run `{\tracingall\lefoot}` inside the document the compilation process never ends and i can't find any informations in the log. Therefore, my question is not only about the mentioned adjustment of the footer, but also a **general** one on working deeper in Latex/Tex backend: How to get these kind of informations if I need to do it again – and this will be the case for sure since I'm only getting started with the template. Here is my MWE (I intentionnaly use the `article` class and no KOMA-class). I added my workaround solution only to the odd pages, so everyone can see the layout differences: ``` \documentclass[a4paper,12pt, twoside,% ]{article} \usepackage[T1]{fontenc} \usepackage{blindtext} \usepackage{geometry} \geometry{% inner=20mm, outer=60mm, top=15mm, bottom=20mm, marginparwidth=45mm, showframe % to show the margins } \usepackage[footwidth=textwithmarginpar,footsepline=0.4pt:text,ilines]{scrlayer-scrpage} \clearpairofpagestyles \ModifyLayer[addvoffset=2.5ex]{scrheadings.foot.odd} \ModifyLayer[addvoffset=2.5ex]{scrheadings.foot.even} \ModifyLayer[addvoffset=2.5ex]{scrheadings.foot.oneside} \ModifyLayer[addvoffset=2.5ex]{plain.scrheadings.foot.odd} \ModifyLayer[addvoffset=2.5ex]{plain.scrheadings.foot.even} \ModifyLayer[addvoffset=2.5ex]{plain.scrheadings.foot.oneside} \setkomafont{pagefoot}{\sffamily\tiny\normalshape} \ohead*{\pagemark} \lefoot*{Journal 2000, § 1--4} \cefoot*{A List of different authors who have written the current article} \refoot*{\bfseries The title of the current article which was written by the different authors mentioned on the left} \lofoot*{\parbox[t]{.35\textwidth}{A List of different authors who have written the current article}} \cofoot*{\hspace*{.13\textwidth}\parbox[t]{.5\textwidth}{\raggedleft\bfseries The title of the current article which was written by the different authors mentioned on the left}} \rofoot*{Journal 2000, § 1--4} \begin{document} \section{Section Heading} \blindtext[5] \end{document} ``` I'm sure the solution can be interpreted from reading *The TeXbook* or *TeX by Topic* or something similar, but it would save me an enormous amount of time if someone has a faster answer. The KOMA-script documentation wasn't as helpful so far. Thanks in advance for your helpful replies! **EDIT** The links provided in the comments are very helpful and I found a lot which I nedd and want to read to understand Latex even better. But the particular question remains unsolved and i couldn't find a solution. I still adjust the footer layout by using `parbox` and `hspace*` commands inside the `lefoot`... commands provided by the `scrlayer-scrpage` package. Inside the package the `\lefoot` command i.e. is defined as `macro:->\sls@renewelement {even}{left}{foot}`. *Has anyone the concrete answer where to find the definition of these three elements, so i can redefine them to fitting my needs?* Or is it generally a bad idea to change something as deep inside the package-tree/backend?
https://tex.stackexchange.com/users/297560
How to find macros to adjust footer (lefoot, cefoot etc.) with scrlayer-scrpage
true
You could use eg. ``` \lefoot*{Journal 2000, § 1--4} \refoot*{% \parbox[t][\ht\strutbox]{.5\textwidth}{\bfseries The title of the current article which was written by the different authors mentioned on the left}% \hspace*{.15\textwidth}% \parbox[t][\ht\strutbox]{.35\textwidth}{\raggedleft A List of different authors who have written the current article}% } \lofoot*{% \parbox[t][\ht\strutbox]{.35\textwidth}{A List of different authors who have written the current article}% \hspace*{.15\textwidth}% \parbox[t][\ht\strutbox]{.5\textwidth}{\raggedleft\bfseries The title of the current article which was written by the different authors mentioned on the left}% } \rofoot*{Journal 2000, § 1--4} ``` or ``` \refoot*{% \parbox{\textwidth}{% \parbox[t][\ht\strutbox]{.5\linewidth}{\bfseries The title of the current article which was written by the different authors mentioned on the left}% \hfill% \parbox[t][\ht\strutbox]{.35\linewidth}{\raggedleft A List of different authors who have written the current article}% }} \lofoot*{% \parbox{\textwidth}{% \parbox[t][\ht\strutbox]{.35\linewidth}{A List of different authors who have written the current article}% \hfill% \parbox[t][\ht\strutbox]{.5\linewidth}{\raggedleft\bfseries The title of the current article which was written by the different authors mentioned on the left}% }} ``` Example: ``` \documentclass[a4paper,12pt, twoside,% ]{article} \usepackage[T1]{fontenc} \usepackage{blindtext} \usepackage{geometry} \geometry{% inner=20mm, outer=60mm, top=15mm, bottom=20mm, marginparwidth=45mm, showframe % to show the margins } \usepackage[footwidth=textwithmarginpar,footsepline=0.4pt:text,ilines]{scrlayer-scrpage} \clearpairofpagestyles \ModifyLayer[addvoffset=2.5ex]{scrheadings.foot.odd} \ModifyLayer[addvoffset=2.5ex]{scrheadings.foot.even} \ModifyLayer[addvoffset=2.5ex]{scrheadings.foot.oneside} \ModifyLayer[addvoffset=2.5ex]{plain.scrheadings.foot.odd} \ModifyLayer[addvoffset=2.5ex]{plain.scrheadings.foot.even} \ModifyLayer[addvoffset=2.5ex]{plain.scrheadings.foot.oneside} \setkomafont{pagefoot}{\sffamily\tiny\normalshape} \ohead*{\pagemark} \ofoot*{Journal 2000, § 1--4} \refoot*{% \parbox[t][\ht\strutbox]{.5\textwidth}{\bfseries The title of the current article which was written by the different authors mentioned on the left}% \hspace*{.15\textwidth}% \parbox[t][\ht\strutbox]{.35\textwidth}{\raggedleft A List of different authors who have written the current article}% } \lofoot*{% \parbox[t][\ht\strutbox]{.35\textwidth}{A List of different authors who have written the current article}% \hspace*{.15\textwidth}% \parbox[t][\ht\strutbox]{.5\textwidth}{\raggedleft\bfseries The title of the current article which was written by the different authors mentioned on the left}% } \begin{document} \section{Section Heading} \blindtext[5] \end{document} ``` You could also use the default footwidth=text and declare additional layers for the marginpar in footer. Then it would be possible to use \ifoot\* and \ofoot\* for the entries aligned with the text.
1
https://tex.stackexchange.com/users/43317
688311
319,312
https://tex.stackexchange.com/questions/688273
3
So, I've tried to shade between two polar curves inside `r = 6 sin (\theta)` and outside `r = 2 + 2 sin(\theta)`. Using tikzfillbetween, I wish to only shade the crescent but it turned out the shaded area is quite abstract and not in the way I like it. Could someone improve my code in a way that I could shade the area in Cartesian system? Hopefully could be done by using fillbetween or anything simple for me to follow. Here is my MWE : ``` \documentclass{article} \usepackage{tikz} \usepackage{pgfplots} \pgfplotsset{compat=newest} \usepgfplotslibrary{fillbetween} \begin{document} \begin{center} \begin{tikzpicture} \begin{axis}[ axis equal, axis x line = middle, axis y line = middle, xlabel = $x$, ylabel = $y$, xtick = {-5, 0, 5}, minor x tick num = 4, ytick = {-5, 0, 5, 10}, minor y tick num = 4, xmin = -3.8, xmax = 3.8, ymin = -1.8, ymax = 6.8, font = \tiny, legend cell align={left}, ] \addplot[name path = A, data cs = polar, orange, smooth, thin, samples = 1000, domain = 0 : 360] (x, {6*sin(x)}); \addplot[name path = B, data cs = polar, magenta, smooth, thin, samples = 1000, domain = 0 : 360] (x, {2 + 2*sin(x)}); \addplot[gray!20, fill opacity = .3] fill between [of = A and B, soft clip = {domain = -2.6:2.6}]; \addlegendentry{{\color{black} $r = 6\sin\theta$}} \addlegendentry{{\color{black} $r = 2 + 2\sin\theta$}} \end{axis} \end{tikzpicture} \end{center} \end{document} ```
https://tex.stackexchange.com/users/222046
Polar curve shading error with fillbetween
false
You can use a regular `\fill` command with the `intersection segments` option to draw the crescent. Also, you should probably decrease the values for `samples` in order to fasten the compilation process: ``` \documentclass[border=10pt]{standalone} \usepackage{pgfplots} \pgfplotsset{compat=newest} \usepgfplotslibrary{fillbetween} \begin{document} \begin{tikzpicture} \begin{axis}[ axis equal, axis x line = middle, axis y line = middle, xlabel = $x$, ylabel = $y$, xtick = {-5, 0, 5}, minor x tick num = 4, ytick = {-5, 0, 5, 10}, minor y tick num = 4, xmin = -3.8, xmax = 3.8, ymin = -1.8, ymax = 6.8, font = \tiny, legend cell align={left}, ] \addplot[name path = A, data cs = polar, orange, smooth, thin, samples = 250, domain = 0 : 360] (x, {6*sin(x)}); \addplot[name path = B, data cs = polar, magenta, smooth, thin, samples = 250, domain = 0 : 360] (x, {2 + 2*sin(x)}); \fill[gray!20, opacity = .3, intersection segments = { of = A and B, sequence = {L2 -- R2[reverse]}, }] -- cycle; \addlegendentry{{\color{black} $r = 6\sin\theta$}} \addlegendentry{{\color{black} $r = 2 + 2\sin\theta$}} \end{axis} \end{tikzpicture} \end{document} ```
2
https://tex.stackexchange.com/users/47927
688321
319,320
https://tex.stackexchange.com/questions/688228
0
Using the following mwe: ``` % vim: spell spelllang=en ft=tex \documentclass[12pt,twoside,openright,english]{book} \usepackage{hyperref} \usepackage{lipsum} \usepackage[explicit]{titlesec} \usepackage{titletoc} \renewcommand{\thechapter}{\Roman{chapter}} \newcommand\periodafter[1]{#1.} \titleformat{\chapter}[display] {\normalfont\large\filcenter}{\filcenter\MakeUppercase{\chaptertitlename\ \periodafter{\thechapter}}}{0pt}{\periodafter{\uppercase{#1}}} \titleformat{\subsection} {\normalfont\small}{}{0em}{\hangindent=0.25in#1} \titlecontents{chapter} [0em] {\filcenter\normalfont\scshape} {\MakeUppercase{\chaptertitlename\ \thecontentslabel}\\\addvspace{5pt}\uppercase} {\MakeUppercase{\thecontentslabel}\\\addvspace{5pt}\uppercase} {}[\addvspace{5pt}] \titlecontents{section} [0em] {\hangindent=0.25in\small} {\contentslabel{0em}} {\contentslabel{0em}} {\titlerule*[1em]{.}\contentspage}[\addvspace{5pt}] \titlecontents{subsection} [0em] {\hangindent=0.25in\small} {} {} {\titlerule*[1em]{.}\contentspage}[\addvspace{5pt}] \setcounter{secnumdepth}{0} \hypersetup{ bookmarksdepth=1 } \begin{document} \tableofcontents \frontmatter \chapter{Foreword} \mainmatter \chapter{A} \subsection{\lipsum[1]} \chapter{B} \subsection{\lipsum[1]} \backmatter \chapter{C} \subsection{1} \lipsum[10] \newpage \subsection{2} \lipsum[10] \end{document} ``` Section C.1 and C.2 **show**, in the toc, the proper page numbers (5 and 6 respectively) However, clicking the red boxed number of either **both** bring you to page 5. This [question's answers and comments](https://tex.stackexchange.com/questions/183943/hyperref-links-in-toc-point-to-wrong-location-when-using-titletoc) suggests it to be an issue regarding versions and says its fixed in titletoc 2.11; however my (freshly updated and upgraded as I write this) texlive installation (using lualatex 1.17.0 (TeX Live 2023)) has versions v2.14 of titletoc/titlesec, and v7.00y of hyperref. Using the MWE from the accepted answer as is seems to produce the same issue.
https://tex.stackexchange.com/users/257555
bad hyperref and pdf bookmark targets when using titletoc/titlesec, but toc numbers are right
true
As the subsection is unnumbered there is no target, as mentioned in the documentation hyperref doesn't fully support titlesec (and hyperref will not change here, we avoid to add more patches to hyperref, titlesec should add support for targets). You can add one e.g. with ``` \titleformat{\subsection}{\normalfont\small}{}{0em}{\hangindent=0.25in\MakeLinkTarget[subsection]{}#1} ```
1
https://tex.stackexchange.com/users/2388
688322
319,321
https://tex.stackexchange.com/questions/56842
17
I write a lot of documents (agreements) based on `memoir` with the `article` option. Normal `pagestyle`is `plain` (page number centered in the footer). Sometimes a document is only one page long, and a page number is unnecessary. It is not much work to put a `\thispagestyle{empty}` after `\maketitle` (because `\maketitle` has hardcoded a `\thispagestyle{plain}` somewhere). But sometimes I forget this, and sometimes I add a word or two, and the document suddenly is two pages long. And it is of course much more fun to have LaTeX to do this automatically. By borrowing some code from Ulrike Fisher’s answer to [this question](https://tex.stackexchange.com/a/4258/9632), I was able to defining this macro: ``` \documentclass{article} \usepackage{lipsum,ifthen} \usepackage[lastpage]{zref} \makeatletter \zref@newprop*{numpage}{\the\value{page}} \zref@addprop{main}{numpage} \newcommand{\oneormorepages}% {\ifthenelse{\zref@extractdefault{LastPage}{numpage}{1}>1}% {\thispagestyle{plain}}% {\thispagestyle{empty}}% } \makeatother \title{Test} \author{Test Testson} \begin{document} \maketitle \oneormorepages \lipsum[1-60] %More than one page %\lipsum[1] % One page \end{document} ``` Is there better and simpler solutions? For example one that does not involve additional packages? To include the macro `\oneormorepages`in the text is a kludge. I can redefine `\maketitle`, but I am reluctant to that. Is there a better solution for integrating the test in the preamble? My goal is to include such test in a separate, private style- or class-file? **EDIT**: And here is the result I have used until today. I patch `\maketitle` on the fly using `\patchcmd` from `etoolbox`, a package I load for other purposes in the ‘real’ document: ``` \documentclass{article} \usepackage{lipsum,etoolbox} %% No page number if the document is a onepager \makeatletter \AtEndDocument{% \ifnum\value{page} > \@ne \immediate\write\@auxout{\global\let\string\@multipage\relax}% \fi } \newcommand*{\oneormorepages}{% \ifdefined\@multipage \thispagestyle{plain}% \else \thispagestyle{empty}% \fi } \patchcmd{\maketitle} {\thispagestyle{plain}}% {\oneormorepages}{}{} %% Change `plain` to `title` if you are using a `memoir` class \makeatother \title{Test} \author{Test Testson} \begin{document} \maketitle \lipsum[1-60] %More than one page %\lipsum[1] % One page \end{document} ``` *EDIT*: MWE is updated 28.09.2014 and improved based on comments from egreg and JFBU. Thanks a lot for all help! **FINAL EDIT 28.09.2014** Based on the discussion in [this question](https://tex.stackexchange.com/q/203403/9632) and [this answer](https://tex.stackexchange.com/a/165941/9632) to another question, I have a working solution not requiring any additional packages, working under KOMAscript and the standard classes and surviving `\pagenumbering{Roman}`. As egreg has pointed out, it is still not fool proof, but I have tried postponing the tests by loading the `atendvi`- and `atveryend`-packages from the `oberdiek`-bundle, and using commands from those packages. Then the tests fail. So for the MWEs below, we have to trust `\AtEndDocument`. (At least for the time being). Here are the MWEs: ``` \documentclass{article} \usepackage{lipsum} \makeatletter % You may remove this line if you change\@ne to 1 \AtEndDocument{\ifnum\value{page}=\@ne\thispagestyle{empty}{}\fi} % survives `\pagenumbering{Roman}` \makeatother % You may remove this line if you change\@ne to 1 \title{Test} \author{Test Testson} \begin{document} \maketitle \lipsum[1] \lipsum[1-6] % Turn on/off this line... \end{document} ``` If you need Roman numbering, you may also load `zref-totpages`and change the test to: ``` \AtEndDocument{\ifnum\ztotpages=\@ne\thispagestyle{empty}{}\fi} ``` Based on [this answer](https://tex.stackexchange.com/a/165888/9632), I have found a solution using `scrartcl`, `scrpage2` and `zref-totpages`, which also survives `\pagenumbering{Roman}`. You may make it more useful by adding additional code to the `false` or `true` parts of the test: ``` \documentclass{scrartcl} \usepackage{zref-totpages,lipsum,scrpage2} \pagestyle{scrplain} \clearscrheadfoot % You may use \@ne instead of 1 if you enclose the line in a `\makeatletter\makeatother` \cfoot[\ifnum\ztotpages=1 \else\pagemark\fi]{\pagemark} \begin{document} \lipsum[1] % automatically remove page number in a document with this line %\lipsum[1-6] % automatically keep page numbers in a document with this line \end{document} ``` And finally, one for the standard classes, conditionally redefining the `plain`-pagestyle. (`let\ps@plain\ps@empty` did not work). ``` \documentclass{article} \usepackage{lipsum,zref-totpages} \pagenumbering{Roman} \makeatletter \renewcommand{\ps@plain}{% \ifnum\ztotpages=\@ne\let\@mkboth\@gobbletwo \let\@oddhead\@empty\let\@oddfoot\@empty \let\@evenhead\@empty\let\@evenfoot\@empty{}% \fi} \makeatother \title{Test} \author{Test Testson} \begin{document} \maketitle \lipsum[1] \lipsum[1-6] % Turn on/off this line... \end{document} ``` Hopefully, it is useful.
https://tex.stackexchange.com/users/9632
Automatically remove page number if document has only one page (but not if two)
false
Current LaTeX already automatically defines `\@abspage@last` via the `.aux` file. Two compilation runs are necessary but no additional package at all: ``` \documentclass{article} \usepackage{lipsum} \makeatletter \newcommand{\oneormorepages}{% \def\singelpage{1}% \ifx\singelpage\@abspage@last \thispagestyle{empty}% \else \thispagestyle{plain}% \fi} \makeatother \title{Test} \author{Test Testson} \begin{document} \pagenumbering{Roman} \maketitle \oneormorepages %\lipsum[1-60] % Several pages \lipsum[1] % Single page %\newpage %\pagenumbering{arabic} %\lipsum[1] \end{document} ```
0
https://tex.stackexchange.com/users/6865
688325
319,324
https://tex.stackexchange.com/questions/688273
3
So, I've tried to shade between two polar curves inside `r = 6 sin (\theta)` and outside `r = 2 + 2 sin(\theta)`. Using tikzfillbetween, I wish to only shade the crescent but it turned out the shaded area is quite abstract and not in the way I like it. Could someone improve my code in a way that I could shade the area in Cartesian system? Hopefully could be done by using fillbetween or anything simple for me to follow. Here is my MWE : ``` \documentclass{article} \usepackage{tikz} \usepackage{pgfplots} \pgfplotsset{compat=newest} \usepgfplotslibrary{fillbetween} \begin{document} \begin{center} \begin{tikzpicture} \begin{axis}[ axis equal, axis x line = middle, axis y line = middle, xlabel = $x$, ylabel = $y$, xtick = {-5, 0, 5}, minor x tick num = 4, ytick = {-5, 0, 5, 10}, minor y tick num = 4, xmin = -3.8, xmax = 3.8, ymin = -1.8, ymax = 6.8, font = \tiny, legend cell align={left}, ] \addplot[name path = A, data cs = polar, orange, smooth, thin, samples = 1000, domain = 0 : 360] (x, {6*sin(x)}); \addplot[name path = B, data cs = polar, magenta, smooth, thin, samples = 1000, domain = 0 : 360] (x, {2 + 2*sin(x)}); \addplot[gray!20, fill opacity = .3] fill between [of = A and B, soft clip = {domain = -2.6:2.6}]; \addlegendentry{{\color{black} $r = 6\sin\theta$}} \addlegendentry{{\color{black} $r = 2 + 2\sin\theta$}} \end{axis} \end{tikzpicture} \end{center} \end{document} ```
https://tex.stackexchange.com/users/222046
Polar curve shading error with fillbetween
true
A very small variation of nice @Jasper Habicht answer (+1) with wee bit shorter code, bigger font size and smaller number of samples: ``` \documentclass[border=3pt]{standalone} \usepackage{pgfplots} \pgfplotsset{compat=1.18} \usepgfplotslibrary{fillbetween} \begin{document} \begin{tikzpicture} \begin{axis}[ axis lines = middle, axis equal, xlabel = $x$, ylabel = $y$, xtick = {-5, 0, 5}, minor x tick num = 4, ytick = {-5, 5}, minor y tick num = 4, xmin = -6, xmax = 6, ymin = -0.8, ymax = 6.8, font = \scriptsize, legend cell align={left}, data cs = polar, smooth, samples=90, domain=0:360 ] \addplot[name path = A, orange] (x, {6*sin(x)}); \addplot[name path = B, magenta] (x, {2 + 2*sin(x)}); \fill[gray!20, opacity = .3, intersection segments = {of = A and B, sequence = {L2 -- R2[reverse]}, }] -- cycle; \addlegendentry{{\color{black} $r = 6\sin\theta$}} \addlegendentry{{\color{black} $r = 2 + 2\sin\theta$}} \end{axis} \end{tikzpicture} \end{document} ```
2
https://tex.stackexchange.com/users/18189
688327
319,325
https://tex.stackexchange.com/questions/688316
2
When I cross-reference a theorem, why do only the number of the chapter and of the section appear? ``` \documentclass[x11names,oneside,12pt]{book} \usepackage{tcolorbox} \tcbuselibrary{theorems,breakable} \newtcbtheorem[number within=section]{thm}{Theorem}{ before skip=10pt, breakable, detach title, leftrule=2mm, before upper={\tcbtitle\quad}, coltitle=black, colback=black!3!white, colframe=black!10!white, fonttitle=\bfseries, arc=0mm, separator sign none, description delimiters parenthesis, terminator sign colon}{theo} \begin{document} \chapter{First Chapter} \section{First Section} \begin{thm}{}{}\label{thm} Statement. \end{thm} In Theorem \ref{thm}\dots \end{document} ```
https://tex.stackexchange.com/users/183151
When cross-referencing a theorem, only the numbers of the chapter and of the section appear
true
When working with theorem-like environments defined with the help of the [tcolorbox](https://www.ctan.org/pkg/tcolorbox) package, you must replace ``` \begin{thm}{}{}\label{thm} ``` with ``` \begin{thm}[label=thm]{}{} ``` This is explained in full detail (maybe even in excessive detail...) in section 4.21, labelled "Counters, Labels, and References", of the user guide of the [tcolorbox](https://www.ctan.org/pkg/tcolorbox) package. --- ``` \documentclass[x11names,oneside,12pt]{book} \usepackage{tcolorbox} \tcbuselibrary{theorems,breakable} \newtcbtheorem[number within=section]{thm}{Theorem}{ before skip=10pt, breakable, detach title, leftrule=2mm, before upper={\tcbtitle\quad}, coltitle=black, colback=black!3!white, colframe=black!10!white, fonttitle=\bfseries, arc=0mm, separator sign none, description delimiters parenthesis, terminator sign colon}{theo} \begin{document} \chapter{First Chapter} \section{First Section} %%\begin{thm}{}{}\label{thm} % <-- wrong \begin{thm}[label=thm]{}{} % <-- right Statement. \end{thm} In Theorem \ref{thm}, \dots \end{document} ```
1
https://tex.stackexchange.com/users/5001
688329
319,326
https://tex.stackexchange.com/questions/688326
2
I'm trying to cite a paper where there's an umlaut in the name of both one of the authors and of the journal. I've looked [here](https://tex.stackexchange.com/q/57743/212208) and [here](https://tex.stackexchange.com/q/134116/212208) and I've tried: ``` @article{ResonantBhabhafor1980, Author = {Reinhardt, J. and Scherdin, A. and M{\"{u}}ller, B. and Greiner, W.}, Journal = {Zeitschrift f{\"{u}}r Physik A Atomic Nuclei}, Number = {4}, Pages = {367--381}, Title = {Resonant Bhabha scattering at MeV energies}, Volume = {327}, Year = {1987} } ``` But I'm getting the error `Extra }, or forgotten \endgroup.` How can I avoid this? In case it's relevant, I'm including ``` \usepackage[backend=biber,sorting=none]{biblatex} ``` Extra context: putting the umlaut in the author field works, putting it in the journal field doesn't More context: i finally got a mwe going: ``` \documentclass[]{report} \usepackage[UKenglish]{babel} % useful to change date format \usepackage{csquotes} % prevents a warning with babel \usepackage{hyperref} \usepackage[backend=biber,sorting=none]{biblatex} \usepackage[capitalise]{cleveref} \addbibresource{Bibliography.bib} \usepackage{ulem} \begin{document} As discussed in \cite{ResonantBhabhafor1980}, Bhabha scattering provides an excellent method to study the potential existence of a particle of this nature. \newpage \printbibliography \end{document} ``` commenting either `\usepackage{ulem}` or `\usepackage[UKenglish]{babel}` stops the error
https://tex.stackexchange.com/users/212208
Writing accented letters in biblatex gives errors when also using the ulem and babel packages
true
Compiling your example with `pdflatex` produces an error ``` Extra }, or forgotten \endgroup. \UL@stop ... \UL@putbox \fi \else \egroup \egroup \UL@putbox \fi \ifnum \UL@... ``` This can be overcome by adding ``` \usepackage[T1]{fontenc} ``` to the preamble. In my example, I've moved the loading of `hyperref` and `cleveref` to the end, as is best practice with those packages. In this case, `hyperref` must be loaded before `cleveref`. ``` \documentclass[]{report} \usepackage[UKenglish]{babel} % useful to change date format \usepackage{csquotes} % prevents a warning with babel \usepackage[T1]{fontenc} \usepackage[backend=biber,sorting=none]{biblatex} \usepackage{ulem} \usepackage{hyperref} \usepackage[capitalise]{cleveref} \begin{filecontents}[overwrite]{\jobname.bib} @article{ResonantBhabhafor1980, Author = {Reinhardt, J. and Scherdin, A. and M{\"{u}}ller, B. and Greiner, W.}, Journal = {Zeitschrift f{\"{u}}r Physik A Atomic Nuclei}, Number = {4}, Pages = {367--381}, Title = {Resonant Bhabha scattering at MeV energies}, Volume = {327}, Year = {1987} } \end{filecontents} \addbibresource{\jobname.bib} \begin{document} \autocite{ResonantBhabhafor1980} \printbibliography \end{document} ```
5
https://tex.stackexchange.com/users/2693
688330
319,327
https://tex.stackexchange.com/questions/688350
2
I'm trying to use the `acronym` environment from the [`acronym` package](https://ctan.org/pkg/acronym) to typeset a list of acronyms in my document. I want to specify a non-standard plural form for an acronym using `\acroplural` (which, according to the [package documentation](http://mirrors.ctan.org/macros/latex/contrib/acronym/acronym.pdf), "is meant to be used in the acronym environment"), but doing so is giving me an error message. MWE --- ### Document ``` \documentclass{article} \usepackage{acronym,hyperref} \begin{document} \begin{acronym} \acro{POI}{point of interest} \acroplural{POI}{POIs}{points of interest} \end{acronym} \end{document} ``` ### Error Messages ``` LaTeX Warning: Hyper reference `acro:POI' on page 1 undefined on input line 8. LaTeX Warning: Hyper reference `acro:POI' on page 1 undefined on input line 8. document.tex:8: Undefined control sequence. \hyper@@link ->\let \Hy@reserved@a \relax \@ifnextchar [{\hyper@link@ }{\hyp... l.8 ...}{point of interest} \acroplural{POI}{POIs} {points of interest} document.tex:8: Argument of \AC@acroplurali has an extra }. <inserted text> \par l.8 ...}{point of interest} \acroplural{POI}{POIs} {points of interest} Runaway argument? {POI}{\hyper@link@ }\def \reserved@b {\hyper@link@ [link]}\futurelet \ETC. document.tex:8: Paragraph ended before \AC@acroplurali was complete. <to be read again> \par l.8 ...}{point of interest} \acroplural{POI}{POIs} {points of interest} [1] (./document.aux) ``` Related ------- [How to pluralize an acronym which ends in 'S' correctly?](https://tex.stackexchange.com/questions/38558) is a similar question, but it asks about defining a non-standard plural form *outside* of the `acronym` environment.
https://tex.stackexchange.com/users/272916
acronym package - acroplural not working in acronym environment
true
Omitting `hyperref` your code compiles but inserts a spurious `points of interest`, it would also lead `\aclp{POI}` to give `POIs` rather than `points of interest`. This is because the second argument of `\acroplural` (the short-form plural) is an optional argument and if supplied should be supplied as `\acroplural{POI}[POIs]{points of interest}`. From the package documentation: In this case it is not necessary to supply it as only the long-form plural is not given by appending an `s`. This issue is not specific to `\acroplural` or the `acronym` environment, it would also occur in `\newacroplural` and `\acrodefplural` which use the same syntax. ``` \documentclass{article} \usepackage{acronym} \begin{document} \begin{acronym} \acro{POI}{point of interest} \acroplural{POI}{points of interest} \end{acronym} \end{document} ``` However with `hyperref` there is a second issue if the optional argument is not supplied ``` \documentclass{article} \usepackage{acronym} \usepackage{hyperref} \begin{document} \begin{acronym} \acro{POI}{point of interest} \acroplural{POI}{points of interest} \end{acronym} \end{document} ``` giving the error > > > ``` > ! Undefined control sequence. > \hyper@@link ->\let \Hy@reserved@a > \relax \@ifnextchar [{\hyper@link@ }{\hyp... > l.8 \acroplural{POI}{points of interest} > > ``` > > This can be resolved as you noted in the comments by explicitly supplying the optional argument as `\acroplural{POI}[POIs]{points of interest}`. However the documentation of acronym seems quite clear that this should not be necessary which would make this a bug in the package. As `\acroplural{POI}{POIs}{points of interest}` is parsed as giving `POI` and `POIs` as the acronym and acronym long-form plural, and then just having the group `{points of interest}` following it (this is not swallowed as an argument as you can see by omitting `hyperref`). You therefore end up seeing the more severe `hyperref`-related error even though the first mistake was in syntax of `\acroplural`.
2
https://tex.stackexchange.com/users/106162
688351
319,338
https://tex.stackexchange.com/questions/657162
0
I try to change the numbering and formatting of my table(s). Currently I am working with this ``` \documentclass[twoside, titlepage=firstiscover, open=right, 11pt]{scrbook} \usepackage[utf8]{inputenc} \usepackage{mathpazo} \usepackage{graphicx} \usepackage{float} \usepackage{tabularx} \usepackage{threeparttablex} \usepackage[font=footnotesize, labelfont = bf]{caption} \newcolumntype{Y}{>{\centering\arraybackslash}X} \usepackage{threeparttable} \begin{document} \begin{table}[!h] \begin{threeparttable} \begin{footnotesize} \caption{My Table Title\\} \begin{tabularx}{\columnwidth}{@{}lYYYYY@{}} \toprule & \multicolumn{5}{c}{bla}\\ \cmidrule{2-6} this & is & some & really & random & text \\ \midrule bla & 0 & 1 & 2 & \textbf{3} & 4\\ blubb & 5 & 6 & 7 & 8 & 9\\ bla blubb & 10 & \textbf{11} & 12 & \textbf{13} & \textbf{14}\\ \bottomrule \end{tabularx} \begin{tablenotes}[flushleft] \footnotesize \item \textit{Note.} This is a note! \end{tablenotes} \label{some label} \end{footnotesize} \end{threeparttable} \end{table} \end{document} ``` With this code I get a table caption of this form: > > **Table 1.1.:** My table title. > > > I would rather - in accordance with APA7 - like to have this form: > > **Table 1.1** > > > *This is my table title.* > > > How can I change my code to achieve this?
https://tex.stackexchange.com/users/162871
Table caption and Table Numbering
false
This caption style can be relative easy implemented in the `talltblr` table, which is `tabularray` package way to write `threeparttable`s: ``` \documentclass[twoside, titlepage=firstiscover, open=right, 11pt]{scrbook} \usepackage{mathpazo} \usepackage{tabularray} \UseTblrLibrary{booktabs, counter} \usepackage[skip=0ex, width=\linewidth, format=plain, font = {small, sf}, labelfont = bf, labelsep = newline, singlelinecheck = off]{caption} \NewTblrTheme{captionof}% needed that talltblr instead of own caption settings % consider settings of the caption package {% \DefTblrTemplate{caption}{default}% {\addtocounter{table}{-1}% \captionof{table}{\InsertTblrText{caption}}% } } \begin{document} \begin{table}[!h] \begin{talltblr}[ theme = captionof, % <--- for considering caption package setup caption = {My Table Title}, label = {tab:???}, remark{Note:} = This is a note! % <--- "table notes" ]{colspec = {@{}l *{4}{X[c]} @{}} } \toprule \SetCell[r=2]{c} & \SetCell[c=5]{c} bla & & & & \\ \midrule this & is & some & really & random & text \\ \midrule bla & 0 & 1 & 2 & \textbf{3} & 4\\ blubb & 5 & 6 & 7 & 8 & 9\\ bla blubb & 10 & \textbf{11} & 12 & \textbf{13} & \textbf{14}\\ \bottomrule \end{talltblr} \end{table} \end{document} ```
0
https://tex.stackexchange.com/users/18189
688365
319,341
https://tex.stackexchange.com/questions/688334
1
I need that the biography to have this specific order and format: Author surname in all-caps and first name initials followed by a point, the document's title in italic, the editor, country, pages cited, number of volume, year. Example: > > DAL ZOTTO P., LARRE J.M., MERLET A., PICAU L., *Memotech Génie énergétique*, Editor Casteilla, France, pages 153 to 159, 2014. > > > Currently I'm using `biblatex`.
https://tex.stackexchange.com/users/298788
How do I format the bibliography to a specific order?
false
This is my first time answering a question here, so bear with me please in case my answer is not the best. Also you did not post any snippets with your question, so it makes answering a bit harder. Also, you did not mention how the citation should look in the text itself, which makes it a bit harder to know whether you will be able to use my suggestion, but here goes a possible solution: 1. Books do not have an address field. Since solutions to change that are more intricate, I find that simply inserting it in the Publisher field is easier. Reference to properties available for the book type: <https://www.bibtex.com/e/book-entry/> . I Also did that to the pages field, since it is usually printed at the end. **===== EDIT =====** As mentioned by [moewe](https://tex.stackexchange.com/users/35864/moewe) below, the property Location can be given to a @book entry type, and address, if used, remaps to location. In any case I tried using the address field during testing and still could not properly get it to fit your description of bibliography style, so maybe the solution I gave is still the least worse one. **===============** With those constraints in mind and the example you gave, I find that the style "apa" is the closest one to meet these requirements. In this style, the last author is preceded by "and" but this post over here had a great discussion on how to deal with this: [Biblatex: Remove 'and' before last author BUT leave it if there are only two authors](https://tex.stackexchange.com/questions/636780/biblatex-remove-and-before-last-author-but-leave-it-if-there-are-only-two-aut) ``` % Basic settings \documentclass[12pt, a4paper]{article} \usepackage[english]{babel} % Bibliography management \usepackage[backend=biber, style=authortitle, maxbibnames=99]{biblatex} \addbibresource{References.bib} % Snippet for removing the last "and" in the case of multiple authors. \DeclareNameAlias{sortname}{family-given} % order of surname and first name in the bibliography \DeclareDelimFormat{finalnamedelim}{% \ifnumgreater{\value{liststop}}{2}{% \printdelim{multinamedelim}}{\addspace\bibstring{and}\space}} \begin{document} \section*{Introduction} Lorem ipsum (\cite{example}). \printbibliography[heading=bibintoc,title={Bibliography}] \end{document} ``` And for the entry I used: ``` @book{example, author = {P. {DAL ZOTTO} and J. M. {LARRE} and A. {MERLET} and L. {PICAU} }, title = {Memotech Génie énergétique}, publisher = {Editor Casteilla, France, pages 153 to 159}, year = {2014} } ``` The output looked like this:
1
https://tex.stackexchange.com/users/298810
688368
319,343
https://tex.stackexchange.com/questions/688374
1
I'm working with latex and I want to change font locally. There are plenty of ways of doing that, but the one I'm interested in is using the included font (in `fontenc`), without having to download a font package. I know it's achievable, because I can use `\DeclareFixedFont {⟨cmd⟩} {⟨encoding⟩} {⟨**family**⟩} {⟨series⟩} {⟨shape⟩} {⟨size⟩}` and then use ⟨cmd⟩ to change font locally. The ⟨family⟩ parameter is defined (as I understood it) as a series of letters coding for a font type, for example `cmtt`, or `cmr` (Computer Modern Roman). I want it to work with pdfLaTeX (I know there is stuff that works only with LuaTeX and XeTex, but that's not what I'm looking for) I did nor find in any documentation, nor the latex font catalogue, nor the latex font guide, nor ..., a way to know all available family, or they corresponding letter code. There's always a few examples with a note saying there's too many to be listed. So here's my question : where one could find such a list ?
https://tex.stackexchange.com/users/298813
About the use of \DeclareFixedFont and available fonts
true
``` \DeclareFixedFont {⟨cmd⟩} {⟨encoding⟩}{family}... ``` will work if there is a file named `<encoding><family>.fd` in tex's input path ``` grep '[.]fd' $(kpsewhich --all ls-R) ``` would list all such files in the standard places. In an up to date texlive 2023 there are almost 5 thousand such files: ``` $ grep '[.]fd' $(kpsewhich --all ls-R) | wc -l 4754 ``` This will include a few special purpose fd files not intended for pdflatex, and does not include files in directories not included in the pre-cached `ls-R` file listings, but is a fairly accurate list in practice. You can get a more managable list by looking for a specific encoding, eg T1 has 794: ``` grep -i -h '^t1.*[.]fd' $(kpsewhich --all ls-R) | sort | uniq T1AccanthisADFStdNoThree-LF.fd T1Alegreya-Inf.fd T1Alegreya-LF.fd T1Alegreya-OsF.fd T1Alegreya-Sup.fd T1Alegreya-TLF.fd T1Alegreya-TOsF.fd T1AlegreyaSans-Inf.fd T1AlegreyaSans-LF.fd T1AlegreyaSans-OsF.fd T1AlegreyaSans-Sup.fd T1AlegreyaSans-TLF.fd T1AlegreyaSans-TOsF.fd T1AlgolRevived-Inf.fd T1AlgolRevived-OsF-TT.fd T1AlgolRevived-OsF.fd T1AlgolRevived-Sup.fd T1AlgolRevived-TLF-TT.fd T1AlgolRevived-TLF.fd T1Almndr-OsF.fd T1AlphaSlabOne-Sup.fd T1AlphaSlabOne-TLF.fd T1AmiciLogo.fd T1ArchivZero-LF.fd T1ArchivZero-OsF.fd T1ArchivZero-Sup.fd T1ArchivZero-TLF.fd T1ArchivZero-TOsF.fd T1Arimo-TLF.fd T1Arvo-TLF.fd T1AuriocusKalligraphicus.fd T1Baskervaldx-LF.fd T1Baskervaldx-OsF.fd T1Baskervaldx-Sup.fd T1Baskervaldx-TLF.fd T1Baskervaldx-TOsF.fd T1BaskervilleF-Dnom.fd T1BaskervilleF-LF.fd T1BaskervilleF-OsF.fd T1BaskervilleF-Sup.fd T1BaskervilleF-TLF.fd T1BaskervilleF-TOsF.fd T1Bttr-TLF.fd T1Cabin-Sup.fd T1Cabin-TLF.fd T1Caladea-TLF.fd T1CascadiaCodThree-Sup.fd T1CascadiaCodThree-TLF.fd T1Chivo-Dnom.fd T1Chivo-Inf.fd T1Chivo-LF.fd T1Chivo-Numr.fd T1Chivo-OsF.fd T1Chivo-Sup.fd T1Chivo-TLF.fd T1Chivo-TOsF.fd T1Cinzel-LF.fd T1CinzelDecorative-LF.fd T1Clara-Sup.fd T1Clara-TLF.fd T1Clara-TOsF.fd T1ClearSans-TLF.fd T1Cochineal-Dnom.fd T1Cochineal-Inf.fd T1Cochineal-LF.fd T1Cochineal-OsF.fd T1Cochineal-Sup.fd T1Cochineal-TLF.fd T1Cochineal-TOsF.fd T1Coelacanth-LF.fd T1Coelacanth-OsF.fd T1Coelacanth-TLF.fd T1Coelacanth-TOsF.fd T1ComicNeue-TLF.fd T1ComicNeueAngular-TLF.fd T1CormorantGaramond-Inf.fd T1CormorantGaramond-LF.fd T1CormorantGaramond-OsF.fd T1CormorantGaramond-Sup.fd T1CormorantGaramond-TLF.fd T1CormorantGaramond-TOsF.fd T1CourierOneZeroPitch-TLF.fd T1CpHwt-Sup.fd T1CpHwt-TLF.fd T1Crimson-TLF.fd T1CrimsonPro-Inf.fd T1CrimsonPro-LF.fd T1CrimsonPro-OsF.fd T1CrimsonPro-Sup.fd T1CrimsonPro-TLF.fd T1CrimsonPro-TOsF.fd T1Crlt-Inf.fd T1Crlt-LF.fd T1Crlt-OsF.fd T1Crlt-Sup.fd T1Crlt-TLF.fd T1Crlt-TOsF.fd T1DANTE.fd T1DejaVuSans-TLF.fd T1DejaVuSansCondensed-TLF.fd T1DejaVuSansMono-TLF.fd T1DejaVuSerif-TLF.fd T1DejaVuSerifCondensed-TLF.fd T1Domitian-Inf.fd T1Domitian-Sup.fd T1Domitian-TLF.fd T1Domitian-TOsF.fd T1EBGaramond-Inf.fd T1EBGaramond-LF.fd T1EBGaramond-OsF.fd T1EBGaramond-Sup.fd T1EBGaramond-TLF.fd T1EBGaramond-TOsF.fd T1EBGaramondInitials-TLF.fd T1ETbb-Dnom.fd T1ETbb-Inf.fd T1ETbb-LF.fd T1ETbb-OsF.fd T1ETbb-Sup.fd T1ETbb-TLF.fd T1ETbb-TOsF.fd T1FiraMono-Sup.fd T1FiraMono-TLF.fd T1FiraMono-TOsF.fd T1FiraSans-LF.fd T1FiraSans-OsF.fd T1FiraSans-Sup.fd T1FiraSans-TLF.fd T1FiraSans-TOsF.fd T1Frm-LF.fd T1GaramondLibre-Inf.fd T1GaramondLibre-LF.fd T1GaramondLibre-OsF.fd T1GaramondLibre-Sup.fd T1Gelasio-LF.fd T1Gelasio-OsF.fd T1Gelasio-Sup.fd T1Gelasio-TLF.fd T1Gelasio-TOsF.fd T1GilliusADF-LF.fd T1GilliusADFCond-LF.fd T1GilliusADFNoTwo-LF.fd T1GilliusADFNoTwoCond-LF.fd T1Go-TLF.fd T1GoMono-TLF.fd T1Gudea-TLF.fd T1Heuristica-Inf.fd T1Heuristica-Sup.fd T1Heuristica-TLF.fd T1Heuristica-TOsF.fd T1HindMadurai-TLF.fd T1IBMPlexMono-Sup.fd T1IBMPlexMono-TLF.fd T1IBMPlexSans-Sup.fd T1IBMPlexSans-TLF.fd T1IBMPlexSerif-Sup.fd T1IBMPlexSerif-TLF.fd T1IMFELLEnglish-TLF.fd T1IbarraRealNova-LF.fd T1IbarraRealNova-OsF.fd T1IbarraRealNova-Sup.fd T1InriaSans-LF.fd T1InriaSans-OsF.fd T1InriaSans-Sup.fd T1InriaSans-TLF.fd T1InriaSans-TOsF.fd T1InriaSerif-LF.fd T1InriaSerif-OsF.fd T1InriaSerif-Sup.fd T1InriaSerif-TLF.fd T1InriaSerif-TOsF.fd T1Inter-LF.fd T1Inter-Sup.fd T1Inter-TLF.fd T1JanaSkrivana.fd T1JosefinSans-LF.fd T1Junicode-Inf.fd T1Junicode-Sup.fd T1Junicode-TLF.fd T1Junicode-TOsF.fd T1Lbstr-LF.fd T1LibertinusMono-TLF.fd T1LibertinusSans-LF.fd T1LibertinusSans-OsF.fd T1LibertinusSans-Sup.fd T1LibertinusSans-TLF.fd T1LibertinusSans-TOsF.fd T1LibertinusSerif-LF.fd T1LibertinusSerif-OsF.fd T1LibertinusSerif-Sup.fd T1LibertinusSerif-TLF.fd T1LibertinusSerif-TOsF.fd T1LibertinusSerifDisplay-LF.fd T1LibertinusSerifDisplay-OsF.fd T1LibertinusSerifDisplay-Sup.fd T1LibertinusSerifDisplay-TLF.fd T1LibertinusSerifDisplay-TOsF.fd T1LibertinusSerifInitials-TLF.fd T1LibreBodoni-Inf.fd T1LibreBodoni-Sup.fd T1LibreBodoni-TLF.fd T1LibreBskvl-LF.fd T1LibreBskvl-Sup.fd T1LibreCsln-Inf.fd T1LibreCsln-LF.fd T1LibreCsln-OsF.fd T1LibreCsln-Sup.fd T1LibreCsln-TLF.fd T1LibreCsln-TOsF.fd T1LibreFranklin-Sup.fd T1LibreFranklin-TLF.fd T1LinguisticsPro-LF.fd T1LinguisticsPro-OsF.fd T1LinuxBiolinumO-LF.fd T1LinuxBiolinumO-OsF.fd T1LinuxBiolinumO-TLF.fd T1LinuxBiolinumO-TOsF.fd T1LinuxBiolinumT-LF.fd T1LinuxBiolinumT-OsF.fd T1LinuxBiolinumT-Sup.fd T1LinuxBiolinumT-TLF.fd T1LinuxBiolinumT-TOsF.fd T1LinuxLibertineDisplayT-LF.fd T1LinuxLibertineDisplayT-OsF.fd T1LinuxLibertineDisplayT-Sup.fd T1LinuxLibertineDisplayT-TLF.fd T1LinuxLibertineDisplayT-TOsF.fd T1LinuxLibertineInitialsT-LF.fd T1LinuxLibertineInitialsT-OsF.fd T1LinuxLibertineInitialsT-TLF.fd T1LinuxLibertineMonoT-LF.fd T1LinuxLibertineMonoT-Sup.fd T1LinuxLibertineMonoT-TLF.fd T1LinuxLibertineO-LF.fd T1LinuxLibertineO-OsF.fd T1LinuxLibertineO-TLF.fd T1LinuxLibertineO-TOsF.fd T1LinuxLibertineT-LF.fd T1LinuxLibertineT-OsF.fd T1LinuxLibertineT-Sup.fd T1LinuxLibertineT-TLF.fd T1LinuxLibertineT-TOsF.fd T1LukasSvatba.fd T1Magra-TLF.fd T1Merriwthr-LF.fd T1Merriwthr-OsF.fd T1Merriwthr-Sup.fd T1Merriwthr-TLF.fd T1Merriwthr-TOsF.fd T1MerriwthrSans-LF.fd T1MerriwthrSans-OsF.fd T1MerriwthrSans-Sup.fd T1MerriwthrSans-TLF.fd T1MerriwthrSans-TOsF.fd T1MintSpirit-Inf.fd T1MintSpirit-LF.fd T1MintSpirit-OsF.fd T1MintSpirit-Sup.fd T1MintSpirit-TLF.fd T1MintSpirit-TOsF.fd T1MintSpiritNoTwo-Inf.fd T1MintSpiritNoTwo-LF.fd T1MintSpiritNoTwo-OsF.fd T1MintSpiritNoTwo-Sup.fd T1MintSpiritNoTwo-TLF.fd T1MintSpiritNoTwo-TOsF.fd T1Montserrat-Dnom.fd T1Montserrat-Inf.fd T1Montserrat-LF.fd T1Montserrat-Numr.fd T1Montserrat-OsF.fd T1Montserrat-Sup.fd T1Montserrat-TLF.fd T1Montserrat-TOsF.fd T1MontserratAlternates-Dnom.fd T1MontserratAlternates-Inf.fd T1MontserratAlternates-LF.fd T1MontserratAlternates-Numr.fd T1MontserratAlternates-OsF.fd T1MontserratAlternates-Sup.fd T1MontserratAlternates-TLF.fd T1MontserratAlternates-TOsF.fd T1Mrcls-LF.fd T1Mrcls-Sup.fd T1NimbusMono.fd T1NimbusMonoN.fd T1NimbusSans.fd T1NimbusSerif.fd T1NotoSans-LF.fd T1NotoSans-OsF.fd T1NotoSans-Sup.fd T1NotoSans-TLF.fd T1NotoSans-TOsF.fd T1NotoSansMono-Sup.fd T1NotoSansMono-TLF.fd T1NotoSansMono-TOsF.fd T1NotoSerif-LF.fd T1NotoSerif-OsF.fd T1NotoSerif-Sup.fd T1NotoSerif-TLF.fd T1NotoSerif-TOsF.fd T1Nunito-Sup.fd T1Nunito-TLF.fd T1Nunito-TOsF.fd T1OldStandard-Sup.fd T1OldStandard-TLF.fd T1Ovrlck-LF.fd T1Ovrlck-OsF.fd T1PTMono-TLF.fd T1PTSans-TLF.fd T1PTSansCaption-TLF.fd T1PTSansNarrow-TLF.fd T1PTSerif-TLF.fd T1PTSerifCaption-TLF.fd T1PlyfrDisplay-LF.fd T1PlyfrDisplay-OsF.fd T1PlyfrDisplay-Sup.fd T1PoiretOne-LF.fd T1Quattro-LF.fd T1Quattro-Sup.fd T1QuattroSans-LF.fd T1QuattroSans-Sup.fd T1Raleway-TLF.fd T1Raleway-TOsF.fd T1Roboto-LF.fd T1Roboto-OsF.fd T1Roboto-TLF.fd T1Roboto-TOsF.fd T1RobotoMono-TLF.fd T1RobotoSerif-LF.fd T1RobotoSerif-OsF.fd T1RobotoSerif-Sup.fd T1RobotoSerif-TLF.fd T1RobotoSerif-TOsF.fd T1RobotoSlab-TLF.fd T1Rosario-Dnom.fd T1Rosario-Inf.fd T1Rosario-LF.fd T1Rosario-Numr.fd T1Rosario-OsF.fd T1Rosario-Sup.fd T1Rosario-TLF.fd T1Rosario-TOsF.fd T1STEP-Inf.fd T1STEP-Sup.fd T1STEP-TLF.fd T1STEP-TOsF.fd T1SourceCodePro-Dnom.fd T1SourceCodePro-Numr.fd T1SourceCodePro-Sup.fd T1SourceCodePro-TLF.fd T1SourceCodePro-TOsF.fd T1SourceSansPro-Dnom.fd T1SourceSansPro-Inf.fd T1SourceSansPro-LF.fd T1SourceSansPro-Numr.fd T1SourceSansPro-OsF.fd T1SourceSansPro-Sup.fd T1SourceSansPro-TLF.fd T1SourceSansPro-TOsF.fd T1SourceSerifPro-Dnom.fd T1SourceSerifPro-LF.fd T1SourceSerifPro-Numr.fd T1SourceSerifPro-OsF.fd T1SourceSerifPro-Sup.fd T1SourceSerifPro-TLF.fd T1SourceSerifPro-TOsF.fd T1Spectral-LF.fd T1Spectral-OsF.fd T1Spectral-Sup.fd T1Spectral-TLF.fd T1Spectral-TOsF.fd T1SticksTooText-Dnom.fd T1SticksTooText-Inf.fd T1SticksTooText-LF.fd T1SticksTooText-Numr.fd T1SticksTooText-OsF.fd T1SticksTooText-Sup.fd T1SticksTooText-TLF.fd T1SticksTooText-TOsF.fd T1TeXGyreScholaX-Inf.fd T1TeXGyreScholaX-LF.fd T1TeXGyreScholaX-OsF.fd T1TeXGyreScholaX-Sup.fd T1TeXGyreScholaX-TLF.fd T1TeXGyreScholaX-TOsF.fd T1Tempora-Sup.fd T1Tempora-TLF.fd T1Tempora-TOsF.fd T1TheanoDidot-TLF.fd T1TheanoDidot-TOsF.fd T1TheanoModern-TLF.fd T1TheanoModern-TOsF.fd T1TheanoOldStyle-TLF.fd T1TheanoOldStyle-TOsF.fd T1Tinos-TLF.fd T1UniversalisADFStd-LF.fd T1XCharter-Dnom.fd T1XCharter-Inf.fd T1XCharter-LF.fd T1XCharter-Numr.fd T1XCharter-OsF.fd T1XCharter-Sup.fd T1XCharter-TLF.fd T1XCharter-TOsF.fd T1XCharterTH-osf.fd T1XCharterTH-tlf.fd T1Zeroswald-Sup.fd T1Zeroswald-TLF.fd T1andk-TLF.fd T1atkinsn-LF.fd T1atkinsn-Sup.fd T1atkinsn-TLF.fd T1cantarell-LF.fd T1cantarell-OsF.fd T1cantarell-TLF.fd T1cantarell-TOsF.fd T1charssil-TLF.fd T1cmodh.fd T1cmor.fd T1cmoss.fd T1cmott.fd T1cmovt.fd T1comfortaa.fd T1dad.fd T1droidsans.fd T1droidsansmono.fd T1droidserif.fd T1erewhon-Dnom.fd T1erewhon-Inf.fd T1erewhon-LF.fd T1erewhon-Numr.fd T1erewhon-OsF.fd T1erewhon-Sup.fd T1erewhon-TLF.fd T1erewhon-TOsF.fd T1fbb-Inf.fd T1fbb-LF.fd T1fbb-OsF.fd T1fbb-Sup.fd T1fbb-TLF.fd T1fbb-TOsF.fd T1ffm.fd T1ffmw.fd T1lato-LF.fd T1lato-OsF.fd T1lato-TLF.fd T1lato-TOsF.fd T1opensans-LF.fd T1opensans-OsF.fd T1opensans-TLF.fd T1opensans-TOsF.fd t1aer.fd t1aess.fd t1aett.fd t1anonymouspro.fd t1antp.fd t1antpl.fd t1antt.fd t1anttc.fd t1anttl.fd t1anttlc.fd t1aram.fd t1artemisia.fd t1artemisiaeuler.fd t1augie.fd t1auncl.fd t1bch.fd t1beuron.fd t1bodoni.fd t1ccr.fd t1clm.fd t1clm2.fd t1clm2d.fd t1clm2dj.fd t1clm2j.fd t1clm2jqs.fd t1clm2js.fd t1clm2jt.fd t1clm2jv.fd t1clm2qs.fd t1clm2s.fd t1clm2t.fd t1clm2v.fd t1clmd.fd t1clmdj.fd t1clmj.fd t1clmjqs.fd t1clmjs.fd t1clmjt.fd t1clmjv.fd t1clmqs.fd t1clms.fd t1clmt.fd t1clmv.fd t1cmbr.fd t1cmdh.fd t1cmfib.fd t1cmfr.fd t1cmg.fd t1cmin.fd t1cmr-1200.fd t1cmr.fd t1cmsd.fd t1cmsrbr.fd t1cmsrbs.fd t1cmsrbt.fd t1cmss.fd t1cmtl.fd t1cmtt.fd t1cmvtt.fd t1copsn.fd t1cpc.fd t1cpr.fd t1cugar.fd t1cyklop.fd t1cypr.fd t1egoth.fd t1etr.fd t1fav.fd t1fcm.fd t1fcs.fd t1fct.fd t1fmm.fd t1fnc.fd t1foekfont.fd t1fonetika.fd t1frc.fd t1fut-sup.fd t1fut.fd t1futj.fd t1futs.fd t1futx.fd t1fve.fd t1fvm.fd t1fvs.fd t1fxl1.fd t1gentium.fd t1gentiumbook.fd t1givbc.fd t1gvibc.fd t1hfodh.fd t1hfor.fd t1hfoss.fd t1hfott.fd t1hfovt.fd t1hmin.fd t1huncl.fd t1imaj.fd t1imin.fd t1ipxg.fd t1ipxm.fd t1iwona.fd t1iwonac.fd t1iwonal.fd t1iwonalc.fd t1jkp.fd t1jkpf.fd t1jkpfosn.fd t1jkpk.fd t1jkpkf.fd t1jkpkfosn.fd t1jkpkos.fd t1jkpkosn.fd t1jkpkvos.fd t1jkpl.fd t1jkplf.fd t1jkplfosn.fd t1jkplk.fd t1jkplkf.fd t1jkplkfosn.fd t1jkplkos.fd t1jkplkosn.fd t1jkplkvos.fd t1jkplos.fd t1jkplosn.fd t1jkplvos.fd t1jkpos.fd t1jkposn.fd t1jkpss.fd t1jkpssf.fd t1jkpssfosn.fd t1jkpssk.fd t1jkpsskf.fd t1jkpsskfosn.fd t1jkpsskos.fd t1jkpsskosn.fd t1jkpsskvos.fd t1jkpssos.fd t1jkpssosn.fd t1jkpssvos.fd t1jkptt.fd t1jkpttos.fd t1jkpttosn.fd t1jkpttvos.fd t1jkpvos.fd t1jkpx.fd t1jkpxf.fd t1jkpxfosn.fd t1jkpxk.fd t1jkpxkf.fd t1jkpxkfosn.fd t1jkpxkos.fd t1jkpxkosn.fd t1jkpxkvos.fd t1jkpxos.fd t1jkpxosn.fd t1jkpxvos.fd t1jtm.fd t1kurier.fd t1kurierc.fd t1kurierl.fd t1kurierlc.fd t1laess.fd t1laett.fd t1lcmss.fd t1lcmtt.fd t1linb.fd t1llcmss.fd t1llcmtt.fd t1lmdh.fd t1lmr.fd t1lmros.fd t1lmss.fd t1lmssos.fd t1lmssq.fd t1lmtt.fd t1lmttos.fd t1lmvtt.fd t1lmvttos.fd t1mak.fd t1maksf.fd t1mdbch.fd t1mdici.fd t1mdpgd.fd t1mdpus.fd t1mdput.fd t1mdputu.fd t1mdugm.fd t1mincochineal.fd t1minebgaramond.fd t1minlibertine.fd t1minntx.fd t1minxcharter.fd t1mlmdh.fd t1mlmr.fd t1mlmss.fd t1mlmssq.fd t1mlmtt.fd t1mlmvtt.fd t1nab.fd t1nanumgt.fd t1nanummj.fd t1neohellenic.fd t1newtxtt.fd t1newtxttz.fd t1npxtt.fd t1ntxdnom.fd t1ntxinf.fd t1ntxlf.fd t1ntxosf.fd t1ntxsups.fd t1ntxth-lf.fd t1ntxth-osf.fd t1ntxth-tlf.fd t1ntxth-tosf.fd t1ntxtlf.fd t1ntxtosf.fd t1ntxtt.fd t1oands.fd t1pag.fd t1pbk.fd t1pbsi.fd t1pcr.fd t1pcrs.fd t1pgoth.fd t1phnc.fd t1phv.fd t1pmhg.fd t1pnc.fd t1ppl.fd t1pplj.fd t1pplx.fd t1proto.fd t1ptm.fd t1put.fd t1pxr.fd t1pxss.fd t1pxtt.fd t1pzc.fd t1qag.fd t1qbk.fd t1qcr.fd t1qcs.fd t1qhv.fd t1qhvc.fd t1qpl.fd t1qtm.fd t1qzc.fd t1rtnd.fd t1rust.fd t1rzcm.fd t1rzcm.fdd t1sarab.fd t1sqrc.fd t1srbtiks.fd t1stix.fd t1stix2.fd t1tgoth.fd t1tib.fd t1trjn.fd t1txr.fd t1txss.fd t1txtt.fd t1uag.fd t1uaq.fd t1ubk.fd t1ucr.fd t1udidot.fd t1ugq.fd t1uhv.fd t1unc.fd t1uncl.fd t1uni.fd t1upl.fd t1uplmr.fd t1utm.fd t1uzc.fd t1vik.fd t1vlmr.fd t1vlmss.fd t1vlmssq.fd t1vlmtt.fd t1vlmvtt.fd t1wedn.fd t1wela.fd t1wesa.fd t1wesu.fd t1weva.fd t1xcmss.fd t1ybd.fd t1ybd0.fd t1ybd1.fd t1ybd2.fd t1ybd2j.fd t1ybdj.fd t1ybv.fd t1ybvw.fd t1yes.fd t1yes0.fd t1yes1.fd t1yesj.fd t1yesjw.fd t1yesw.fd t1yfrak.fd t1yly.fd t1ylyw.fd t1yrd.fd t1yrda.fd t1yrdaw.fd t1yrdw.fd t1yv1.fd t1yv1d.fd t1yv2.fd t1yv3.fd t1yvo.fd t1yvoa.fd t1yvoad.fd t1yvod.fd t1yvt.fd t1yvtajw.fd t1yvtaw.fd t1yvtd.fd t1yvtj.fd t1yvtjw.fd t1yvtw.fd t1zcsth-lf.fd t1zcsth-osf.fd t1zi4.fd t1zlmtt.fd t1zlmvtt.fd t1zpldnom.fd t1zplinf.fd t1zpllf.fd t1zplnumr.fd t1zplosf.fd t1zplsubs.fd t1zplsups.fd t1zplth-lf.fd t1zplth-osf.fd t1zplth-tlf.fd t1zplth-tosf.fd t1zpltlf.fd t1zpltosf.fd ```
1
https://tex.stackexchange.com/users/1090
688377
319,345
https://tex.stackexchange.com/questions/79591
51
Is there a bibliography style (I'm using `bibtex`) that works with `article` class where the numbers appear as superscripts and also numbered as they appear in the text (as in `unsrt`)? I read some related questions using `revtex`, but nothing seem to work with basic `article` class.
https://tex.stackexchange.com/users/888
Superscripts in bibliography with bibtex
false
While not 100% what your question asks for, biblatex has a function `\supercite` which is a drop-in replacement for `\cite` and does what you want
1
https://tex.stackexchange.com/users/298825
688382
319,347