{formatting} is for general questions about formatting document elements. Use this tag in addition to other tags specifying what should be formatted. For questions about font attributes (e.g., {bold}, {italic}, {small-caps}, {sans-serif}, {typewriter}), use the appropriate tag instead.

learn more… | top users | synonyms

3
votes
3answers
67 views

How do I redefine the paragraph style midway through the document (and then go back to the default)?

I prefer to build my bibliography manually because I'm finicky about the formatting, and I need each bibliographical entry to have a hanging indent and an empty line after it. I'm doing fine with this ...
2
votes
1answer
21 views

Switch i, j dots with an arrow

I'm writing a Physics template and I came across this issue. I want the i, j to have vector lines instead of those dots. How can I do it?
3
votes
1answer
67 views

Argumentless macros for use in other macros

I'm in need of argument text formatters for use in some environments that use macros to redefine properties (e.g., enumitem). I need to underline text but there is no equivalent argumentless macro ...
0
votes
0answers
15 views

Publication-style format to include statistical tables with the Coef, Odds Ratio, Standard Error, and significance

I was wondering if there is a publication-style format if I wanted to include the coefficient estimate, the odds ratio (OR), the standard error of the estimate, and the significance (i.e. stars such ...
1
vote
3answers
24 views

Cant get the points in a \parts to bold on right hand side

I would like to get the points on the right hand side of the page in bold on the same line as the question see below. This is all I have so far. Not sure how to \renew \begin{parts} \part[2] ...
5
votes
3answers
182 views

How to cross out a word in LaTex

How can I cross out a word in a sentence in Latex without using a package? MWE: \documentclass{article} \usepackage{cancel} \begin{document} %BeginDocument The first \xcancel{three commands} work in ...
1
vote
2answers
107 views

utf8x character fails in the table of contents every second time i compile

\documentclass[a4paper]{report} \usepackage[utf8x]{inputenc} \begin{document} \tableofcontents \chapter{ø} \end{document} First time I compile this, I get an ø in the table of contents. Second time ...
2
votes
0answers
51 views

Is there any single property/option for creating all borders in LaTeX table?

\begin{tabular}{ | c | c | c | } \hline 1 & 2 & 3 \\ \hline 4 & 5 & 6 \\ \hline 7 & 8 & 9 \\ \hline \end{tabular} If we want to create a ...
1
vote
1answer
26 views

How to format the leading dots of section page number and subsection page number respectively in the table of contents

everyone: I came across a problem. Following is how I format my table of contents: \usepackage{tocloft} \tocloftpagestyle{empty} \renewcommand{\cftdot}{…} \renewcommand{\cftdotsep}{0} ...
2
votes
1answer
126 views

Using Easylist and leaving one entry bullet blank

So I have a checklist using the checkboxes. I want to make occasional ones not have the check box because there are several indented checkboxes I want to choose from. I see Choosing the bullet of a ...
2
votes
2answers
23 views

Package changes horizontal pipe to horizontal for chapter formatting

I need to change the style of my chapters to a different one. I found a package which would do that, and it works nicely. However, my code before the edit was like this: ...
1
vote
1answer
19 views

Putting more than one image in one appendix

I am writing my PhD thesis on Sharelatex after having uploaded the template provided by my university. Usually, I try to solve this sort of problems on my own, but this time I couldn't really figure ...
0
votes
1answer
46 views

list all 3 to 5 author names in the first in-text citation using apacite

I use \usepackage{apacite} in the preamble (sublime 2 editor) and \bibliographystyle{apacite}. I did not have to manually install the apacite package. For in-text citations of 3 to 5 authors, I need ...
3
votes
3answers
71 views

Formal proof formatting in Latex

Here is what I intend to achieve 1.r (Given) 2.(t ∧ r) → s (Given) 3.(p → t) → (q → ¬s) (Given) 4.t ∧ r (Assumption) ...
0
votes
0answers
23 views

customized header in latex with chapter name on right side without CHAPTERNO [duplicate]

I want to put chapter name on right side of my header.I tried \leftmark but it is giving me CHAPTERNO.CHAPTERNAME format. However,I only want to have CHAPTERNAME. What can I do to suppress the chapter ...
2
votes
3answers
302 views

Templates for math student [closed]

I am going to start my math major, and I learned the basics of latex because I would like to use it to make my documents and take notes. But now I would like to find some templates to use for: ...
11
votes
2answers
474 views

Using prefix notation

I want to show prefix notation in my document, somewhat like this: + (x 5 3) (- 6 4) However, I want to enter it in maths mode, but maths mode removes all the spaces, so I get +(x53)(-64) Which ...
1
vote
1answer
34 views

How to input text from a file

I need to do the following: I have a file A which consists out of short fragments of text: Text 1 Text 2 Text 3 Text 4 I have another file file B in which I need to input ...
4
votes
2answers
127 views

Broken automatic line breaking in section titles when ulem and hyperref are used

I am trying to use the ulem package to underline section titles while still being able to have automatic line breaking: \documentclass{scrartcl} \usepackage[normalem]{ulem} \begin{document} ...
7
votes
3answers
88 views

\hrule after descenders

I'm trying to redo my CV in latex, and I'm running into a minor issue with the placement of \hrule. I define a category environment for each section via \newenvironment{category}[1] {% ...
1
vote
2answers
46 views

Wrapping text in a fcolorbox? [duplicate]

I'm using package "color" to have a green text box with black text, and my code is - \textbf{\fcolorbox{black}{green!30}{black text on a boxed green background}} How can I get it to wrap lines ...
8
votes
3answers
135 views

Hanging Indents / Text Wrapping

I'm trying to implement a command to be used in place of the itemize/enumerate environments. The idea is that I want to have a command (\detail), which can be used to construct an itemized list ...
1
vote
1answer
56 views

How to align item labels?

When I try to answer the a matching question in my assignment, I find that my final PDF of the four answers shown above are not aligned with each other. It seems that the lowercase "b" is taking more ...
2
votes
2answers
40 views

\titlesec and chapter&section missing zero error

I've looked and looked on here for a possible answer but i'm coming short. I even referenced the titlesec .pdf instructions and still no clue. I'm having an issue with my \chapter in the main body, ...
4
votes
2answers
122 views

Conditions in algorithms are underlined

I'm using algorithm2e for typesetting pseudocode. Generally I find it easy to use, however, I cannot seem to find the setting that underlines the conditions in my while and for loops and ...
3
votes
1answer
22 views

pgfplots bar plot number format

I was just trying to compile some data into a bar chart using pgfplots. Things seem to work apart from the following: The annotation for the bars has low precision, i.e. only 3 decimals, it is shown ...
0
votes
0answers
10 views

I am having problems with table placement [duplicate]

Hi I am sorry if this is a repeat, I tried to find a similar problem but I could not. I am making Cayley tables and I quite like the ease of the code I am using, but something strange keeps happening. ...
3
votes
1answer
59 views

Automated format in a nested enumerate environment

I have to do a small document, in which I intend to use Tufte-handout rather than article or Scrartcl classes and compile it with XeLaTeX with a typography I intend to use. However I have a ...
0
votes
0answers
49 views

Using “newlfm” template - How to remove 2nd page and empty white space after signature block?

I have just begun using the "newlfm" template to write a cover letter but when I print the letter it generates a blank second page and leaves entirely too much white space beneath the signature block. ...
0
votes
1answer
28 views

Table not displaying in desired location [duplicate]

I am writing a lab report and I want to display the a table underneath my Results section. This is my code: However, the result looks like this: Why is this the case? Thanks!
5
votes
3answers
116 views

Draw italic box as a placeholder (around a single letter) in a word

I am comparing a lot of different cases that are all following a predefined naming scheme. I would now like to replace one of the character in the name with a box to indicate that this parameter is ...
1
vote
0answers
57 views

Right way for text inside math

I'd like to know (if there is) the better way to punctuate text inside math mode. I mean, when we use , or ;, they are punctuation for the text, not for the math and so I think that they should be ...
0
votes
1answer
32 views

Alignment of Appendix Chapter Headings

I am in the final weeks of my time as a PhD graduate student, and I need to fix one last item in my thesis to conform to my graduate school's thesis formatting requirements. The graduate school ...
0
votes
0answers
24 views

Finding the cause for an overfull vbox [duplicate]

When compiling my document I get the following warning message: Badbox line 1: Overfull \vbox (1.77525pt too high) has occurred while \output is active [] Now from Google I learned that this ...
0
votes
0answers
28 views

IEEEtran table formatting doesn't work

I'm totally new to this so any insight would be greatly appreciated. I want to create a document using IEEEtran and despite trying on multiple operating systems and editors I can't seem to get tables ...
2
votes
1answer
18 views

Specify Figure name color and slant

Every time I have to denote a figure name in the text I have to type: {\textcolor{ocre}{\bf{\emph{Fig.\;\ref{figurename}(b)}}}} Is there an optimized way to specify this in the preamble so I do ...
1
vote
1answer
82 views

New example environment, with symbol at the end

Is there a standard formatted environment specifically used for examples? I'm writing a document on linear algebra, with the usual definition-theorem-proposition-example structure. Right now when I ...
2
votes
1answer
44 views

Equation number is too far from the equation

I'm trying to number some equations in a document that I'm writing, but the numbers are to the extreme right of page and I want it to be next to the equation. Right now, for example, it looks like: ...
2
votes
1answer
38 views

Adding a different colored line to each row of a table

It is possible to get colored \hlines with the example provided below. However, there are several issues with this implementation: It needs a \newcommand for every color, which then has to be used ...
4
votes
1answer
23 views

Making certain equation environments larger

I'm writing a lab report in LaTeX that involves a lot of equations. I wish for some equations to be larger than normal, owing to the fact that there are a lot of terms that are in the exponential, and ...
6
votes
2answers
72 views

How to restrict width of tcolorbox according to the length of the text it contains

I have created a tcolorbox (as given in tcolorbox version 3.40 manual - page 155) LaTeX Code: \tcbset{ enhanced, colback=red!5!white, boxrule=0.1pt, ...
1
vote
1answer
13 views

How to affect line spacing in only one group on the title page?

I am trying to set up a title page for my summaries of the classes I take. The problem lies with the line spacing for the title being too small and me not being able to change just that. My .sty-file ...
2
votes
1answer
22 views

Citation in longtable overflows into margin

I have to produce two different versions of a document: one with author-year citations, and one with numbered citations. Thus, I'm using natbib and for each document I modify the natbib options. ...
4
votes
1answer
46 views

Using subfig package with bmcart class breaks caption formatting

I am writing a paper for a journal and have to use the bmcart class of the BioMed Central template found here (direct link to ZIP file). I use subfigures, but as soon as I load the subfig package, ...
0
votes
0answers
36 views

Latex stretches my last page before plots

If an image is too big to be put on some page that already contains some text, Latex puts it on the next page and stretches the space between the text lines of the preceding page. I would rather ...
21
votes
3answers
5k views

Fanciest way to include Mathematica code in LaTeX

I am trying to include a Mathematica code in LaTeX. To obtain the Mathematica code I just exported notebook as PDF. I didn't like the way it was included in my TEX code so I just thought of adding a ...
2
votes
1answer
26 views

Equal vertical spacing between quote and chapter number independent of line spacing

Similar to the answer of this question on stackoverflow, I have renewed the \begin{savequote} and \end{savequote} environment to be always single spaced no matter what the rest of the document is. ...
3
votes
2answers
28 views

Bolding the first line of \item elements, question/answer sytle

I was wondering if it was possible to bold the first line of an enumerated list without effecting the remainder of the list. The output I want would be the same as: \begin{enumerate} \item ...
31
votes
5answers
10k views

Date format: YYYY-MM-DD

Currently I put the date in my document using: \date{\today} How do I display the date in the YYYY-MM-DD format?
1
vote
1answer
49 views

Non italic text in math formula inside remark

I use some text in the math formula, e.g.: $ \texttt{MinimumPolynomial}(T) \mid \texttt{CharacteristicPolynomial}(T)$. I use "\texttt" to make such text non-italic. This works fine but, when I ...