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/682551
0
Total newbee here. At the moment I am writing the final paper of my apprenticeship. I have a template from my company, this already provides plenty of classes. However, my title page needs to have my candidate number on it. How can i add a new title element to a document using class `bfhthesis`? This is my document: ``` % define document class \documentclass[ report, % paper format 12pt, % fontsize bibliography=totoc, % If enabled add bibliography to TOC listof=totoc, % If enabled add lists to TOC bilingual, % monolingual, BCOR=1mm, titleimage-ratio=34, ngerman, ]{bfhthesis} % BFH Thesis Class \begin{document} \frontmatter \title{title} \subtitle{subtitle} \author{surname name} \institution{institution} \department{department} \version{1.2} \titlegraphic{\includegraphics[width=\width]{img/titleimg.png}} \expert{surname name, surname name} %---------------- BFH tile page ----------------------------------------- \maketitle \pagenumbering{arabic} %------------ TABLEOFCONTENTS ---------------- \tableofcontents %------------ START MAIN PART ---------------- \mainmatter \chapter{Abstract} lorem ipsum \end{document} ```
https://tex.stackexchange.com/users/294834
Help with integrating new title elements into my provided template
false
Currently it is unclear, where and how the candidate number should be printed. Here one example with number but without a title for that number: ``` \documentclass[ report, % paper format 12pt, % fontsize bibliography=totoc, % If enabled add bibliography to TOC listof=totoc, % If enabled add lists to TOC bilingual, % monolingual, BCOR=1mm, titleimage-ratio=34, ngerman, ]{bfhthesis} % BFH Thesis class \begin{document} \frontmatter \title{title} \subtitle{subtitle} \author{surname name\newline candidate number} \institution{institution} \department{department} \version{1.2} % \titlegraphic{\includegraphics[width=\width]{img/titleimg.png}} \expert{surname name, surname name} %---------------- BFH tile page ----------------------------------------- \maketitle \pagenumbering{arabic} %------------ TABLEOFCONTENTS ---------------- \tableofcontents %------------ START MAIN PART ---------------- \mainmatter \chapter{Abstract} lorem ipsum \end{document} ``` If you also want a title for it, you IMHO would have to change the definition of `\versioninformation`. The original definition could be found in `bfhlayout.sty`. However, if you have been instructed to use this class or template and are then required to deviate from it, the supervisor should also be able to tell you how to do this.
1
https://tex.stackexchange.com/users/277964
682596
316,709
https://tex.stackexchange.com/questions/682593
2
Suppose I have three numerical variables `a,b,c` and I want to use them in TeX then I write : ``` token.set_macro("a",a,'global') token.set_macro("b",b,'global') token.set_macro("c",c,'global') ``` I would like not to have to write "a", "b" and "c" and if possible treat all cases together, something like f(a,b,c). After some research I found a very heavy solution [With debug.getlocal](https://stackoverflow.com/questions/10458306/get-name-of-argument-of-function-in-lua) Is it possible to find another solution? Finally the question should be: if pi=3.14 how to write `tex.print("pi" .."="..tostring(pi))` without duplicating `pi`
https://tex.stackexchange.com/users/3144
Problem to name multiple macros from lua variables
true
Not quite the form you asked for but it's easier to iterate over a table ``` \documentclass{article} \directlua{ t={ a=11, b=22, c=33 } function f (t) for k,v in pairs(t) do token.set_macro(k,v,'global') end end f(t) } \show\a \show\b \show\c \begin{document} \end{document} ``` produces ``` > \a=macro: ->11. l.17 \show\a ? > \b=macro: ->22. l.18 \show\b ? > \c=macro: ->33. l.19 \show\c ? ``` showing all three macros are set. --- Or if you want to use variables, iterate over the *names* ``` \documentclass{article} \directlua{ a=11 b=22 c=33 function f (t) for k,v in pairs(t) do token.set_macro(v,_G[v],'global') end end f{"a","b","c"} } \show\a \show\b \show\c \begin{document} \end{document} ```
6
https://tex.stackexchange.com/users/1090
682598
316,710
https://tex.stackexchange.com/questions/682593
2
Suppose I have three numerical variables `a,b,c` and I want to use them in TeX then I write : ``` token.set_macro("a",a,'global') token.set_macro("b",b,'global') token.set_macro("c",c,'global') ``` I would like not to have to write "a", "b" and "c" and if possible treat all cases together, something like f(a,b,c). After some research I found a very heavy solution [With debug.getlocal](https://stackoverflow.com/questions/10458306/get-name-of-argument-of-function-in-lua) Is it possible to find another solution? Finally the question should be: if pi=3.14 how to write `tex.print("pi" .."="..tostring(pi))` without duplicating `pi`
https://tex.stackexchange.com/users/3144
Problem to name multiple macros from lua variables
false
You could go the other way round: instead of trying to retrieve the variable name as a string, retrieve the variable value from a string. ``` \documentclass{article} \directlua{ pi = 3.14 function print_debug(name) if _G[name] then tex.print(name.."=".._G[name]) else tex.print(name.." not found") end end } \begin{document} \directlua{print_debug("pi")} \end{document} ```
5
https://tex.stackexchange.com/users/117050
682599
316,711
https://tex.stackexchange.com/questions/682581
5
I've found the following code in another question: ``` \def\scan#1{\scanA#1*} \def\scanA{\futurelet\next\scanB} \def\scanB{\expandafter\ifx\next\space \expandafter\scanC \else \expandafter\scanE \fi} \def\scanC{\afterassignment\scanD \let\next= } \def\scanD{\scanE{ }} \def\scanE#1{\ifx*#1\else \dosomething{#1} \expandafter\scanA \fi} ``` The effect is to convert a string like `ABC` into `\dosomething{A}\dosomething{B}\dosomething{C}`. If `\let\dosomething=\uppercase`, then `\scan{Hello World!}` obtains `HELLO WORLD!`. I understand when `\ifx\next\space` in `\scanB` gets `false`, it expands to `\scanE`, which captures the next unread token as its parameter and `\dosomething`. However, when it gets `true`, it expands to `\scanC`. `\scanD` expands to `\scanE{ }` so that we may handle the spaces. But why the next `\scanA` will skip the space, and how `\afterassignment` and `\let\next=` work? ===== update by OrthoPole ===== I think I've understood the process myself. When the `\ifx` get `true`, the stream looks like `\futurelet·\next·\scanB·_·...` (`_` stands for a space token), and it expands to `\afterassignment·\scanD·\let·\next·=·_·_·...`. We see `\let` allows an optional space token, hence the first space after `=` will be omitted, and `\next` will be assigned the second space. After this assignment, `\scanD` will be expanded. Since the two spaces after `=` are absorbed by `\let`, we get `\scanD·...`.
https://tex.stackexchange.com/users/270268
How does \afterassignment work?
true
`\afterassignment\cs` will reinsert `\cs` in the input stream as soon as the next assignment has been performed. What's considered as an assignment? Setting the value of a register (but for box registers it's slightly more complicated); doing `\.def` where `.` stands for nothing, `g`, `x`, `char` and so on; doing `\let`. Your case is the last one. Now the syntax for `\let` is ``` \let <cs><optional spaces><optional =><one optional space> ``` The `<optional spaces>` part is not interesting in your case, because you always have `\let\scanD`. More interesting is `<one optional space>`. In this case TeX does *no* expansion of the token following `=`, as witnessed by ``` \let\x=\space\message{abc} ``` that prints `abc` on the console and makes `\x` to be the same as `\space`. Doing ``` \def\scanC{\afterassignment\scanD \let\next} ``` would fail if the token after `\scanC` is `=`, because it would be taken as part of the `\let` instruction, which isn't wanted. But also ``` \def\scanC{\afterassignment\scanD \let\next=} ``` would fail if the token after `\scanC` is an explicit space token, because it would be taken as `<one optional space>`. You want instead to assign to `\next` the next token, so you need ``` \def\scanC{\afterassignment\scanD \let\next= } ```
5
https://tex.stackexchange.com/users/4427
682601
316,713
https://tex.stackexchange.com/questions/682607
2
I have a trouble in fixing the position of a tikzpicture when there is overlay. In the example, due to the overlay of the texts below the picture, the picture will float a bit. However, I would like the picture to be fixed at the exact position, such that when I scroll the pages the effect looks like only the text is changing but the picture doesn't move at all. Here is my example: ``` \documentclass[10pt,xcolor={dvipsnames}]{beamer} \usepackage{tikz} \begin{document} \begin{frame}{title} \begin{center} \begin{tikzpicture} \tikzset{ round node/.style={circle,draw,inner sep=1.5} } \node [round node] (1) {1}; \end{tikzpicture} \end{center} \begin{itemize} \only<1>{ \item By convention, we do not draw the information sets that contain a single node \item Therefore, any uncircled (or unlinked) decision node should be understood as a \textbf{singleton} information set} \item<2> In Figure (b), \textbf{player 2 has two singleton information sets}: \begin{itemize} \item The left one: player 2 knows that player 1 has chosen H \item The right one: player 2 knows that player 1 has chosen T \end{itemize} \end{itemize} \end{frame} \end{document} ``` Remark: I don't use `\uncover` or `\onslide` because I don't want to leave blank space.
https://tex.stackexchange.com/users/238639
Fix the postion of tikzpicture
true
The easiest way to avoid any potential jumping is to use a top aligned frame: ``` \documentclass{beamer} \usepackage{tikz} \begin{document} \begin{frame}[t]{title} \begin{center} \begin{tikzpicture} \tikzset{ round node/.style={circle,draw,inner sep=1.5} } \node [round node] (1) {1}; \end{tikzpicture} \end{center} \begin{itemize} \only<1>{ \item By convention, we do not draw the information sets that contain a single node \item Therefore, any uncircled (or unlinked) decision node should be understood as a \textbf{singleton} information set} \item<2> In Figure (b), \textbf{player 2 has two singleton information sets}: \begin{itemize} \item The left one: player 2 knows that player 1 has chosen H \item The right one: player 2 knows that player 1 has chosen T \end{itemize} \end{itemize} \end{frame} \end{document} ``` Alternatively, you could use an `overlayarea` of suitable height: ``` \documentclass{beamer} \usepackage{tikz} \begin{document} \begin{frame}{title} \begin{center} \begin{tikzpicture} \tikzset{ round node/.style={circle,draw,inner sep=1.5} } \node [round node] (1) {1}; \end{tikzpicture} \end{center} \begin{overlayarea}{\textwidth}{.5\textheight} \begin{itemize} \only<1>{ \item By convention, we do not draw the information sets that contain a single node \item Therefore, any uncircled (or unlinked) decision node should be understood as a \textbf{singleton} information set} \item<2> In Figure (b), \textbf{player 2 has two singleton information sets}: \begin{itemize} \item The left one: player 2 knows that player 1 has chosen H \item The right one: player 2 knows that player 1 has chosen T \end{itemize} \end{itemize} \end{overlayarea} \end{frame} \end{document} ```
1
https://tex.stackexchange.com/users/36296
682608
316,717
https://tex.stackexchange.com/questions/682592
1
My MWE generates a PDF with links from the ref to the endnote and from the endnote to the ref. When I convert my TeX to epub using `tex4ebook main.tex -o main.epub` I lose the links. How can I generate an epub from my LaTeX that has linked endnotes? It's for a book and I'm open to changing up my workflow, including converting the main matter to markdown, using a tool other than `tex4ebook`, or using another packages for endnotes. ``` \documentclass{memoir} \usepackage{enotez} \setenotez{backref=true} \usepackage{hyperref} \begin{document} Some sample text.\endnote{And a sample endnote} \printendnotes \end{document} ```
https://tex.stackexchange.com/users/272500
How to generate an epub with linked endnotes?
false
I saw [here](https://github.com/michal-h21/tex4ebook/issues/91#issuecomment-1019450401) that someone got linked endnotes working with tex4ebook by rolling their own with `\label` and `\ref`. I wrote the mwe below to do this which creates the commands `noteref` and `noteitem`. I added a tappable arrow to the endnote to return to the ref. I need to add a conditional to the mwe to remove the arrow when compiling for print. I'd also like to add a period after the number in the enumerated list, but am not sure how without also added the period to the superscript number. I'll update the mwe when I get these added. ``` \documentclass{book} \newcounter{dummy} \usepackage{hyperref} \usepackage{enumitem} \makeatletter \newcommand{\noteref}[1]{\textsuperscript{\ref{itm:#1}\label{#1ref}}} \newcommand{\noteitem}[1]{\item\label{itm:#1}\hyperref[#1ref]{$\nwarrow$}} \makeatother \newcommand*{\mprime}{\ensuremath{'}} \begin{document} \chapter*{Chapter 1} This is really noteworthy.\noteref{first} \chapter*{Chapter 2} This, too, is noteworthy.\noteref{second} \chapter*{Chapter 3} This is also noteworthy.\noteref{third} \chapter*{Notes} \begin{enumerate}[label=\textnormal{\arabic*}] \noteitem{first} This is the first endnote. \noteitem{second} This is the second endnote. \noteitem{third} This is the third endnote. \end{enumerate} \end{document} ```
0
https://tex.stackexchange.com/users/272500
682611
316,718
https://tex.stackexchange.com/questions/682610
4
I stumbled accors `\Vec{...}` (notice the capitalised command). Since it is impossible to do case-sensitive searches on Google and SE, I have to ask: What does it do? Can I overwrite it? It seems to have the same effect as `\vec{...}`.
https://tex.stackexchange.com/users/172890
What is `\Vec` (capitalised)
false
TeX differentiates between uppercase and lowercase in general, so `\vec` is not the same as `\Vec`. In plain TeX, only `\vec` is defined, but the package `amsmath` defines `\Vec` as being the same as `\vec` ("for backward compatibility" as the manual states): ``` \def\Vec{\vec} ``` So, yes, if you mean the macro as it is defined by the `amsmath` package, it does exactly the same as `\vec`. And yes, in this case you could redefine it (after having loaded `amsmath`) without affecting the defintion of `\vec`. I am not sure whether redefining it is a good idea though, since this might break things where other packages rely on the fact that `amsmath` defines the capitalized macro to be the same as the non-capitalized one. However, since you did not provide a [minimal working example (MWE)](https://tex.meta.stackexchange.com/q/228) the above is only a guess. There might also exist other packages or document classes that define `\Vec` in their own, different way, and it could be a problem to redefine this macro in this situation, of course.
4
https://tex.stackexchange.com/users/47927
682612
316,719
https://tex.stackexchange.com/questions/682610
4
I stumbled accors `\Vec{...}` (notice the capitalised command). Since it is impossible to do case-sensitive searches on Google and SE, I have to ask: What does it do? Can I overwrite it? It seems to have the same effect as `\vec{...}`.
https://tex.stackexchange.com/users/172890
What is `\Vec` (capitalised)
true
If I do ``` > ack '\\Vec[^f@t-]' /usr/local/texlive/2023/texmf-dist/tex/latex/ ``` (the exclusion list in the regex is just to avoid false positives) the answer is ``` /usr/local/texlive/2023/texmf-dist/tex/latex/amsmath/amstex.sty 774:\gdef\Vec{\RIfM@\DN@{\mathaccent@{"017E }}\else 775: \DN@{\nonmatherr@\Vec}\fi\next@} /usr/local/texlive/2023/texmf-dist/tex/latex/amsmath/amsmath-2018-12-01.sty 876:\def\Vec{\vec} /usr/local/texlive/2023/texmf-dist/tex/latex/amsmath/amsmath.sty 902:\def\Vec{\vec} /usr/local/texlive/2023/texmf-dist/tex/latex/lwarp/lwarp-amsmath.sty 156:\CustomizeMathJax{\let\Vec\vec} ``` So basically, the only package that defines `\Vec` is `amsmath` (`amstex.sty` is kept for backwards compatibility). Why? If you look in `amsmath.sty` you'll see also `\Acute`, `\Hat` and so on for all math accents. In the first versions of `amsmath`, the capitalized version was used to get stacked accents right, so you had to type ``` \Dot{\Hat{x}} ``` to get the right position of the accents. In later versions, the problem of stacking accents was solved in a different way (which adds a not so nice “feature”, but that's not the point), so the capitalized versions were redefined to be the same as the all-lowercase commands. Using `\Vec` or `\vec` is exactly the same.
5
https://tex.stackexchange.com/users/4427
682619
316,721
https://tex.stackexchange.com/questions/682216
0
I want to reduce the distance that the node text gets placed relative to the anchor. I have two nodes like this to add labels to a point in the axis: ``` \node[red] (point) at (1,0) {\(\bullet\)}; \node[anchor=south west] at (point) {(1,0)}; ``` That adds a red dot at the point and a node above right of it with some text. I want to move the text node closer to the point since the automatic placement puts it a bit far away. How do i do that? Is there an option to make placement "tight" or "compact"? Would it make sense to change from two nodes to one node plus the label option added to the bullet node?
https://tex.stackexchange.com/users/258117
TikZ: Reduce distance of node to anchor
true
If you need dots (to mark a point/coordinate) it's always better to use an actual circle drawn by TikZ. The glyphs `\bullet` or `\textbullet` don't necessarily have their center on the actual coordinate and you can't reference them as good. A node of shape `circle` is used best. Setting the `inner sep` to zero allows the diameter to be given via `minimum size`. To put a node closer to that dot it be best to reduce its `inner sep`. Technically, using a negative `outer sep` works, too, but I don't see a good reason for it in this case. (See the `inner sep` value in the `every label` key.) Since it seems like you want to label a coordinate on the page, the `label` key is a nice way to place another node in reference to a given node without having to give it an explicit name. It allows you to use a style like `dot` in the second code which not only adds the label but also places the dot on the right coordinate without having to give it twice. (Though, this will not always work, of course.) Code ---- ``` \documentclass[tikz]{standalone} \begin{document} \tikz[ bullet/.style={shape=circle, fill, draw, inner sep=+0pt, minimum size=+3.5pt}, every label/.append style={inner sep=+.1em} ] \node[bullet, red, label={north east:$(1, 0)$}] at (1,0) {}; \tikz[ dot/.style args={#1:#2}{bullet, label={#1:$#2$}, at={#2}, node contents=}, bullet/.style={shape=circle, fill, draw, inner sep=+0pt, minimum size=+3.5pt}, every label/.append style={inner sep=+.1em} ] \node[red, dot={north east:(1, 0)}]; \end{document} ```
1
https://tex.stackexchange.com/users/16595
682620
316,722
https://tex.stackexchange.com/questions/682592
1
My MWE generates a PDF with links from the ref to the endnote and from the endnote to the ref. When I convert my TeX to epub using `tex4ebook main.tex -o main.epub` I lose the links. How can I generate an epub from my LaTeX that has linked endnotes? It's for a book and I'm open to changing up my workflow, including converting the main matter to markdown, using a tool other than `tex4ebook`, or using another packages for endnotes. ``` \documentclass{memoir} \usepackage{enotez} \setenotez{backref=true} \usepackage{hyperref} \begin{document} Some sample text.\endnote{And a sample endnote} \printendnotes \end{document} ```
https://tex.stackexchange.com/users/272500
How to generate an epub with linked endnotes?
true
I've modified the code for a similar package, `pagenote`, for which [I wrote support not long ago](https://tex.stackexchange.com/a/680395/2891). See the linked answer for more details, the basic idea is the same - I added some TeX4ht hooks to insert links to the list of notes and back. ``` \ExplSyntaxOn \NewConfigure{enotezmark}{2} \protected\def\:tempa #1#2{\def\:currentnoteid{#1}\a:enotezmark\o:enotez_write_mark:nn:{#1}{#2}\b:enotezmark} \HLet\enotez_write_mark:nn\:tempa \NewConfigure{enotezback}{2} \protected\def\:tempa#1{\def\:currentnoteid{#1}\a:enotezback\o:enotez_write_list_number:n:{#1}\b:enotezback} \HLet\enotez_write_list_number:n\:tempa \Configure{enotezmark}{\Link{enotez\:currentnoteid}{enotez-bk\:currentnoteid}}{\EndLink} \Configure{enotezback}{\Link{enotez-bk\:currentnoteid}{enotez\:currentnoteid}\HCode{<sup>}}{\HCode{</sup>}\EndLink} \ExplSyntaxOff ``` This is the result:
1
https://tex.stackexchange.com/users/2891
682624
316,723
https://tex.stackexchange.com/questions/682633
0
I have a little problem with the numbers that are supposed to indicate the size of the respective bars. These are a bit very far outside the actual diagram. Unfortunately, I can't see my mistake until now to adjust them accordingly, precisely because the diagram becomes much larger and no longer fits completely on the slide. ``` \documentclass[10pt,% aspectratio=169,% ]{beamer} \usepackage[T1]{fontenc} \usepackage[utf8x]{inputenc} \usepackage{lmodern} \usepackage[english]{babel} \usepackage{pgfplots} \pgfplotsset{compat=1.18, /pgf/number format/use comma, table/col sep = comma} \usetikzlibrary{patterns} \begin{filecontents*}{tabellen/data1.csv} Substanz,x,Messung1,AbwMessung1,Messung2,AbwMessung2,Messung3,AbwMessung3,Messung4,AbwMessung4 Salzsäure [v\%/v],1,0.04,0.00,0.24,0.00,0.20,0.00,0.23,0.00 Natronlauge [g/L],2,0.00,0.50,0.78,0.44,0.54,0.00,0.88,0.00 Titanpentachlorid [g/L],3,0.00,0.00,1.39,0.05,0.00,0.00,0.99,0.00 Isopropanol [g/L],4,0.00,0.00,0.05,0.00,0.06,0.00,0.04,0.00 Benzol [g/mL],5,1.07,0.00,1.03,0.00,1.03,0.00,1.03,0.00 \end{filecontents*} \begin{document} \begin{frame}{Title} \begin{tikzpicture} \begin{axis}[ ybar=2pt, ylabel={Konzentration}, % width=\textwidth, height=\textheight, xticklabels from table={tabellen/data1.csv}{Substanz}, xtick=data, ticklabel style={/pgf/number format/.cd, use comma, 1000 sep = {}}, nodes near coords, every node near coord/.append style={ yshift=transformdirectiony(\myshift+1), anchor=center, rotate=90, font=\scriptsize }, ymajorgrids=true, legend pos= north east, legend cell align=right, ] \addplot [draw = blue, fill = blue!30!white, error bars/.cd, y dir=both, y explicit, error mark=triangle*, error bar style={color=black}] table[ x=x, y=Messung1, y error=AbwMessung1, visualization depends on=1.25*\thisrow{AbwMessung1} \as \myshift, ] {tabellen/data1.csv}; \addlegendentry{1. Messung}; \addplot [draw = red, fill=red!30!white, error bars/.cd, y dir=both, y explicit, error mark=triangle*, error bar style={color=black}] table[ x=x, y=Messung2, y error=AbwMessung2, visualization depends on=1.25*\thisrow{AbwMessung2} \as \myshift, ] {tabellen/data1.csv}; \addlegendentry{2. Messung}; \addplot [draw = green, fill=green!30!white, error bars/.cd, y dir=both, y explicit, error mark=triangle*, error bar style={color=black}] table[ x=x, y=Messung3, y error=AbwMessung3, visualization depends on=1.25*\thisrow{AbwMessung3} \as \myshift, ] {tabellen/data1.csv}; \addlegendentry{3. Messung}; \addplot [draw = violet, fill=violet!30!white, error bars/.cd, y dir=both, y explicit, error mark=triangle*, error bar style={color=black}] table[ x=x, y=Messung4, y error=AbwMessung4, visualization depends on=1.25*\thisrow{AbwMessung4} \as \myshift, ] {tabellen/data1.csv}; \addlegendentry{4. Messung}; \end{axis} \end{tikzpicture} \end{frame} \end{document} ```
https://tex.stackexchange.com/users/293851
pgfplots: numbers are outside the diagram
true
Instead of making the shift of the coordinates dependent on the height of the respective bar, I suggest to use a fixed shift, e.g. `yshift=0.1cm`: ``` \documentclass[10pt,% aspectratio=169,% ]{beamer} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{lmodern} \usepackage[english]{babel} \usepackage{pgfplots} \pgfplotsset{compat=1.18, /pgf/number format/use comma, table/col sep = comma} \usetikzlibrary{patterns} \begin{filecontents*}[overwrite]{data1.csv} Substanz,x,Messung1,AbwMessung1,Messung2,AbwMessung2,Messung3,AbwMessung3,Messung4,AbwMessung4 Salzsäure [v\%/v],1,0.04,0.00,0.24,0.00,0.20,0.00,0.23,0.00 Natronlauge [g/L],2,0.00,0.50,0.78,0.44,0.54,0.00,0.88,0.00 Titanpentachlorid [g/L],3,0.00,0.00,1.39,0.05,0.00,0.00,0.99,0.00 Isopropanol [g/L],4,0.00,0.00,0.05,0.00,0.06,0.00,0.04,0.00 Benzol [g/mL],5,1.07,0.00,1.03,0.00,1.03,0.00,1.03,0.00 \end{filecontents*} \begin{document} \begin{frame}{Title} \begin{tikzpicture} \begin{axis}[ ybar=2pt, ylabel={Konzentration}, width=\textwidth, height=.8\textheight, xticklabels from table={data1.csv}{Substanz}, xtick=data, ticklabel style={/pgf/number format/.cd, use comma, 1000 sep = {}}, nodes near coords, every node near coord/.append style={ % yshift=transformdirectiony(\myshift+1), yshift=0.1cm, anchor=west, rotate=90, font=\scriptsize }, ymajorgrids=true, legend pos= north east, legend cell align=right, ] \addplot [draw = blue, fill = blue!30!white, error bars/.cd, y dir=both, y explicit, error mark=triangle*, error bar style={color=black}] table[ x=x, y=Messung1, y error=AbwMessung1, visualization depends on=1.25*\thisrow{AbwMessung1} \as \myshift, ] {data1.csv}; \addlegendentry{1. Messung}; \addplot [draw = red, fill=red!30!white, error bars/.cd, y dir=both, y explicit, error mark=triangle*, error bar style={color=black}] table[ x=x, y=Messung2, y error=AbwMessung2, visualization depends on=1.25*\thisrow{AbwMessung2} \as \myshift, ] {data1.csv}; \addlegendentry{2. Messung}; \addplot [draw = green, fill=green!30!white, error bars/.cd, y dir=both, y explicit, error mark=triangle*, error bar style={color=black}] table[ x=x, y=Messung3, y error=AbwMessung3, visualization depends on=1.25*\thisrow{AbwMessung3} \as \myshift, ] {data1.csv}; \addlegendentry{3. Messung}; \addplot [draw = violet, fill=violet!30!white, error bars/.cd, y dir=both, y explicit, error mark=triangle*, error bar style={color=black}] table[ x=x, y=Messung4, y error=AbwMessung4, visualization depends on=1.25*\thisrow{AbwMessung4} \as \myshift, ] {data1.csv}; \addlegendentry{4. Messung}; \end{axis} \end{tikzpicture} \end{frame} \end{document} ```
1
https://tex.stackexchange.com/users/36296
682637
316,727
https://tex.stackexchange.com/questions/682100
2
I have created an article with a bibliography (natbib + BibDesk, using commands `\citet` and `\citep`). Since I have to submit the .tex file, and my master file.bib is very big, I need a .bib file containing just the items cited in my paper. Is there an easy way to do this on iMac?
https://tex.stackexchange.com/users/85519
Extract short .bib file from paper
false
There are other approaches as well, including a short [Python script](https://github.com/jamestrimble/remove-unused-citations) I have successfully used in the past.
1
https://tex.stackexchange.com/users/26614
682639
316,728
https://tex.stackexchange.com/questions/682617
1
As it is described in [reference manual of etoc, p.34](https://ctan.math.washington.edu/tex-archive/macros/latex/contrib/etoc/etoc.pdf), it is possible to typeset a `\localtableofcontents` at any place of the document. One needs only to follow the steps: 1. `\invisiblelocaltableofcontents \label{foo}` <-- this inside of section for which you need the toc 2. `\tableofcontents \ref{foo}` <-- this at the place WHERE you need the TOC to be typesetted **The question is, how to achieve the same effect for `\locallistoftables` or `\locallistoffigures`?**
https://tex.stackexchange.com/users/294874
etoc: typeset locallistoffigures or locallistoftables elsewhere
true
I am slowly turning into [etoc](https://ctan.org/pkg/etoc) expert here, thanks to going through large parts of its dense document recently in March 2023. My initial reaction was that this was probably not possible as there is no indication whatsoever that I could find about this in the document of [etoc](https://ctan.org/pkg/etoc). And I was going to suggest to write the author a feature request, but much to my surprise this seems to work: ``` \documentclass{article} \usepackage[lof,lot]{etoc} \begin{document} \section{foo} \etocsetnexttocdepth{none} \locallistoffigures\label{lof_of_foo} \subsection{bar} Some text \begin{figure}[htbp] \centering put a graphic here \caption{some figure} \label{fig:1} \end{figure} \section{bar} \renewcommand\listfigurename{This is LOF of section foo} \locallistoffigures\ref{lof_of_foo} \end{document} ``` as it produces after two compilations from a state with no auxiliary files: If you add such things to existing document probably 3 passes will be needed I guess. The `\renewcommand\listfigurename{This is LOF of section foo}` is only for demonstration purpose. In practice it would force you to reissue it with another definition if further `local lofs` are done. I see there is a `\locallistfigurename` but it wouldn't solve the need to have to redefine it at each new one. --- A slightly more complex example as stress test: ``` \documentclass{article} \usepackage[lof,lot]{etoc} \renewcommand\localcontentsname{Local table of contents} \begin{document} \section{foo} \localtableofcontents\label{toc_of_foo} \etocsetnexttocdepth{none} \locallistoffigures\label{lof_of_foo} \subsection{subfoo} Some text \begin{figure}[htbp] \centering put a graphic here \caption{some figure} \label{fig:1} \end{figure} \section{bar} \renewcommand\listfigurename{This is local LOF of section foo} \locallistoffigures\ref{lof_of_foo} \renewcommand\localcontentsname{This is local TOC of section foo} \tableofcontents\ref{toc_of_foo} \renewcommand\listfigurename{This is local LOF of this section} \locallistoffigures \subsection{subbar} Some text \begin{figure}[htbp] \centering put another graphic here \caption{some other figure} \label{fig:2} \end{figure} \end{document} ```
0
https://tex.stackexchange.com/users/293669
682643
316,731
https://tex.stackexchange.com/questions/682572
5
I don't get it. `Gill Sans MT` supports Small Caps without any issue in Word and Powerpoint. Font recognition apps event identify it. And yet, there is no way I can get them. ``` \documentclass{article} \usepackage{fontspec} \setmainfont{Gill Sans MT}[ SmallCapsFeatures={Letters=SmallCaps}, SmallCapsFont={*}, ] \begin{document} \textsc{Small Caps.} \end{document} ```
https://tex.stackexchange.com/users/262813
Small Caps with Gill Sans MT
true
Here is a code based on `egreg`'s answer, which automatically detects the current font before passing the value to the command. **EDIT:** I corrected the issue with `WordSpace` by using `\newfontfamily` instead of obsolete package option. The apostrophe and comma not being rendered properly has been fixed thanks to `user94293`'s answer. ``` \documentclass{article} \usepackage{fontspec} \setmainfont{Times New Roman} \newfontfamily\gill{gill Sans MT} \newfontfamily\hadriano[UprightFont={* Light},BoldFont={* Bold}]{AT Hadriano Std} \newfontfamily\minion{Minion Pro Capt} \newfontfamily\stix{STIX Two Math}[AutoFakeBold=2] \newfontfamily\djvs[BoldFont={* Bold}]{DejaVu Sans} \newfontfamily\arial{Arial Unicode MS} \newfontfamily\free{Free Serif} \newfontfamily\symbola{Symbola}[FakeBold=0.5] \ExplSyntaxOn \NewDocumentCommand{\smartsc}{m} { \krebs_smartsc:n { #1 } } \seq_new:N \l__krebs_smartsc_words_in_seq \seq_new:N \l__krebs_smartsc_words_out_seq \cs_new_protected:Nn \krebs_smartsc:n { \group_begin: \newfontfamily{\currentfont}{\csname f@family\endcsname} \newfontfamily{\currentfontSC}{\csname f@family\endcsname}[Scale=0.72,WordSpace=1.75,FakeBold=1.1] \currentfontSC \seq_set_split:Nnn \l__krebs_smartsc_words_in_seq { ~ } { #1 } \seq_set_map:NNn \l__krebs_smartsc_words_out_seq \l__krebs_smartsc_words_in_seq { \__krebs_smartsc:n { ##1 } } \seq_use:Nn \l__krebs_smartsc_words_out_seq { ~ } \group_end: } \cs_new_protected:Nn \__krebs_smartsc:n { \text_map_inline:nn { #1 } { \__krebs_smartsc_letter:n { ##1 } } } \cs_new_protected:Nn \__krebs_smartsc_letter:n { \int_compare:nTF { \char_value_lccode:n { `#1 } = `#1 } { \char_uppercase:N #1 } { {\currentfont #1} } } \ExplSyntaxOff \begin{document} \noindent \smartsc{Small Caps are Nice, Aren't They?} (Times fake) \textsc{Small Caps are Nice, Aren't They?} (Times real) \gill\smartsc{Small Caps are Nice, Aren't They?} (Gill fake) \textsc{Small Caps are Nice, Aren't They?} (Gill real - No support) \hadriano\smartsc{Small Caps are Nice, Aren't They?} (Hadriano fake) \textsc{Small Caps are Nice, Aren't They?} (Hadriano real - No support) \minion\smartsc{Small Caps are Nice, Aren't They?} (Minion Pro Capt fake) \textsc{Small Caps are Nice, Aren't They?} (Minion Pro Capt real) \stix\smartsc{Small Caps are Nice, Aren't They?} (Stix Two Math fake) \textsc{Small Caps are Nice, Aren't They?} (Stix Two Math real - No support) \djvs\smartsc{Small Caps are Nice, Aren't They?} (DejaVu Sans fake) \textsc{Small Caps are Nice, Aren't They?} (DejaVu Sans real - No support) \arial\smartsc{Small Caps are Nice, Aren't They?} (Arial fake) \textsc{Small Caps are Nice, Aren't They?} (Arial real - No support) \free\smartsc{Small Caps are Nice, Aren't They?} (Free Serif fake) \textsc{Small Caps are Nice, Aren't They?} (Free Serif real) \symbola\smartsc{Small Caps are Nice, Aren't They?} (Symbola fake) \textsc{Small Caps are Nice, Aren't They?} (Symbola real - No support) \end{document} ```
4
https://tex.stackexchange.com/users/262813
682653
316,735
https://tex.stackexchange.com/questions/344160
13
**Short question**: Is there some font encoding or other trick that would allow the unicode character `²` (exponent 2) to be correctly interpreted by LaTeX, notably in math mode (i.e. translate it automatically into `^{2}`)? (and likewise for ³, ⁴, ...) **Detailed rationale**: Normally, to introduce an exponent in math mode one uses the ^ symbol, as in `x^2` or `e^{i\pi}`. I've been using LaTeX for decades and this feels very natural. However, with my current setup, when I type the characters `x` `^` `2` on the keyboard, it results in the two unicode characters `x²`. I do have a `\RequirePackage[utf8]{inputenc}` around the beginning of my personal style file, and Unicode characters in general are interpreted correctly (accented characters and such). Usually I think about it and do type `x` `^` `^` `2` which results in `x^2`, but often I'm typing fast and later have to go back to every line of code that produces a `LaTeX Error: Command \texttwosuperior unavailable in en` error. This is annoying. I could implement a workaround at the level of my editor (I use vim, so it would be simple to add a mapping to convert the ² into ^2), but I'm wondering if there's a better editor-independent way to handle this.
https://tex.stackexchange.com/users/3301
Interpreting unicode ², ³, etc... characters in math mode
false
OpTeX does it right. ``` \fontfam[lm] x²³ and $x²³$. \bye ```
1
https://tex.stackexchange.com/users/51799
682658
316,738
https://tex.stackexchange.com/questions/682660
7
In the answers to this question: [What is the difference between \over and \frac?](https://tex.stackexchange.com/q/73822/965), one finds the ams and plain latex definitions of `\frac`, respectively: ``` \DeclareRobustCommand{\frac}[2]{{\begingroup#1\endgroup\@@over#2}} \DeclareRobustCommand\frac[2]{{\begingroup#1\endgroup\over#2}} ``` Is there a reason grouping is not used around `#2`? That is, like this: ``` \DeclareRobustCommand{\frac}[2]{{\begingroup#1\endgroup\@@over\begingroup#2\endgroup}} \DeclareRobustCommand\frac[2]{{\begingroup#1\endgroup\over\begingroup#2\endgroup}} ```
https://tex.stackexchange.com/users/965
Why is grouping used in the numerator of the definition of \frac but not the denominator?
true
declarations in the numerator of a primitive `{ ... \over ...}` can leak in to the denominator, but an extra group in the denominator would do nothing. ``` \documentclass{article} \begin{document} \[ { a \over b} + { \fam0 a \over b} + {\begingroup \fam0 a \endgroup \over b} \] \end{document} ```
11
https://tex.stackexchange.com/users/1090
682661
316,739
https://tex.stackexchange.com/questions/682662
3
I want to diagram what 4 KB means. ``` $\underbrace{4}_{2^2} \underbrace{\text{KB}}_{2^{10}}$ ``` I'd like to put a multiplication sign between the two underbrace *in the underbrace space* (same level, size, etc) without the multiplication sign actually having a brace over it. And maybe even an `= 2^{12}` part at the end in the same style.
https://tex.stackexchange.com/users/291129
Underbrace space without underbrace?
true
Something like this? The `\mkern2mu` directive inside the argument of `\mathllap` serves to places the `\times` symbol right below the gap between the two horizontal braces. (A larger value for the argument of `\mathllap` would push the `\times` symbol further to the left.) Likewise, `\mathrlap{\cramped{\,=\,2^{12}}}` serves to place `=2^{12}` to the right of the main argument of the second `\underbrace` directive. ``` \documentclass{article} \usepackage{mathtools} % for '\mathllap', '\mathrlap', and '\cramped' macros \begin{document} \[ \underbrace{4}_{2^2} \underbrace{\mathrm{KB}}% _{\mathllap{\times\mkern2mu} 2^{10} % <-- main argument of '\underbrace' \mathrlap{\cramped{\,=\,2^{12}}}} \] \end{document} ```
3
https://tex.stackexchange.com/users/5001
682665
316,741
https://tex.stackexchange.com/questions/291531
5
I'm new to EMACS (on Ubuntu) and I have started using the `org` mode to begin with. I tried to convert my .org files into LaTeX only to see an error saying `pdf was not produced` Upon checking the error online, I understood that packages required for .org to latex were not available. I used `sudo apt-get install auctex` to install the required packages. Now I'm left with the following error message. ``` This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Debian) restricted \write18 enabled. entering extended mode (/home/prasannarajaram/list.tex LaTeX2e Babel and hyphenation patterns for 2 languages loaded. (/usr/share/texlive/texmf-dist/tex/latex/base/article.cls Document Class: article 2007/10/19 v1.4h Standard LaTeX document class (/usr/share/texlive/texmf-dist/tex/latex/base/size11.clo)) (/usr/share/texlive/texmf-dist/tex/latex/base/inputenc.sty (/usr/share/texlive/texmf-dist/tex/latex/base/utf8.def (/usr/share/texlive/texmf-dist/tex/latex/base/t1enc.dfu) (/usr/share/texlive/texmf-dist/tex/latex/base/ot1enc.dfu) (/usr/share/texlive/texmf-dist/tex/latex/base/omsenc.dfu))) (/usr/share/texlive/texmf-dist/tex/latex/base/fontenc.sty (/usr/share/texlive/texmf-dist/tex/latex/base/t1enc.def) kpathsea: Running mktextfm ecrm1095 mktextfm: Running mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input ecrm1095 This is METAFONT, Version 2.718281 (TeX Live 2013/Debian) kpathsea: Running mktexmf ecrm1095 ! I can't find file `ecrm1095'. ...ljfour; mag:=1; nonstopmode; input ecrm1095 Please type another input file name ! Emergency stop. ...ljfour; mag:=1; nonstopmode; input ecrm1095 Transcript written on mfput.log. grep: ecrm1095.log: No such file or directory mktextfm: `mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input ecrm1095' failed to make ecrm1095.tfm. kpathsea: Appending font creation commands to missfont.log. ! Font T1/cmr/m/n/10.95=ecrm1095 at 10.95pt not loadable: Metric (TFM) file not found. relax l.100 \fontencoding\encodingdefault\selectfont ) (/usr/share/texlive/texmf-dist/tex/latex/base/fixltx2e.sty) (/usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty (/usr/share/texlive/texmf-dist/tex/latex/graphics/keyval.sty) (/usr/share/texlive/texmf-dist/tex/latex/graphics/graphics.sty (/usr/share/texlive/texmf-dist/tex/latex/graphics/trig.sty) (/usr/share/texlive/texmf-dist/tex/latex/latexconfig/graphics.cfg) (/usr/share/texlive/texmf-dist/tex/latex/pdftex-def/pdftex.def (/usr/share/texlive/texmf-dist/tex/generic/oberdiek/infwarerr.sty) (/usr/share/texlive/texmf-dist/tex/generic/oberdiek/ltxcmds.sty)))) (/usr/share/texlive/texmf-dist/tex/latex/tools/longtable.sty) (/usr/share/texlive/texmf-dist/tex/latex/float/float.sty) ! LaTeX Error: File `wrapfig.sty' not found. Type X to quit or to proceed, or enter new name. (Default extension: sty) Enter file name: ! Emergency stop. l.10 \usepackage {soul}^^M ! ==> Fatal error occurred, no output PDF file produced! Transcript written on /home/prasannarajaram//list.log. ``` Where am I going wrong? Do I need to install more packages? or is it to do with the configuration. Note: I'm pressed up for download limits. Already used up 400+ MB for downloading `AUCTEX` The source `org` file is here ``` This is my first to do list in ORG mode in emacs * This is heading level 1 There should be some text here ** Heading level 2 This is to see how the system behaves when there is text between level 1 and 2 *** this is heading level 3 THIS also Speaks VOLUMES about THE POWER OF EMACS-ORG MODE. **** This is heading level 4 *this text will be bold* /whereas this will be italics/ _and this needs to be underline_ I WOULD LIKE TO SEE IF IT INDENTS BELOW THE THIRD HEADING. However the C code for printing Hello World program will look like this #+begin_SRC C #include int main (void) { printf("Hello World!"); return 0; } #+end_SRC C #+begin_quote "This is a quote" #+end_quote * Let me create a list here [66%] - [X] first item - [ ] second item - [X] third item - [X] is this a nested item - [X] is this also nested - i doubt - yes it is First I would like to list down the list of commands for Org mode I have learnt so far. - An asterisk creates a heading level 1 + A double asterisk creates a heading level 2 and so on so forth + To create a check list use `-[ ]` + In order to see the percentage of the items checked off in the check list use `[0%]` + In order to see the number of checked items checked off in the check list use `[0/0]` - this is another one - this is the next one + this is an unordered list * TODO list [4/6] : - [ ] How to create a numbered list - [ ] How to markup multiple lines of code in =code= style - [ ] How to create a bulleted list - [X] How to split screens in EMACS - for horizontal split use C-x-2; vertical split:C-x-3 - [X] How to toggle a check list item - C-c C-c - [X] In order to change the outline view to a cleaner view use the command M-x-org-indent-mode - [X] In order to wrap the text to be visually pleasing use M-x-visual-line-mode * Let us try to make a table now | S.No | Name | |-------+------------| | | | | 1 | Arthy | | 2 | Indu | | 3 | Padmavathy | | 4 | Prakruti | | 5 | Prasanna | | 6 | Rajaram | |-------+------------| | Total | | ** More details | S.No | Work location | Working hours | Price | |------+----------------------+---------------+-------| | | | | | | 1 | United States | X-Y | 100 | |------+----------------------+---------------+-------| | 2 | United Arab Emirates | X'-Y' | 100 | |------+----------------------+---------------+-------| * Conclusion #this is a COMMENT AND I HOPE this will not be displayed ** COMMENT and this will not be displayed * Links [[http://www.google.com][Google.com]] #+BEGIN_VERSE Great clouds overhead Tiny black birds rise and fall Snow covers Emacs -- AlexSchroeder #+END_VERSE ```
https://tex.stackexchange.com/users/65365
Exporting .org files to LaTeX - Error
false
I found this thread by having the same error message: `! LaTeX Error: File wrapfig.sty not found.` on manjaro. `sudo pacman -S texlive-latex-extra` fixed it for me.
0
https://tex.stackexchange.com/users/294911
682666
316,742
https://tex.stackexchange.com/questions/508744
-1
I've got a document in REVTex (based off the apssample.tex template) that is exhibiting some odd behavior in the bibliography: For papers with two authors, the space between the first author's last name and "and" is missing, so that > > J. Smith and M. Jones > > > is rendered as > > J. Smithand M. Jones > > > If I switch the document from REVTex 4.2 to REVTex 4.1, then the bibliography renders as expected. I haven't been able to track down this problem any more deeply -- e.g., the console output doesn't suggest anything obvious -- and my internet searches haven't turned up any other reports on this behavior. Any suggestions on what I might be missing?
https://tex.stackexchange.com/users/97638
REVTex 4.2 bibliography missing space after first author name
true
The missing space was caused by a bug in apsrev4-2.bst. The bug was fixed in [this update to the bst file](https://tug.org/svn/texlive/trunk/Master/texmf-dist/bibtex/bst/revtex/apsrev4-2.bst?pathrev=49751&view=diff&r1=49751&r2=49672&diff_format=h) (specifically the change to line 1580), which had not propagated to the system I was writing the paper on.
1
https://tex.stackexchange.com/users/97638
682669
316,743
https://tex.stackexchange.com/questions/682652
2
I am making a Beamer presentation, like say: ``` \begin{frame} \only<1>{\Huge}\onslide<1->{Text 1.} \begin{itemize} \item<2->\only<2>{\Huge} Item 1. \item<3->\only<3>{\Huge} Item 2. \end{itemize} \end{frame} ``` The goal is to make each slide present the currently introduced text in a huge font, while leaving the rest of the text visible but much smaller. This works, but (1) This requires a lot of writing commands per slide. (2) Is quite fragile -- if I have to reorder things, I could potentially need to spend a lot of time renumbering. Is there a way to make it do the same job while parsing a source that looks more like, for example, ``` \begin{frame} Text 1. \slide \begin{itemize} \item Item 1. \item Item 2. \end{itemize} ``` or perhaps with a minimal amount of extra commands to separate out the slides? --- I don't have a lot of experience with creating commands, but experimented with this and it didn't work: ``` \newcounter{slidenum} \setcounter{slidenum}{1} \newcommand{\next}[1]{\only<\theslidenum>{\Huge}\onslide<\theslidenum->{#1}\addtocounter{slidenum}{1}} ``` In the way that I imagine this working, I could put every next overlay in a `\next{...}` command and at the start of every frame, restart the counter. But when I try to use it in a slide, the item in the `\next{...}` is neither made huge nor is it hidden on the first overlay.
https://tex.stackexchange.com/users/62274
Simplifying a Beamer overlay style
true
Does the following do what you want? ``` \documentclass{beamer} \newcommand{\hugeOnce}[1]{{\only<.>{\Huge} #1}} \begin{document} \begin{frame}[<+->] \only<+->{\hugeOnce{Text 1.}} \begin{itemize} \item \hugeOnce{Item 1.} \item \hugeOnce{Item 2.} \end{itemize} \end{frame} \end{document} ```
3
https://tex.stackexchange.com/users/12212
682673
316,746
https://tex.stackexchange.com/questions/682667
4
I would like to separate blocks of text (stories) via a horizontal line inserted automatically between the blocks, but not before the first or after the last. I tried to achieve this by creating a flag with etoolbox to indicate whether the current block is the first, but this does not seem to work. The boolean always seems to evaluate to false. I have provided a simple example below, with the text "BETWEEN STORIES" rather than an hrule. ``` \documentclass{article} \usepackage{etoolbox} \newbool{didonestory} \newenvironment{stories}{\boolfalse{didonestory}}{} \newenvironment{story}{ \ifbool{didonestory}{BETWEEN STORIES}{} }{ \booltrue{didonestory} } \begin{document} \begin{stories} \begin{story} Test 1 \end{story} \begin{story} Test 2 \end{story} \end{stories} \end{document} ``` Here I expect the output to be "Test 1 BETWEEN STORIES Test 2" but instead the output is only "Test 1 Test 2". My questions are: 1. What am I doing wrong with the Boolean values? 2. Is there a more standard way to achieve what I want here?
https://tex.stackexchange.com/users/294910
Unexpected behavior with etoolbox
false
you are setting the boolean to true in a group. Do if after the environment: ``` \documentclass{article} \usepackage{etoolbox} \newbool{didonestory} \newenvironment{stories}{\boolfalse{didonestory}}{} \AddToHook{env/story/after}{\booltrue{didonestory}} \newenvironment{story}{\ifbool{didonestory}{BETWEEN STORIES}{}}{} \begin{document} \begin{stories} \begin{story} Test 1 \end{story} \begin{story} Test 2 \end{story} \end{stories} \end{document} ```
6
https://tex.stackexchange.com/users/2388
682674
316,747
https://tex.stackexchange.com/questions/682652
2
I am making a Beamer presentation, like say: ``` \begin{frame} \only<1>{\Huge}\onslide<1->{Text 1.} \begin{itemize} \item<2->\only<2>{\Huge} Item 1. \item<3->\only<3>{\Huge} Item 2. \end{itemize} \end{frame} ``` The goal is to make each slide present the currently introduced text in a huge font, while leaving the rest of the text visible but much smaller. This works, but (1) This requires a lot of writing commands per slide. (2) Is quite fragile -- if I have to reorder things, I could potentially need to spend a lot of time renumbering. Is there a way to make it do the same job while parsing a source that looks more like, for example, ``` \begin{frame} Text 1. \slide \begin{itemize} \item Item 1. \item Item 2. \end{itemize} ``` or perhaps with a minimal amount of extra commands to separate out the slides? --- I don't have a lot of experience with creating commands, but experimented with this and it didn't work: ``` \newcounter{slidenum} \setcounter{slidenum}{1} \newcommand{\next}[1]{\only<\theslidenum>{\Huge}\onslide<\theslidenum->{#1}\addtocounter{slidenum}{1}} ``` In the way that I imagine this working, I could put every next overlay in a `\next{...}` command and at the start of every frame, restart the counter. But when I try to use it in a slide, the item in the `\next{...}` is neither made huge nor is it hidden on the first overlay.
https://tex.stackexchange.com/users/62274
Simplifying a Beamer overlay style
false
You could use a similar trick as in <https://topanswers.xyz/tex?q=1334#a1579> and create a new beamer action: ``` \documentclass{beamer} \newenvironment{hugeenv}{\only{\Huge}}{} \begin{document} \begin{frame} \only<+>{\Huge} Text \begin{itemize}[<huge@+|+->] \item Item 1. \item Item 2. \end{itemize} \end{frame} \end{document} ```
3
https://tex.stackexchange.com/users/36296
682675
316,748
https://tex.stackexchange.com/questions/682562
0
I add Acronyms and Reference in Overleaf. ``` \usepackage[acronym,nopostdot]{glossaries} \renewcommand{\glsnamefont}[1]{\textbf{#1}} \setlength\LTleft{0pt} \setlength\LTright{0pt} \setlength\glsdescwidth{0.8\hsize} \makeglossaries \newacronym{ny}{NY}{New York} \printglossary[type=acronym,style=long] \arcfull{ny} is a city \citet{author2000}. ``` The reference list showed me incorrectly ``` Author(2000). ny city. ``` It should show me like this, which is original title. ``` Author(2000). NY city. ``` I would like to keep NY in main body, and reference does not change with the Acronyms, reference list keep original title.
https://tex.stackexchange.com/users/294842
Acronyms | Reference| abbreviation | Overleaf | Latex
false
Thanks, everyone! I manually add {} in bibtext of reference to keep it uppercase. It seems like it's not because of Acronyms.
0
https://tex.stackexchange.com/users/294842
682678
316,751
https://tex.stackexchange.com/questions/682680
1
I am writing my master thesis and would like to know which citation call-out style `plainnat` uses. For example is it APA, Harvard, etc.? Furthermore, I would like to show the surname of the author before the first name in the bibliography. This is how it is now: "George Alexandridis, Kathleen P Fuller...", but I would like it to be "Alexandridis George, Fuller Kathleen P...". Is there a way to do this? My code is as follows: ``` \bibliographystyle{plainnat} \setlength{\bibhang}{0pt} \bibliography{Library} ```
https://tex.stackexchange.com/users/294915
Which citation call-out style (e.g. Harvard, APA) does plainnat use?
false
The `plainnat` bibliography style, when used with the `natbib` citation management package, can create three [3!] separate citation call-out styles: * If `natbib` is loaded with the option `numbers`, `plainnat` will generate numeric-style citation call-outs. * If `natbib` is loaded with the option `super`, `plainnat` will generate superscript-style numeric citation call-outs. * If `natbib` is loaded with the option `authoryear`, `plainnat` will generate authoryear-style citation call-outs. Incidentally, both APA and Harvard are associated with authoryear-style citation call-outs. The formatted bibliographic entries that BibTeX generates when it use the `plainnat` bib style do not conform to APA rules. To change the way an author's full name is formatted, from (say) "Kevin de Bruyne" to "de Bruyne, Kevin", I suggest you proceed as follows. * Find the file `plainnat.bst` in your TeX distribution. Make a copy of this file and name the copied file, say, `plainnatrev.bst` ("rev" being short for "reversed"). Don't edit an original file of your TeX distribution directly. * Open the file in a text editor. The program you use to edit your tex files will do fine. * In the file `plainnatrev.bst`, locate the function called `format.names`. (In my copy of the file, this function starts on line 216.) * In the `format.names` function, locate the following line: ``` { s nameptr "{ff~}{vv~}{ll}{, jj}" format.name$ 't := ``` Change it to ``` { s nameptr "{vv~}{ll}{, jj}{, ff}" format.name$ 't := ``` In case you're curious: the components `ll`, `ff`, `vv` and `jj` represent the surname, first name(s), "von", and junior components of a full name. Each "full name" is assumed to contain at least a surname component. * Save the file `plainnatrev.bst` either in the directory that contains your main tex file or in a directory that's searched by BibTeX. If you choose the second option, be sure to also refresh the filename database of your TeX distribution as needed. If you have no idea what the preceding sentence means, I suggest you choose the first option. * In your main tex file, change `\bibliographystyle{plainnat}` to `\bibliographystyle{plainnatrev}` and perform a full recompile cycle: LaTeX, BibTeX, and LaTeX twice more. Happy BibTeXing! --- ``` \documentclass{article} \begin{filecontents}[overwrite]{mybib.bib} @misc{af:3001, author = "George Alexandridis and Kathleen P. Fuller", title = "Thoughts", year = 3001, } @misc{kdb:5001, author = "Kevin de Bruyne and Lucas, Jr., Robert E.", title = "Further thoughts", year = 5001, } \end{filecontents} \usepackage[authoryear,round]{natbib} \bibliographystyle{plainnatrev} \begin{document} \noindent \citet{af:3001}, \citep{kdb:5001} \bibliography{mybib} \end{document} ```
2
https://tex.stackexchange.com/users/5001
682690
316,754
https://tex.stackexchange.com/questions/682667
4
I would like to separate blocks of text (stories) via a horizontal line inserted automatically between the blocks, but not before the first or after the last. I tried to achieve this by creating a flag with etoolbox to indicate whether the current block is the first, but this does not seem to work. The boolean always seems to evaluate to false. I have provided a simple example below, with the text "BETWEEN STORIES" rather than an hrule. ``` \documentclass{article} \usepackage{etoolbox} \newbool{didonestory} \newenvironment{stories}{\boolfalse{didonestory}}{} \newenvironment{story}{ \ifbool{didonestory}{BETWEEN STORIES}{} }{ \booltrue{didonestory} } \begin{document} \begin{stories} \begin{story} Test 1 \end{story} \begin{story} Test 2 \end{story} \end{stories} \end{document} ``` Here I expect the output to be "Test 1 BETWEEN STORIES Test 2" but instead the output is only "Test 1 Test 2". My questions are: 1. What am I doing wrong with the Boolean values? 2. Is there a more standard way to achieve what I want here?
https://tex.stackexchange.com/users/294910
Unexpected behavior with etoolbox
true
You want to set the boolean globally. ``` \documentclass{article} \usepackage{etoolbox} \newbool{didonestory} \newenvironment{stories}{\global\boolfalse{didonestory}}{} \newenvironment{story}{% \ifbool{didonestory}{BETWEEN STORIES}{}% }{% \global\booltrue{didonestory}% } \begin{document} \begin{stories} \begin{story} Test 1 \end{story} \begin{story} Test 2 \end{story} \end{stories} \end{document} ```
1
https://tex.stackexchange.com/users/4427
682691
316,755
https://tex.stackexchange.com/questions/682572
5
I don't get it. `Gill Sans MT` supports Small Caps without any issue in Word and Powerpoint. Font recognition apps event identify it. And yet, there is no way I can get them. ``` \documentclass{article} \usepackage{fontspec} \setmainfont{Gill Sans MT}[ SmallCapsFeatures={Letters=SmallCaps}, SmallCapsFont={*}, ] \begin{document} \textsc{Small Caps.} \end{document} ```
https://tex.stackexchange.com/users/262813
Small Caps with Gill Sans MT
false
Since you are using `fontspec`: If you need to fake small caps, you might wish to use the `FakeStretch` optional argument. See the `fontspec` manual. You might also wish to increase the letter spacing, but I believe that FakeStretch already helps you there. If you downscale uppercase letters, to make fake small caps, then the weight (thickness) of the characters also decreases in proportion. You can compensate in the horizontal direction using FakeStretch. Compensation should not be exactly the inverse of the shrinkage, since small caps are normally slightly lighter than uppercase. Fontspec also has `FakeBold` but I am reluctant to use it. I do not know its algorithm. At least in some font editors, using the equivalent of FakeBold runs the risk of generating self-crossing or ambiguous glyph outlines. But FakeStretch is merely a one-dimensional scale, so that should not cause any problems. FakeStretch will leave the horizontal bars (and serifs) alone, so they will be too thin. But this may escape notice. Depends on the font. On a related note, some folks like to put acronyms in "medium caps" between small caps and uppercase. If you do that, it is usually better to upscale true small caps (if available) and unstretch the widths, rather than downscale uppercase and stretch the widths.
1
https://tex.stackexchange.com/users/287367
682695
316,757
https://tex.stackexchange.com/questions/682549
4
I'd like to learn basic TeX programming (as a programming language instead of a tool of typeset) systematically, but I find "the Tex Book" by Knuth spends much time on typeset matter. Is there a book that focuses on explicit Tex programming and goes deeper?
https://tex.stackexchange.com/users/270268
Is there a book explicitly about TeX programming?
false
Si vous parlez français, vous peux trouver [how to program in TeX](https://ctan.org/pkg/apprendre-a-programmer-en-tex) chez CTAN. Translation: > > If you speak French, then you can find ["How to program in TeX"](https://ctan.org/pkg/apprendre-a-programmer-en-tex) on CTAN. > > >
3
https://tex.stackexchange.com/users/52679
682699
316,760
https://tex.stackexchange.com/questions/489315
1
Is it possible to insert delta but not in math mode? I have ``` \def\Name{text ...} ``` where text include \delta. This \Name is in displayed in bold and in plain and \delta in math mode can be only one of them. Thank you I need to write delta in a way \textbf make it bold. I can't use \bm in math mode. ``` \documentclass[12pt,a4paper]{report} \begin{document} \textbf{text $\delta$} \end{document} ```
https://tex.stackexchange.com/users/181272
Write bold \delta
false
A very clever one: ``` \boldsymbol{\delta} ```
0
https://tex.stackexchange.com/users/294928
682702
316,761
https://tex.stackexchange.com/questions/682703
2
An earlier post [How to handle figures and images using MikTeX Plain TeX (not LaTeX) on a 35 year old document](https://tex.stackexchange.com/questions/525257/how-to-handle-figures-and-images-using-miktex-plain-tex-not-latex-on-a-35-year?newreg=1925fe4de4614c9d8435f069f7933b49) (that I am not allowed to comment on) suggested this simple solution. (I also am working on converting a thesis from the 1980s.) ``` \pdfximage width .25\hsize{man.png} \pdfrefximage\pdflastximage ``` which worked immediately for me using the pdftex command. Thank you! However, the image is not centered on the page but up against the left margin. Does anyone know how to center the image?
https://tex.stackexchange.com/users/294929
Centering images in Plain TeX when using pdftex
true
You can do in vertical mode (i.e after empty line): ``` \centerline{\pdfximage width .25\hsize{man.png} \pdfrefximage\pdflastximage} ``` or ``` \pdfximage width .25\hsize{man.png} \centerline{\pdfrefximage\pdflastximage} ``` The first line only loads data of the image to the memory (it is used in PDF file as a numerated object) but doesn't draw it. The number of this object is accessible by `\pdflastximage` register. And the primitive `\pdfrefximage <num>` really draws the image saved in the object `<num>`. The `\centerline` plain TeX macro is defined as ``` \def\centerline#1{\hbox to\hsize{\hss#1\hss}} ``` so, it does centering of its parameter to the width `\hsize`. Another method is doing this in vertical mode: ``` \noindent\hfil ...image... ``` finalized by empty line. This works if the the value of the `\parfillskip` register is `0pt plus 1fil`. This is very common value. The value is used as `\hskip` at the end last line of each paragraph.
6
https://tex.stackexchange.com/users/51799
682720
316,768
https://tex.stackexchange.com/questions/682549
4
I'd like to learn basic TeX programming (as a programming language instead of a tool of typeset) systematically, but I find "the Tex Book" by Knuth spends much time on typeset matter. Is there a book that focuses on explicit Tex programming and goes deeper?
https://tex.stackexchange.com/users/270268
Is there a book explicitly about TeX programming?
false
If you are able to read Czech, then there is [TeXbook inside out](https://petr.olsak.net/tbn.html).
4
https://tex.stackexchange.com/users/51799
682722
316,769
https://tex.stackexchange.com/questions/682485
0
I want to use the exam class for a project and have already learned that using multiple questions environments causes some problems. Therefore, I wanted to include everything inside of one questions environment. Now I got some problems with the resulting margins, which you can see using the following snippet: ``` \documentclass[]{exam} \firstpageheadrule \runningheadrule \begin{document} \begin{questions} \section{Name} \question What is the value of $x$ in $x^2 = 4$? \section{Next Section} \question Bob has 2 apples, what is the temperature of the sun? \end{questions} \end{document} ``` In general, I want the sections to align with the header rule. One solution would be that the number of the questions (main questions, not subquestions) is inside the margin so that the section and the text of the questions align with the rule. Another solution would be to shift the questions so that the number of the questions and the sections align, and both also align with the head rule. Sadly I am not able to create any of those solutions. Can you help me? So far, I tried solutions with `\fullwidth`, `EnvFullwidth` and changing the `hoffset`/`offsidemargin`, but none of my attempts led to a satisfying solution.
https://tex.stackexchange.com/users/209246
Exam class change margin without affecting header, footer
false
The exam class is mainly a fancy list. For more information see chapter 4.10 [here](https://mirror.physik.tu-berlin.de/pub/CTAN/macros/latex/contrib/exam/examdoc.pdf). Thus, we can set common list length parameters for those list extensions. This resulted in a solution as follows: ``` \documentclass[]{exam} \firstpageheadrule \runningheadrule % Here is the adaption: \renewcommand{\questionshook}{% \setlength{\leftmargin}{0pt}% } \begin{document} \begin{questions} \section{Name} \question What is the value of $x$ in $x^2 = 4$? \section{Next Section} \question Bob has 2 apples, what is the temperature of the sun? \end{questions} \end{document} ```
0
https://tex.stackexchange.com/users/209246
682724
316,770
https://tex.stackexchange.com/questions/682721
2
when I try to compute the following Latex code I constantly get the "overfull hbox" error. I've tried manually controlling column width using P{xcm} but that doesn't seem to be working for me either. Does anyone know of a robust solution? ``` \begin{table}[H] \begin{tabular}{|ccccccc|} \hline \multicolumn{7}{|c|}{\textbf{Mechanical Loads}} \\ \hline \multicolumn{1}{|c|}{Requirement} & \multicolumn{1}{c|}{Description} & \multicolumn{1}{c|}{Engineer} & \multicolumn{1}{c|}{Location} & \multicolumn{1}{c|}{TR Number} & \multicolumn{1}{c|}{Date Completed} & Pass / Fail \\ \hline \multicolumn{1}{|c|}{Test 1} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 2} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 3} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 4} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 5} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 6} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 7} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 8} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 9} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 10} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 11} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 12} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 13} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \end{tabular} \end{table} ```
https://tex.stackexchange.com/users/255038
Table: overfull hbox
false
First and foremost, you have got to get rid of the multitude of `\multicolumn{1}` wrappers. Without this fix, nothing else matters. (Aside: Why on earth were these wrappers inserted? Maybe because a bot did the design work??) Once these wrappers are gone, I'd suggest you employ a `tabularx` environment, set its overall width to `\textwidth`, and allow line-breaking within cells in the six data columns. ``` \documentclass{article} \usepackage{tabularx,ragged2e,booktabs} \newcolumntype{C}{>{\Centering\hspace{0pt}}X} \renewcommand\tabularxcolumn[1]{m{#1}} \begin{document} \begin{table}[ht] \setlength\tabcolsep{3pt} % default: 6pt \caption{Mechanical Loads\strut} \begin{tabularx}{\textwidth}{@{} l CCCCCC @{}} \toprule Req'ment & Description & Engineer & Location & TR Number & Date Completed & Pass\slash Fail \\ \midrule Test 1 & Brief description & Example & United Kingdom & & & \\ \addlinespace Test 2 & Brief description & Example & United Kingdom & & & \\ \addlinespace \dots \\ %Test 3 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 4 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 5 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 6 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 7 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 8 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 9 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 10 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 11 & Brief description & Example & United Kingdom & & & \\ \addlinespace %Test 12 & Brief description & Example & United Kingdom & & & \\ \addlinespace Test 13 & Brief description & Example & United Kingdom & & & \\ \bottomrule \end{tabularx} \end{table} \end{document} ```
3
https://tex.stackexchange.com/users/5001
682726
316,772
https://tex.stackexchange.com/questions/34604
300
How do I enter Unicode characters in LaTeX? What packages do I need to install and what escape sequence do I type to specify Unicode characters in an ASCII source file?
https://tex.stackexchange.com/users/334
Entering Unicode characters in LaTeX
false
Just linking to this other answer that uses `unicode-math`’s source file to automatically define all symbols: [Unicode maths in pdflatex](https://tex.stackexchange.com/questions/601579/unicode-maths-in-pdflatex)
0
https://tex.stackexchange.com/users/116348
682727
316,773
https://tex.stackexchange.com/questions/682684
0
Is it possible to specify how to color a variable with `mintinline`? What I mean is, for instance, to use `\mintinline{python}{myClass}` and color `myClass` as a Class variable, or as a function. If I use the command as it is, I just get black color by default, but strings are colorized correctly, like `\mintinline{python}{'a string'}`.
https://tex.stackexchange.com/users/14561
Minted: colorize variable in inline mode
true
I don't think this is possible. To start with your mark-up must convey to Pygments the info that `myClass` is a class object name. Perhaps while registering a dedicated lexer with Pygments which will simply tokenize every word in the input as a class name. Meanwhile, you can do some reverse-engineering and produce for example this: ``` \documentclass{article} \usepackage{minted} \makeatletter \newcommand\highlightaspyclass[1]{% \minted@generate@PYGdef{default}% {\minted@PYGdef@default\PYG{n+nc}{#1}}% }% \makeatother \begin{document} This is highlighted \highlightaspyclass{myClass}. \end{document} ``` Basically for this I started from some ``` \begin{minted}{python} class myClass: pass \end{minted} ``` in the document, ran latex and went to see the pygmentize output mark-up which turned out to be `\PYG{n+nc}{myClass}` which will thus a priori the mark-up for Python Class objects which I could abstract into a sort of generic `\highlightaspyclass` command. Then some digging into minted source code and by luck it was possible to do the above. "default" stands for the "style" variable defined via `\usemintedstyle`, so update the above if using a custom one. (section `3.4 Using different styles` in the minted doc). You will need to repeat the above preliminary procedure for each other type of token and create an associated custom macro. Mind that things such as compatibility with being used in section titles or the like might get lost and perhaps handling of special characters requiring sanitization that `\mintedinline` does in its way and is not done in our custom hacked command. You must run the above with shell-escape, as generally with minted. EDIT: you will also have to set manually the typeface, like for example using monospace font family which I have not done here.
1
https://tex.stackexchange.com/users/293669
682728
316,774
https://tex.stackexchange.com/questions/682707
0
The manual says that I can change it in "pdf-viewer/configure" but I can't find it in "Options"->"Configure TeXstudio"->"Internal pdf viewer." I asked ChatGPT and it says that there should be "Advanced Editor" in "Configure TeXstudio," but my version (4.5.1) doesn't have that tab in the configuration.
https://tex.stackexchange.com/users/184650
How can I turn off "Cursor follows Scrolling" in TeXstudio?
true
In embedded pdf viewer: In windowed pdf viewer:
1
https://tex.stackexchange.com/users/123653
682730
316,775
https://tex.stackexchange.com/questions/682721
2
when I try to compute the following Latex code I constantly get the "overfull hbox" error. I've tried manually controlling column width using P{xcm} but that doesn't seem to be working for me either. Does anyone know of a robust solution? ``` \begin{table}[H] \begin{tabular}{|ccccccc|} \hline \multicolumn{7}{|c|}{\textbf{Mechanical Loads}} \\ \hline \multicolumn{1}{|c|}{Requirement} & \multicolumn{1}{c|}{Description} & \multicolumn{1}{c|}{Engineer} & \multicolumn{1}{c|}{Location} & \multicolumn{1}{c|}{TR Number} & \multicolumn{1}{c|}{Date Completed} & Pass / Fail \\ \hline \multicolumn{1}{|c|}{Test 1} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 2} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 3} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 4} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 5} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 6} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 7} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 8} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 9} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 10} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 11} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 12} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 13} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \end{tabular} \end{table} ```
https://tex.stackexchange.com/users/255038
Table: overfull hbox
false
* Please always provide MWE (Minimal Working Example), which a small but complete, compilable document, which reproduce your problem * Due to lack of it, we haven't any information about your document pages' layout (size of `\textwidth`, which has strong influence on table appearing). * It seems that you wrote your table with some table generator, which which fill code with unnecessary `\multicolumn{1}{c}{...}` vrapers. Remove them!. * Selected column types as well used `\multicolumn`s not enable to break break text in cells in to (or more) lines, consequently your problem arise. * You may consider to use ˙tabularray` package for table. Using it a table code is more concise: ``` \documentclass{article} \usepackage{ragged2e} \usepackage{tabularray,ragged2e} \UseTblrLibrary{booktabs} %\newcolumntype{C}{>{\Centering\hspace{0pt}}X} %\renewcommand\tabularxcolumn[1]{m{#1}} \begin{document} \begin{table}[ht] \caption{Mechanical Loads\strut} \begin{tblr}{colsep=1pt, colspec = {@{} l *{6}{X[m, font=\linespread{0.84}\selectfont, cmd=\Centering\hspace{0pt}]} @{}} } \toprule Req'ment & Description & Engineer & Location & TR Number & Date Completed & Pass\slash Fail \\ \midrule Test 1 & Brief description & Example & United Kingdom & & & \\ Test 2 & Brief description & Example & United Kingdom & & & \\ Test 3 & Brief description & Example & United Kingdom & & & \\ Test 4 & Brief description & Example & United Kingdom & & & \\ Test 5 & Brief description & Example & United Kingdom & & & \\ Test 6 & Brief description & Example & United Kingdom & & & \\ Test 7 & Brief description & Example & United Kingdom & & & \\ Test 8 & Brief description & Example & United Kingdom & & & \\ Test 9 & Brief description & Example & United Kingdom & & & \\ Test 10 & Brief description & Example & United Kingdom & & & \\ Test 11 & Brief description & Example & United Kingdom & & & \\ Test 12 & Brief description & Example & United Kingdom & & & \\ Test 13 & Brief description & Example & United Kingdom & & & \\ \bottomrule \end{tblr} \end{table} \end{document} ```
3
https://tex.stackexchange.com/users/18189
682731
316,776
https://tex.stackexchange.com/questions/682713
0
I want to change the footnote symbol in block of Beamer. I used the following command. ``` \usepackage[symbol]{footmisc} \renewcommand{\thefootnote}{\fnsymbol{footnote}} ``` Then Symbols of thanks and footnote not used in block ware changed. But Symbols of footnote used in block weren't changed. Please tell me how to change them? I'm a Japanese Student so, I want you to forgive small mistakes about English.
https://tex.stackexchange.com/users/284985
How to change the footnote symbol in Beamer block
true
You could use the same trick as in <https://tex.stackexchange.com/a/18500/36296> ``` \documentclass{beamer} \usetheme{Warsaw} \renewcommand{\thempfootnote}{\ifcase\value{mpfootnote}\or\textasteriskcentered\or\textdagger\or\textdaggerdbl\fi} \begin{document} \begin{frame} \begin{block}{title} content\footnote{text} \end{block} abc\footnote{test} \end{frame} \end{document} ```
0
https://tex.stackexchange.com/users/36296
682733
316,777
https://tex.stackexchange.com/questions/682572
5
I don't get it. `Gill Sans MT` supports Small Caps without any issue in Word and Powerpoint. Font recognition apps event identify it. And yet, there is no way I can get them. ``` \documentclass{article} \usepackage{fontspec} \setmainfont{Gill Sans MT}[ SmallCapsFeatures={Letters=SmallCaps}, SmallCapsFont={*}, ] \begin{document} \textsc{Small Caps.} \end{document} ```
https://tex.stackexchange.com/users/262813
Small Caps with Gill Sans MT
false
Word processors often have the capability of faking fonts that aren't in the system; with TeX this is not possible, because we're doing fine typography, not just printing whatever. With *several* limitations (only text, no commands), you can fake small caps. For your simple application it should do. Here I use Gillius ADF as I don't have Gill Sans MT. ``` \documentclass{article} \usepackage{fontspec} \setmainfont{Gillius ADF}[% replacement for Gill Sans NFSSFamily=gilliusadf, ] \newfontfamily{\scaledgillius}{Gillius ADF}[Scale=0.8,FakeBold=1.5,WordSpace=1.25] \ExplSyntaxOn \NewDocumentCommand{\fakesc}{m} { \krebs_fakesc:n { #1 } } \seq_new:N \l__krebs_fakesc_words_in_seq \seq_new:N \l__krebs_fakesc_words_out_seq \cs_new_protected:Nn \krebs_fakesc:n { \group_begin: \scaledgillius \seq_set_split:Nnn \l__krebs_fakesc_words_in_seq { ~ } { #1 } \seq_set_map:NNn \l__krebs_fakesc_words_out_seq \l__krebs_fakesc_words_in_seq { \__krebs_fakesc:n { ##1 } } \seq_use:Nn \l__krebs_fakesc_words_out_seq { ~ } \group_end: } \cs_new_protected:Nn \__krebs_fakesc:n { \text_map_inline:nn { #1 } { \__krebs_fakesc_letter:n { ##1 } } } \cs_new_protected:Nn \__krebs_fakesc_letter:n { \int_compare:nTF { \char_value_uccode:n { `#1 } = `#1 } { {\fontfamily{gilliusadf}\selectfont #1 } } { \char_uppercase:N #1 } } \ExplSyntaxOff \begin{document} \fakesc{Smáll Câps. Ii} \textit{\fakesc{Smáll Câps. Ii}} \end{document} ```
5
https://tex.stackexchange.com/users/4427
682738
316,779
https://tex.stackexchange.com/questions/682721
2
when I try to compute the following Latex code I constantly get the "overfull hbox" error. I've tried manually controlling column width using P{xcm} but that doesn't seem to be working for me either. Does anyone know of a robust solution? ``` \begin{table}[H] \begin{tabular}{|ccccccc|} \hline \multicolumn{7}{|c|}{\textbf{Mechanical Loads}} \\ \hline \multicolumn{1}{|c|}{Requirement} & \multicolumn{1}{c|}{Description} & \multicolumn{1}{c|}{Engineer} & \multicolumn{1}{c|}{Location} & \multicolumn{1}{c|}{TR Number} & \multicolumn{1}{c|}{Date Completed} & Pass / Fail \\ \hline \multicolumn{1}{|c|}{Test 1} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 2} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 3} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 4} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 5} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 6} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 7} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 8} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 9} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 10} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 11} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 12} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \multicolumn{1}{|c|}{Test 13} & \multicolumn{1}{c|}{Brief description} & \multicolumn{1}{c|}{Example} & \multicolumn{1}{c|}{United Kingdom} & \multicolumn{1}{c|}{} & \multicolumn{1}{c|}{} & \\ \hline \end{tabular} \end{table} ```
https://tex.stackexchange.com/users/255038
Table: overfull hbox
false
First of all, here's a recommended reading [tables](https://en.wikibooks.org/wiki/LaTeX/Tables). Second of all, don't use table generators! Frankly, ChatGPT can produce much cleaner code for simple tables like yours. Anyway, the link leads to content, after reading which you should be able to create this and even more complicated tables without much help. Based on your example, the table is too wide and doesn't fit within a page. Out of many solutions, I think you could make two groups and stack them together or rotate and render the table vertically (see the sections below). You should also use captions instead of extra top headers, which can be formatted if you wish; e.g. in codes below, uncomment lines of `\DeclareCaption...` and lines inside `\captionsetup` to make the caption bold but I wouldn't recommend it. If cells are too wide, `p{}`-type column creates paragraph-like cells and add line breaks if necessary. Also see [Mico](https://tex.stackexchange.com/a/682726/31283)'s answer for example of using `X`-type for unified columns. Alternatively, it's possible to add line breaks manually with convenient macros such as `\thead` for headers or `\makecell` for regular cells. In both cases `\\` is accepted but both macros require additional `makecell` package. On top of that, `\Gape` in the last headers increase row height to add more space for headers (also requires `makecell` package). **Rotate** ``` \documentclass{article} \usepackage{rotating} \usepackage{makecell} \usepackage{caption} % \DeclareCaptionTextFormat{bold-text}{\bfseries#1} % \DeclareCaptionLabelFormat{bold-label}{\bfseries\bothIfFirst{#1~}{}#2} \captionsetup[table]{ position=top, skip=3pt, % textformat=bold-text, % labelformat=bold-label, } \renewcommand{\theadfont}{\normalsize} \renewcommand{\theadgape}{\Gape[0pt][0pt]} \begin{document} \begin{sidewaystable} \renewcommand{\arraystretch}{1.25} \centering \caption{Mechanical Loads}\label{tab:mech-loads-v} \begin{tabular}{l *6{c}} \hline \thead{Requirement} & \thead{Description} & \thead{Engineer} & \thead{Location} & \thead{TR\\Number} & \thead{Date\\Completed} & \thead{\Gape[10pt]{Pass/Fail}} \\ \hline Test 1 & Brief description & Example & United Kingdom & & & \\ Test 2 & Brief description & Example & United Kingdom & & & \\ Test 3 & Brief description & Example & United Kingdom & & & \\ Test 4 & Brief description & Example & United Kingdom & & & \\ Test 5 & Brief description & Example & United Kingdom & & & \\ Test 6 & Brief description & Example & United Kingdom & & & \\ Test 7 & Brief description & Example & United Kingdom & & & \\ Test 8 & Brief description & Example & United Kingdom & & & \\ Test 9 & Brief description & Example & United Kingdom & & & \\ Test 10 & Brief description & Example & United Kingdom & & & \\ Test 11 & Brief description & Example & United Kingdom & & & \\ Test 12 & Brief description & Example & United Kingdom & & & \\ Test 13 & Brief description & Example & United Kingdom & & & \\ \hline \end{tabular} \end{sidewaystable} \end{document} ``` **Split into groups** ``` \documentclass{article} \usepackage{makecell} \usepackage{caption} % \DeclareCaptionTextFormat{bold-text}{\bfseries#1} % \DeclareCaptionLabelFormat{bold-label}{\bfseries\bothIfFirst{#1~}{}#2} \captionsetup[table]{ position=top, skip=3pt, % textformat=bold-text, % labelformat=bold-label, } \renewcommand{\theadfont}{\normalsize} \renewcommand{\theadgape}{\Gape[0pt][0pt]} \begin{document} \begin{table}[tbh] \renewcommand{\arraystretch}{1.25} \centering \caption{Mechanical Loads}\label{tab:mech-loads-h} \begin{tabular}{l *3{c}} \hline \thead{Requirement} & \thead{Description} & \thead{Engineer} & \thead{\Gape[10pt]{Location}} \\ \hline Test 1 & Brief description & Example & United Kingdom \\ Test 2 & Brief description & Example & United Kingdom \\ Test 3 & Brief description & Example & United Kingdom \\ Test 4 & Brief description & Example & United Kingdom \\ Test 5 & Brief description & Example & United Kingdom \\ Test 6 & Brief description & Example & United Kingdom \\ Test 7 & Brief description & Example & United Kingdom \\ Test 8 & Brief description & Example & United Kingdom \\ Test 9 & Brief description & Example & United Kingdom \\ Test 10 & Brief description & Example & United Kingdom \\ Test 11 & Brief description & Example & United Kingdom \\ Test 12 & Brief description & Example & United Kingdom \\ Test 13 & Brief description & Example & United Kingdom \\ \hline \hline \thead{Requirement} & \thead{TR\\Number} & \thead{Date\\Completed} & \thead{\Gape[9pt]{Pass/Fail}} \\ \hline Test 1 & & & \\ Test 2 & & & \\ Test 3 & & & \\ Test 4 & & & \\ Test 5 & & & \\ Test 6 & & & \\ Test 7 & & & \\ Test 8 & & & \\ Test 9 & & & \\ Test 10 & & & \\ Test 11 & & & \\ Test 12 & & & \\ Test 13 & & & \\ \hline \end{tabular} \end{table} \end{document} ``` | Rotate | Split | | --- | --- | | | |
3
https://tex.stackexchange.com/users/31283
682740
316,780
https://tex.stackexchange.com/questions/682739
2
I would like to have a tikz picture recurring on every page of a certain pagestyle except for the page with the chapter title. When compiling the MWE, I get the picture only on the page with the chapter title but nowhere else. I would also like to omit the section title from the first page of the chapter. ``` \documentclass[12pt, oneside,headsepline=true,chapterprefix=false,headings=optiontohead,toc=indentunnumbered, usegeometry]{scrreprt} \usepackage{lmodern} \usepackage[english]{babel} \usepackage{tikz} %%%---header/footer \usepackage[ automark, autooneside=false,% <- needed if you want to use \leftmark and \rightmark in a onesided document headsepline ]{scrlayer-scrpage} \newpairofpagestyles{MyIntro}{% \clearpairofpagestyles% \ohead*{\ifstr{\leftmark}{\rightbotmark}{}{\rightbotmark}}{% \begin{tikzpicture}[remember picture,overlay] \node[rectangle, minimum width=0.12\paperheight, minimum height=1.3cm, fill=gray!50, text=white, font=\fontsize{14}{14}\bfseries, xshift=-.55cm,yshift=-5cm,rotate=90] at (current page.north east){\makebox[0pt][c]{\hspace{0cm} Introduction}}; \end{tikzpicture} } \ofoot*{\pagemark} } \usepackage{lipsum} \begin{document} \thispagestyle{empty} \tableofcontents \chapter{Introduction} \pagestyle{MyIntro} \section{The First Section} \lipsum[1-3] \section{The Second Section} \lipsum[4-12] \end{document} ```
https://tex.stackexchange.com/users/39559
scrlayer-scrpage: Use tikz picture as part of the header in one-sided document
true
Currently you are adding the `tikzpicture` to the *selection* of the page style. To make it a part of the page style either add it using `\ohead` etc. or define a new layer and add this new layer to the page style. Additionally, I would not recommend to add any mark (but `\pagemark`) to the plain style, because the plain style it mentioned to be used for pages without running head. So I get, e.g.: ``` \documentclass[12pt, oneside,headsepline=true,chapterprefix=false,headings=optiontohead,toc=indentunnumbered, usegeometry]{scrreprt} \usepackage{lmodern} \usepackage[english]{babel} \usepackage{tikz} %%%---header/footer \usepackage[ automark, autooneside=false,% <- needed if you want to use \leftmark and \rightmark in a onesided document headsepline ]{scrlayer-scrpage} \newpairofpagestyles{MyIntro}{% \clearpairofpagestyles \ohead{% \Ifstr{\leftmark}{\rightbotmark}{}{\rightbotmark}% \begin{tikzpicture}[remember picture,overlay] \node[rectangle, minimum width=0.12\paperheight, minimum height=1.3cm, fill=gray!50, text=white, font=\fontsize{14}{14}\bfseries, xshift=-.55cm,yshift=-5cm,rotate=90] at (current page.north east){\makebox[0pt][c]{\hspace{0cm} Introduction }}; \end{tikzpicture} }% \ofoot*{\pagemark}% } \pagestyle{MyIntro} \usepackage{lipsum} \begin{document} \thispagestyle{empty} \tableofcontents \chapter{Introduction} \pagestyle{MyIntro} \section{The First Section} \lipsum[1-3] \section{The Second Section} \lipsum[4-12] \end{document} ``` BTW: Options `oneside` and `chapterprefix=false` are defaults with `scrreprt`. Option `usegeometry` make sense only if you would load package `geometry`. An alternative suggestion would be, to use the LaTeX mark mechanism also for the text of the chapter thumb, e.g., using the new commands documented in `ltmarks-doc.pdf` (available in every LaTeX distribution, that provides these commands): ``` \documentclass[12pt, oneside,headsepline=true,chapterprefix=false,headings=optiontohead,toc=indentunnumbered, usegeometry]{scrreprt} \usepackage{lmodern} \usepackage[english]{babel} \usepackage{tikz} %%%---header/footer \usepackage[ automark, autooneside=false,% <- needed if you want to use \leftmark and \rightmark in a onesided document headsepline ]{scrlayer-scrpage} \NewMarkClass{chaptername} \newpairofpagestyles{MyIntro}{% \clearpairofpagestyles \ohead{% \Ifstr{\leftmark}{\rightbotmark}{}{\rightbotmark}% \begin{tikzpicture}[remember picture,overlay] \node[rectangle, minimum width=0.12\paperheight, minimum height=1.3cm, fill=gray!50, text=white, font=\fontsize{14}{14}\bfseries, xshift=-.55cm,yshift=-5cm,rotate=90] at (current page.north east){\FirstMark{chaptername}}; \end{tikzpicture} }% \ofoot*{\pagemark}% } \usepackage{xpatch} \xapptocmd{\chaptermark}{\InsertMark{chaptername}{#1}}{}{} \pagestyle{MyIntro} \usepackage{lipsum} \begin{document} \thispagestyle{empty} \tableofcontents \chapter{Introduction} \pagestyle{MyIntro} \section{The First Section} \lipsum[1-3] \section{The Second Section} \lipsum[4-12] \end{document} ``` BTW: Currently is makes no sense to define a new pair of page styles instead of using the predefined pair `scrheadings` and `plain.scrheadings`. However, maybe in your real document, there is a sense. So I've not changed this.
3
https://tex.stackexchange.com/users/277964
682744
316,783
https://tex.stackexchange.com/questions/131917
8
Looking for properly formatted BibTeX citations for articles or books can be tedious. I used to use the functionality from Google Scholar, but found that for many cases the BibTeX files are poorly formatted, are missing information, or even contain wrong information. For mathematics papers, <http://www.ams.org/mathscinet/> appears to be a reasonable alternative. But it is manually maintained and unfortunately a paid service (many universities have access). Are there other similar databases, possibly for other fields of science?
https://tex.stackexchange.com/users/13262
Well-maintained BibTeX Databases
false
As of now, none exists. E.g., if you search for "model checking" in <http://www.bibtexsearch.com/>, you would notice BibTeX entries for publications that lack certain information, such as the addresses of publishers. Prof. Jason Mars (<https://midas.umich.edu/faculty-member/jason-mars/>) had a script (a Python script, or a similar programming language) that could grab information from the ACM Digital Library (<https://dl.acm.org/>). Unfortunately, I noticed that the ACM Digital Library can contain incorrect information for names (diacritics problem), titles (mathematical expression typesetting problem), publishers (diacritics problem), and addresses (diacritics problem) that have diacritics, diacritical marks, accents, or mathematical notations. Likewise, other digital/online libraries from other publishers have the same problem. This is true, regardless of whether they provide access to the suggested BibTeX entry for each publication in the digital/online library. I believe that cultural/ethnic bias also plays a role in complicating the ability of these digital libraries to track authors over time to determine who claims to be the (co-)author of a publication, due to people can use different versions of their names. E.g., using the initial (or first letter) of their first name, or initials for the first and middle names, or list all their middle names for a subset of their publications but not others. For people who come from populations with many people have the same first name and last name, but different middle names (if any, at all), this becomes complicated when people are not consistent in how they name themselves. People do change their names, not necessarily when they get married or change their gender identity, but also for other reasons. For people who live in English-speaking countries that have had to work with people who use computer technology, or typewriters back in the day, they may have used versions of their names without diacritics, but now do. E.g., does "J. Smith" for a publication refers to John Smith, Jason Smith, or another Smith. What happens when people with the same tuple/set of first name and last name work in a research topic? Fancy natural language processing, computer vision (for PDF only publications that lack text-only versions of the publications), and other artificial intelligence technologies, can help us with the aforementioned problems, including validating information in a given BibTeX entry with information that can be obtained from a valid and decent (quality of the images, PDF document, or physical copy of the publication/book) copy of the publication. While we can all share our BibTeX databases, or set of BibTeX entries, do you trust that other people have done due diligence in validating information that they included in their BibTeX databases? After all, I just indicated the problems of publishers having problems validating/checking the information of BibTeX entries for their publications, including those associated with professional societies in computer science and computer engineering, or related field (such as electrical and computer engineering), such as ACM and IEEE. However, start now, and over time you can accumulate tens of thousands of BibTeX entries in your BibTeX database. I have a BibTeX database with more than 20,000 BibTeX entries.
0
https://tex.stackexchange.com/users/201705
682745
316,784
https://tex.stackexchange.com/questions/682751
0
I am writing something in the MLA style and I need to use quotations. My professor requires the indentation of the quotations to be 35 pt which I can do. But I want to make my paragraph indentations to be smaller than 35 pt. How may I do that?
https://tex.stackexchange.com/users/294014
Different indentation sizes
false
I don't know if I understood your question correctly, but here is an attempt to answer. You can change the indentation of paragraphs using the command `\setlength{\parindent}{Xpt}` where X is the length of the indentation you want in points. For example: `\setlength{\parindent}{20pt}`. If you want to change the vertical space between paragraphs, you can use the command `\setlength{\parskip}{Xpt}` where X is the length of the space you want in points. For example: `\setlength{\parskip}{10pt}`.
0
https://tex.stackexchange.com/users/183803
682753
316,787
https://tex.stackexchange.com/questions/682746
0
How can I add several different comments ? ``` \begin{comment} something \end{comment} \begin{comment2} something2 \end{comment2} ```
https://tex.stackexchange.com/users/293843
How to add different comments \begin{comment} , \begin{comment2},
true
You can define your own comment environments in using the `\newenvironment` command. Have a look: ``` \\newenvironment{comment2} {\\par\\color{blue}\\textbf{Comment:} \\itshape} {\\par} \\begin{comment2} something2 \\end{comment2} ``` If you provide us with a minimal working example, we can try to focus the answer on what you are looking for.
1
https://tex.stackexchange.com/users/183803
682755
316,788
https://tex.stackexchange.com/questions/682754
1
When, automatically, documentation some code the LaTeX output gives me the,logical, warning: ``` Package: fixltx2e 2016/12/29 v2.1a fixes to LaTeX (obsolete) Applying: [2015/01/01] Old fixltx2e package on input line 46. Package fixltx2e Warning: fixltx2e is not required with releases after 2015 (fixltx2e) All fixes are now in the LaTeX kernel. (fixltx2e) See the latexrelease package for details. Already applied: [0000/00/00] Old fixltx2e package on input line 53. ``` So in my own case I could just leave out the line: ``` \usepackage{fixltx2e} ``` but this would give some problems for people that (unfortunately) still use an old version of LaTeX. I found in <https://tex.stackexchange.com/a/569709/44119>: > > Since version 2020-10-01 the LaTeX kernel provides the command `\IfFormatAtLeastTF{<date>}{<true code>}{<false code>}` > > > but this gives of course the same problems as this only exists after the 2020 release. I also found <https://tex.stackexchange.com/a/26229/44119>: ``` \newcommand*\@iflatexlater{\@ifl@t@r\fmtversion} \@iflatexlater{2001/09/01}{\TRUE}{\FALSE} ``` and applying this as: ``` \newcommand*\@iflatexlater{\@ifl@t@r\fmtversion} \@iflatexlater{2016/01/01}{}{\usepackage{fixltx2e}} ``` gives me the error: ``` ! LaTeX Error: Command \@ already defined. 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.15 \newcommand*\@i flatexlater{\@ifl@t@r\fmtversion} ? ! Emergency stop. ... l.15 \newcommand*\@i flatexlater{\@ifl@t@r\fmtversion} ! ==> Fatal error occurred, no output PDF file produced! ``` Normally on this site it is usual to create a MWE though I hope the information provided here is already sufficient to give a pointer to a solution.
https://tex.stackexchange.com/users/44119
Check release date of LaTeX distribution
true
Your last version doesn't work because you need `\makeatletter` to use `@` in command names. The recommended way is to define: ``` \makeatletter \providecommand\IfFormatAtLeastTF{\@ifl@t@r\fmtversion} \makeatother ``` then use `\IfFormatAtLeastTF` throughout. `\providecommand` will only define the command if it doesn't exist yet, which is exactly what you want. --- If you are writing a package or class, I wouldn't advise you to support LaTeX versions older than 3 or 4 years. TeXLive 2015 is *old*, and there is really no reason to use it nowadays: back then, support for older versions was important because (mainly) of Overleaf and arXiv, but both now use recent enough distributions.
3
https://tex.stackexchange.com/users/134574
682759
316,791
https://tex.stackexchange.com/questions/20710
3
When using ctable and sideways, the tables are rotated automatically. ``` \documentclass[10pt,b5paper,twoside]{report} \usepackage[lmargin=25mm,rmargin=25mm,tmargin=27mm,bmargin=30mm]{geometry} \usepackage{hyperref} \usepackage[pagestyles]{titlesec} \usepackage{ctable} ``` With some of the tables I would like to adjust the angle myself (so it rotates 270 instead of 90 degrees). Any way I can do this? ``` \ctable[caption= Descriptive statistics, label=desc_stat_fut, doinside=\small \renewcommand\arraystretch{1.5}, center, sideways]{XXXXXXXXXXXXXX}{\tnote[]{The sample totals 1728 observations. THIS NOTE IS VERY LONG!}}{ \toprule \multicolumn{14}{c}{Descriptive statistics} \\ & Mean. & Med & Min & Max & StDev & Skew & Kurt & $\rho_{1}$ & $\rho_{5}$ & $\rho_{12}$ & JB & Q(10) & PP \\ \midrule $P_{t}$ & 58.23 & 56.48 & 25.19 & 145.29 & 25.73 & 1.07 & 0.91 & 1.00 & 0.99 & 0.97 & 397.72 & 17285.06 & -1.62 \\ $\log(P_{t})$ & 3.97 & 4.03 & 3.23 & 4.98 & 0.42 & 0.15 & -0.70 & 1.00 & 0.98 & 0.97 & 43.09 & 17217.45 & -1.83 \\ $P_{t}-P_{t-1}$ & 0.02 & 0.02 & -10.52 & 16.37 & 1.55 & 0.42 & 11.83 & -0.03 & -0.02 & 0.07 & 10368.48 & 16.37 & -43.10 \\ $\log\left(\frac{P_{t}}{P_{t-1}}\right)$ & 0.00 & 0.00 & -0.13 & 0.15 & 0.03 & -0.07 & 3.42 & -0.04 & -0.04 & 0.09 & 862.62 & 32.05 & -43.68 \\ $\left(\log(\frac{P_{t}}{P_{t-1}})\right)^{2}$ & 0.00 & 0.00 & 0.00 & 0.02 & 0.00 & 6.56 & 59.28 & 0.17 & 0.20 & 0.21 & 271607.31 & 1041.23 & -40.44 \\ \bottomrule } ```
https://tex.stackexchange.com/users/5957
Rotate ctable, manipulate sideways
false
*As this is still the top search result regarding this problem, here the solution to it using only the ctable package.* As stated at the *sideways* option in the [ctable manual](https://texdoc.org/serve/ctable/0) use `\setupctable{captionsleft}` or `\setupctable{captionsright}` before the table and reset it to back to the default with `\setupctable{captionsinside}` afterwards. ``` \documentclass[10pt,b5paper,twoside]{report} \usepackage[lmargin=25mm,rmargin=25mm,tmargin=27mm,bmargin=30mm]{geometry} \usepackage{hyperref} \usepackage[pagestyles]{titlesec} \usepackage{ctable} \begin{document} \setupctable{captionsright}% turns the caption of all following sidewaystables to the right \ctable[ caption=Descriptive statistics, label=desc_stat_fut, doinside=\small \renewcommand\arraystretch{1.5}, center, sideways ]{ XXXXXXXXXXXXXX }{ \tnote[]{The sample totals 1728 observations. THIS NOTE IS VERY LONG!} }{ \toprule \multicolumn{14}{c}{Descriptive statistics} \\ & Mean. & Med & Min & Max & StDev & Skew & Kurt & $\rho_{1}$ & $\rho_{5}$ & $\rho_{12}$ & JB & Q(10) & PP \\ \midrule $P_{t}$ & 58.23 & 56.48 & 25.19 & 145.29 & 25.73 & 1.07 & 0.91 & 1.00 & 0.99 & 0.97 & 397.72 & 17285.06 & -1.62 \\ $\log(P_{t})$ & 3.97 & 4.03 & 3.23 & 4.98 & 0.42 & 0.15 & -0.70 & 1.00 & 0.98 & 0.97 & 43.09 & 17217.45 & -1.83 \\ $P_{t}-P_{t-1}$ & 0.02 & 0.02 & -10.52 & 16.37 & 1.55 & 0.42 & 11.83 & -0.03 & -0.02 & 0.07 & 10368.48 & 16.37 & -43.10 \\ $\log\left(\frac{P_{t}}{P_{t-1}}\right)$ & 0.00 & 0.00 & -0.13 & 0.15 & 0.03 & -0.07 & 3.42 & -0.04 & -0.04 & 0.09 & 862.62 & 32.05 & -43.68 \\ $\left(\log(\frac{P_{t}}{P_{t-1}})\right)^{2}$ & 0.00 & 0.00 & 0.00 & 0.02 & 0.00 & 6.56 & 59.28 & 0.17 & 0.20 & 0.21 & 271607.31 & 1041.23 & -40.44 \\ \bottomrule } \setupctable{captionsinside}%restores the default sideways behavior \end{document} ```
0
https://tex.stackexchange.com/users/289838
682760
316,792
https://tex.stackexchange.com/questions/682750
2
How is it possible to use combined Unicode characters (such as x̃, x̅, X̅, f̅, f᷉, f̂) in a definition of `\DeclareUnicodeCharacter`? So something like `\newunicodechar{x̃}{\tilde{x}}` (using the package `newunicodechar`) or `\DeclareUnicodeCharacter{00780303}{\tilde x}` would be nice.
https://tex.stackexchange.com/users/236300
Use \DeclareUnicodeCharacter with combined Unicode characters
false
It is hard, bordering impossible, to support unicode combining characters with pdftex. This is not much of a problem in practice as (if using luatex is not an option) you can usually pre-process to handle the combinations. For example if instead of using pdflatex directly you use `myscript` which is ``` sed -e 's/\(.\)\xcc\x83/\\tilde{\1}/g' \ -e 's/\(.\)\xcc\x85/\\bar{\1}/g' \ -e 's/\(.\)\xe1\xb7\x89/\\acute{\\grave{\\acute{\1}}}/g' \ -e 's/\(.\)\xcc\x82/\\hat{\1}/g' \ $1 > $1- pdflatex $1- ``` then with `file.tex` ``` \documentclass{article} \begin{document} $x̃, x̅, X̅, f̅, f᷉, f̂$ \end{document} ``` the command `myscript file.tex` produces The script is written using bash syntax but a .bat file for windows could be used with a suitable windows sed (or perl or python)
2
https://tex.stackexchange.com/users/1090
682770
316,794
https://tex.stackexchange.com/questions/682761
3
Is there a way to show/print the border of a paragraph to see what spacing it has before and after?
https://tex.stackexchange.com/users/255699
Show limits/borders of paragraph
false
You could make use of the [`lua-visual-debug` package](https://www.ctan.org/pkg/lua-visual-debug) maybe (which requires typesetting with LuaTeX obviously): ``` \documentclass{article} \usepackage[latin]{babel} \usepackage[skip=12pt, indent=30pt, parfill=50pt]{parskip} \usepackage{lipsum} \usepackage{lua-visual-debug} \begin{document} \lipsum[1-2] \bigskip \lipsum[2] \end{document} ``` The tiny ticks to the left show where the box of the upper paragraph box ends and the lower starts (highlighted in red; sorry for the overly large pictures, but the ticks would not be visible otherwise). This shows where the boxes of the first two paragraphs "meet": This shows the `\bigskip` between the second and the third paragraph:
7
https://tex.stackexchange.com/users/47927
682774
316,795
https://tex.stackexchange.com/questions/682604
1
I am trying to setup a Knitr workflow in EMACS ESS. I can get a pdf to compile using `pdflatex` and `knitr-ess`, but the bibliography is not generated. I am using `zotxt` to insert citations from zotero, but I am not sure if that is relevant. In my search to find a solution I found this <https://tex.stackexchange.com/a/73779/287729> saying I should do the following: 1. Run LaTeX 2. Run BibTex 3. Run LaTeX 4. Run LaTeX But when I try to compile the pdf with `LaTeX` (via Command -> LaTeX in EMACS) I get an error: ``` ! I can't find file `myfile.rnw.tex'. <*> myfile.Rnw.tex (Press Enter to retry, or Control-Z to exit) Please type another input file name ! Emergency stop. <*> myfile.Rnw.tex ``` And the pdf is not compiled. I tried the following: 1. Run pdflatex 2. Run Bibtex but when I try to run pdflatex again it fails because of the error ``` Not re-weaving as input file ’myfile.rnw’ hasn’t changed Not re-exporting as input file ’myfile-woven.tex’ hasn’t changed ``` Here is an MRE: ``` \documentclass{article} \usepackage[backend=bibtex]{biblatex} \bibliography{sample} \title{ETemplate} \author{Your name goes here} \begin{document} \maketitle \section*{Abstract} This is my abstract. It is not abstract. @hilbornQuantitativeFisheriesStock1992 \printbibliography \end{document} ``` I am open to other approaches as just want to get this functional. Interestingly, I can get the following to compile with citations in Rstudio ``` \documentclass{article} \usepackage[backend=bibtex]{biblatex} \bibliography{sample.bib} \begin{document} <<setup, include=FALSE, cache=FALSE, echo=FALSE>>= Sys.setenv(TEXINPUTS=getwd(), BIBINPUTS=getwd(), BSTINPUTS=getwd()) @ this doc \parencite{nefsc62ndNortheastRegional2017} \parencite{hilbornMeasuringFisheriesManagement2020} \printbibliography \end{document} ``` So clearly this is an EMACS issue.
https://tex.stackexchange.com/users/287729
can't compile pdf using LaTex in polymode from .rnw file
false
For anyone following along at home...I figured it out. Here are the steps 1. use pdflatex on the document, 2. open the myfile.tex in emacs file that was created by pdflatex (it also created a pdf). 3. use the emacs menu bar command -> LaTeX 4. use the emacs menu bar command -> BibTeX 5. use the emacs menu bar command -> LaTeX 6. use the emacs menu bar command -> LaTeX (again) and the bibliography is generated.
0
https://tex.stackexchange.com/users/287729
682775
316,796
https://tex.stackexchange.com/questions/682736
3
I want to set 1.15 line spacing (as there is option in microsoft word) for the entire content in book class. I referred to some question on this site. I found the following. `\linespread{1.667}` sets double space (2.0 line spacing as in microsoft word). `\linespread{1.25}` sets one and half space (1.5 line spacing as in microsoft word). How to set line spacing 1.15 as required in microsoft word? Would the command `\linespread{0.958}` set 1.15 line spacing as in microsoft word? I also have another query. If in a class file it is set as `\AtBeginDocument{\linespread{0.958}}` will it affect the entire content in book? Should I use it before or after `\LoadClass{book}`?
https://tex.stackexchange.com/users/75476
How to achieve the equivalent of the MS Word "1.15" Line Spacing option with the LaTeX 'book' document class?
true
Don't modify the low-level parameter `\linespread` directly, as doing so will also affect how material in footnotes and tables is spaced. (Of course, if your document has neither footnotes nor tables, you don't have to worry about this point, do you?) Instead, I suggest you load the [setspace](https://ctan.org/tex-archive/macros/latex/contrib/setspace) package and issue various `\setstretch{xx}` directives, where "xx" is a stretch or shrinkage factor; a value of 1.0 is the default. I've performed a number of side by side tests with MS Word and LaTeX to determine which arguments of `\setstretch` correspond to the 1.15, 1.5, and 2.0 stretch settings of MS Word. All tests use "A4" as the default paper size. The font is Times Roman, the font size is 12pt in LaTeX and 12bp ("big points", aka "Adobe points") in Word. The LaTeX document class is `book`, and the margin width is 2.5cm on all four sides in both test documents. The LaTeX test document is as follows: ``` \documentclass[12pt]{book} \usepackage[a4paper,margin=2.5cm,showframe]{geometry} \usepackage{newtxtext,newtxmath} % Times Roman \usepackage{setspace} \input blob \begin{document} \raggedright \setstretch{1.0} % no stretching or shrinking \blob \cleardoublepage \setstretch{1.2} % corresponds to Word's "1.15" setting \blob \cleardoublepage \setstretch{1.5} % corresponds to Word's "1.5" setting \blob \cleardoublepage \setstretch{2.0} % corresponds to Word's "Double" setting \blob \end{document} ``` The file `blob.tex` has the following contents: ``` \newcommand{\blob}{\noindent aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk1 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk2 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk3 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk4 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk5 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk6 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk7 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk8 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk9 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk0 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk1 aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk aöfjasdlökfjasöl dsjfasölkjfa sdajfasölk asdljfaölk2 } ``` If you have both a LaTeX and an MS Word installation at hand, you may verify for yourself that the MS Word line spacing options "Single", "1.5 Lines", "Double", and "Multiple - 1.15" correspond to `\setstretch{1.0}`, `\setstretch{1.5}`, `\setstretch{2.0}`, and `\setstretch{1.2}`. Yes, that's `1.2`, not `1.15`, in the argument of the final `\setstretch` directive. In case you're curious, the 1.0, 1.2, 1.5, and 2.0 stretch factors serve to place 48, 40, 32, and 24 lines of text per page in the test document defined above. (The stretch factor 1.15 would place 34, not 32, lines on the first page.) Interestingly, the stretch factors of 1.5 and 2.0 do *not* correspond to the `onehalfspacing` and `doublespacing` options of the `setspace` package; the latter two options actually correspond to stretch factors of 1.241 and 1.655 if the main document font size is 12pt. Somewhat reassuringly, though, the `singlespacing` package option does correspond to a stretch factor of 1.0. Finally, a couple of screenshots, for (a) MS Word with line spacing option 1.15 and (b) LaTeX with `\setstretch{1.2}`. Observe that both documents have 32 lines of text on the left and 8 lines of text on the right.
5
https://tex.stackexchange.com/users/5001
682778
316,798
https://tex.stackexchange.com/questions/539357
4
As an academic writer using (La)TeX to write documents, there is always a question we had for iPad... Can the newest generation [iPad-pro 2020](https://www.apple.com/ipad-pro/) run LaTex such as TexShop or other (La)TeX software that you use on MacBook (Pro)? and then produce a PDFTeX? 1. If yes, please provide how to do it. 2. If not, what are the other resolutions to use/compile (La)TeX? What comes into my mind: * [Overleaf](https://www.overleaf.com/): run LaTex online. (This answer does not exist in 2010.) * other lists from <https://en.wikipedia.org/wiki/Comparison_of_TeX_editors> I suppose the [iPad-pro 2020](https://www.apple.com/ipad-pro/) may make new differences for us to run (La)TeX on iPad? (p.s. There was a prior question in 2010 but now we are in 2020, the answer was 10 years ago: [Is there a (La)TeX distribution running on iPad?](https://tex.stackexchange.com/q/8021/41144))
https://tex.stackexchange.com/users/41144
Compile and Edit (La)TeX on iPad-pro 2020
false
I'm using the free app "a-Shell" for this purpose (and many others). <https://apps.apple.com/de/app/a-shell/id1473805438> a-Shell is a local terminal emulator, including TeX (texlive 2022, with Tikz and LuaTeX) for text processing. For editing the tex-files you can use vim (also included in a-Shell) or any other editor like Koder (<https://apps.apple.com/de/app/koder-code-editor/id1447489375>) In a-Shell just type "pdflatex file.tex" and after that "view file.pdf". Or view the created pdf in "Documents" with live-updates after compiling (<https://apps.apple.com/de/app/documents-file-manager-app/id364901807>). A good point to start with a-Shell is: <https://github.com/holzschu/a-shell>
0
https://tex.stackexchange.com/users/232548
682779
316,799
https://tex.stackexchange.com/questions/201382
11
I'm not sure if it is a good idea to maintain a single large bibtex database or if I should split it into multiple smaller ones. I have compiled a very large India-specific database (over 100,000 records) from various sources. So, what are the most important positives and negatives for one approach or the other one? Is there any difference in how bibtex and biblatex treat big data files? Are there any threats to be considered with either approach?
https://tex.stackexchange.com/users/134611
Large bibtex/biblatex database
false
As of the late 2010s, multiple BibTeX-supporting reference management software, which I have used and can accept BibTeX databases as input, would fail to load BibTeX databases with more than 5000 BibTeX entries. While LaTeX can support multiple BibTeX databases/files in its `\bibliography{}` command, I want to simplify the process/heuristic for creating the BibTeX key that I assign for/to each BibTeX entry in my BibTeX database(s). E.g., to create my preferred BibTeX key, I use the author's last name, or the first co-author's last name, appended by the year. Smith2000 is an example. For publications that yield multiple BibTeX keys with the same preferred BibTeX key, I would append a letter (assigned in alphabetical order) to the preferred BibTeX key. This is based on the author-date method for referencing publications, or Harvard referencing style or Harvard citation style. It is a type of parenthetical referencing. Else, it would cause confusion. E.g., if multiple BibTeX databases for a given LaTeX document use the same BibTeX key for different references, this would create problems when interpreting/processing the BibTeX databases/files. My guess is that the first occurring instance of the BibTeX key would have its entry used, while the rest are ignored. Also, if I am unable to track the error message to the subset of BibTeX databases/files with the problem, I would have problems addressing/fixing the problem. Such problems can be avoided by using a script to create a set of all the BibTeX keys that are found in all the BibTeX databases. If any repeated instances of BibTeX keys are found, it can report an error/warning, so that we can be notified of the problem and fix it by changing the repeating/"offending" BibTeX keys to new BibTeX keys. Reference for using multiple BibTeX databases/files: <https://en.wikibooks.org/wiki/LaTeX/Bibliography_Management#Getting_current_LaTeX_document_to_use_your_.bib_file> I do not have problems with typesetting LaTeX documents with 20,000 references, except for using the `\cite{}` LaTeX command to cite more than 20,000 references in a LaTeX document. I created a workaround for the problem by partitioning the list of BibTeX keys into multiple cite commands. I used a Python script to grab a list of all the BibTeX keys in my BibTeX database/file, and print the BibTeX keys in sets of 10 per `\cite{}` LaTeX command. You can validate this by using the `\nocite{*}` LaTeX command to list all the BibTeX entries in the bibliography of the LaTeX document, without having to specify all of the BibTeX keys in the BibTeX database(s). <https://en.wikibooks.org/wiki/LaTeX/Bibliography_Management#No_cite> Using a single BibTeX database also makes it easier for me to share my BibTeX database with others. I do not need to keep track of where all the BibTeX databases/files are. I use a single BibTeX database for all LaTeX documents. An advantage of sufficiently small BibTeX databases, of less than 1,000 BibTeX entries, multiple open-source, and monetarily free, reference management software would accept these BibTeX databases. Consequently, their BibTeX parsers would check for compliance with the BibTeX language. Else, you have to use the aforementioned `\nocite{*}` LaTeX command to typeset a simple LaTeX document to check if your BibTeX database(s) comply with the BibTeX language specification. You can also build your own parser, or script to check for common problems that you may make when creating and updating your BibTeX database(s).
0
https://tex.stackexchange.com/users/201705
682782
316,800
https://tex.stackexchange.com/questions/682783
3
I have an `inlinetodo` macro/command that is defined depending on a toggle: ``` \nottoggle{disableAnnotations}{ \NewDocumentCommand \inlinetodo {m}{\pdfmarkupcomment[color=yellow]{[TODO: #1]}{}} }{ \NewDocumentCommand \inlinetodo {m}{} } ``` As you see, the command does not make anything if `disableAnnotations` is enabled. But that is not entirely true. If I have ``` This is the first line. \inlinetodo{Explain the issue here!} Last line here. ``` Then there will be a larger space between "…first line." and "Last line…". How can I avoid the space, so that the result will be equal to ``` This is the first line. Last line here. ``` if annotations are disabled?
https://tex.stackexchange.com/users/1280
Create macro with no effect, even if used exlusively in a line
true
It depends what you want exactly: ``` \documentclass{article} \begin{document} This is the first line. Last line here. \medskip \NewDocumentCommand \inlinetodo {m}{} This is the first line. \inlinetodo{Explain the issue here!} Last line here. This is the first line. \inlinetodo{Explain the issue here!}Last line here. This is the first line.\inlinetodo{Explain the issue here!} Last line here. \medskip \RenewDocumentCommand \inlinetodo {m}{\ignorespaces} This is the first line. \inlinetodo{Explain the issue here!} Last line here. This is the first line. \inlinetodo{Explain the issue here!}Last line here. This is the first line.\inlinetodo{Explain the issue here!} Last line here. \medskip \RenewDocumentCommand \inlinetodo {m}{\unskip} This is the first line. \inlinetodo{Explain the issue here!} Last line here. This is the first line. \inlinetodo{Explain the issue here!}Last line here. This is the first line.\inlinetodo{Explain the issue here!} Last line here. \medskip \makeatletter \RenewDocumentCommand \inlinetodo {m}{\@bsphack\@esphack} \makeatother This is the first line. \inlinetodo{Explain the issue here!} Last line here. This is the first line. \inlinetodo{Explain the issue here!}Last line here. This is the first line.\inlinetodo{Explain the issue here!} Last line here. \end{document} ```
8
https://tex.stackexchange.com/users/2388
682786
316,803
https://tex.stackexchange.com/questions/682792
1
I would like to create a portfolio with all my best work in it, and I would like it to look something similar to this the image in this webpage: <https://loopcreativo.com/portfolio-crea-uno-saca-maximo-rendimiento-trabajo/> Does anyone have any idea where can I find a template suitable to my needs? Thanks in advance.
https://tex.stackexchange.com/users/294972
LaTeX - Project portfolio
false
Look for package `flowfram`, which was created for brochures and similar. See my recent examples: * about [grid layout with LaTeX](https://tex.stackexchange.com/a/682526/245790) * about [a layout-driven approach for designing a CV](https://tex.stackexchange.com/a/682657/245790) Or use a layout-driven program like FrameMaker, Scribus (open source) or MS Publisher (may be on your computer already).
2
https://tex.stackexchange.com/users/245790
682796
316,808
https://tex.stackexchange.com/questions/682736
3
I want to set 1.15 line spacing (as there is option in microsoft word) for the entire content in book class. I referred to some question on this site. I found the following. `\linespread{1.667}` sets double space (2.0 line spacing as in microsoft word). `\linespread{1.25}` sets one and half space (1.5 line spacing as in microsoft word). How to set line spacing 1.15 as required in microsoft word? Would the command `\linespread{0.958}` set 1.15 line spacing as in microsoft word? I also have another query. If in a class file it is set as `\AtBeginDocument{\linespread{0.958}}` will it affect the entire content in book? Should I use it before or after `\LoadClass{book}`?
https://tex.stackexchange.com/users/75476
How to achieve the equivalent of the MS Word "1.15" Line Spacing option with the LaTeX 'book' document class?
false
This is general information, rather than an answer to the question. But it is definitely worth knowing, for anyone who is writing a book (in any document class) and is familiar with a word processor. Most word processors assume that the glyph metrics (size and space of the character drawings) obey this limitation: The distance from lowest point on any glyph, to the highest point on any other glyph, does not exceed 1.2 times the font size. This includes modifiers such as diacriticals. For example, suppose that the lowest point is the bottom of lowercase "y", and the highest point is the top of uppercase "Aacute" or "Aring". This is typical for Western language fonts. If the font size is F (measured in pt or bp or anything else), then the distance from bottom to top should not exceed 1.2F. That allows the word processor (or TeX) to use a minimum line skip of 1.2F, confident that there will be no clash between low and high points of the characters. Most fonts are designed with this limitation in mind. A few are not. For English writers, or anyone not using such things as accented uppercase letters, it is possible to have line skip lower than 1.2F. Even with accented uppercase, there is a low chance that such a letter will happen to be directly underneath a character with greatest descender, so it is sometimes possible to use less than 1.2F. But for languages with stacked diacritical marks, 1.2F is not enough. If not enough line skip is provided, then some lines will move apart. This may look unsightly. I am not certain whether to original question referred to line skip of 1.15F, or to 1.15x1.2F, or something else. Books intended for causal reading (fiction) often use more than the minimum line skip.
0
https://tex.stackexchange.com/users/287367
682806
316,815
https://tex.stackexchange.com/questions/681418
44
I'm currently reading [Sparks of Artificial General Intelligence: Early experiments with GPT-4](https://arxiv.org/pdf/2303.12712.pdf). This paper by Microsoft employees experiments with the capabilities of GPT-4, a successor of ChatGPT. One task is to draw a unicorn with tikz.ㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤ They claim: > > GPT-4 produces impressive outputs that are [...] at least comparable (if not superior) to what a human would do. > > > Who wants to prove them wrong? edit: Please don't include PNG / JPG / other pixel image formats. MS-SPO is the only one allowed to do that (as a grandfathering-rule) - kudos for finding the loophole in this question and for thinking outside of the box edit: We now have 200 [fun](/questions/tagged/fun "show questions tagged 'fun'") questions!
https://tex.stackexchange.com/users/5645
Draw a unicorn in TikZ
false
Draw it using the totally experimental (but also already totally capable) `l3draw` package (okay, I have to admit that it is not Ti*k*Z then): ``` \documentclass[border=10pt]{standalone} \usepackage{l3draw} \begin{document} \ExplSyntaxOn \draw_begin: \draw_linewidth:n { 2pt } \color_select:n { black!50 } \draw_path_moveto:n { \draw_point_polar:nnn { 1.75cm } { 2cm } { 270 } } \draw_path_arc:nnnn { 270 } { 140 } { 1.75cm } { 2cm } \draw_path_arc:nnnn { 240 } { 50 } { 0.25cm } { 0.25cm } \draw_path_curveto:nn { -1.25cm , 2cm } { -1.75cm , 2cm } \draw_path_moveto:n { \draw_point_polar:nnn { 1.75cm } { 2cm } { 115 } } \draw_path_curveto:nn { -1.5cm , 2.5cm } { -2cm , 2.5cm } \draw_path_curveto:nn { -2.5cm , 2cm } { -1.75cm , 1.5cm } \draw_path_moveto:n { \draw_point_polar:nnn { 1.75cm } { 2cm } { 270 } } \draw_path_arc:nnnn { 270 } { 400 } { 1.75cm } { 2cm } \draw_path_arc:nnnn { 300 } { 480 } { 0.25cm } { 0.25cm } \draw_path_curveto:nn { 1.25cm , 2cm } { 1.75cm , 2cm } \draw_path_moveto:n { \draw_point_polar:nnn { 1.75cm } { 2cm } { 65 } } \draw_path_curveto:nn { 1.5cm , 2.5cm } { 2cm , 2.5cm } \draw_path_curveto:nn { 2.5cm , 2cm } { 1.75cm , 1.5cm } \draw_path_use_clear:n { stroke } \color_select:n { black } \draw_path_circle:nn { -0.75cm , 0.45cm } { 2.5mm } \draw_path_circle:nn { 0.75cm , 0.45cm } { 2.5mm } \draw_path_use_clear:n { fill } \color_select:n { white } \draw_path_circle:nn { -0.7cm , 0.5cm } { 0.9mm } \draw_path_circle:nn { 0.8cm , 0.5cm } { 0.9mm } \draw_path_use_clear:n { fill } \color_select:n { black!50 } \draw_path_ellipse:nnn { -0.5cm , -1.25cm } { 1mm , -0.5mm } { 0mm , 1.5mm } \draw_path_ellipse:nnn { 0.5cm , -1.25cm } { 1mm , 0.5mm } { 0mm , 1.5mm } \draw_path_use_clear:n { fill } \color_stroke:n { yellow!75!red } \color_fill:n { yellow!85!red } \draw_path_moveto:n { -0.25cm , 2cm, } \draw_path_lineto:n { 0cm , 3.75cm } \draw_path_lineto:n { 0.25cm , 2cm } \draw_path_use_clear:n { fill, stroke } \color_stroke:n { magenta!85!cyan } \color_fill:n { magenta } \draw_path_moveto:n { \draw_point_polar:nnn { 1.75cm } { 2cm } { 115 } } \draw_path_curveto:nnn { -0.75cm , 2.25cm } { -0.25cm , 2.25cm } { 1cm , 1.25cm } \draw_path_curveto:nnn { -0.75cm , 3.25cm } { -1cm , 2.5cm } { \draw_point_polar:nnn { 1.75cm } { 2cm } { 115 } } \draw_path_use_clear:n { fill, stroke } \draw_end: \ExplSyntaxOff \end{document} ```
10
https://tex.stackexchange.com/users/47927
682808
316,817
https://tex.stackexchange.com/questions/682814
1
Many writing systems / scripts, including Latin and Cyrillic, have one or more cursive forms, where letters are connected, with forms depend on the letters before and after them. While one can create somewhat-grotesque rough approximations of such writing (see [this question](https://tex.stackexchange.com/q/291313/5640) for example) by relying on a small number of fixed glyphs as the different forms of a character - this actually requires more careful modeling, involving continuous rather than discrete spaces of parameters of glyph-forms, the possibility of adjusting lengths and heights of connective glyph-curves for connection to the previous and next glyph etc. In some cursive systems, the vertical position also varies as one moves forward along a word, so that words or lines move in a diagonal rather than on a straight line (see [this example](https://en.wikipedia.org/wiki/Nastaliq#/media/File:Khatt-e_Nastaliq.jpg) of Nasta'liq Arabic script). Do any of the layout engines in the TeX world support cursive typesetting, even in a single writing system? Do any font representation systems support it? If not, are there plans or project to introduce such support?
https://tex.stackexchange.com/users/5640
Does any of the TeX engines support proper cursive typesetting?
false
It is hard to not mentioning the showcase of Omega with the Zapfino font. <https://tug.org/TUGboat/Articles/tb24-2/tb77adams.pdf> Note that, Omega is an abandoned project, luaTeX could be considered as the on going successor of Omega, but not all the features from Omega would be ported.
3
https://tex.stackexchange.com/users/246082
682815
316,820
https://tex.stackexchange.com/questions/682821
0
I have a piece of code where I'm iterating over a list of items, but I do this in several places and would like to avoid having to redefine that list every time. This is what I have working: ``` \foreach \f in {193, 87, 88, 85, 80, 81, 79, 89}{ \includegraphics{\f.png} } ``` I'd like instead be able to something like this: ``` \foreach \f in \allfs{ \includegraphics{\f.png} } ``` Is there a way to define `\allfs` such that I can iterate over it? I tried just doing a `\newcommand\allfs{{193, 87, 88, 85, 80, 81, 79, 89}}` but that doesn't work. It instead looks for the file `{193, 87, 88, 85, 80, 81, 79, 89}.png` Sorry if this is a duplicate question, I was having trouble figure out the right way to phrase things to search
https://tex.stackexchange.com/users/199528
Can you define a varaible that you then use as the list of elements to \foreach loop over?
false
Instead of `\foreach` I would rather use the `/.list` key, which avoids the need for a macro like `\f` as loop variable and avoids groups. In this context, it is particularly convenient because it can be paired with the `/.expanded` key. ``` \documentclass{article} \usepackage{pgffor} \usepackage{graphicx} \begin{document} \newcommand\allfs{{a,b,c,duck}} \pgfkeys{include graphics/.code={\includegraphics{example-image-#1.pdf}\par}}% \par is only added for this example \pgfkeys{include graphics/.list/.expanded=\allfs} \end{document} ```
0
https://tex.stackexchange.com/users/nan
682823
316,823
https://tex.stackexchange.com/questions/682824
3
The dingbat called "OrnamentDiamondSolid" is too big. I tried putting footnotesize on it, which helped a little. How can I make it yet smaller? ``` \documentclass[14pt]{beamer} \usepackage{bbding} \begin{document} \begin{itemize} \item[\footnotesize{\OrnamentDiamondSolid}] Text \end{itemize} \end{document} ```
https://tex.stackexchange.com/users/277990
Change size of dingbat
true
``` \documentclass[14pt]{beamer} \usepackage{bbding} \begin{document} \begin{frame} \begin{description} \item[\OrnamentDiamondSolid] Text \item[{\small\OrnamentDiamondSolid}] Text \item[{\footnotesize\OrnamentDiamondSolid}] Text \item[{\scriptsize\OrnamentDiamondSolid}] Text \item[{\tiny\OrnamentDiamondSolid}] Text \item[{\fontsize{5pt}{\baselineskip}\selectfont\OrnamentDiamondSolid}] Text \item[{\fontsize{4pt}{\baselineskip}\selectfont\OrnamentDiamondSolid}] Text \item[{\fontsize{3pt}{\baselineskip}\selectfont\OrnamentDiamondSolid}] Text \item[{\fontsize{2pt}{\baselineskip}\selectfont\OrnamentDiamondSolid}] Text \item[{\fontsize{1pt}{\baselineskip}\selectfont\OrnamentDiamondSolid}] Text \end{description} \end{frame} \end{document} ```
7
https://tex.stackexchange.com/users/238422
682828
316,824
https://tex.stackexchange.com/questions/682814
1
Many writing systems / scripts, including Latin and Cyrillic, have one or more cursive forms, where letters are connected, with forms depend on the letters before and after them. While one can create somewhat-grotesque rough approximations of such writing (see [this question](https://tex.stackexchange.com/q/291313/5640) for example) by relying on a small number of fixed glyphs as the different forms of a character - this actually requires more careful modeling, involving continuous rather than discrete spaces of parameters of glyph-forms, the possibility of adjusting lengths and heights of connective glyph-curves for connection to the previous and next glyph etc. In some cursive systems, the vertical position also varies as one moves forward along a word, so that words or lines move in a diagonal rather than on a straight line (see [this example](https://en.wikipedia.org/wiki/Nastaliq#/media/File:Khatt-e_Nastaliq.jpg) of Nasta'liq Arabic script). Do any of the layout engines in the TeX world support cursive typesetting, even in a single writing system? Do any font representation systems support it? If not, are there plans or project to introduce such support?
https://tex.stackexchange.com/users/5640
Does any of the TeX engines support proper cursive typesetting?
false
The issue can be solved by "generalized ligatures". They are provided by classical TeX. For example, I created the font [Slabikar](http://petr.olsak.net/ftp/olsak/slabikar/) in 1997. The generalized ligatures are saved to TFM by Metafont. The article about the font [linked here](http://petr.olsak.net/ftp/olsak/slabikar/slabi.pdf) describes all these principles and includes illustrations.
7
https://tex.stackexchange.com/users/51799
682840
316,828
https://tex.stackexchange.com/questions/386808
2
Has anyone ever come across the following error, and how would I solve it? Quick googling did not seem to help, and I guess that the issue may not be with \etalchar (I don't define it ever), but some conflicting packages. ``` LaTeX Error: Command \etalchar already defined. 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.1 \newcommand{\etalchar}[1]{$^{#1}$} ? ```
https://tex.stackexchange.com/users/3260
LaTeX Error: Command \etalchar already defined
false
As suggested [here](https://www.fogman.de/?p=165), changing `\newcommand` to `\providecommand` in your desired `.bst`-file worked for me: 1. Locate the `.bst`-file for the `\bibliographystyle` you want to use, e.g., `/usr/share/texlive/texmf-dist/bibtex/bst/bibtex/alpha.bst` on Linux or `C:\MiKTeX 2.9\bibtex\bst\bibtex\alpha.bst` on Windows 2. Edit the file and navigate to the `FUNCTION {begin.bib}` section 3. Change `\newcommand{\etalchar}[1]{$^{#1}$}` to `\providecommand{\etalchar}[1]{$^{#1}$}` 4. Run (`sudo`) `texhash` 5. Clean auxilary files in your LaTeX project (e.g., using Tools - Clean Auxillary Files) in TeXstudio 6. Recompile your document
0
https://tex.stackexchange.com/users/84434
682849
316,830
https://tex.stackexchange.com/questions/682843
0
``` \begin{equation*} f \in S\mbox{*} \iff Re({\frac{zf'(z)}{f(z)})>0 \end{equation*} ```
https://tex.stackexchange.com/users/294996
Can some please tell me how to put curly braces around the real part in an equation?
false
Something like this? ``` \documentclass[a4paper,12pt]{article} \usepackage{mathtools,amssymb} \begin{document} \begin{equation*} f \in S^* \iff \mathrm{Re}\left(\biggl\{\frac{zf'(z)}{f(z)}\biggr\}\right)>0 \end{equation*} \end{document} ```
2
https://tex.stackexchange.com/users/117876
682850
316,831
https://tex.stackexchange.com/questions/682858
2
I intent to point the arrow to $A = B$, but the arrow comes from outside of the slide. Why that? Here it is the code ``` \documentclass[10pt,xcolor={dvipsnames}]{beamer} \mode<article> % only for the article version { \usepackage{fullpage} \usepackage{hyperref} } \mode<presentation> { %\setbeamertemplate{background canvas}[vertical shading][bottom=red!10,top=blue!10] \setbeamercovered{transparent} \usefonttheme{serif} \usecolortheme{crane} } \usepackage{pgf,pgfarrows,pgfnodes,pgfautomata,pgfheaps,pgfshade} \usepackage[latin1]{inputenc} \usepackage{colortbl} \usepackage{amstext,amssymb,amsmath,amsfonts,amsthm,amsbsy} \usepackage{tikz} \setbeamercovered{dynamic} \setbeamertemplate{items}[circle] \begin{document} \begin{frame} My equation: \begin{gather*} A = B \tikz[remember picture, overlay, baseline=-.5ex] \node (n1) {}; \qquad \tikz[baseline]{ \node[fill=blue!20,opacity=.6,anchor=base] (t1) {$\substack{\text{{\tiny{\color{blue}This is}}} \\ \text{{\tiny{\color{blue}my equation}}}}$};} \begin{tikzpicture}[overlay] \path[->,blue,opacity=.6]<1-> (n1) edge [] (t1); \end{tikzpicture} \end{gather*} \end{frame} \end{document} ```
https://tex.stackexchange.com/users/293909
Using Tikz in Beamer with arrow pointing improperly
false
If you want to use nodes across different tikz pictures, you need the `remember picture` option. That being said: * you could simplify the `t1` node a lot. Using math mode to stack the text above each other seems very cumbersome. * you should really clean up your preamble. Many of the packages are outdated and the .log file will tell you this after each compilation. Also don't need to load all the ams\* package, as beamer does this automatically. * not sure if this is your actual image, or just a shorted example, but I think it would be much easier to draw all three components in a single picture, then tikz can properly position the elements for you. * you might also want to have a look at the tikzmarks library ``` \documentclass[10pt,xcolor={dvipsnames,table}]{beamer} \mode<article> % only for the article version { \usepackage{fullpage} \usepackage{hyperref} } \mode<presentation> { %\setbeamertemplate{background canvas}[vertical shading][bottom=red!10,top=blue!10] \setbeamercovered{transparent} \usefonttheme{serif} \usecolortheme{crane} } %\usepackage{pgf,pgfarrows,pgfnodes,pgfautomata,pgfheaps,pgfshade} %\usepackage[latin1]{inputenc} %\usepackage{colortbl} %\usepackage{amstext,amssymb,amsmath,amsfonts,amsthm,amsbsy} \usepackage{tikz} \setbeamercovered{dynamic} \setbeamertemplate{items}[circle] \begin{document} \begin{frame} My equation: \begin{gather*} A = B \tikz[remember picture, overlay, baseline=-.5ex] \node (n1) {}; \qquad \tikz[baseline=0.5ex,remember picture]{ \node[fill=blue!20,opacity=.6,anchor=base,align=center,font=\color{blue}\tiny] (t1) {This is\\ my equation}; } \begin{tikzpicture}[overlay,remember picture] \draw<1->[->,blue,opacity=.6] (n1) -- (t1); \end{tikzpicture} \end{gather*} \end{frame} \end{document} ```
0
https://tex.stackexchange.com/users/36296
682859
316,834
https://tex.stackexchange.com/questions/682858
2
I intent to point the arrow to $A = B$, but the arrow comes from outside of the slide. Why that? Here it is the code ``` \documentclass[10pt,xcolor={dvipsnames}]{beamer} \mode<article> % only for the article version { \usepackage{fullpage} \usepackage{hyperref} } \mode<presentation> { %\setbeamertemplate{background canvas}[vertical shading][bottom=red!10,top=blue!10] \setbeamercovered{transparent} \usefonttheme{serif} \usecolortheme{crane} } \usepackage{pgf,pgfarrows,pgfnodes,pgfautomata,pgfheaps,pgfshade} \usepackage[latin1]{inputenc} \usepackage{colortbl} \usepackage{amstext,amssymb,amsmath,amsfonts,amsthm,amsbsy} \usepackage{tikz} \setbeamercovered{dynamic} \setbeamertemplate{items}[circle] \begin{document} \begin{frame} My equation: \begin{gather*} A = B \tikz[remember picture, overlay, baseline=-.5ex] \node (n1) {}; \qquad \tikz[baseline]{ \node[fill=blue!20,opacity=.6,anchor=base] (t1) {$\substack{\text{{\tiny{\color{blue}This is}}} \\ \text{{\tiny{\color{blue}my equation}}}}$};} \begin{tikzpicture}[overlay] \path[->,blue,opacity=.6]<1-> (n1) edge [] (t1); \end{tikzpicture} \end{gather*} \end{frame} \end{document} ```
https://tex.stackexchange.com/users/293909
Using Tikz in Beamer with arrow pointing improperly
false
if the problem is only to add colored node with two line text in equation, then try the following (simple) suggestion: ``` \documentclass[10pt,xcolor={dvipsnames,table}]{beamer} \mode<article> % only for the article version { \usepackage{fullpage} \usepackage{hyperref} } \mode<presentation> { \setbeamertemplate{background canvas}[vertical shading][bottom=red!10,top=blue!10] \setbeamercovered{transparent} \usefonttheme{serif} \usecolortheme{crane} \setbeamercovered{dynamic} \setbeamertemplate{items}[circle] } \usepackage{tikz} \begin{document} \begin{frame} My equation: \[ A = B \quad\tikz[baseline=-0.5ex] \draw[blue, ->, shorten >=3pt] (0,0) -- ++ (1,0) node[fill=blue!20,align=center,font=\tiny, right] {This is\\ my equation}; \] \end{frame} \end{document} ```
0
https://tex.stackexchange.com/users/18189
682862
316,835
https://tex.stackexchange.com/questions/682861
1
I'm trying to write a function to ease the drawing of figures. I called this function `\drawcurve` as is shown below. It's purpose is to create a curve between 2 lines indicated by coordinates in it's arguments. It looks like this: `\drawcurve{<line1_co1>}{<line1_co2>}{<line2_co1>}{<line2_co2>}{<curve settings>}` I'm however stumbling on the problem that due to my definition for coordinate v1 and v2, the tikz library also reserves space on the figure for these undrawn coordinates causing my figure to be lobsided. Up until now, I haven't been able to figure out how to make either tikz not reserve space for these coordinates or avoid using the coordinate definition altogether. How can I achieve this? The code of the figure I'm making is also included. The problem doesn't seem extremely bad in this case, but as I would like to use the command `\drawcurve` often during my Thesis, it needs to work in every circumstance. I hope my question is clear. Thanks! ``` \newcommand{\drawcurve}[5]{ \draw #1 coordinate (start_far) #2 coordinate (start_close) ($(start_close) - (start_far)$) coordinate (v1) #3 coordinate (end_close) #4 coordinate (end_far) ($(end_close) - (end_far)$) coordinate (v2) ; \draw let \p1=(v1), \n1={atan2(\y1,\x1)} in let \p2=(v2), \n2={atan2(\y2,\x2)} in [#5] (start_close) to[out=\n1,in=\n2] (end_close) ; } ``` ``` \documentclass[a4paper, 10pt]{article} \usepackage{siunitx} \usepackage{tikz} \usetikzlibrary{calc} \usetikzlibrary{fit} \begin{document} \begin{figure}[h!] \centering \begin{tikzpicture} % AXES \draw[->] (0, 0) -- (0, 5) node[above] {$A[\qty{}{\decibel}]$}; \draw[->] (0, 0) -- (8, 0) node[right] {$f [\qty{}{\hertz}]$}; % DRAW DOTTED LINES \draw[dotted, thick] (8,3) -- (0, 3); \draw[dotted, thick] (4,0) -- (4, 4); % DRAW CURVES \draw[color=blue, ultra thick] (0,3.5) -- (3.5,3.5); \drawcurve{(0,3.5)}{(3.5,3.5)}{(5,2.5)}{(6.5,1)}{color=blue, ultra thick} \draw[color=blue, ultra thick] (5,2.5) -- (6.5,1); \draw[color=red, ultra thick] (0,2.5) -- (3.5,2.5); \drawcurve{(0,2.5)}{(3.5,2.5)}{(5,3.5)}{(5.5,4)}{color=red, ultra thick} \draw[color=red, ultra thick] (5,3.5) -- (5.5,4); \drawcurve{(5,3.5)}{(5.5,4)}{(6.5,4)}{(8,2.5)}{color=red, ultra thick} \draw[color=red, ultra thick] (6.5,4) -- (8,2.5); \draw[color=green, ultra thick] (0,3) -- (5.5,3); \drawcurve{(0,3)}{(5.5,3)}{(7,2)}{(8,1)}{color=green, ultra thick} \draw[color=green, ultra thick] (7,2) -- (8,1); \end{tikzpicture} \caption{} \label{fig:myfig} \end{figure} \end{document} ```
https://tex.stackexchange.com/users/270591
LaTeX reserving space for undrawn coordinates
true
You could add the option `overlay` to the path in your custom macro where you define the coordinates. This way, this path won't add to the bounding box of the picture: ``` \documentclass{standalone} \usepackage{siunitx} \usepackage{tikz} \usetikzlibrary{calc} \newcommand{\drawcurve}[5]{ \path[overlay] #1 coordinate (start_far) #2 coordinate (start_close) ($(start_close) - (start_far)$) coordinate (v1) #3 coordinate (end_close) #4 coordinate (end_far) ($(end_close) - (end_far)$) coordinate (v2) ; \draw let \p1=(v1), \n1={atan2(\y1,\x1)} in let \p2=(v2), \n2={atan2(\y2,\x2)} in [#5] (start_close) to[out=\n1,in=\n2] (end_close) ; } \begin{document} \begin{tikzpicture} % AXES \draw[->] (0, 0) -- (0, 5) node[above] {$A[\qty{}{\decibel}]$}; \draw[->] (0, 0) -- (8, 0) node[right] {$f [\qty{}{\hertz}]$}; % DRAW DOTTED LINES \draw[dotted, thick] (8,3) -- (0, 3); \draw[dotted, thick] (4,0) -- (4, 4); % DRAW CURVES \draw[color=blue, ultra thick] (0,3.5) -- (3.5,3.5); \drawcurve{(0,3.5)}{(3.5,3.5)}{(5,2.5)}{(6.5,1)}{color=blue, ultra thick} \draw[color=blue, ultra thick] (5,2.5) -- (6.5,1); \draw[color=red, ultra thick] (0,2.5) -- (3.5,2.5); \drawcurve{(0,2.5)}{(3.5,2.5)}{(5,3.5)}{(5.5,4)}{color=red, ultra thick} \draw[color=red, ultra thick] (5,3.5) -- (5.5,4); \drawcurve{(5,3.5)}{(5.5,4)}{(6.5,4)}{(8,2.5)}{color=red, ultra thick} \draw[color=red, ultra thick] (6.5,4) -- (8,2.5); \draw[color=green, ultra thick] (0,3) -- (5.5,3); \drawcurve{(0,3)}{(5.5,3)}{(7,2)}{(8,1)}{color=green, ultra thick} \draw[color=green, ultra thick] (7,2) -- (8,1); \end{tikzpicture} \end{document} ```
1
https://tex.stackexchange.com/users/47927
682867
316,837
https://tex.stackexchange.com/questions/682866
1
How I can fixed the "word" which is not in line with the remaining ones in the following code? ``` \documentclass[10pt,xcolor={dvipsnames,table}]{beamer} \mode<article> % only for the article version { \usepackage{fullpage} \usepackage{hyperref} } \mode<presentation> { %\setbeamertemplate{background canvas}[vertical shading][bottom=red!10,top=blue!10] \setbeamercovered{transparent} \usefonttheme{serif} \usecolortheme{crane} } \usepackage{tikz} \setbeamercovered{dynamic} \setbeamertemplate{items}[circle] \begin{document} \begin{frame} Consider the equation \begin{equation*} A = B \hspace*{0.5cm} \tikz[baseline,remember picture]{ \node[fill=blue!20,opacity=.6,anchor=base,align=center,font=\color{blue}\tiny] (t1) {My Theorem (...)}; } \end{equation*} This \tikz[remember picture, baseline=-.5ex] \node (n1) {word}; is a little misplaced. \begin{tikzpicture}[overlay,remember picture] \draw<1->[->,blue,opacity=.6] (n1) -- (t1); \end{tikzpicture} \end{frame} \end{document} ```
https://tex.stackexchange.com/users/293909
Word which is not in line with the others
true
With `baseline=-.5ex` you shift the baseline of the tikzpicture. This will shift the word inside the node as well. As said before: have a look at the `tikzmark` library or the `hf-tikz` package instead of manually playing around with baselines and alignments. Then you won't run into problems like this. ``` \documentclass[10pt,xcolor={dvipsnames,table}]{beamer} \mode<article> % only for the article version { \usepackage{fullpage} \usepackage{hyperref} } \mode<presentation> { %\setbeamertemplate{background canvas}[vertical shading][bottom=red!10,top=blue!10] \setbeamercovered{transparent} \usefonttheme{serif} \usecolortheme{crane} } \usepackage{tikz} \setbeamercovered{dynamic} \setbeamertemplate{items}[circle] \usetikzlibrary{tikzmark} \begin{document} \begin{frame} Consider the equation \begin{equation*} A = B \hspace*{0.5cm} \tikz[baseline,remember picture]{ \node[fill=blue!20,opacity=.6,anchor=base,align=center,font=\color{blue}\tiny] (t1) {My Theorem (...)}; } \end{equation*} This \tikzmarknode{n1}{word} is a little misplaced. \begin{tikzpicture}[overlay,remember picture] \draw<1->[->,blue,opacity=.6] (n1.north) -- (t1); \end{tikzpicture} \end{frame} \end{document} ```
0
https://tex.stackexchange.com/users/36296
682868
316,838
https://tex.stackexchange.com/questions/682813
2
How to put text at the end of a line (outmost right) in an align\* environment? I have a set of equations in align\* and at the end of each line I want to write a little bit text which explains that line. And I want it to be at the right of each line.
https://tex.stackexchange.com/users/294982
Text at end of math-line in align environment
false
There are two different kinds of objects that can adorn an equation: 1. a number or tag or 2. an “explanation”. The number or tag doesn't belong in the equation: it's just a convenience for cross references, handier than “the third equation on page 234”. An explanation instead *is* part of the equation (or the step in a derivation) and should not be flush right. The code: ``` \begin{alignat*}{2} a+(b+s(c)) &=a+s(b+c) &\qquad& \text{(definition)} \\ &=s(a+(b+c)) && \text{(definition)} \\ &=s((a+b)+c)) && \text{(induction)} \\ &=(a+b)+s(c) && \text{(definition)} \end{alignat*} ``` The same (ab)using `\tag`: ``` \begin{align*} a+(b+s(c)) &=a+s(b+c) \tag{definition} \\ &=s(a+(b+c)) \tag{definition} \\ &=s((a+b)+c)) \tag{induction} \\ &=(a+b)+s(c) \tag{definition} \end{align*} ``` But this has an obvious problem: if the document class specifies `leqno`, you'd get with no warning. A possible way out is to use `flalign*` ``` \documentclass[leqno]{article} \usepackage{amsmath} \usepackage{showframe} \begin{document} After observing that $a+(b+0)=a+b=(a+b)+0$ we can proceed to prove the associativity of addition by induction, namely \begin{flalign*} &&a+(b+s(c)) &=a+s(b+c) &&\text{(definition)} \\ &&&=s(a+(b+c)) &&\text{(definition)} \\ &&&=s((a+b)+c)) &&\text{(induction)} \\ &&&=(a+b)+s(c) &&\text{(definition)} \end{flalign*} \end{document} ``` But I'd stay with the first display, for the reasons outlined at the beginning.
0
https://tex.stackexchange.com/users/4427
682870
316,839
https://tex.stackexchange.com/questions/682865
1
I've been trying to follow the insights from the following posts: * [Are the TikZ libraries cd and external incompatible with one another?](https://tex.stackexchange.com/questions/171931/are-the-tikz-libraries-cd-and-external-incompatible-with-one-another) * [How to avoid redefining ampersand & globally?](https://tex.stackexchange.com/q/632643/148934) * [Use & inside commands](https://tex.stackexchange.com/q/619960/148934) (The user tobiasBora seems to be interested in achieving very similar things to me.) However, I've ended up in a jumble of nothing quite working in all possible cases. In short, I want to use a tikzcd environment that * works as you would expect it to (duh!) * also works in conjunction with the externalize package * also works if you want to embed it in an amsmath align environment * works with the beamer document class My current attempt is in the MWE below: ``` \documentclass{article} \usepackage{tikz} \usepackage{amsmath,xparse,etoolbox} \usetikzlibrary{cd,external} %we don't actually need externalisation to demonstrate the problem, so turn it off for now %\tikzexternalize \makeatletter \NewDocumentEnvironment{quantikz}{O{}+b}{% %local redefinition of catcode \begingroup \catcode`&=\active \def\@temp{\tikzcd@[#1]\scantokens{#2}}% \expandafter\@temp\endtikzcd\endgroup }{} %replace commands with environment. seems to help with externalize. \patchcmd\tikzcd@{\tikzpicture}{\begin{tikzpicture}}{}{} \patchcmd\endtikzcd{\endtikzpicture}{\end{tikzpicture}}{}{} \makeatother \tikzcdset{nodes in empty cells} %this works %also works with external switched on %also works when documentclass is beamer \begin{document} \begin{quantikz} H & \ar[l] \end{quantikz} %this does not work %neither does ampersand replacement % \begin{align*} % \begin{quantikz} % & \ar[l] % \end{quantikz} % \end{align*} %original environment works with ampersand replacement %but does not externalize \begin{align*} \begin{tikzcd}[ampersand replacement=\&] H \& \ar[l] \end{tikzcd} \end{align*} \end{document} ``` I had wondered if a simple solution would be to get ampersand replacement working again within the new environment. But even if I directly replace all instances of & with \pgfmatrixnextcell, the quantikz environment doesn't seem to work inside align.
https://tex.stackexchange.com/users/148934
Resolving tikzcd/externalize/align incompatibilities
true
Here's a defintion of `quantikz` that grabs the body and replaces every `&` in it with a `\pgfmatrixnextcell`. Then, it places a `tikzpicture` environment in a way that the `external` accepts it (having `\end{tikzpicture}` not hidden in another macro) and disables the `tikzpicture` environment inside `tikzcd`. For this the options to `\tikzcd` (`\begin{tikzcd}`) will be moved to the `tikzpicture` environment which is where it's usually placed anyway. This does *not patch* the `tikzcd` environment in any regard but only provides a new `quantikz` environment which should work like the original `tikzcd` environment but with `&` even inside an argument to a macro and with activated externalization. Code ---- ``` \documentclass{article} \usepackage{tikz} \usepackage{amsmath} \usetikzlibrary{cd, external} \tikzexternalize \ExplSyntaxOn \NewDocumentEnvironment{quantikz}{O{}+b}{ \begin{tikzpicture}[commutative~diagrams/.cd, every~diagram, #1] \tl_set:Nn \l_tmpa_tl { #2 } \tl_replace_all:Nnn \l_tmpa_tl { & } { \pgfmatrixnextcell } \begingroup \def\tikzpicture[##1]{} \let\endtikzpicture\relax \tikzcd \l_tmpa_tl \endtikzcd \endgroup \end{tikzpicture} }{} \ExplSyntaxOff \tikzcdset{ nodes in empty cells, diagrams={baseline=-axis_height}}% https://tex.stackexchange.com/a/678935/16595 \begin{document} \begin{quantikz} H & \ar[l] \end{quantikz} \begin{align*} \left\{\begin{quantikz} H & \ar[l] X \\ B \ar[ur] \end{quantikz}\right\} & = \{ x + 2 \} \end{align*} \end{document} ```
1
https://tex.stackexchange.com/users/16595
682872
316,840
https://tex.stackexchange.com/questions/682869
1
Consider this simple document. ``` \documentclass{scrbook} \usepackage{scrlayer-scrpage} \pagestyle{scrheadings} \usepackage{amsmath} \usepackage{blindtext} \begin{document} \title{\Huge Me} \author{Maulik} \date{\today} \maketitle \chapter{Introduction} \blindtext[10] \chapter{Methods} \blindtext[10] \end{document} ``` As you can see, I am using a KOMA-script class. In this document, I want to have horizontal lines after the header, and before the footer. It would look something like ``` header -------- Text of the document ------- footer ``` I know it can be done using fancyhdr package, along with renewcommand (as shown [here](https://tex.stackexchange.com/questions/109153/how-to-add-horizontal-line-after-header-and-before-footer)). But is it possible to do the same using scrlayer-scrpage package, which is default in the KOMA-script classes?
https://tex.stackexchange.com/users/267842
How can I add horizontal lines after the header and before the footer in koma-script classes?
true
For horizontal lines below the header and above the footer, just use the `headsepline` and `footsepline` options of `scrlayer-scrpage`: ``` \documentclass{scrbook} \usepackage[headsepline, footsepline]{scrlayer-scrpage} \pagestyle{scrheadings} \usepackage{amsmath} \usepackage{blindtext} \begin{document} \title{\Huge Me} \author{Maulik} \date{\today} \maketitle \chapter{Introduction} \blindtext[10] \chapter{Methods} \blindtext[10] \end{document} ```
2
https://tex.stackexchange.com/users/216203
682873
316,841
https://tex.stackexchange.com/questions/28491
2
Using a LaTeX or similar text-macro tool/library, how can I generate an Entity-Relationship Diagram then generate SQL from it?
https://tex.stackexchange.com/users/7356
Generate Entity-Relationship Diagram then generate SQL from that
false
``` \documentclass{article} \usepackage{tikz} \usepackage{tikz-er2} \begin{document} \begin{tikzpicture}[entity/.style={draw=blue!50, fill=blue!20, thick, rectangle, minimum width=10mm, minimum height=7mm}, attribute/.style={draw=black, fill=white, thick, ellipse, minimum width=10mm, minimum height=7mm}, relationship/.style={draw=red!50, fill=red!20, thick, diamond, minimum width=10mm, minimum height=7mm, aspect=2}] \node[entity] (user) {User}; \node[attribute] (userid) [above left of=user] {\key{user\_id}} edge (user); \node[attribute] (name) [above of=user] {name} edge (user); \node[attribute] (email) [above right of=user] {email} edge (user); \node[attribute] (password) [right of=user] {password} edge (user); \node[entity] (product) [below of=user] {Product}; \node[attribute] (productid) [above left of=product] {\key{product\_id}} edge (product); \node[attribute] (pname) [above of=product] {name} edge (product); \node[attribute] (price) [above right of=product] {price} edge (product); \node[attribute] (description) [right of=product] {description} edge (product); \node[attribute] (categoryid) [below right of=product] {category\_id} edge (product); \node[entity] (category) [below of=product] {Category}; \node[attribute] (categoryid2) [above left of=category] {\key{category\_id}} edge (category); \node[attribute] (cname) [above of=category] {name} edge (category); \node[attribute] (description2) [above right of=category] {description} edge (category); \node[attribute] (parentid) [below left of=category] {parent\_id} edge (category); \node[entity] (order) [right of=product, xshift=5cm] {Order}; \node[attribute] (orderid) [above left of=order] {\key{order\_id}} edge (order); \node[attribute] (userid2) [above right of=order] {user\_id} edge (order); \node[attribute] (productid2) [below left of=order] {product\_id} edge (order); \node[attribute] (quantity) [below of=order] {quantity} edge (order); \node[attribute] (date) [below right of=order] {date} edge (order); \node[entity] (payment) [below of=order] {Payment}; \node[attribute] (paymentid) [above of=payment] {\key{payment\_id}} edge (payment); \node[attribute] (amount) [left of=payment] {amount} edge (payment); \node[attribute] (paymentmethod) [right of=payment] {payment\_method} edge (payment); \node[attribute] (orderid2) [below left of=payment] {order\_ ```
0
https://tex.stackexchange.com/users/294565
682879
316,843
https://tex.stackexchange.com/questions/682509
1
Running latexmk, I sometimes get files lualatex1234.fls. Would be interesting where they come from. Nevertheless, I want to erase and so aded to `.latexmkrc` ``` $clean_ext .= " %R.synctex.gz %R.*.vrb lualatex17420.fls"; ``` Beleave or not, whereas the synctex files are erased and also the vrb files (coming from beamer class), even though \* represents arbitrary numbers, the lualatex files are not erased. I suspect, latexmk expects some placeholder or i dont know. Maybe in latexmk another variable would be nice holding the current processor, so that I can write configs which also work for xelatex.
https://tex.stackexchange.com/users/60463
latexmk: does not clean lualatex[number].fls
false
The description for `$clean_ext` in the latexmk documentation explains all this. The items in `$clean_ext` are either extensions of files to be removed (with the basename being that of the main .tex file), or contain the place holder `%R` (for the basename of the main .tex file). There is at present no convenient way of getting latexmk to automatically remove the files like `lualatex17420.fls` that sometimes are generated when a \*latex program is terminated prematurely. (The integer in the filename is the process number of the process generating the file, so it will change from run to run.) Latexmk is somewhat conservative about what files it automatically deletes, because of the danger of unexpectedly deleting files that have nothing to do with the current document.
2
https://tex.stackexchange.com/users/8495
682888
316,845
https://tex.stackexchange.com/questions/682891
4
I noticed an interesting conflict between several packages. I was using symbols from `gensymb` in math mode, but this seemed to cause problems in a very particular scenario. This seems to be the case for any document class. When I call `\usepackage{nicematrix}` before `\usepackage{gensymb}` AND call `\usepackage` on any of the following packages: `(textcomp,xfrac,chemmacros)`, I run into problems when trying to place symbols from `gensymb` into math mode. The error reads `"\textfont 4 is undefined (character W). $\ohm$"` or `"\textfont 4 is undefined (character �). $\degree$"`. I just updated to TeX Live 2023 (full scheme) and updated my packages using tlmgr. I however had the same problems in the 2022 version as well. Attached is a minimal working example. ``` \documentclass{article} \usepackage{nicematrix} \usepackage{gensymb} %Add any of these three packages and the gensymb symbols (\degree,\ohm) do not work in math mode if nicematrix is situated before gensymb. If nicematrix is placed after gensymb, no problems arise. \usepackage{textcomp} %\usepackage{xfrac} %\usepackage{chemmacros} \begin{document} \degree $\degree$ \ohm $\ohm$ \end{document} ``` I already found a workaround by placing `\usepackage{nicematrix}` after `\usepackage{gensymb}` but I was interested if anyone had a clue as to what was causing this problem. Here is also the full log output: ``` This is pdfTeX, Version 3.141592653-2.6-1.40.25 (TeX Live 2023) (preloaded format=pdflatex 2023.4.14) 14 APR 2023 17:42 entering extended mode restricted \write18 enabled. %&-line parsing enabled. **testitesti.tex (./testitesti.tex LaTeX2e <2022-11-01> patch level 1 L3 programming layer <2023-03-30> (/usr/local/texlive/2023/texmf-dist/tex/latex/base/letter.cls Document Class: letter 2021/12/07 v1.3c Standard LaTeX document class (/usr/local/texlive/2023/texmf-dist/tex/latex/base/size10.clo File: size10.clo 2022/07/02 v1.4n Standard LaTeX file (size option) ) \longindentation=\dimen140 \indentedwidth=\dimen141 \labelcount=\count185 ) (/usr/local/texlive/2023/texmf-dist/tex/latex/nicematrix/nicematrix.sty (/usr/local/texlive/2023/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty (/usr/local/texlive/2023/texmf-dist/tex/latex/graphics/graphicx.sty Package: graphicx 2021/09/16 v1.2d Enhanced LaTeX Graphics (DPC,SPQR) (/usr/local/texlive/2023/texmf-dist/tex/latex/graphics/keyval.sty Package: keyval 2022/05/29 v1.15 key=value parser (DPC) \KV@toks@=\toks16 ) (/usr/local/texlive/2023/texmf-dist/tex/latex/graphics/graphics.sty Package: graphics 2022/03/10 v1.4e Standard LaTeX Graphics (DPC,SPQR) (/usr/local/texlive/2023/texmf-dist/tex/latex/graphics/trig.sty Package: trig 2021/08/11 v1.11 sin cos tan (DPC) ) (/usr/local/texlive/2023/texmf-dist/tex/latex/graphics-cfg/graphics.cfg File: graphics.cfg 2016/06/04 v1.11 sample graphics configuration ) Package graphics Info: Driver file: pdftex.def on input line 107. (/usr/local/texlive/2023/texmf-dist/tex/latex/graphics-def/pdftex.def File: pdftex.def 2022/09/22 v1.2b Graphics/color driver for pdftex )) \Gin@req@height=\dimen142 \Gin@req@width=\dimen143 ) (/usr/local/texlive/2023/texmf-dist/tex/latex/pgf/systemlayer/pgfsys.sty (/usr/local/texlive/2023/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.te x \pgfutil@everybye=\toks17 \pgfutil@tempdima=\dimen144 \pgfutil@tempdimb=\dimen145 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/utilities/pgfutil-latex.def \pgfutil@abb=\box51 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/pgf.revision.tex) Package: pgfrcs 2023-01-15 v3.1.10 (3.1.10) )) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/systemlayer/pgfsys.code.tex Package: pgfsys 2023-01-15 v3.1.10 (3.1.10) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex \pgfkeys@pathtoks=\toks18 \pgfkeys@temptoks=\toks19 (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/utilities/pgfkeyslibraryfil tered.code.tex \pgfkeys@tmptoks=\toks20 )) \pgf@x=\dimen146 \pgf@y=\dimen147 \pgf@xa=\dimen148 \pgf@ya=\dimen149 \pgf@xb=\dimen150 \pgf@yb=\dimen151 \pgf@xc=\dimen152 \pgf@yc=\dimen153 \pgf@xd=\dimen154 \pgf@yd=\dimen155 \w@pgf@writea=\write3 \r@pgf@reada=\read2 \c@pgf@counta=\count186 \c@pgf@countb=\count187 \c@pgf@countc=\count188 \c@pgf@countd=\count189 \t@pgf@toka=\toks21 \t@pgf@tokb=\toks22 \t@pgf@tokc=\toks23 \pgf@sys@id@count=\count190 (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/systemlayer/pgf.cfg File: pgf.cfg 2023-01-15 v3.1.10 (3.1.10) ) Driver file for pgf: pgfsys-pdftex.def (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-pdftex.d ef File: pgfsys-pdftex.def 2023-01-15 v3.1.10 (3.1.10) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-common-p df.def File: pgfsys-common-pdf.def 2023-01-15 v3.1.10 (3.1.10) ))) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/systemlayer/pgfsyssoftpath. code.tex File: pgfsyssoftpath.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgfsyssoftpath@smallbuffer@items=\count191 \pgfsyssoftpath@bigbuffer@items=\count192 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/systemlayer/pgfsysprotocol. code.tex File: pgfsysprotocol.code.tex 2023-01-15 v3.1.10 (3.1.10) )) (/usr/local/texlive/2023/texmf-dist/tex/latex/xcolor/xcolor.sty Package: xcolor 2022/06/12 v2.14 LaTeX color extensions (UK) (/usr/local/texlive/2023/texmf-dist/tex/latex/graphics-cfg/color.cfg File: color.cfg 2016/01/02 v1.6 sample color configuration ) Package xcolor Info: Driver file: pdftex.def on input line 227. (/usr/local/texlive/2023/texmf-dist/tex/latex/graphics/mathcolor.ltx) Package xcolor Info: Model `cmy' substituted by `cmy0' on input line 1353. Package xcolor Info: Model `hsb' substituted by `rgb' on input line 1357. Package xcolor Info: Model `RGB' extended on input line 1369. Package xcolor Info: Model `HTML' substituted by `rgb' on input line 1371. Package xcolor Info: Model `Hsb' substituted by `hsb' on input line 1372. Package xcolor Info: Model `tHsb' substituted by `hsb' on input line 1373. Package xcolor Info: Model `HSB' substituted by `hsb' on input line 1374. Package xcolor Info: Model `Gray' substituted by `gray' on input line 1375. Package xcolor Info: Model `wave' substituted by `hsb' on input line 1376. ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcore.code.tex Package: pgfcore 2023-01-15 v3.1.10 (3.1.10) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmath.code.tex (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex \pgfmath@dimen=\dimen156 \pgfmath@count=\count193 \pgfmath@box=\box52 \pgfmath@toks=\toks24 \pgfmath@stack@operand=\toks25 \pgfmath@stack@operation=\toks26 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.code. tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic .code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.trigo nometric.code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.rando m.code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.compa rison.code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.base. code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.round .code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.misc. code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.integ erarithmetics.code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathcalc.code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfmathfloat.code.tex \c@pgfmathroundto@lastzeros=\count194 )) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/math/pgfint.code.tex) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepoints.co de.tex File: pgfcorepoints.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgf@picminx=\dimen157 \pgf@picmaxx=\dimen158 \pgf@picminy=\dimen159 \pgf@picmaxy=\dimen160 \pgf@pathminx=\dimen161 \pgf@pathmaxx=\dimen162 \pgf@pathminy=\dimen163 \pgf@pathmaxy=\dimen164 \pgf@xx=\dimen165 \pgf@xy=\dimen166 \pgf@yx=\dimen167 \pgf@yy=\dimen168 \pgf@zx=\dimen169 \pgf@zy=\dimen170 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathconst ruct.code.tex File: pgfcorepathconstruct.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgf@path@lastx=\dimen171 \pgf@path@lasty=\dimen172 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathusage .code.tex File: pgfcorepathusage.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgf@shorten@end@additional=\dimen173 \pgf@shorten@start@additional=\dimen174 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorescopes.co de.tex File: pgfcorescopes.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgfpic=\box53 \pgf@hbox=\box54 \pgf@layerbox@main=\box55 \pgf@picture@serial@count=\count195 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcoregraphicst ate.code.tex File: pgfcoregraphicstate.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgflinewidth=\dimen175 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcoretransform ations.code.tex File: pgfcoretransformations.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgf@pt@x=\dimen176 \pgf@pt@y=\dimen177 \pgf@pt@temp=\dimen178 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorequick.cod e.tex File: pgfcorequick.code.tex 2023-01-15 v3.1.10 (3.1.10) ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreobjects.c ode.tex File: pgfcoreobjects.code.tex 2023-01-15 v3.1.10 (3.1.10) ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathproce ssing.code.tex File: pgfcorepathprocessing.code.tex 2023-01-15 v3.1.10 (3.1.10) ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorearrows.co de.tex File: pgfcorearrows.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgfarrowsep=\dimen179 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.cod e.tex File: pgfcoreshade.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgf@max=\dimen180 \pgf@sys@shading@range@num=\count196 \pgf@shadingcount=\count197 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreimage.cod e.tex File: pgfcoreimage.code.tex 2023-01-15 v3.1.10 (3.1.10) ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreexternal. code.tex File: pgfcoreexternal.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgfexternal@startupbox=\box56 ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorelayers.co de.tex File: pgfcorelayers.code.tex 2023-01-15 v3.1.10 (3.1.10) ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcoretranspare ncy.code.tex File: pgfcoretransparency.code.tex 2023-01-15 v3.1.10 (3.1.10) ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepatterns. code.tex File: pgfcorepatterns.code.tex 2023-01-15 v3.1.10 (3.1.10) ) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/basiclayer/pgfcorerdf.code. tex File: pgfcorerdf.code.tex 2023-01-15 v3.1.10 (3.1.10) ))) (/usr/local/texlive/2023/texmf-dist/tex/generic/pgf/modules/pgfmoduleshapes.cod e.tex File: pgfmoduleshapes.code.tex 2023-01-15 v3.1.10 (3.1.10) \pgfnodeparttextbox=\box57 ) (/usr/local/texlive/2023/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty (/usr/local/texlive/2023/texmf-dist/tex/latex/l3kernel/expl3.sty Package: expl3 2023-03-30 L3 programming layer (loader) (/usr/local/texlive/2023/texmf-dist/tex/latex/l3backend/l3backend-pdftex.def File: l3backend-pdftex.def 2023-03-30 L3 backend support: PDF output (pdfTeX) \l__color_backend_stack_int=\count198 \l__pdf_internal_box=\box58 )) Package: l3keys2e 2023-02-02 LaTeX2e option processing using LaTeX3 keys ) Package: nicematrix 2023/03/31 v6.17 Enhanced arrays with the help of PGF/TikZ (/usr/local/texlive/2023/texmf-dist/tex/latex/tools/array.sty Package: array 2022/09/04 v2.5g Tabular extension package (FMi) \col@sep=\dimen181 \ar@mcellbox=\box59 \extrarowheight=\dimen182 \NC@list=\toks27 \extratabsurround=\skip48 \backup@length=\skip49 \ar@cellbox=\box60 ) (/usr/local/texlive/2023/texmf-dist/tex/latex/amsmath/amsmath.sty Package: amsmath 2022/04/08 v2.17n AMS math features \@mathmargin=\skip50 For additional information on amsmath, use the `?' option. (/usr/local/texlive/2023/texmf-dist/tex/latex/amsmath/amstext.sty Package: amstext 2021/08/26 v2.01 AMS text (/usr/local/texlive/2023/texmf-dist/tex/latex/amsmath/amsgen.sty File: amsgen.sty 1999/11/30 v2.0 generic functions \@emptytoks=\toks28 \ex@=\dimen183 )) (/usr/local/texlive/2023/texmf-dist/tex/latex/amsmath/amsbsy.sty Package: amsbsy 1999/11/29 v1.2d Bold Symbols \pmbraise@=\dimen184 ) (/usr/local/texlive/2023/texmf-dist/tex/latex/amsmath/amsopn.sty Package: amsopn 2022/04/08 v2.04 operator names ) \inf@bad=\count199 LaTeX Info: Redefining \frac on input line 234. \uproot@=\count266 \leftroot@=\count267 LaTeX Info: Redefining \overline on input line 399. LaTeX Info: Redefining \colon on input line 410. \classnum@=\count268 \DOTSCASE@=\count269 LaTeX Info: Redefining \ldots on input line 496. LaTeX Info: Redefining \dots on input line 499. LaTeX Info: Redefining \cdots on input line 620. \Mathstrutbox@=\box61 \strutbox@=\box62 LaTeX Info: Redefining \big on input line 722. LaTeX Info: Redefining \Big on input line 723. LaTeX Info: Redefining \bigg on input line 724. LaTeX Info: Redefining \Bigg on input line 725. \big@size=\dimen185 LaTeX Font Info: Redeclaring font encoding OML on input line 743. LaTeX Font Info: Redeclaring font encoding OMS on input line 744. \macc@depth=\count270 LaTeX Info: Redefining \bmod on input line 905. LaTeX Info: Redefining \pmod on input line 910. LaTeX Info: Redefining \smash on input line 940. LaTeX Info: Redefining \relbar on input line 970. LaTeX Info: Redefining \Relbar on input line 971. \c@MaxMatrixCols=\count271 \dotsspace@=\muskip16 \c@parentequation=\count272 \dspbrk@lvl=\count273 \tag@help=\toks29 \row@=\count274 \column@=\count275 \maxfields@=\count276 \andhelp@=\toks30 \eqnshift@=\dimen186 \alignsep@=\dimen187 \tagshift@=\dimen188 \tagwidth@=\dimen189 \totwidth@=\dimen190 \lineht@=\dimen191 \@envbody=\toks31 \multlinegap=\skip51 \multlinetaggap=\skip52 \mathdisplay@stack=\toks32 LaTeX Info: Redefining \[ on input line 2953. LaTeX Info: Redefining \] on input line 2954. ) \g__nicematrix_env_int=\count277 \g__nicematrix_NiceMatrixBlock_int=\count278 \l__nicematrix_note_in_caption_int=\count279 \l__nicematrix_columns_width_dim=\dimen192 \l__nicematrix_col_width_dim=\dimen193 \g__nicematrix_row_total_int=\count280 \g__nicematrix_col_total_int=\count281 \g__nicematrix_last_row_node_int=\count282 \l__nicematrix_key_nb_rows_int=\count283 \g__nicematrix_blocks_wd_dim=\dimen194 \g__nicematrix_blocks_ht_dim=\dimen195 \g__nicematrix_blocks_dp_dim=\dimen196 \l__nicematrix_width_dim=\dimen197 \l__nicematrix_tabular_width_dim=\dimen198 \l__nicematrix_rule_width_dim=\dimen199 \l__nicematrix_old_iRow_int=\count284 \l__nicematrix_old_jCol_int=\count285 \g__nicematrix_total_X_weight_int=\count286 \l__nicematrix_X_columns_dim=\dimen256 \l__nicematrix_x_initial_dim=\dimen257 \l__nicematrix_y_initial_dim=\dimen258 \l__nicematrix_x_final_dim=\dimen259 \l__nicematrix_y_final_dim=\dimen260 \l__nicematrix_tmpc_dim=\dimen261 \l__nicematrix_tmpd_dim=\dimen262 \g__nicematrix_width_last_col_dim=\dimen263 \g__nicematrix_width_first_col_dim=\dimen264 \l__nicematrix_row_min_int=\count287 \l__nicematrix_row_max_int=\count288 \l__nicematrix_col_min_int=\count289 \l__nicematrix_col_max_int=\count290 \g__nicematrix_static_num_of_col_int=\count291 \l__nicematrix_rounded_corners_dim=\dimen265 \l__nicematrix_line_width_dim=\dimen266 \g__nicematrix_block_box_int=\count292 \l__nicematrix_submatrix_extra_height_dim=\dimen267 \l__nicematrix_submatrix_left_xshift_dim=\dimen268 \l__nicematrix_submatrix_right_xshift_dim=\dimen269 \l__nicematrix_first_row_int=\count293 \l__nicematrix_first_col_int=\count294 \l__nicematrix_last_row_int=\count295 \l__nicematrix_last_col_int=\count296 \c@tabularnote=\count297 \c@nicematrix_draft=\count298 \l__nicematrix_cell_space_top_limit_dim=\dimen270 \l__nicematrix_cell_space_bottom_limit_dim=\dimen271 \l__nicematrix_xdots_inter_dim=\dimen272 \l__nicematrix_xdots_shorten_start_dim=\dimen273 \l__nicematrix_xdots_shorten_end_dim=\dimen274 \l__nicematrix_xdots_radius_dim=\dimen275 \l__nicematrix_notes_above_space_dim=\dimen276 \l__nicematrix_left_margin_dim=\dimen277 \l__nicematrix_right_margin_dim=\dimen278 \l__nicematrix_extra_left_margin_dim=\dimen279 \l__nicematrix_extra_right_margin_dim=\dimen280 \c__nicematrix_max_l_dim=\dimen281 \l__nicematrix_position_int=\count299 \l__nicematrix_start_int=\count300 \l__nicematrix_multiplicity_int=\count301 \l__nicematrix_brace_yshift_dim=\dimen282 ) (/usr/local/texlive/2023/texmf-dist/tex/latex/gensymb/gensymb.sty Package: gensymb 2022/10/17 v1.0.2 (KJH) ) (/usr/local/texlive/2023/texmf-dist/tex/latex/base/textcomp.sty Package: textcomp 2020/02/02 v2.0n Standard LaTeX package ) (build/testitesti.aux) \openout1 = `testitesti.aux'. LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 12. LaTeX Font Info: ... okay on input line 12. LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 12. LaTeX Font Info: ... okay on input line 12. LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 12. LaTeX Font Info: ... okay on input line 12. LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 12. LaTeX Font Info: ... okay on input line 12. LaTeX Font Info: Checking defaults for TS1/cmr/m/n on input line 12. LaTeX Font Info: ... okay on input line 12. LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 12. LaTeX Font Info: ... okay on input line 12. LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 12. LaTeX Font Info: ... okay on input line 12. (/usr/local/texlive/2023/texmf-dist/tex/context/base/mkii/supp-pdf.mkii [Loading MPS to PDF converter (version 2006.09.02).] \scratchcounter=\count302 \scratchdimen=\dimen283 \scratchbox=\box63 \nofMPsegments=\count303 \nofMParguments=\count304 \everyMPshowfont=\toks33 \MPscratchCnt=\count305 \MPscratchDim=\dimen284 \MPnumerator=\count306 \makeMPintoPDFobject=\count307 \everyMPtoPDFconversion=\toks34 ) (/usr/local/texlive/2023/texmf-dist/tex/latex/epstopdf-pkg/epstopdf-base.sty Package: epstopdf-base 2020-01-24 v2.11 Base part for package epstopdf Package epstopdf-base Info: Redefining graphics rule for `.eps' on input line 4 85. (/usr/local/texlive/2023/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg File: epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Liv e )) \symgns@font=\mathgroup4 LaTeX Font Info: Overwriting symbol font `gns@font' in version `bold' (Font) TS1/cmr/m/n --> TS1/cmr/b/n on input line 12. Package gensymb Info: Math companion symbols declared on input line 12. LaTeX Info: Redefining \degree on input line 12. LaTeX Info: Redefining \celsius on input line 12. Package gensymb Info: Using text companion symbols for \degree, \celsius and \p erthousand on input line 12. LaTeX Info: Redefining \ohm on input line 12. Package gensymb Info: Using \textohm for \ohm on input line 12. Package gensymb Info: Using \textmu for \micro on input line 12. ! \textfont 4 is undefined (character �). l.14 $\degree$ Somewhere in the math formula just ended, you used the stated character from an undefined font family. For example, plain TeX doesn't allow \it or \sl in subscripts. Proceed, and I'll try to forget that I needed that character. ! \textfont 4 is undefined (character W). l.17 $\ohm$ Somewhere in the math formula just ended, you used the stated character from an undefined font family. For example, plain TeX doesn't allow \it or \sl in subscripts. Proceed, and I'll try to forget that I needed that character. [1 {/usr/local/texlive/2023/texmf-var/fonts/map/pdftex/updmap/pdftex.map}{/usr/loc al/texlive/2023/texmf-dist/fonts/enc/dvips/cm-super/cm-super-ts1.enc}] (build/testitesti.aux) ) Here is how much of TeX's memory you used: 11783 strings out of 476017 263900 string characters out of 5789774 1850666 words of memory out of 5000000 32087 multiletter control sequences out of 15000+600000 513076 words of font info for 35 fonts, out of 8000000 for 9000 1141 hyphenation exceptions out of 8191 87i,6n,90p,431b,110s stack positions out of 10000i,1000n,20000p,200000b,200000s </usr/local/texlive/2023/texmf-dist/fonts/type1/public/ amsfonts/cm/cmr10.pfb></usr/local/texlive/2023/texmf-dist/fonts/type1/public/cm -super/sfrm1000.pfb> Output written on build/testitesti.pdf (1 page, 12159 bytes). PDF statistics: 22 PDF objects out of 1000 (max. 8388607) 14 compressed objects within 1 object stream 0 named destinations out of 1000 (max. 500000) 13 words of extra memory for PDF output out of 10000 (max. 10000000) ```
https://tex.stackexchange.com/users/295034
Possible conflict between nicematrix and gensymb (and an additional package)
true
EDIT : This bug of `nicematrix` has been solved in the version 6.18 2023-04-19. --- The reason is that `nicematrix` uses a specific a detail of the implementation of `{array}` of `array` (in order to detect empty cells --- that is to say cells with only spaces between the `&`--- in some types of columns.) In order to detect whether `{array}` has been changed, a test is done (by composing a small tabular in a scratch box at the beginning of the document). That's the origin of the incompatibility. Maybe I will delete that test in a future version (I'm not sure if it was a good idea). For the moment, there is a key at load-time to disable that test: `\usepackage[no-test-for-array]{nicematrix}` ``` \documentclass{article} \usepackage[no-test-for-array]{nicematrix} \usepackage{amsmath} \usepackage{gensymb} %Add any of these three packages and the gensymb symbols (\degree,\ohm) do not work in math mode if nicematrix is situated before gensymb. If nicematrix is placed after gensymb, no problem arises. \usepackage{textcomp} %\usepackage{xfrac} %\usepackage{chemmacros} \begin{document} \degree $\degree$ \ohm $\ohm$ \end{document} ``` I will (at least) add a warning in the documentation of `nicematrix`. Thanks for the feedback.
3
https://tex.stackexchange.com/users/163000
682897
316,847
https://tex.stackexchange.com/questions/682898
2
I've tried the solutions from [Entering Unicode characters in LaTeX](https://tex.stackexchange.com/questions/34604/entering-unicode-characters-in-latex) on Overleaf but they are not working. **Attempt 1:** When using `\usepackage[utf8]{inputenc}`: ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage[utf8]{inputenc} \begin{document} To stop the charges, frugal users are advised to click on the ⏻ \end{document} ``` It throws the error ``` LaTeX Error: Unicode character ⏻ (U+23FB) ``` **Attempt 2:** When trying `\DeclareUnicodeCharacter{23FB}{\poweroff}` ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage[utf8]{inputenc} \DeclareUnicodeCharacter{23FB}{\poweroff} \begin{document} To stop the charges, frugal users are advised to click on the \poweroff \end{document} ``` It throws the error: ``` Undefined control sequence. ``` **Attempt 3:** When using `\usepackage[utf8x]{inputenc}` ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage[utf8x]{inputenc} \begin{document} To stop the charges, frugal users are advised to click on the ⏻ \end{document} ``` It throws the error: ``` Package ucs Error: Unknown Unicode character 9211 = U+23FB, ``` **Attempt 4:** Using `\usepackage{fontspec}`, see <https://www.overleaf.com/read/vkyzfjndxkgm> ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage[utf8]{inputenc} \usepackage{fontspec} \begin{document} To stop the charges, frugal users are advised to click on the {\fontspec{Symbola} \symbol{"1F343}} \end{document} ``` It just didn't compile and threw an error: ``` (fontspec) LuaTeX. (fontspec) (fontspec) You must change your typesetting engine to, (fontspec) e.g., "xelatex" or "lualatex" instead of (fontspec) "latex" or "pdflatex". Type <return> to continue. ... l.45 \msg_fatal:nn {fontspec} {cannot-use-pdftex} ```
https://tex.stackexchange.com/users/9992
How to use the Power Symbol (⏻) character in text in LaTeX?
false
Using lualatex (option in overleaf sidebar) you can use any font that has the character, eg ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage{fontspec} \newfontfamily\sfam{symbola} \begin{document} To stop the charges, frugal users are advised to click on the {\sfam ⏻} \end{document} ``` On the overleaf sidebar:
6
https://tex.stackexchange.com/users/1090
682902
316,850
https://tex.stackexchange.com/questions/682898
2
I've tried the solutions from [Entering Unicode characters in LaTeX](https://tex.stackexchange.com/questions/34604/entering-unicode-characters-in-latex) on Overleaf but they are not working. **Attempt 1:** When using `\usepackage[utf8]{inputenc}`: ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage[utf8]{inputenc} \begin{document} To stop the charges, frugal users are advised to click on the ⏻ \end{document} ``` It throws the error ``` LaTeX Error: Unicode character ⏻ (U+23FB) ``` **Attempt 2:** When trying `\DeclareUnicodeCharacter{23FB}{\poweroff}` ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage[utf8]{inputenc} \DeclareUnicodeCharacter{23FB}{\poweroff} \begin{document} To stop the charges, frugal users are advised to click on the \poweroff \end{document} ``` It throws the error: ``` Undefined control sequence. ``` **Attempt 3:** When using `\usepackage[utf8x]{inputenc}` ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage[utf8x]{inputenc} \begin{document} To stop the charges, frugal users are advised to click on the ⏻ \end{document} ``` It throws the error: ``` Package ucs Error: Unknown Unicode character 9211 = U+23FB, ``` **Attempt 4:** Using `\usepackage{fontspec}`, see <https://www.overleaf.com/read/vkyzfjndxkgm> ``` \documentclass{article} \usepackage[letterpaper,top=2cm,bottom=2cm,left=3cm,right=3cm,marginparwidth=1.75cm]{geometry} \usepackage[utf8]{inputenc} \usepackage{fontspec} \begin{document} To stop the charges, frugal users are advised to click on the {\fontspec{Symbola} \symbol{"1F343}} \end{document} ``` It just didn't compile and threw an error: ``` (fontspec) LuaTeX. (fontspec) (fontspec) You must change your typesetting engine to, (fontspec) e.g., "xelatex" or "lualatex" instead of (fontspec) "latex" or "pdflatex". Type <return> to continue. ... l.45 \msg_fatal:nn {fontspec} {cannot-use-pdftex} ```
https://tex.stackexchange.com/users/9992
How to use the Power Symbol (⏻) character in text in LaTeX?
false
As a workaround, if you have trouble with choosing the right font or with setting up the document, you could make use of `\faPowerOff` provided by the `fontawesome` package: ``` \documentclass{article} \usepackage{fontawesome} \begin{document} To stop the charges, frugal users are advised to click on the \faPowerOff \end{document} ```
6
https://tex.stackexchange.com/users/47927
682903
316,851
https://tex.stackexchange.com/questions/682884
3
I posted the following question [10 years ago](https://tex.stackexchange.com/questions/95600/recommended-workflow-latex-epub-with-math-viewable-on-ipad), and the answers at the time were basically that there wasn't yet any particular good/easy solution, in part because of the immaturity of ePub3. My only real update to the question itself would be that I would add Kindle and other common e-readers as targets along with IOS, again with the primary goal of reliably reproducing complex math, ideally with scalable (not rasterized) renderings. > > I'm looking for a workflow that will take me efficiently and reliably > from existing LaTeX documents (e.g., books) with lots of (sometimes) > complex embedded math to high-quality ePubs that will display nicely > in iBooks under iOS6 and, ideally, on other readers as well (lower > priority). > > > I've been looking at LateXML, TeX4ht, plasTeX, XhtmLaTeX, pandoc, > ebook-convert, and the tbook DTD (which starts with XML rather than > LaTeX and thus looks promising primarily for new documents). All of > these tools seem to have a lot to offer, but none of them, as far as I > can tell, gets me to the finish line without what appears to be > significant manual intervention (implying a need for significant > learning/debugging as well). I haven't been able to decide yet which > pathway is worth investing the time and energy on. Looking forward to > an up-to-date assessment. > > > I'll note that I already published an ePub textbook with equations > rendered as SVG, and it displayed very nicely in iBooks under iOS5. > Unfortunately, iOS6 broke it, and the eBook is now a virtual > paperweight. I'm trying to recover and get the same book back into a > usable ePub format that renders equations nicely. > > > I don't mind investing in a commercial product if it's the least > painful means to solve the problem, but I'd prefer to build a > script-based workflow based on open-source tools for Mac OS X. > > > With another decade behind us since then, it seems likely that options have improved, so I'd welcome an update.
https://tex.stackexchange.com/users/25086
Converting LaTeX doc with extensive math to portable eBook
false
If the Ebook is going to be distributed via a commercial outlet (such as for Kindle) then you probably cannot use any fonts other than the ones built into the reader software. Partly that is avoid potential technical issues, and partly that is to avoid having them re-distribute an embedded font for which they do not have the license. Depending on various factors, some distributors may refuse files with vector graphics, other than the simplest kind. This is unlikely to change in the near future. It is because there are many ways to write vector graphics that will display as intended with some software, but not others. The bug is in the vector graphics, not the reader software. Just as with badly-written HTML, different software may apply different guesses as to what to do. So, if you can get your graphics working on an iPAY$ device, it may be unintelligible on Windows, Linux, Android, and maybe even OSX, or it may depend on which app is used for viewing. And finally: A lot has happened in the past 10 years. Devices now have more screen resolution, much more memory, and much more storage. Depending on how many diagrams/equations you have, and whether they are simply black/white or grayscale/color, it may be practical to rasterize them to PNG. If black/white, they can be rasterized at 1-bit per pixel before PNG compression. If rasterized to 600ppi, an image can be magnified quite a bit before pixelization is noticeable. There's always PDF. I believe that nearly any device (including Kindle) can read it, if it does not rely on exotic features.
1
https://tex.stackexchange.com/users/287367
682906
316,853
https://tex.stackexchange.com/questions/682915
0
How to print the current style (rm, sf, tt) in a give position of a document? ``` \begin{document} \sffamily % print current style -> sf \rmfamily % print current style -> rm \ttfamily % print current style -> tt \end{document} ```
https://tex.stackexchange.com/users/255699
Get current style (rm, sf, tt)
true
do you really want `rm` etc? as latex never has those names even locally. You can access the current family, `\f@family` ``` \documentclass{article} \begin{document} \makeatletter \sffamily \f@family \rmfamily \f@family \ttfamily \f@family \end{document} ``` pdftex: xetex
1
https://tex.stackexchange.com/users/1090
682926
316,861
https://tex.stackexchange.com/questions/682927
0
I have subappendices within each chapter using the `subappendices` command from the `appendix`. I have the appendices show up in my table of contents within each chapter as follows. ``` \AtBeginEnvironment{subappendices}{% \chapter*{Appendix} \addcontentsline{toc}{chapter}{Appendices} \counterwithin{figure}{section} \counterwithin{table}{section} } ``` ``` Chapter 1 Section 1.1 Section 1.2 Appendices Appendix 1.A Chapter 2 ``` How can I create a list of appendices in a separate page (similar to list of figures and tables)?
https://tex.stackexchange.com/users/295048
List of subappendices
false
[toclotf](https://www.ctan.org/pkg/tocloft) lets you create custom lists of counters used in a document. I would recommend to get familiar with the package even though a solution is within the `appendix` package. As an example, here's the code with a custom counter `subappendix`, which is used in a new list of appendices. You can print the list either on the current or a new page if you append `\clearpage` before \listof...`. ``` \documentclass{book} \usepackage{etoolbox} \usepackage{kantlipsum} \usepackage{tocloft} \newlistof[chapter]{subappendix}{apx}{List of Appendices} \renewcommand{\thesubappendix}{Appendix \thechapter.\Alph{subappendix}} \newcommand\appx[1]{% \refstepcounter{subappendix}% \section*{\thesubappendix\enspace#1}% \addcontentsline{apx}{subappendix}{\protect\numberline{\thesubappendix} #1}\par} \renewcommand{\cftsubappendixnumwidth}{7em} \title{The title} \author{First Last} \date{} \begin{document} \maketitle \tableofcontents \clearpage \listofsubappendix \chapter{The first chapter} \kant[9][1] \section{A regular section} \kant[10] \section{Another regular section} \kant[11] \appx{This is an appendix} \kant[1] \appx{This is another appendix} \kant[2] \chapter{The second chapter} \kant[11][1] \section{A regular section} \kant[12] \section{Another regular section} \kant[13] \appx{This is an appendix in another chapter} \kant[3] \appx{This is another appendix} \kant[4] \appx{This is the last appendix} \kant[5] \end{document} ```
1
https://tex.stackexchange.com/users/31283
682934
316,866
https://tex.stackexchange.com/questions/682940
0
The following latex input: ``` \documentclass{article} \pagestyle{myheadings} \markright{\ifodd\thepage ODD HEADER on \thepage\else EVEN HEADER on \thepage\fi} ``` outputs "ODD HEADER on 1" on all pages, apparently because \thepage is 1 when \markright is executed. How can I fix this (preferably without using fancyhdrs)?
https://tex.stackexchange.com/users/294710
value of \thepage in \markright is always 1
false
`\markright` expand its argument. In the time you wrote the line ``` \markright{\ifodd\thepage ODD HEADER on \thepage\else EVEN HEADER on \thepage\fi} ``` `\thepage` was equal 1, so after expansion the information the is stored in the node is `ODD HEADER on 1`. You can solve that by storing `\ifodd\thepage ODD HEADER on \thepage\else EVEN HEADER on \thepage\fi` in a protected macro: ``` \documentclass{article} \pagestyle{myheadings} \NewDocumentCommand\Tim{}{\ifodd\thepage ODD HEADER on \thepage\else EVEN HEADER on \thepage\fi} \markright{\Tim} \begin{document} hello \newpage hello\newpage hello \end{document} ```
0
https://tex.stackexchange.com/users/264024
682942
316,869
https://tex.stackexchange.com/questions/682950
0
I want the figure to rotate. ``` \begin{figure} \begin{tikzpicture} \coordinate (A) at (0,0); \coordinate (B) at (1,-2); \coordinate (C) at (3,2); \draw[thin, dashed](A)node[left]{A}--(B)node[below]{B}--(C)node[above]{C}--cycle; \draw[thick,rotate around={90:(B)}](A)node[left]{A}--(B)node[below]{B}--(C)node[above]{C}--cycle; \end{tikzpicture} \end{figure} ``` But, The figure doesn't rotate.
https://tex.stackexchange.com/users/284985
How to rotate triangle in Tikz?
true
Try: ``` \begin{tikzpicture}[rotate=30] \coordinate (A) at (0,0); \coordinate (B) at (1,-2); \coordinate (C) at (3,2); \draw[thin, dashed,](A)node[left]{A}--(B)node[below]{B}--(C)node[above]{C}--cycle; \draw[thick,rotate around={90:(B)}](A)node[left]{A}--(B)node[below]{B}--(C)node[above]{C}--cycle; \end{tikzpicture} ```
0
https://tex.stackexchange.com/users/24644
682951
316,874
https://tex.stackexchange.com/questions/682940
0
The following latex input: ``` \documentclass{article} \pagestyle{myheadings} \markright{\ifodd\thepage ODD HEADER on \thepage\else EVEN HEADER on \thepage\fi} ``` outputs "ODD HEADER on 1" on all pages, apparently because \thepage is 1 when \markright is executed. How can I fix this (preferably without using fancyhdrs)?
https://tex.stackexchange.com/users/294710
value of \thepage in \markright is always 1
false
As explained already `\markright` expands at time of definition. Here is syntax for legacy LaTeX. Although `\ifodd` is I presume not official LaTeX, it is core TeX (hence I allowed myself `\noexpand` which is not LaTeX either). ``` \documentclass{article} % only for screenshot purposes \usepackage[paperheight=4cm,height=2cm,includehead,nofoot]{geometry} \pagestyle{myheadings} \markright{\noexpand\ifodd\value{page}% ODD HEADER on \protect\thepage \noexpand\else EVEN HEADER on \protect\thepage \noexpand\fi} \begin{document} A \clearpage B \clearpage C \end{document} ``` Mind that I avoided `\thepage` in the `\ifodd` test as `\thepage` is not guaranteed to be compatible with TeX numerical context.
0
https://tex.stackexchange.com/users/293669
682952
316,875
https://tex.stackexchange.com/questions/682881
1
When I try to compile a file using XeLaTeX and fontspec that uses the Dejavu Sans font (that's of course not already installed in the MacOS system), by `\usepackage{pifont}`, or if I want to use the font CMU Serif by `\setsansfont{CMU Serif}`, fontspec cannot find the fonts (error `Package fontspec Error: The font "CMU Serif" cannot be found.`). I'm aware that one workaround is to add the directory that provides these fonts (`/Library/TeX/Root/texmf-dist/fonts/opentype`) as a symlink inside `~/Library/Fonts`. However, doing so breaks some websites on Firefox (likely due to sandboxing and duplicate font issues), and Firefox is really that much more crucial than latex. It's not possible that there is no other solution apart from either specifying the file path for each font or causing trouble on my entire MacOS system installation, to force `fontspec` to find a custom directory with fonts... Can anyone please help resolve this? Related issue describing in more detail the conundrum: [Fontspec package can't find "Latin Modern Mono" on MacOS/MacTeX](https://tex.stackexchange.com/questions/400699/fontspec-package-cant-find-latin-modern-mono-on-macos-mactex)
https://tex.stackexchange.com/users/295027
MacOS Font Loading with XeTeX and fontspec fails
false
(a bit too long for comment) The [fontspec](https://ctan.org/pkg/fontspec) manual mentions in **2.2 By file name** how to load by filename which is not quite same as a full file path. For example on my system ``` \documentclass{article} \usepackage{fontspec} %\XeTeXtracingfonts1 \setmainfont{DejaVuSans}[ Extension = .ttf, BoldFont = *-Bold, ItalicFont = *-Oblique, BoldItalicFont = *-BoldOblique ] \begin{document} abcde \textit{abcde} \textbf{abcde} \textbf{\textit{abcde}} \end{document} ``` I used the `\XeTeXtracingfonts1` in a first pass to have all details in the log file with using syntax `\setmainfont{DejaVu Sans}` and the symlinks in place. Then I could identify the font basenames (alternatively use the FontBook to get them). Problem with the above is specifying the extension. I think I once had a problem (*warning: I doubt very much my own paragraph here, because TeXLive will have same structure everywhere, so it must have been some other context where the fonts were not in TeXLive or were installed system wide on one computer and from TeXLive in another*) of portability because on some system the font used was installed with `.otf` extension (i.e. in `texmf-dist/fonts/opentype`) and on some other with `.ttf` (in `texmf-dist/fonts/truetype`). Reading (again) **2.2 By file name** it appears perhaps the better syntax would be here: ``` \usepackage{fontspec} \XeTeXtracingfonts1 \setmainfont{DejaVuSans}[ Path, BoldFont = *-Bold, ItalicFont = *-Oblique, BoldItalicFont = *-BoldOblique ] \begin{document} abcde \textit{abcde} \textbf{abcde} \textbf{\textit{abcde}} \end{document} ``` This works on my mac os after having removed the symlink to `texmf-dist/fonts/truetype` but not sure if there is some cache involved. A priori it should work on pristine install also.
1
https://tex.stackexchange.com/users/293669
682955
316,877
https://tex.stackexchange.com/questions/682961
1
I want to build a \dotfill command where I can specify a minimum length. I have tried: ``` \makebox[0.88em]{\dotfill}\dotfill ``` As the standard spacing of dotfill is 0.44em, so I get exactly two dots. However, there is a slightly bigger spacing between the first two dots and the dots from the second \dotfill command. Does anyone have an idea how I can solve that?
https://tex.stackexchange.com/users/295013
\dotfill with minimal length
true
you can copy the definition of `\dotfill` replacing `\hfill` by skip with a larger natural size: ``` \documentclass{article} %\def\dotfill{% % \leavevmode % \cleaders \hb@xt@ .44em{\hss.\hss}\hfill % \kern\z@} % \MakeRobust\dotfill \DeclareRobustCommand\mydotfill{% \leavevmode \cleaders \hbox to.44em{\hss.\hss}\hskip .88em plus 1fill \kern0pt } \begin{document} 1 a\dotfill b 2 a\dotfill b\hspace{0pt plus 1filll}c {\parfillskip=.5\textwidth minus .5\textwidth 3 a\dotfill b } 4 a\mydotfill b 5 a\mydotfill b\hspace{0pt plus 1filll}c {\parfillskip=.5\textwidth minus .5\textwidth 6 a\mydotfill b } \end{document} ```
4
https://tex.stackexchange.com/users/1090
682965
316,882
https://tex.stackexchange.com/questions/682814
1
Many writing systems / scripts, including Latin and Cyrillic, have one or more cursive forms, where letters are connected, with forms depend on the letters before and after them. While one can create somewhat-grotesque rough approximations of such writing (see [this question](https://tex.stackexchange.com/q/291313/5640) for example) by relying on a small number of fixed glyphs as the different forms of a character - this actually requires more careful modeling, involving continuous rather than discrete spaces of parameters of glyph-forms, the possibility of adjusting lengths and heights of connective glyph-curves for connection to the previous and next glyph etc. In some cursive systems, the vertical position also varies as one moves forward along a word, so that words or lines move in a diagonal rather than on a straight line (see [this example](https://en.wikipedia.org/wiki/Nastaliq#/media/File:Khatt-e_Nastaliq.jpg) of Nasta'liq Arabic script). Do any of the layout engines in the TeX world support cursive typesetting, even in a single writing system? Do any font representation systems support it? If not, are there plans or project to introduce such support?
https://tex.stackexchange.com/users/5640
Does any of the TeX engines support proper cursive typesetting?
false
Both LuaLaTeX and XeLaTeX support any OpenType feature that HarfBuzz does, including the initial and medial forms of cursive (and Arabic).
0
https://tex.stackexchange.com/users/61644
682966
316,883
https://tex.stackexchange.com/questions/682941
0
I am using `datatool` to read `csv` file and get values from it. I also want to use these values in a chapter names. I have no problems with `TOC` and pages. I can see values from my csv file. But `bookmarks` create by `hyperref` (I think) have only `PK`/indexes, but not values from csv file. Additionally I have got this warning: `Package hyperref Warning: Token not allowed in a PDF string.` My values in csv file have only A-Za-z0-9 letters and not special Unicode symbols like `\sqrt`. Here is my sample code that can show the issue. ``` %&xelatex % !TEX program = xelatex \documentclass{book} \usepackage{polyglossia} \usepackage{fontspec} \usepackage{noto-mono} % to support hyperref package \usepackage{amsmath,amsthm,amssymb,mathrsfs,amsfonts,dsfont} \usepackage{hyperref} \hypersetup{ colorlinks=true, linkcolor=blue, filecolor=magenta, urlcolor=blue, } \usepackage{datatool} \author{Some} \title{Any} \begin{filecontents*}{data.csv} PK,Value 1,Val1 2,Val2 \end{filecontents*} \DTLloaddb{values}{data.csv} \ExplSyntaxOn \NewDocumentCommand{\getValue}{m}{\DTLfetch{values}{PK}{#1}{Value}} \ExplSyntaxOff \begin{document} \frontmatter \tableofcontents \mainmatter \chapter{AAA \getValue{1}} \chapter{BBB \getValue{2}} \end{document} ```
https://tex.stackexchange.com/users/294709
Package hyperref Warning: Token not allowed in a PDF string. Using value from CSV in TOC
false
your \getValue command is not expandable, and \DTLfetch is not expandable either (most datatools command aren't). You need to store your data in a way that they can be retrieved in an expandable way. ``` \documentclass{book} \usepackage{hyperref} \hypersetup{ colorlinks=true, linkcolor=blue, filecolor=magenta, urlcolor=blue, } \usepackage{datatool} \author{Some} \title{Any} \begin{filecontents*}[force]{data.csv} PK,Value 1,Val1 2,Val2 \end{filecontents*} \DTLloaddb{values}{data.csv} \ExplSyntaxOn \prop_new:N\g_sergei_data_prop \NewDocumentCommand{\storeValue}{mm}{\prop_gput:NVV\g_sergei_data_prop#1#2} \NewExpandableDocumentCommand{\getValue}{m}{\prop_item:Nn\g_sergei_data_prop{#1}} \ExplSyntaxOff \DTLforeach{values}{\mynum=PK,\myval=Value}{\storeValue\mynum\myval} \begin{document} \frontmatter \tableofcontents \mainmatter \chapter{AAA \getValue{1}} \chapter{BBB \getValue{2}} \end{document} ``` (If a prop is the right data container depends on your actual use case)
2
https://tex.stackexchange.com/users/2388
682971
316,885
https://tex.stackexchange.com/questions/682975
3
``` \documentclass[12pt] {article} \usepackage{amsmath} \usepackage{amssymb} \usepackage{booktabs} \def\baselinestretch{2.0} \setlength{\textwidth}{18cm} \setlength{\textheight}{21cm} \setlength{\evensidemargin}{-0.15cm} \setlength{\oddsidemargin}{-0.15cm} \begin{document} \begin{flalign*} &\text{Now}\; u(x,0)=\sin (2\pi x)&&\\ &\Longrightarrow\; \sum_{n=1}^\infty a_n \sin \left(n\pi x\right)=\sin (2\pi x)\\ &\Longrightarrow\;a_2=1\; \text{and all others $a_n's$ are zero.}\\ &\text{Hence the solution is}: u(x,t)= e^{- 4\pi^2t}\sin \left(2\pi x\right) \addlinespace[0.5cm] \end{flalign*} \textbf{Problem-3:} Solve: \end{document} ``` I want to add some vertical whitespace locally after `end{flalign*}`. So I added `\addlinespace[0.5cm]`. But it's not working.
https://tex.stackexchange.com/users/214287
Adding vertical whitespace after equation
true
I suggest you insert `\bigskip` -- or, if that's too much, `\medskip` or even `\smallskip` -- right before `\textbf{Problem 3.}`. I would also replace `\def\baselinestretch{2.0}` with ``` \usepackage[nodisplayskipstretch]{setspace} \setstretch{2.0}` ``` ``` \documentclass[12pt]{article} \usepackage{amsmath,amssymb} %\def\baselinestretch{2.0} \usepackage[nodisplayskipstretch]{setspace} \setstretch{2.0} \setlength{\textwidth}{18cm} \setlength{\textheight}{21cm} \setlength{\evensidemargin}{-0.15cm} \setlength{\oddsidemargin}{-0.15cm} \begin{document} \noindent \dots % no blank line immediately before '\begin{align*}' \begin{align*} &\text{Now } u(x,0)=\sin (2\pi x)\\ &\Longrightarrow\; \sum_{n=1}^\infty a_n\sin(n\pi x)=\sin(2\pi x)\\ &\Longrightarrow\;a_2=1 \text{ and all other $a_n$'s are zero.}\\ &\text{Hence the solution is: $u(x,t)= e^{-4\pi^2t}\sin (2\pi x)$} \end{align*} \bigskip % <-- or \medskip, \smallskip, or whatever \noindent \textbf{Problem 3.} Solve \dots \end{document} ```
4
https://tex.stackexchange.com/users/5001
682977
316,888
https://tex.stackexchange.com/questions/682980
1
My goal is to install commercial font GT-America to use with TeX. The font consist of several *.otf* files. **What I did so far:** * Installed all the fonts using *sudo autoinst* * Ran *sudo texhash* and *sudo updmap -sys* afterwards * Ran *pdflatex* with my sample document **The error that occured:** If I run *pdflatex* for my file, it almost finishes, but then it gets stuck on this error: ``` --mfmode / --bdpi 600 --mag 1+150/600 --dpi 750 GTAmerica-CondensedBold-lf-t1--base mktexpk: don't know how to create bitmap font for GTAmerica-CondensedBold-lf-t1--base. mktexpk: perhaps GTAmerica-CondensedBold-lf-t1--base is missing from the map file. ``` **What I've tried to solve the issue:** * Cleaned the config file in my directory * Took a look at the map folder in /usr/share/texmf/fonts/map/dvips/GTAmerica, the font seems to be there **My setup:** Linux 6.2.10-1-MANJARO (64-bit) TeX 3.141592653 (TeX Live 2023/Arch Linux) kpathsea version 6.3.5 If anybody has a clue or could point me to the right direction, I'd be really grateful.
https://tex.stackexchange.com/users/295083
TeX: mktexpk: don't know how to create bitmap font
false
The `updmap-sys --enable Map=GTAmerica.map` command worked after issuing `sudo texhash` and `sudo updmap-sys`. After that the file gets compiled even with pdflatex.
0
https://tex.stackexchange.com/users/295083
682982
316,889
https://tex.stackexchange.com/questions/682923
0
The best way to built a bibliographic style seems to rely on the use of makebst. However, most likely, you can make a formatting mistake in choosing among the numerous options that you need to set. But several posts on the forum tell that editing the .dbj file by any editor it is possible to make some adjustments to obtain the result you were looking for following a trial-and-error procedure. I tried all this. Unfortunately, the .dbj file I got seems to contain only a list of options but not the choice that I made during the generation of the .bst. As example, I report here the line which seems related to the date format about the year: %DATE FORMAT (if author-year citations)% %: (def) Year plain yr-par,%: Year in parentheses% yr-brk,%: Year in brackets% yr-col,%: Year preceded by colon% yr-per,%: Year preceded by period% yr-com,%: Date preceded by comma% yr-blk,%: Year preceded by space% But where is the choice I made so that I could modify it an produce an other .bst from this modified .bdj? Many thanks.
https://tex.stackexchange.com/users/273692
Modify a .bdj file to obtain a new .bst
true
The `.bdj` file is a TeX file, so all lines starting with `%` are comments. `makebst` uses this to list all possible options and comment not chosen options by adding a `%` in the first column, while lines of the chosen options start with a . So e.g. ``` %DATE FORMAT (if author-year citations) % %: (def) Year plain yr-par,%: Year in parentheses % yr-brk,%: Year in brackets % yr-col,%: Year preceded by colon % yr-per,%: Year preceded by period % yr-com,%: Date preceded by comma % yr-blk,%: Year preceded by space ``` has a space at the beginning of the line `yr-par,%: Year in parentheses`, so you chose "Year in parentheses". If you want to change this, replace the first space in the currently selected line with a `%` and the `%` in the newly selected line with . E.g. to select "Year in brackets", you would change the block to ``` %DATE FORMAT (if author-year citations) % %: (def) Year plain % yr-par,%: Year in parentheses yr-brk,%: Year in brackets % yr-col,%: Year preceded by colon % yr-per,%: Year preceded by period % yr-com,%: Date preceded by comma % yr-blk,%: Year preceded by space ```
2
https://tex.stackexchange.com/users/80496
682987
316,891
https://tex.stackexchange.com/questions/682984
2
I have this example where I want to draw a line in the background from corner to opposite corner of the page using `metapost`, The problem is that the line does not reach both ends, and I cannot figure out what is missing ``` % lualatex \documentclass{article} \usepackage{luamplib} \AddToHook{shipout/background} {% \put(0,-\paperheight){% \begin{mplibcode} beginfig(1); draw origin -- (\the\paperwidth,\the\paperheight); endfig; \end{mplibcode} } } \begin{document} text \end{document} ```
https://tex.stackexchange.com/users/54817
Line from lower left to upper right corner of page with metapost
true
If you look carefully at your output you may see that there is a mismatch here between a4 (210mm x 297mm) and letter (8.5in x 11in). Your PDF appears to have a4 paper, but `paperheight` and `paperwidth` are set for letter paper. Your example works just fine if I explicitly set `a4paper` and add a magic 2pt shift left. ``` % lualatex \documentclass[a4paper]{article} \usepackage{luamplib} \AddToHook{shipout/background} {% \put(-2,-\paperheight){ \begin{mplibcode} beginfig(1); drawdblarrow (origin -- (\the\paperwidth,\the\paperheight)); endfig; \end{mplibcode} } } \begin{document} text \end{document} ``` I added the arrow heads just to show the ends of the line. But the actual solution is to add the `geometry` package. One of the useful things that this does is to normalize the PDF paper sizes so that they match the LaTeX paper sizes. It is quite surprising that the standard classes do not do this! But if you just add `\usepackage{geometry}` your example will work as expected: ``` % lualatex \documentclass{article} \usepackage{geometry} \usepackage{luamplib} \AddToHook{shipout/background} {% \put(0,-\paperheight){% \begin{mplibcode} beginfig(1); draw origin -- (\the\paperwidth,\the\paperheight); endfig; \end{mplibcode} } } \begin{document} text \end{document} ``` Compiling this produces:
3
https://tex.stackexchange.com/users/15036
682988
316,892
https://tex.stackexchange.com/questions/682689
0
I am sure that I overlooked something very obvious. Still, why does the example in [this nice answer](https://tex.stackexchange.com/a/359320/47927) work, but if I remove the loop, I get an error about a grouping mismatch? Consider the following minimal non-working example: ``` \documentclass{article} \begin{filecontents}{\jobname.bib} @article{testref, author = {Miller, Alice and Highlight, Shine and Smith, Bob}, title = {The title}, journal = {The journal}, pages = {65--78}, year = 2014} \end{filecontents} \usepackage{xpatch} \usepackage[normalem]{ulem} \usepackage[backend=biber,bibencoding=utf8,style=numeric-comp,maxbibnames=99]{biblatex} \addbibresource{\jobname.bib} \newbox\savenamebox % does not work \newbibmacro*{name:bbold}[2]{% \iffieldequalstr{hash}{01b588ba4e4ad753feae6c81709fc04b}% {\bfseries\setbox\savenamebox\hbox\bgroup\listbreak}{}% } \newbibmacro*{name:ebold}[2]{% \iffieldequalstr{hash}{01b588ba4e4ad753feae6c81709fc04b}% {\egroup\uline{\usebox\savenamebox}\listbreak}{}% } % === \xpatchbibmacro{name:given-family}{\usebibmacro{name:delim}{#2#3#1}}{\usebibmacro{name:delim}{#2#3#1}\begingroup\usebibmacro{name:bbold}{#1}{#2}}{}{} \xapptobibmacro{name:given-family}{\usebibmacro{name:ebold}{#1}{#2}\endgroup}{}{} \begin{document} \nocite{*} \printbibliography \end{document} ``` The original code has instead ``` \newbibmacro*{name:bbold}[2]{% \def\do##1{\iffieldequalstr{hash}{##1}{\bfseries\setbox\savenamebox\hbox\bgroup\listbreak}{}}% \dolistloop{\boldnames}% } \newbibmacro*{name:ebold}[2]{% \def\do##1{\iffieldequalstr{hash}{##1}{\egroup\uline{\usebox\savenamebox}\listbreak}{}}% \dolistloop{\boldnames}% } \newcommand*{\boldnames}{} \forcsvlist{\listadd\boldnames}{ {4fcd4bca11ef811f3aef17c792b6ef3e}, {01b588ba4e4ad753feae6c81709fc04b}} ``` This works well. But why is this? Does the loop somehow delay expansion so that the grouping mismatch is irrelevant? How could I get a working example without a loop?
https://tex.stackexchange.com/users/47927
Grouping mismatch if loop is dissolved
true
The problem, as pointed out in the comments (thanks to [user691586](https://tex.stackexchange.com/users/293669/user691586)), is that I forgot to remove the `\listbreak` macros from the original code which are somehow used for processing the CSV list and which are not needed here any more. Without these, the code works fine: ``` \documentclass{article} \begin{filecontents}{\jobname.bib} @article{testref, author = {Miller, Alice and Highlight, Shine and Smith, Bob}, title = {The title}, journal = {The journal}, pages = {65--78}, year = 2014} \end{filecontents} \usepackage{xpatch} \usepackage[normalem]{ulem} \usepackage[backend=biber,bibencoding=utf8,style=numeric-comp,maxbibnames=99]{biblatex} \addbibresource{\jobname.bib} \newbox\savenamebox \newbibmacro*{name:bbold}[2]{% \iffieldequalstr{hash}{01b588ba4e4ad753feae6c81709fc04b}% {\bfseries\setbox\savenamebox\hbox\bgroup}{}% } \newbibmacro*{name:ebold}[2]{% \iffieldequalstr{hash}{01b588ba4e4ad753feae6c81709fc04b}% {\egroup\uline{\usebox\savenamebox}}{}% } \xpatchbibmacro{name:given-family}{\usebibmacro{name:delim}{#2#3#1}}{\usebibmacro{name:delim}{#2#3#1}\begingroup\usebibmacro{name:bbold}{#1}{#2}}{}{} \xapptobibmacro{name:given-family}{\usebibmacro{name:ebold}{#1}{#2}\endgroup}{}{} \begin{document} \nocite{*} \printbibliography \end{document} ```
0
https://tex.stackexchange.com/users/47927
683000
316,896
https://tex.stackexchange.com/questions/680997
2
I'm trying use the asymptote package with vimtex, it's the first time I try it. When I try to compile, the figure doesn't appear at all in the pdf. This is an example code I found to test: ``` \usepackage[inline]{asymptote} % I've also tried without [inline] but I get the same results ... \begin{asy} settings.outformat = "pdf"; defaultpen(fontsize(10pt)); label("Hello world!"); \end{asy} ``` The only warning I get is ``` Package asymptote Warning: file `***-1.pdf' not found on input line 30. ``` The `myfile-*.asy` files do appear in the folder. I found [this issue](https://github.com/lervag/vimtex/issues/1113) in the vimtex github where they suggest using a latexmkrc file with ``` sub asy {return system("asy \"$_[0]\"");} add_cus_dep("asy","eps",0,"asy"); add_cus_dep("asy","pdf",0,"asy"); add_cus_dep("asy","tex",0,"asy"); ``` I tried putting this file in the folder I'm working on but it makes the vimtex compilation fail inmediately. Update: Running `asy myfile-1.asy` in the terminal returns this error: ``` no matching variable 'byteinv' no matching variable '_schur' ``` To fix this I've manually updated to 2.85, because was using the MiKTeX version 2.81 which didn't work properly. Now it works if I run `asy myfile-1.asy` manually, but vimtex doesn't do it automatically.
https://tex.stackexchange.com/users/293806
Asymptote figures don't appear with vimtex
true
The problem is the `.asy` files can't compile because apparently the MiKTeX distribution of Asymptote doesn't have compatible files and executable, as pointed out [here](https://sourceforge.net/p/asymptote/discussion/409349/thread/909cd01735/#b805). Instead, download and install Asymptote from [here](https://sourceforge.net/projects/asymptote/) and copy the files from `C:\Program Files\Asymptote` (not sure if you need all the files but it works for me) into the same directory as the incompatible version (`C:\Users\David\AppData\Local\Programs\MiKTeX\miktex\bin\x64` in my case) (there might be another way to use the correct executable without copying the files, but that's beyond my knowledge). I think you also need to rename the `asy.exe` file you copied to `miktex-asy.exe`. Now you can compile the `.asy` files by executing them with the Asymptote program or in a terminal with `asy myfile-*.asy`. Vimtex uses latexmk by default. In order to automatically compile the `myfile-*.asy` files when compiling with vimtex, you need to add a `.latexmkrc` file in the directory you're working on with the following: ``` sub asy {return system("asy \"$_[0]\"");} add_cus_dep("asy","eps",0,"asy"); add_cus_dep("asy","pdf",0,"asy"); add_cus_dep("asy","tex",0,"asy"); ```
1
https://tex.stackexchange.com/users/293806
683003
316,897
https://tex.stackexchange.com/questions/682993
0
I'm using TeX Live right now on ArchLinux with VS Code and [James Yu's LaTeX Workshop](https://marketplace.visualstudio.com/items?itemName=James-Yu.latex-workshop) or `pdflatex`. Here is my `latex-v`: ``` pdfTeX 3.141592653-2.6-1.40.25 (TeX Live 2023/Arch Linux) kpathsea version 6.3.5 Copyright 2023 Han The Thanh (pdfTeX) et al. There is NO warranty. Redistribution of this software is covered by the terms of both the pdfTeX copyright and the Lesser GNU General Public License. For more information about these matters, see the file named COPYING and the pdfTeX source. Primary author of pdfTeX: Han The Thanh (pdfTeX) et al. Compiled with libpng 1.6.39; using libpng 1.6.39 Compiled with zlib 1.2.13; using zlib 1.2.13 Compiled with xpdf version 4.04 ``` I've tried many ways of using Garamond (e.g. `\usepackage{ebgaramond}`), which is supposedly packed in TeX Live as far as I know. When I run it on VS Code, I get: ``` File `ebgaramond.sty' not found. ``` What am I missing? Do I need to install extra stuff? (I've installed TeX Live through AUR's [`texlive-full`](https://aur.archlinux.org/packages/texlive-full))
https://tex.stackexchange.com/users/64441
Can't Find Garamond Font
false
Can you switch to the `lualatex` compiler, and use the `fontspec` package for loading fonts? With `fontspec` you can load fonts directly by font name, even if it is a system (rather than TeX) font. When you write `\usepackage` or `\RequestPackage` TeX looks for a `*.sty` file. Even if you are looking for fonts, it will look for `FontName.sty` rather than `FontName.otf` or other font type. Some font packages require their own `*.sty` file, which contains information about math substitutions and other stuff. Some font packages may provide a dummy `*.sty` file, just in case TeX looks for it. Try this, compiled with `lualatex` not `pdflatex` (and be sure that everything is utf-8 encoded): ``` \documentclass{article} \usepackage{fontspec} \setmainfont{EB Garamond} % Assumes that you have the fonts already. \begin{document} Hello, World! \end{document} ```
1
https://tex.stackexchange.com/users/287367
683006
316,898
https://tex.stackexchange.com/questions/682874
1
I feel exhausted and frustrated from trying to use some of the fonts from: <https://tug.org/FontCatalogue/> , e.g. Calligraphical and Handwritten Fonts, Other (mostly decorative) Fonts, etc. I have tried many of the comments/suggestions from tex.stackexchange.com and I still fail :-(. I have carefully examined the log files but nothing I saw in them was the "key" to solving the problems associated with the LaTeX code. I have been using LaTeX for over 40 years and thought I could find at least one possible solution; but, now I must stop working on this. Please, I beg of you, take a close look at why there are so many font problems being reported with miktex 22, 23 and see if there is a fix that really works. I am using **miktex 4.9 console** in the administrator mode. I have reinstalled miktex at least 7 times by now -- still font problems. The following is taken from the **System Report.txt** file generated by TeXstudio 4.5.1 (git 4.5.1) Using Qt Version 6.4.2, compiled with Qt 6.4.2 RTeXstudio (4.5.1): dpi: 96 where pdflatex: C:\Program Files\MiKTeX\miktex\bin\x64\pdflatex.exe PDFLATEX: pdflatex.exe -version MiKTeX-pdfTeX 4.14 (MiKTeX 23.1) I will prepare an example that should be helpful in finding the problems associated with "special" fonts in TeXstudio. > > ***How can I upload the tex file for this example to be prepared?*** > > >
https://tex.stackexchange.com/users/80252
How to use the different fonts available for LaTeX -- miktex (23.1) on a windows 10 platform?
false
I will take the wild guess that since you have been using TeX for 40 years, you are still trying to do things the ancient way. Can you compile with `lualatex`? Yes, it's in MiKTeX. You text must be utf-8 encoded (I believe even Windows does that, nowadays). Your fonts must be `*.otf` or `*.ttf` but NOT the old Type 1 PostScript fonts. They do not need to come from TeX (even system fonts will work). Try this, compiled with `lualatex`: ``` \documentclass{article} \usepackage{fontspec} \setmainfont{Your Favorite Font} % Actual font name. \begin{document} Hello, World! \end{document} ``` Now, some TeX fonts are not available as `*.otf` or `*.ttf`. In this case, you can use the `FontForge` program to import the existing font format, and convert it to `*.otf` (Open Type). BIG EDIT: I can get Starburst to work. Do these things: 1. Download the `initials` zip package directly from CTAN. Unzip it in your home directory (not within TeX). 2. Install FontForge. Open file `Starburst.pfb` in FontForge. 3. FontForge Menu Encoding > Reencode > Unicode (BMP). 4. Edit > Select > Select All. 5. Element > Correct Direction. 6. Hints > Clear Hints. 7. Element > Overlap > Remove Overlap. 8. Element > Font Info > PS Private > New > BlueValues 9. File > Generate Fonts > choose OpenType (CFF). You will get a dialog box informing you that there are missing extrema, wrong direction, self-intersection. Ignore that, and generate the font. The messages are meaningful, but not worth fixing without expertise. Then you will have Starburst.otf. It is an OpenType font. In a place such as your TEXMFHOME directory, create fonts/opentype/initials and drop a copy of Starburst.otf in there. Then refresh the files (MiKTeX has a button to press, Linux uses command `mktexlsr`). Do not `\usepackage{initials}` or `starburst` or anything of the sort. Instead, compile with lualatex, like this: ``` \documentclass{article} \usepackage{fontspec} \setmainfont{EB Garamond} % or whatever \newfontface\shazam{Starburst} \begin{document} {\shazam Hello World !}\par And hello to Martians, too.\par \end{document} ``` Result: Ok @rallg, Your procedure for using FontForge, although rather complex, worked and the following Latex code worked with Texstudio and Texmaker :-). ``` \documentclass{article} \usepackage{fontspec} \setmainfont{Lucida Sans} % or whatever \newfontface\shazam{Starburst-Regular} \begin{document} {\shazam Hello World !}\par And hello to Martians, too.\par \end{document} ``` I still can not understand how to add a comment on someone else's comment. Example, if I hit a CR (carriage return) for a new line, then my comment on their comment is posted -- this is not what should happen IMHO!
2
https://tex.stackexchange.com/users/287367
683009
316,899
https://tex.stackexchange.com/questions/683014
0
``` \documentclass[a4paper, twoside,12pt]{article} \usepackage[margin=1.5cm]{geometry} \usepackage{polyglossia} \setdefaultlanguage{arabic} \setotherlanguage{english} \setmainfont{amiri} \usepackage{multicol} \newcommand{\ar}{\textarabic} \newcommand{\en}{\textenglish} \usepackage{luamplib} \everymplib{input mpchess} \begin{document} \section{مقدمة} \LARGE لدي طموح بأني سأستطيع استخدام حزم الشطرنج في لاتيك لإنتاج كتيب جميل عن الشطرنج يوماً ما. \begin{mplibcode} string pgnstr; pgnstr := "1. e4 e5 2. Nf3 Nc6 3. Nxe5 Nxe5 4. Bb5 c6"; build_chessboards_from_pgn(pgnstr); beginfig(0); set_color_theme("BrownLichess"); set_coords_outside; init_backboard; draw backboard; show_last_move(3); draw chessboard_step(3); %init_chessboard; %draw chessboard; %draw_arrows(red)("e7--h5","g1|-e5"); endfig; \end{mplibcode} وذلك عندما أجد حلاً لمشكلة ظهور الرقعة خارج الصفحة في حزمة \en {mpchess} \end{document} ```
https://tex.stackexchange.com/users/189636
why mpchess generated board is out of the page here is the simplest code possible
false
the chessboard isn't bidi aware. You could try with babel and switch to english (and so LTR) for the board: ``` \documentclass[a4paper, twoside,12pt]{article} \usepackage[margin=1.5cm]{geometry} \usepackage[english,arabic, provide=*, bidi=basic, layout=counters.tabular]{babel} \babelfont{rm}[Renderer=Harfbuzz]{amiri} \usepackage{multicol} \newcommand{\ar}{\textarabic} \newcommand{\en}{\foreignlanguage{english}} \usepackage{luamplib} \everymplib{input mpchess} \begin{document} \section{مقدمة} \LARGE لدي طموح بأني سأستطيع استخدام حزم الشطرنج في لاتيك لإنتاج كتيب جميل عن الشطرنج يوماً ما. \en{% \begin{mplibcode} string pgnstr; pgnstr := "1. e4 e5 2. Nf3 Nc6 3. Nxe5 Nxe5 4. Bb5 c6"; build_chessboards_from_pgn(pgnstr); beginfig(0); set_color_theme("BrownLichess"); set_coords_outside; init_backboard; draw backboard; show_last_move(3); draw chessboard_step(3); %init_chessboard; %draw chessboard; %draw_arrows(red)("e7--h5","g1|-e5"); endfig; \end{mplibcode} } % \selectlanguage{arabic} وذلك عندما أجد حلاً لمشكلة ظهور الرقعة خارج الصفحة في حزمة \en {mpchess} \end{document} ```
4
https://tex.stackexchange.com/users/2388
683019
316,903
https://tex.stackexchange.com/questions/682185
1
I downloaded the ISO image of TeXlive 2023 (specifically, texlive2023-20230313.iso). I also checked the SHA512 sum, and it was good. This ISO was too big to unpack onto any DVD\_RW that I had on hand, so I used Gnome MultiWriter to "burn" the ISO to the USB. This was accomplished without any error. Using root privileges, I issued the command `# perl install-tl -gui`. Rather than getting the GUI (despite the fact that I have Tcl/Tk installed), a message flashed by, in the gist of `cannot execute wish...` but this was not retrievable. I then got the interface, below: ``` ======================> TeX Live installation procedure <===================== ======> Letters/digits in <angle brackets> indicate <======= ======> menu items for actions or customizations <======= = help> https://tug.org/texlive/doc/install-tl.html <======= Detected platform: GNU/Linux on x86_64 <B> set binary platforms: 2 out of 6 <S> set installation scheme: scheme-full <C> set installation collections: 41 collections out of 41, disk space required: 8065 MB (free: 118421 MB) <D> set directories: TEXDIR (the main TeX directory): !! default location: /usr/local/texlive/2023 !! is not writable or not allowed, please select a different one! TEXMFLOCAL (directory for site-wide local files): /usr/local/texlive/texmf-local TEXMFSYSVAR (directory for variable and automatically generated data): /usr/local/texlive/2023/texmf-var TEXMFSYSCONFIG (directory for local config): /usr/local/texlive/2023/texmf-config TEXMFVAR (personal directory for variable and automatically generated data): ~/.texlive2023/texmf-var TEXMFCONFIG (personal directory for local config): ~/.texlive2023/texmf-config TEXMFHOME (directory for user-specific files): ~/texmf <O> options: [X] use letter size instead of A4 by default [X] allow execution of restricted list of programs via \write18 [X] create all format files [X] install macro/font doc tree [X] install macro/font source tree [X] create symlinks to standard directories [X] after install, set CTAN as source for package updates <V> set up for portable installation Actions: <I> start installation to hard disk <P> save installation profile to 'texlive.profile' and exit <Q> quit Enter command: I Installing to: /usr/local/texlive/2023 username@username-computername:/media/username/TeXLive2023$ ``` I did relent, gave up on having access to the GUI, and simply plugged away with this command-line menu, setting options etc. I then executed the action . I must point out that **installation does *not*, in fact, take place.** I've read the documentation, but I cannot see where the error is. --- I carried out **all** of the installation commands while operating as **"root"** ``` / / Enter command: I Installing to: /usr/local/texlive/2023 root@username-computername:/media/username/TeXLive2023# / / / ``` at this juncture, I waited 15 minutes (as there was *some* HDD activity). But when I checked, a directory `/usr/local/texlive/2023` still had not been created. I did the same routine with the installer as before, but instead I asked for it to print the installation profile only, then exit `<P>`. The terminal output made it appear as if something was being 'printed' (to file), but I searched all of my directory tree, and it is NOT there.
https://tex.stackexchange.com/users/287274
Install TeXlive 2023 from DVD-USB fails
false
I had previously installed TeXlive 2022 using the DVD method (note that 2022 was small enough to fit on a standard 4.7GB DVD, but 2023 is ~6GB and I had to move to a USB stick). I did not have any problem of this sort when installing 2022 from the DVD, which was created from an ISO image. I persevered. As noted above, I ran the installer several times as 'root' and as 'user' with the same failure mode (it simply refused to start). I did go through the installation routine and checked each of the installation directories that were suggested (using the "D" option before running the installer). There was nothing weird there. And during the prior installation of 2022 from DVD, I didn't do anything w.r.t the directories, just accepted the defaults and ran the installer. I hit upon the idea of manually creating the primary directory for the new installation (being: `/usr/local/texlive/2023`). I then tried the installation again. And, it ran and installed successfully. In summary, it seems that the 2023 installer either doesn't have the `mkdir` function at all, or there is some problem with it creating the primary directory (again, in my case, `/usr/local/texlive/2023`). Any and all of the other directories required were subsequently created by the TeXlive 2023 installer. The other issue is, as noted in the original query, that the `install-tl gui` or `install-tl -gui` command doesn't work (*regardless* of whether one attempts to run it as 'root' or as 'user'); it didn't seem to generate an error message, it just gave me the terminal-window display instead. I will post a note on the TUG site about this, and link back to this question.
0
https://tex.stackexchange.com/users/287274
683020
316,904
https://tex.stackexchange.com/questions/682989
5
I run TexLive Utility infrequently (about twice a year, because I concentrate on the content I create, not on updating my installation). I would like to be able to use it, say now, for TexLive 2022, but TexLive 2023 has been released so the updates are no longer possible. I did not succeed finding a 2022 mirror I could use so that I have a final version of it on my computer and can later decide if I want to go through the hassle of installing again TexLive in the 2023 version. Additionally I would like the TeX Live Utility to automatically suggest repositories for historical versions if available.
https://tex.stackexchange.com/users/4371
Can you still update a TexLive 202X when a TeXLive 202X+1 is released?
false
Thanks to several very helpful comments, I will answer my main question: **How do you update TexLive after next year's version is released?** You can use a repository with archives of previous versions. <https://ftp.math.utah.edu/pub/tex/historic/systems/texlive/2022/tlnet-final> as the time of writing, <https://ftp.math.utah.edu/pub/tex/historic/systems/texlive/> (mentionned by @cabohah as well) contains the texlive archives for years from 1996 to now. [TUG Historic FTP site](ftp://tug.org/historic/systems/texlive/2022/tlnet-final) seems to work well for Europe. 1. (answer in comments by Ulrike Fischer) If you are willing to use the command line tools (which are called by the GUI Utility anyway). tlmgr update --repository <https://ftp.math.utah.edu/pub/tex/historic/systems/texlive/2022/tlnet-final> --list gives the list of packages to update and ``` tlmgr update --repository https://ftp.math.utah.edu/pub/tex/historic/systems/texlive/2022/tlnet-final --all ``` tries to update everything. This to run with admin rights. For more flexibility consult the manual for tlmgr. Worked well on one of my computers. 2. (tested by me for this question on 2022, on one computer) you can insert this repository address directly as the current repository in TexLive Utility. First you will need to acknowledge a dialog that the version has changed on your usual repository and that there is no update available. You insert the archive address, then validate. This will allow to make a last update of everything you want on your installation. 3. Of course, you can use CTAN to install specific pieces of the texlive galaxy with bugfixes or new features. As @rallg points out, as texlive2022 is frozen, you might as well install it in the main tree so that you avoid interaction if you finally install 2023. I had no specific style or package to upgrade to this time, so I did not use that. Other helpful questions in stackexchange: [How do I update my TeX distribution](https://tex.stackexchange.com/questions/55437/how-do-i-update-my-tex-distribution/55438#55438) [Can I install an ancient TexLive distribution ?](https://tex.stackexchange.com/questions/274870/can-i-specify-texlive-version-to-install-in-the-install-tl-profile?rq=1) [the TexLive release cycle](https://tex.stackexchange.com/questions/493966/understanding-the-texlive-release-cycle-what-is-the-meaning-of-a-texlive-releas)
3
https://tex.stackexchange.com/users/4371
683038
316,911
https://tex.stackexchange.com/questions/75449
116
Is it possible to specify the width and height of a `tikzpicture`? To scale a `tikzpicture` I use the option `scale`, i.e. for instance ``` \begin{tikzpicture}[scale = 2] ... \end{tikzpicture} ``` I tried to change the width and height as ``` \begin{tikzpicture}[width = 2in, height = 3in] ... \end{tikzpicture} ``` but this gives me an error "I do not know the key /tikz/width".
https://tex.stackexchange.com/users/nan
Specifying the width and height of a tikzpicture
false
I don't know how useful this will be to others, but I found adding a node that defines a minimum width and height worked pretty well for me. I needed this because one of my nodes was of a variable width, but I needed the image to be anchored to the bottom right of the page. The code would look like: ``` \draw (0, 0) node[inner sep=0,anchor=east,minimum width=8.75in, minimum height=112pt] {}; ``` Make sure to change the `anchor` as needed. The downside here is that if any of your nodes go outside the area defined by the first node, you picture will still grow to be larger. You might be able to avoid that by using the `\clip` option inside a scope, but I didn't experiment with that.
2
https://tex.stackexchange.com/users/295133
683040
316,912
https://tex.stackexchange.com/questions/683015
0
Hello there i cant add my bibliography to my file. I am using Texlive and Texmaker. In texmaker i switched the setting from the configuration of bibtex to biber %. I also updated biber via shell command tlgmr update biber. When i type biber test into the shell command i get the following error: PS C:\WINDOWS\system32> biber test INFO - This is Biber 2.19 INFO - Logfile is 'test.blg' ERROR - Cannot find 'test.bcf'! INFO - ERRORS: 1 My test.tex contains the following code: > > \documentclass[a4paper, 12pt]{article} > > > \usepackage[utf8]{inputenc} > \usepackage[english]{babel} > \usepackage[T1]{fontenc} > > > \usepackage[backend=biber, style=numeric]{biblatex} > > > \addbibresource{literatur\_BA.bib} > > > \bibliography{literatur\_BA} > > > \begin{document} > > > \cite{Epoxidharze} > > > \printbibliogrpahy > > > test > \end{document} > > > The \printbibliography command doesnt do anything. I can see the \cite in my pdf.
https://tex.stackexchange.com/users/293330
Biber cant find the needed .bcf file
false
I had to add the correct path of biber and texlive to my system environment and to the environment of my User. D:\texlive\2022\bin\win32 D:\texlive\2023\bin\windows
1
https://tex.stackexchange.com/users/293330
683048
316,917
https://tex.stackexchange.com/questions/683042
6
I want Theorem/Example with the following numbers: ``` Theorem 1.1. Example 1.2.1. Example 1.2.2. Theorem 1.3. ``` However, I am only able to obtain: ``` Theorem 1.1. Example 1.1.1. Example 1.1.2. Theorem 1.2. ``` Here is my code: ``` \documentclass{article} \usepackage{amsthm} \newtheorem{thm}{Theorem}[section] \newtheorem{exmp}{Example}[thm] \begin{document} \section{Section 1} \begin{thm} \end{thm} \begin{exmp} \end{exmp} \begin{exmp} \end{exmp} \begin{thm} \end{thm} \end{document} ``` Thanks in advance.
https://tex.stackexchange.com/users/293033
Theorem/Example numbering in LaTeX
true
The following solution employs the `etoolbox` package and its `\BeforeBeginEnvironment` macro. Specifically, the additional preamble code shown below serves to step the `thm` counter at the start of an `exmp` environment if one of the following two conditions is true: * A `thm` environment was executed recently, i.e., somewhere before the occurrence of an `exmp` environment. In contrast, if the current `exmp` environment is preceded by another `exmp` environment, the `thm` counter is not stepped. * The `exmp` environment occurs *before* a `thm` environment occurs within the current section. ``` \documentclass{article} \usepackage{amsthm} \newtheorem{thm}{Theorem}[section] \newtheorem{exmp}{Example}[thm] %% start of new code block \usepackage{etoolbox} % for '\BeforeBeginEnvironment' macro \newif\ifThmRecent\ThmRecenttrue % initiate the conditional \BeforeBeginEnvironment{thm}{\ThmRecenttrue} % set to 'true' \BeforeBeginEnvironment{exmp}{% \ifThmRecent \ThmRecentfalse \stepcounter{thm} \else \ifnum\value{thm}=0 \stepcounter{thm} \fi \fi } %% end of new code block \begin{document} \section{Uno} \begin{thm}\end{thm} \begin{exmp}\end{exmp} \begin{exmp}\end{exmp} \begin{thm}\end{thm} \section{Due} \begin{thm}\end{thm} \begin{exmp}\end{exmp} \begin{thm}\end{thm} \section{Tre} \begin{exmp}\end{exmp} \begin{exmp}\end{exmp} \begin{thm}\end{thm} \end{document} ```
5
https://tex.stackexchange.com/users/5001
683050
316,918
https://tex.stackexchange.com/questions/683049
1
Is it possible to combine multiple biblatex citation commands with optional arguments? Please consider the following example: ``` % I use this if I want to reference the whole referenced work \parencite{Author00} % compiles to (Author, 2000) in my setup % I use this if I want to reference a specific chapter in the referenced work \parencite[Chapter~0]{Author00} % compiles to (Author, 2000, Chapter 0) in my setup ``` If I want to reference multiple works at once, that's easy enough with ``` \parencite{Author00,AnotherAuthor01} % compiles to (Author, 2000; Another Author, 2001) in my setup ``` But what if I want to mix one reference with an optional argument and one without? Or reference two chapters in two different referenced works? What I'd like to see is something like: > > (Author, 2000; Another Author 2001, Chapter 1) > > > and > > (Author, 2000, Chapter 0; Another Author 2001, Chapter 1) > > > The following **does not** yield what I want (due to potentially applied auto-sorting of references): ``` \parencite[Chapter~0]{Author00,AnotherAuthor01} % compiles to (Author, 2000; Another Author, 2001, Chapter 0) in my setup % -> Note that the Chapter reference was supposed to belong to the first reference \parencite[Chapter~0, Chapter~1]{Author00,AnotherAuthor01} % compiles to (Author, 2000; Another Author, 2001, Chapter 0, Chapter 1) in my setup. % The Chapter references do not "attach" to the respective reference ``` Am I missing anything in the way the biblatex commands work or do I need to use a more custom setup? --- The following is an insufficient workaround: ``` \parencite[Chapter~0]{Author00}\parencite[Chapter~1]{AnotherAuthor01} % compiles to (Author, 2000, Chapter 1)(Another Author, 2001, Chapter 1) in my setup. % -> Note the interrupted brackets ```
https://tex.stackexchange.com/users/295141
Combine multiple \parencite with optional arguments
true
I found a simple answer to my question. Here's the answer in case anyone else stumbles upon this. It's as easy as: ``` \parencites[Chapter~0]{Author00}[Chapter~1]{AnotherAuthor01} ``` and will compile to > > (Author, 2000, Chapter 0; Another Author, 2001, Chapter 1) > > >
2
https://tex.stackexchange.com/users/295141
683052
316,920
https://tex.stackexchange.com/questions/682961
1
I want to build a \dotfill command where I can specify a minimum length. I have tried: ``` \makebox[0.88em]{\dotfill}\dotfill ``` As the standard spacing of dotfill is 0.44em, so I get exactly two dots. However, there is a slightly bigger spacing between the first two dots and the dots from the second \dotfill command. Does anyone have an idea how I can solve that?
https://tex.stackexchange.com/users/295013
\dotfill with minimal length
false
That is a XY problem. David answer solved exactly what you asked (fix a minimun of dots, then +1) but not what you want (find a good solution for dot lines with 0-1 dots). My crystal ball said that fix a minimum of dots is not that what you want, because force things in this way can produce a big `Overfull \hbox` (see black part of the MWE). What my crystal ball cannot see is what other solution could you consider good for these cases, because it depends a lot of contents and personal preferences. One simple solution could be enclose "a" and/or "b" in `\parbox`es, to ensure that that a+b will not take more than `\linewidth-0.88em`. Another more complex (it need two runs!), is check if the width of a+b is smaller that this (taking at least b as argument of the macro) so you can use the standard `\dotfill` but otherwise do ... what you consider better. Just as example, the fix in the MWE is move the "b" part to the next line with a half dotted line. The MWE also show that omitting the curly braces (`{}`) will take as first argument only the next character, so when "b part" is a word or sentence, it can produce wrong results. ``` \documentclass[a6paper,draft]{article} \usepackage[margin=1in,showframe]{geometry} \usepackage{linegoal,xcolor,lipsum} \parindent0pt\parskip0pt \newlength\ihave \newlength\remain \newlength\ineed \begin{document} \DeclareRobustCommand\mydotfill{% \leavevmode \cleaders \hbox to.44em{\hss.\hss}\hskip .88em plus 1fill \kern0pt } No argument (fake \verb-\dotfill-): \rule{.75\linewidth}{1.5ex} \mydotfill b\par \rule{.85\linewidth}{1.5ex} \mydotfill b\par \rule{.95\linewidth}{1.5ex} \mydotfill b\par \rule{.75\linewidth}{1.5ex} \mydotfill basic\par \rule{.85\linewidth}{1.5ex} \mydotfill basic\par \rule{.95\linewidth}{1.5ex} \mydotfill basic\par \renewcommand\mydotfill[1]{% \settowidth{\ihave}{#1}% \setlength{\remain}{\dimexpr\linegoal}% \setlength{\ineed}{\dimexpr\ihave+.88em}% \ifdim\remain>\ineed \dotfill#1\else\\[-1ex]% \mbox{}\hfill$\vdots$\dotfill#1\fi} \color{blue} Argument is next character % better with curly braces ... \rule{.75\linewidth}{1.5ex} \mydotfill b\par \rule{.85\linewidth}{1.5ex} \mydotfill b\par \rule{.95\linewidth}{1.5ex} \mydotfill b\par \color{red} But it should not : % ... because this \rule{.75\linewidth}{1.5ex} \mydotfill basic\par \rule{.85\linewidth}{1.5ex} \mydotfill basic\par \rule{.95\linewidth}{1.5ex} \mydotfill basic\par \color{magenta} Argument is the next word/setence: \rule{.75\linewidth}{1.5ex} \mydotfill{basic}\par \rule{.85\linewidth}{1.5ex} \mydotfill{basic}\par \rule{.95\linewidth}{1.5ex} \mydotfill{basic approach method}\par \end{document} ```
0
https://tex.stackexchange.com/users/11604
683053
316,921
https://tex.stackexchange.com/questions/683029
1
I have to boxes with the same table settings. Two issues: (1) The width of the gray background is different. (2) It is not possible to add a multiline equation via `\begin{align*}`. (Error: `\begin{align}` allowed only in paragraph.) Do I need two different `\SetTblrInner[mytblr]` and `\SetTblrInner[mytblr2]`? Here is an example with the above error: ``` \documentclass{scrartcl} \usepackage[margin=1.0cm]{geometry} \renewcommand{\familydefault}{\sfdefault} \usepackage{tikz} \usetikzlibrary{angles, positioning, quotes, shapes.geometric, } \tikzset{baseline=(current bounding box.center), my angle/.style = {draw, font=\small, angle eccentricity=1.55, angle radius=3mm}, base/.style = {draw, thick}, dashline/.style = {densely dashed, thick}, every edge quotes/.style = {auto=right, inner sep=1pt, font=\small}, Rect/.style args = {#1/#2}{base, minimum height=#1, minimum width=#2}, Trap/.style args = {#1/#2}{base, trapezium, trapezium left angle=#1, trapezium right angle=#2, minimum width=30mm} } \usepackage{tcolorbox} \tcbset{fonttitle=\bfseries, coltitle=white, colback=white, colframe=black,nobeforeafter,sharp corners, sidebyside, sidebyside gap=3mm, lower separated=false } \usepackage{sfmath} \usepackage{tabularray} \usepackage{amsmath} \NewTblrEnviron{mytblr} % <--- added by @Jasper Habicht \SetTblrInner[mytblr]{ hline{1,2,Z} = 1pt, vline{1,Z} = 1pt, hline{even[3-X]} = {dashed, fg=gray, 0.5pt}, colspec = {Q[l, bg=gray!10, font=\small\bfseries] X[c, bg=gray!10] Q[c, wd=33mm]}, colsep = 3pt, cell{1}{1} = {c=3}{l}, cell{odd[3]}{1} = {c=2}{c, fg=black, mode=math}, row{1} = {bg=gray!30, mode=text}, row{2-Z}= {belowsep=4pt}, row{odd[3-Z]} = {ht = 19mm} } \begin{document} \noindent \begin{tcolorbox}[title = Title] \begin{mytblr}{} Square & & \\ Area & & \\ \begin{align*} A&=a\cdot a\\ & = a^{2} \end{align*}&=a\cdot a a^2 & & \tikz{\node (a) [Rect=14mm/14mm] {}; \path (a.south west) to["a"] (a.south east) (a.south east) to["a"] (a.north east); } \\ Circumference & & \\ u=4\cdot a & & \tikz{\node (a) [Rect=14mm/14mm] {}; \path (a.south west) to["a"] (a.south east) (a.south east) to["a"] (a.north east); } \\ \end{mytblr} \medskip \begin{mytblr}{} Pythagorean Theorem & & \\ \textnormal{In any right-angled\\ triangle it holds that} & & \\ a^{2}+b^{2}=c^{2} & & \tikz{[very thick] \draw (-1.5,0)coordinate[](A) --(1.2,0)coordinate[](B) --(-1.5,1.2)coordinate[](C) --cycle; % rechte Winkel \pic[draw,fill=gray!10,fill opacity=0.5,angle radius=4mm,"$\pmb{\cdot}$" opacity=1] {angle=B--A--C}; % Streckenbezeichnungen \path (A) -- node [midway,below] {\scriptsize b} (B); \path (A) -- node [midway,left] {\scriptsize a} (C); \path (B) -- node [midway,above] {\scriptsize c} (C);} \\ \end{mytblr} \end{tcolorbox} \end{document} ```
https://tex.stackexchange.com/users/294659
One table setting produces different background width
true
Like this? In your code you have three errors: * instead of `align*` you should use `aligned` * for two line text in "Pythagorean Theorem" you should remove `\textnormal` command before curly brace (see MWE below) * spurious math code after `align*` (remove it!) *Off-topic*: for mark of right corner I would use: * for labeling of shapes border you should use a way as I use at drawing of images in ma answer and you copied in "Square" part * style for angle I would add to `tikzset` (you can change style name according to your wish) ``` \documentclass{scrartcl} \usepackage[margin=1.0cm]{geometry} \renewcommand{\familydefault}{\sfdefault} \usepackage{tikz} \usetikzlibrary{angles, positioning, quotes, shapes.geometric, } \tikzset{baseline=(current bounding box.center), my angle/.style = {draw, font=\small, angle eccentricity=1.55, angle radius=3mm}, base/.style = {draw, thick}, dashline/.style = {densely dashed, thick}, every edge quotes/.style = {auto=right, inner sep=1pt, font=\small}, Rect/.style args = {#1/#2}{base, minimum height=#1, minimum width=#2}, Trap/.style args = {#1/#2}{base, trapezium, trapezium left angle=#1, trapezium right angle=#2, minimum width=30mm}, ANG/.style = {draw, fill=gray!10, angle radius=4mm, angle eccentricity=#1}, } \usepackage{tcolorbox} \tcbset{fonttitle=\bfseries, coltitle=white, colback=white, colframe=black,nobeforeafter,sharp corners, sidebyside, sidebyside gap=3mm, lower separated=false } \usepackage{sfmath} \usepackage{tabularray} \usepackage{amsmath} \NewTblrEnviron{mytblr} % <--- added by @Jasper Habicht \SetTblrInner[mytblr]{ hline{1,2,Z} = 1pt, vline{1,Z} = 1pt, hline{even[3-X]} = {dashed, fg=gray, 0.5pt}, colspec = {Q[l, bg=gray!10, font=\small\bfseries] X[c, bg=gray!10] Q[c, wd=33mm]}, colsep = 3pt, cell{1}{1} = {c=3}{l}, cell{odd[3]}{1} = {c=2}{c, fg=black, mode=math}, row{1} = {bg=gray!30, mode=text}, row{2-Z}= {belowsep=4pt}, row{odd[3-Z]} = {ht = 19mm} } \begin{document} \noindent \begin{tcolorbox}[title = Title] \begin{mytblr}{} Square & & \\ Area & & \\ \begin{aligned} A&=a\cdot a\\ & = a^{2} \end{aligned} & & \tikz{\node (a) [Rect=14mm/14mm] {}; \path (a.south west) to["a"] (a.south east) (a.south east) to["a"] (a.north east); } \\ Circumference & & \\ u=4\cdot a & & \tikz{\node (a) [Rect=14mm/14mm] {}; \path (a.south west) to["a"] (a.south east) (a.south east) to["a"] (a.north east); } \\ \end{mytblr} \medskip \begin{mytblr}{} Pythagorean Theorem & & \\ {In any right-angled\\ triangle it holds that} & & \\ a^{2}+b^{2}=c^{2} & & \tikz{[very thick] \draw (0,0)coordinate[](A) -- (3,0)coordinate[](B) -- (0,1.5)coordinate[](C) -- cycle; % rechte Winkel \pic[ANG=0.5, "$\pmb{\cdot}$"] {right angle=B--A--C}; % Streckenbezeichnungen \path (A) edge ["$b$"] (B) (B) edge ["$c$"] (C) (C) edge ["$a$"] (A); } \\ \end{mytblr} \end{tcolorbox} \end{document} ```
1
https://tex.stackexchange.com/users/18189
683055
316,922