Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [formatting]

{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.

1
vote
0answers
13 views

How to display vertical lines at indents in lstlisting?

I want to display vertical lines in indentations. I already found this thread: Lstlisting and indentation lines, but it isn't what I want. This is how my attempt looks like: This is how I want it to ...
2
votes
2answers
45 views

Drawing a horizontal \rule through the middle of a line

How can I do something like \noindent\rule{\linewidth}{0.25mm} but in a way that doesn't leave a big gap before it? Currently it's kind of like \bottomrule, almost as if it skips a line. I want it to ...
0
votes
0answers
23 views

Paragraphs and indention [duplicate]

Latex by default indents the first line of a new paragraph, but does not leave empty vertical space. Currently, I am writing a text with many formulas in it. I don't think this paragraph style works ...
0
votes
0answers
28 views

Table formatting issue in Overleaf

I am using Overleaf for a report and my table header isn't formatting correctly. This is the initial part of the code (the table is long, spanning across two pages - it has 20 rows. I am a total ...
1
vote
0answers
24 views

No counter 'chapter' defined. \begin{document} [duplicate]

Upon trying to insert Python code in my LateX document I ran into corresponding error message. Code, which recreates the error message and contains only the most vital parts of my documents: \...
1
vote
1answer
27 views

Allowing values to bypass tabular column alignment

I have 8 columns in my table and everything fits perfectly except the very last value, which is about 5 columns long/wide (it's a very long binary string) and it's on the last row all by itself, I ...
0
votes
0answers
42 views

What's a nice way to display code in a document?

I'm looking for a nice or creative way to display code in a LaTeX document. I see a lot of nice layouts in books, with text-boxes, titles, annotations, delimiters, and all sorts of attractive things. ...
1
vote
1answer
62 views

How to make 4 columns of this recommended format LaTeX table?

I am researching on how to format and use tables the proper way and I came across this guide: How to make nice tables On one of the slides, there is this table, which looks pretty nice and it's also ...
1
vote
1answer
51 views

Custom notation table with page reference

I would like to combine this question with this one. The goal is to build a list of notation with the following properties the symbol is on the left in a column with fixed width the description is ...
3
votes
1answer
77 views

How do I align a math environment to the right?

I'm trying to wrote a few math formulas, but they go left. The picture will explain: As you can see, the < signs are not in the same line. The code: צד ראשון: \L{ \begin{eqnarray*} 2(i+1) & ...
1
vote
1answer
38 views

Adjusting dotfill for custom table of notations

Consider the following code/picture: \documentclass{article} \usepackage{graphicx} \usepackage{amsmath} \begin{document} \noindent \begin{tabular}{@{}p{2.62cm}@{}p{9.5cm}@{}} $\varliminf,\varlimsup$ &...
0
votes
1answer
35 views

How to format spacing between reference key and reference text in Bibtex? [duplicate]

I want to increase the spacing between the reference key and the text in my bibliography as shown in the picture below: I'm using Bibtex. Any suggestions? Thanks in advance!
1
vote
1answer
45 views

number question

I'm trying to figure out how I can make numbers in my index sort in ascending order, right now 11 is sorting between 1 and 2, i'm trying to make it come after 9 and 10. I could add a 0 before the ...
0
votes
0answers
14 views

Having problems to set size of font in my document [duplicate]

I am experiencing some issues when I want to set the font size of my document to 14pt. If I set a number different than 12 the size of the font becomes smaller. Honestly I am kinda new using LaTeX so ...
0
votes
0answers
15 views

How to define an environment for a boxed and named theorem?

The environment below gives a boxed theorem with normal font (non italic text). \documentclass[11pt]{article} \usepackage[tikz]{mdframed} \usepackage{amsthm} \newtheorem{thm}{Theorem}[section] \...
2
votes
2answers
19 views

Missing number, treated as zero formatdate

So I am fairly new to latex and most of my use of it is in combination with Rmarkdown files, but am trying to integrate the two. Essentially, I have a command which takes is supposed to be a date (in ...
0
votes
3answers
30 views

Prevent pagebreaks before and after part

I'm trying to create a titlepage that's linked in the table of contents (i.e. clicking the link should send me onto the titlepage). It should look like this: \documentclass[oneside]{scrbook} \...
5
votes
2answers
50 views

Two column layout for stage play

I know there is a couple of document classes specifically designed for stage play scripts, but as far as I could tell, none offered the feature I'm looking for. I want the names of the characters to ...
0
votes
1answer
64 views

How to write complexity classes in LaTeX? [duplicate]

I would like to write the complexity classes P, NP, NP-complete and NP-hard in LaTex with the mathematical format as follows:
5
votes
1answer
85 views

\LARGE{\textbf{…}} vs \textbf{\LARGE{…}} [duplicate]

I am currently writing a project report, and have come across a strange thing. While making the title page, when I insert the title, if I wrote \textbf{\LARGE{Multi-Server Authentication Scheme ...
1
vote
1answer
12 views

Redefining style after the current command or page

I am trying to write for the first time my own class. I am redefining the \maketitle, and I would like two things: the font size to be changed after it (namely to around 14pt, the only way I found is ...
1
vote
1answer
49 views

Set pagenumbers to only appear on the right

As the title suggests, how can I set my pagenumbers to only appear on the right? Because I don't know which setting is even responsible for this, where would I have to look to find out what options ...
0
votes
1answer
26 views

How can i remove this blank page after my list of figures?

All chapters of my work have enough text in them to fill atleast two pages, so this is not an issue, but for my list of figures, i get this empty page after wards: This is my main page: \...
3
votes
2answers
87 views

Remove rulers from draft view

I plan to use this document template for constructing my thesis: http://www.latextemplates.com/template/masters-doctoral-thesis However, when running in draft mode, multiple rulers appear in the ...
1
vote
1answer
31 views

file ended while scanning use of \frac no blank lines

Here my code that creates the problem in my code: \begin{equation*} Pressure Ratio = \frac{p_{03}}{p_{01}}, Mass Flow Rate = \frac{\dot m \sqrt{R T_{01}}{p_{01} d^2}, Specific Heat Capacity = \frac{...
1
vote
1answer
47 views

Linguistic Formula [duplicate]

I am trying to type linguistic formulas in LateX. An example would be smilar to this: https://upload.wikimedia.org/wikipedia/en/8/8e/AmerEngFlappingRule_annotated.PNG
1
vote
1answer
57 views

How to align text behind bullet points

The issue is when a bullet goes over 1 line. Then the alignment is broken like this. I have found I can fix this issue by adding spaces to separate the lines, but this feels sub-optimal. Is there a ...
1
vote
1answer
29 views

Package fncychap: how do you make the title boxes smaller

I'm new to LaTeX and wanted to write my dissertation in report mode. I am trying to use the package fncychapbut I noticed that my typeset version has a massive box that stretches to halfway down the ...
0
votes
0answers
14 views

Adding headers and splitting equations using align

So I want to use a 3-column style to display these equations (this works). I also want a header such as "Level 3 Level 2 Level 1" above each column, respectively. When I try to add this format in ...
1
vote
2answers
103 views

Can the math version be changed within a tabular/array environment?

As so many questions (respectively answers) on this sight point out, it is possible to exhaust (respectively, extend) the list of slots allocated to math alphabets. The following MWE accomplishes my ...
0
votes
1answer
30 views

Align caption next to table that is below another table

I have the following code: \begin{table}[] \begin{varwidth}{\columnwidth} \setlength{\lineskip}{5.4pt}\raggedright \begin{tabular}{l|l|l|l|l|l|l|} \cline{2-7} & \multicolumn{1}{c|}{FDDI} & \...
4
votes
1answer
209 views

Formating an equation

I have the following equation \documentclass[12pt]{article} \usepackage[a4paper]{geometry} \usepackage{mathtools} \begin{document} \begin{equation*} u(x) = \left\{ \begin{multlined} \...
0
votes
2answers
29 views

Add the word “from” in a citation with a new \cite command

I would like to add the word "from" in the citation when I based myself on the work of the researchers I cite e.g. (from Lander et al., 2001) Maybe with a new command in order to have 2 types of ...
1
vote
1answer
63 views

Change Awesome CV layout

I'm using awesome-cv.cls and it's amazing. However, one thing that I want would be to change the job title to be beside the company name as well as the date to be beside location. In my attached ...
5
votes
3answers
260 views

Can't remove one character of space in my environment

The essay I'm working on requires an abstract with no abstract title and does not require any indentation. Therefore, I defined the following: \renewenvironment{abstract} {% \par % \noindent \...
0
votes
0answers
59 views

Conditional Latex table: Cell value color based on its value

I would like to create a conditional where values less than 7 are in red and values greater than or equal to 7 are in blue. I would like a result like the one below: Follows my MWE. \documentclass[...
0
votes
0answers
31 views

Change the font size of the word “Theorem”

What should I do if I want to change the font size of the word "Theorem" but not of the body of the theorem? It doesn't seem that \newtheoremstyle has a parameter for this. It is probably a rather ...
0
votes
1answer
42 views

How format latex code in []

What editor allows you to do automatic indentation as in the example in [] []1 If I use TexStudio it does so Or is it all done by hand?
0
votes
1answer
25 views

Prevent LaTeX from spacing header from text to fill up the page

(New to LaTeX, so please answer in detail and with examples) I am trying to write a report, and at one part I have a list of questions I need to propose. However, whenever I try to add the list, the ...
1
vote
1answer
26 views

Escaping the “^” character causes formatting error

Escaping "^" after \tt is causing formatting error in the following code. All words after \^{} is being affected by \tt. Code: \item Use the {\tt linspace} command to create a vector $\mathbf{x} \in ...
2
votes
1answer
29 views

Using \newcommand to shortcut math mode $…$ with text spacing issues

(New to LaTeX, so please explain solutions in detail and with examples) I have many N_{(s)}, N_{(s,a)}, R_{(s)}, R_{(s,a)}, etc in my report. These are also often integrated with other equations: $...
2
votes
1answer
31 views

How to add custom line and improve this code?

I have work from my campus, but, not all is learned, so I must develop this script, so, I have problem about text and table. I need to compile like this. I have use \hline but that will line ...
2
votes
1answer
32 views

bibliography backreferences with hyperref: format individual page number

I would like to format the backreferences in italics when the citation is called from a custom command (but not otherwise). I've been playing with both \backrefxxx and \backrefalt inside the custom ...
0
votes
0answers
36 views

Turn off: \UseRawInputEncoding after specific text

Is it possible to turn off \UseRawInputEncoding after a specific line? I had to put it in to display my code. I tried to implement \usepackage[utf8]{inputenc} after my "code block". But it only ...
1
vote
2answers
38 views

Can't make font (of different family from main) bold in new environment

My document's main text is set as follows: \renewcommand{\familydefault}{\sfdefault} % sans serif to default \usepackage[defaultsans,osfigures,scale=1]{opensans} % change main font here So ...
0
votes
1answer
30 views

make distance between acronym and description

i have a problem with my glossaries format. Is it possible to make a distance (hspace) between the acronym or symbol and their description? now, it is something like that: Bsp. Beispiel Another ...
1
vote
1answer
30 views

Changing Color of Author Thanks in Document

Let's say you have the following title in mwe.tex: \documentclass{article} \title{Sample Title} \author{John Doe\thanks{email}~ and Jane Doe\thanks{twitter}} \date{\today} \begin{document} \...
1
vote
2answers
32 views

How to format the algorithm

I have the text for the following algorithm, but I am unable to format it, with the numbers and spacing as in the image: $COVERABILITY-GRAPH((S,T,F,M_0))$\\ $(V,E,v_0):=(\{M_0\},\emptyset,M_0);$\\ ...
0
votes
3answers
41 views

How to move the lines in arrays

I wanted to apply Ruffini's rule but since I'm using fractions it's all crowded and messy. Is there a way to leave more space between the lines? \begin{equation*} \begin{array}{c|c c c|c} ...
4
votes
1answer
60 views

Fit (vertically portrayed) image with the caption displayed below

So I have this code: \begin{figure}[H] \centering \includegraphics[height=\textheight, width=\textwidth]{similar_waveforms_filtered_and_cut_new} \caption{Seiemic traces for events studied in ...