Questions tagged [line-numbering]

{line-numbering} is about numbering the text lines of documents or parts of them. Popular packages are `lineno` and {ledmac}.

Filter by
Sorted by
Tagged with
0
votes
0answers
9 views

Quick build in TexMaker problem

Every time I Quick build in TexMaker to View Pdf, they push me up to the first line of my Latex so I forget the line I was in before making Quick build!! Is there any solution? Cause I need to check ...
2
votes
1answer
20 views

No linenumbers inside the multicolumn text

Good Evening, I need to remove linenumbers from inside the multi-column text. Source: \begin{multicols}{2} \begin{enumerate}[\rm(a)] \item Item 1 ...
0
votes
1answer
57 views

(led)sidenotes and linenumbers are moved up

I'm writing a large document, consisting for the most part of passages written in reledmac- and reledpar-environments. In a twosided part spanning several pages, the argument of \ledsidenote as well ...
1
vote
2answers
99 views

line numbering & vruler on middle of page

I want to add line numbering to a document. I can't use lineno because for one reason or another it does not detect all the lines of my document (I use a lot of math equations and this makes line ...
2
votes
1answer
35 views

Reset algorithm counter

I am writing an algorithm, where the Input has two lines. I first tried with itemize environment, later substitued with algorithmic for uniform look-and-feel. The problem is, the counter in the actual ...
1
vote
0answers
16 views

Breakable tcolorbox and internallinenumbers

Consider the following example: \documentclass{article} \usepackage[many]{tcolorbox} \usepackage{lineno} \usepackage{blindtext} \begin{document} \blindtext[3] \begin{tcolorbox}[breakable] \...
0
votes
1answer
44 views

Table of contents with line numbers?

For my AP Stats notes this year, I've been citing everything with line numbers instead of page numbers, as most sections wind up being less than a page and I want to be able to find things quickly. I'...
1
vote
1answer
18 views

Line numbering doesn't work

I need a help, I wrote some algorithmic pseudocode in Latex and I want to show all the line numbers, no like on the image, every second. Thank you for help. Latex Code \documentclass[a1paper,0pt]{...
0
votes
1answer
36 views

\linesnumbered in package algorithm2e: how to change font size of numbers indicating the lines?

I'm using algorithm2e package \linesnumbered in Overleaf, but font size of numbers indicating the lines in the algorithm is smaller than I expected. Is there any way to change the font size?
1
vote
0answers
24 views

Footnote out of the page leads to a huge overfull \vbox

Consider the following example (it may require TeX Live 2021): \documentclass{article} \usepackage[T1]{fontenc} \usepackage{minimalist} \geometry{ papersize={7in,10in}, total={40em,60em}, ...
0
votes
0answers
23 views

How to enable line numbers in minted for code blocks with more than 2 lines?

I tend to use the same setting throughout my document. So, I have the following: \usepackage[outputdir=build_dir]{minted} \setminted{ xleftmargin=2em, fontsize=\footnotesize, breaklines, ...
0
votes
1answer
24 views

Using listings package, can I display line numberings in paretheses?

I want to achieve the following effect for line numbers using lstlisting: (1) public constructor(value?: number) { (2) if (value > 0xff) { (3) throw new Error('Value should not be greater ...
4
votes
1answer
69 views

Reference line number of string from text file

I want to reference a line from a non-TeX text file that contains a fixed string. I just want to be able to get its line number. I'll need to do this several times for the same file, so it'd be nice ...
0
votes
0answers
53 views

unnumbered lines in LyX algorithm float

I'm trying to write an algorithm in LyX, and since I'm a hebrew user a lot of methods did not work for me. I tried the following method, which worked but doesn't have numbered lines. I'd like to know ...
0
votes
0answers
22 views

Package for line numbering all content including float

Is there a package for numbering every line of a document (say article/book) along the lines of lineno package, but gives line number inside floats too? (this is for review purpose). I suppose it is ...
2
votes
2answers
37 views

How to set single verse numbering with poetry package?

I am using the poetry package, in memoir with LuaLatex. The poem that brings me here is a fragment, so my goal is that the first line has the numbering [17], and then from line 20 the numbering is ...
1
vote
2answers
42 views

How to put line numbers at the right side of the right column by combining multicol and lineno?

I would like to move the line numbers from the left side of the right column to its right side using lineno and multicol. Could you please help me how to reach this goal? My example is the following: \...
0
votes
0answers
13 views

Algorithm line numbering continues to another algorithm

I'm writing multiple algorithms but line numbering continues to another algorithm, see image: Code: \usepackage{algorithm,algorithmic} \usepackage{algpseudocode} \begin{algorithm}[h] \SetKwInOut{...
1
vote
2answers
59 views

How can I add some line numbers of emacs into pdf created by latex

Is it possible to print Line Number in emacs to the Latex pdf for lines that I prefer? If it is easy, I want to use those numbers with M-g M-g (goto-line command) I asked the same question here, I am ...
1
vote
0answers
156 views

How to add line numbers to a PDF?

I am trying to add line numbers to a PDF of a thousand pages. I only have the PDF and don't have the source text that was used to generate the PDF. As part of my research, I have reviewed the ...
3
votes
1answer
77 views

circle for each number in the algorithm

Is there an algorithm package that allows me to achieve the style of the algorithms where each number is inside a circle in an algorithm? I am interested specifically in the numbering of the steps by ...
1
vote
1answer
84 views

number line with different interval

I'm new to the latex and I'm wondering how I can create a number line with different interval and labeled letter like this:
3
votes
1answer
54 views

Environment with its own line numbers

I would like to create an environment with its own line numbers, that is to say: (1) the lines within this environment are not counted by lineno (2) it has a continuous line numbering itself, with ...
0
votes
0answers
24 views

How do I define a more stable numbering of proof steps with letters

I have some proofs that require many steps, and I wanted to number them with letters so as to not confuse with the numbers used for Definitions, Axioms, Lemmas and Theorems. Here is a MWE of what I ...
2
votes
2answers
1k views

How to remove line numbers from my paper?

I am using the template of MDPI https://www.mdpi.com/data/MDPI_template.zip?v=20201020 I wonder how can I remove line numbers next to each line? % LaTeX support: latex@mdpi.com % In case you need ...
0
votes
0answers
28 views

How to not count lines in a part of a latex document with lineo?

I am using lineo with revtex to count lines in my latex documents. I would like to not count lines for a small part of the document but still count for the rest of the document. Do you know how I can ...
0
votes
0answers
16 views

Resize line numbering

I use Texmaker to help with writing in LaTex. I have added line-numbering to the draft of my thesis. The size of the line number is a bit too small. Is there a way to make the size a bit bigger? The ...
3
votes
1answer
28 views

Empty line number when removing date

I have line numbers displayed and no date after the title. However, if I remove the date with \date{} there is a line number left in the empty line after the title. How can I remove it? Here is the ...
0
votes
1answer
59 views

latex linenumbers do not work properly

I am having some problem with lineno. Specifically, this happens when I introduce the first equation in my document. I the following example I get a wrong numbering of text lines in the latex ...
1
vote
1answer
62 views

Listings: skip line number ONLY where command is defined

I have looked at the following: Suppress line numbering for empty lines in listings package Suppress line numbering for specific lines in listings package However, the solution given in the latter ...
0
votes
1answer
53 views

Disabling Line Number in Section Titles not Working

I am trying to apply the answer to this question in Overleaf. I want to number my lines but I don't want the chapter/section titles to be numbered. I'm running into errors when applying the answer. ...
0
votes
0answers
15 views

Line numbering within pages with listings package

When I use listings package as is, line numbers appear in the margin and the listing lines start at the margin. I know a workaround of putting each listing into a minipage with \noindent, but it is ...
0
votes
0answers
526 views

LaTeX listings package JSON formatting

I am using package listings for JSON data. I am following this example How to improve listings display of JSON files from this stackexchange answer. It generates the following output: I added caption ...
0
votes
1answer
26 views

First number and captions in listings environment

I am using listings to display code and I added firstnumber and caption but it doesn't appears to work. There's an example: \documentclass[11pt,fleqn]{book} % Default font size and left-justified ...
0
votes
1answer
53 views

Continue linenumbering between sections in reledmac + reledpar

I am helping my girlfrien with her thesis (a commented edition and translation of an old occitan poem). The main portion of the work is the critical edition: a chapter in which she divided the poem's ...
0
votes
0answers
15 views

Quotes within numbered text: position of line numbers

I am wondering if, for an indented passage (a quote) it would be possible to shift reledmac's line numbering from the margin into the gap left by the indentation? The following MWE \documentclass{...
1
vote
1answer
32 views

poemscol: How to fix slight indent with \startverseline?

I'm using \startverseline to get my line numbers aligned with the beginning of a runover line (as described in the poemscol manual, 3.3.2). The line number is now in the right place, but the line is ...
1
vote
1answer
56 views

code input with linenumbers

I write a thesis and want to have my code/textfile in the appendix. I dont want to copy the code, I only want to write the path of my file into tex. I already tried \verbatiminput{main.py} and \...
3
votes
1answer
212 views

Enumerating from highest number to the lowest

I would like to know if there is a way to get an enumerate list in LaTeX such that if I write a total of N items, then I get N. Item numeber N N - 1. Item number N - 1 ... 1. Item number 1 So if N = ...
3
votes
1answer
90 views

Central line number for large function with algorithm2e

I have an algorithm (using algorithm2e) where I need a big function, so I want to enter it as an equation. But the line numbering seems a bit weird, as it numbers an empty line. I want the number to ...
0
votes
1answer
83 views

set margin 7 mm from left lineno internal line numbers

I am trying to set a 7 mm margin from the left on my pseudocode. I am using lineno package and this is what I wrote: \lipsum[2-4] \begin{alltt}{\footnotesize{\internallinenumbers S = \(\emptyset\) ...
0
votes
1answer
101 views

Line numbering problem with the AIP template

I am writing a paper based on the AIP template, and I want to add the line number. I tried with lineno, but it has some problems: as a standard (you can see that by opening the template in Overleaf), ...
1
vote
1answer
58 views

Combining linerange, firstnumber and consecutivenumbers leads to non-consecutive numbers

If I use linerange, firstnumber and consecutivenumbers with line markers it results in non-consecutive line numbers. MWE: \documentclass[a4paper]{article} \usepackage{listings} \begin{filecontents}{...
1
vote
2answers
30 views

Hide the numbering of some lines in algorithmc

I have the following LaTeX algorithm's code. I just need to hide the numbering of the first three lines; any suggestions? \documentclass{article} \usepackage{algorithm} \usepackage{algorithmic} \...
0
votes
1answer
44 views

Line numbering outside a box

I have problems getting a line numbering similar to that in the picture. I created the box with \frambox{\parbox{ but with the command \linenumbers I only get the whole box numbered with a 1. I ...
4
votes
1answer
63 views

Don't reset line numbers using Verse package

I would like line numbers to not reset when using verse environment. Consider this MWE: \documentclass{book} \usepackage{verse} \poemlines{5} \begin{document} \chapter{} \begin{verse} Lorem ipsum ...
1
vote
2answers
124 views

Find the line number inside a vbox (at end of paragraph), and change the behavior of a macro that follows next

Edit: I have added a luatex solution as an answer to my question. I have a \vbox in which I plan to typeset long material (long poetry), the way it is typeset is slightly unique. There is a special ...
0
votes
1answer
86 views

How to add title on line numbers?

So I am using the function \linenumbers which by default puts a number for each line at the left for the written text. But I somehow need a unit/title on the number but I can't find anything about ...
3
votes
2answers
200 views

Indentation of line numbers while using equations within algorithm2e

I have written some algorithms using the package algorithm2e. Some of my algorithms also include aligned formulas. My problem is that line numbers below lines ending with equations have a larger ...
2
votes
0answers
60 views

Position of line numbers using algorithm2e and fontenc [duplicate]

I want to present an algorithm with the package algorithm2e. It mostly works fine, only the position of the line numbers are wrong. The numbers are printed within the margin of the page. I figured ...

1
2 3 4 5
8