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
27 views

Adding line numbers without lineno package

I've had several persistent issues with the lineno package and journal article templates (e.g., not numbering certain paragraphs). Is it possible to just add an "unaligned" column of line numbers on ...
1
vote
1answer
31 views

Reledmac: in-text Bible verse numbers

A nice little macro on reledmac allows replace line numbers with verse numbers. This is particularly useful for Bible verse. My question elaborates on this feature of reledmac. What should I do if, in ...
1
vote
0answers
20 views

Reledmac/Reledpar: Labeling translation paragraphs with line ranges instead of line numbers

TL;DR Rather than number my translation's lines separately, I would like to label each translation paragraph with the line range of the original language verse they translate. It doesn't seem like ...
0
votes
1answer
31 views

Reledmac hide stanza numbering in text, keep in apparatus

I've just started using reledmac to prepare a critical edition of a poem and I would like to number the stanzas automatically, hiding the stanza numbers on the left in the main text and keeping them ...
1
vote
1answer
53 views

ConTeXt: Line numbers in different margins in doublesided document

I'm numbering my lines in a double-sided ConTeXt Mkiv document like so: \usemodule[ipsum] \setuppagenumbering[alternative=doublesided] \starttext \startlinenumbering \ipsum \ipsum \ipsum \ipsum \...
1
vote
0answers
61 views

Suppress line numbering for specific lines (including blank ones) in listings package

My question is exactly the same as this one, but in my case some of the lines for which I would like to suppress line numbering are blank, and the accepted answer for that question produces an ...
2
votes
1answer
82 views

Context images / figures and linenumbering

When typesetting a document with linenumbering, I get heavy problems with images. The linenumbering becomes a mess. What do I do wrong? Here is an MWE: \setuppapersize[A5] \setupexternalfigures[...
1
vote
1answer
58 views

Line numbering for all lines of pseudocode algorithm in Lyx

I am trying to add an algorithm in pseudocode within LyX in version 2.3.2 as described here. Add the \usepackage{algorithm,algpseudocode} into the preamble Insert a algorithm block (Insert --> ...
5
votes
1answer
60 views

Switch off Old Number otf feature for line numbering in ConTeXt

I am using OldNumber features in my presentations, because I like them (de gustibus…). However they look quite odd when used to number lines. What should I do to have lines numbered the standard way ...
1
vote
0answers
71 views

reledmac - no columns - different linenumbers in left and right margin

I don't know if this is even possible but it never hurts to ask: I am transcribing a medieval Dutch manuscript in which text is displayed in two columns. I have to display it in one continuous text. ...
0
votes
1answer
58 views

reledmac linenumbers inside of the print space

Using the reledmac package I have trouble with putting the linenumbers inside of the print space (cf. picture). The code in the preamble is now simply: \usepackage[parfill]{parskip} \usepackage[...
0
votes
1answer
88 views

How to skip lines in lstlisting with dots? [duplicate]

I am wondering if package listings has a feature that can skip a few lines and substitute them with some dots, to produce something like the following 1 | error_temp = error - ((numpy.linalg.norm(b,...
1
vote
2answers
52 views

How to align line numbers horizontally with package algorithm2e

I'm trying to write an algorithm using the package algorithm2e. This is my code: \usepackage[linesnumbered,ruled]{algorithm2e} ... {\footnotesize \IncMargin{1em} \begin{algorithm}[H] \...
3
votes
1answer
29 views

usepackage[modulo]{lineno} - need also linenumber on line 1

I use lineno to number my lines, obviously. I need a number every 5 lines so I enabled the option modulo. But, because 1 mod 5 <> 0, the firstline does not get numbered. And as you already ...
4
votes
2answers
191 views

lstlisting - line number gaps

Is it possible to add non-number characters on the left of a code block? Specifically, I want to add ... to correspond with some source code (see image). I am currently using commands to stop / ...
0
votes
1answer
76 views

lineno workaround reset impossible using pagewise/switch etc

I'm having a difficulty/impossibility with the lineno package. What I want to write is a book, so double-sided, with different sections each anew beginning at 1. So the setup is quite simple and ...
4
votes
2answers
146 views

Hexadecimal line numbers in listings

Is it possible to introduce hexadecimal line numbers in steps of two using the listings package? In the MWE \documentclass{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{...
3
votes
1answer
203 views

Bible verse numbers in margin with reledmac

I'm trying to achieve something like this layout, a Bible text with verse numbers in the margins: In addition, I need footnotes linked to the verse numbers. I'm trying to make that work in reledmac, ...
0
votes
1answer
47 views

Numbering lines in an document

I wanna set some numbers at the end of an line but dont know how? Dont just wanna number some equations (for that i use "align") but in an text, if there is an important statement i wanna refer to ...
0
votes
0answers
70 views

Text overwriting line number in algorithmic environment - Solved

Below is a MWE consisting of two small algorithms demonstrating how the unnecessary use of {...} environment can cause unexpected behavior from LaTeX, i.e., overwriting line number as shown in the ...
1
vote
1answer
145 views

Continuous line numbering in lstlisting, but separate lsttableoflistings entries?

i'd like to use the name=something,firstlinenumber=auto function for continuous line numbering throughout a couple of subsequent listings in my document. I'd also like to have each of the listings ...
5
votes
2answers
338 views

How to use lineno with amsmath align?

Is there a way to have lineno show line numbers for a paragraph that uses the align environment? In the following example, the (first) paragraph that ends with \begin{align} ... \end{align} does not ...
0
votes
1answer
88 views

How to remove line numbering when using copernicus.cls

The copernicus.cls style file adds line numbering to the manuscript. I would to remove it so I can convert the pdf to word more easily (and thus share with some co-authors), however I can't seem to ...
2
votes
1answer
42 views

How to restart numbering of lines in “reledpar” package

I'm trying to learn how to use the package "reledpar". In particular I would like to have multiple texts on a page and their translations on the facing page. Thus I saw that using reledpar package (...
0
votes
1answer
119 views

Information showing up only on the first page

I'm running latex files on my device. These are the first few lines of the file: \documentclass[sigconf, anonymous, review]{acmart} \usepackage{adjustbox} \usepackage{array,booktabs} \usepackage{...
0
votes
1answer
60 views

How to force \linenumbers ignore figures in the text

I would like to include figures in the text in a journal paper immediately after Figure \ref{fig:something} so that they can be shown nearest to the texts referring to them. It works well. However, ...
3
votes
1answer
47 views

Changing listing numbers

I want to change the numbers of a listing based on certain rules: Line 10: no number Line 11 onwards: the number that corresponds to the line+5 The displayed numbers should thus be: 1, 2, 3, 4, 5, 6,...
1
vote
1answer
31 views

Item number not aligned with tasks

I have an alignment issue when using enumerate and tasks. Specifically, when I have a "blank" item with associated tasks, the item # and task # don't line up horizontally. Any suggestions would be ...
1
vote
0answers
19 views

Line numbers required in multi column text [duplicate]

Here I faced challenge for fixing line number style as like the attached image could any one help how to fix this. Note: Required style as indicated in green color MWE: \documentclass{book} \...
0
votes
1answer
243 views

How to add line numbers in selected lines to my Algorithm in Latex?

I am writing an article to submit to IEEE and, following instruction of the IEEEtran class, I am using the algorithmicx.sty package to write algorithms inside a figure environment, instead of using ...
2
votes
1answer
196 views

Lineno package in latex causes warning message

I'm trying to figure out why the line number package in latex causes a warning message. Once I add lineno package in my preamble, I receive the following message: ./lineno.sty: LaTeX Warning: Command ...
1
vote
2answers
108 views

Align equation number with any line within an `equation` environment?

Is there an environment / modification that: Works within a display math environment begin{equation} Allows for alignment of lines. Allows equation number to be aligned with any specific line, e.g. ...
1
vote
0answers
116 views

line numbers (of tex file)

I am looking for a way to annotate the pdf with line numbers (like we get with the lineno package). But I want these numbers to correspond to the line number in the source (tex) file, so I know where ...
2
votes
1answer
336 views

linenomath printing extra numbers on last line of multline, align, flalign environments

I am using \usepackage{lineno} to print line numbers on my document. My document has lots of equations. I use \usepackage{mathtools} and frequently use environments such as align, multline and ...
3
votes
1answer
563 views

Restart line numbers after every chapter

I am using the lineno package to add line numbers to my document. Is there a way to restart the numbering after every chapter? There is an option called pagewise which restarts line numbering on ...
4
votes
2answers
901 views

Turning the “line number” on in kile?

I think it is a really easy problem, but Google could not help and this searching function neither. I love kile, but the settings section is like a big mess for me. I would love to turn on a bar on ...
1
vote
1answer
207 views

elsarticle: Line number stopped in middle of document

I'm using \modulolinenumbers[5] and document class elsarticle. Line numbers worked fine till page 6 it stopped working to page 10 then it came back continuing from the number it stopped at. Can ...
0
votes
0answers
35 views

One-off redefinition of the section numbering

I use a the article class and have set the following: \renewcommand{\thesection}{\Roman{section}} \renewcommand{\@seccntformat}[1]{{\csname the#1\endcsname}.\hspace{0.5em}} This makes my \section{...
3
votes
1answer
212 views

Need to add line numbers extreme left of the page

I need to add line number in the latex {revtex4-1} generated pdf file. I am using the userpakage \usepackage{lineno} and \linenumbers after \begin{document}. It's showing the line number but very ...
0
votes
0answers
66 views

Redefine align environment with line numberig purpose

Can I redefine align (and other math environments) to obtain something like my (dumb) example? \documentclass[11pt]{article} \usepackage{amsmath} \usepackage{lineno} \linenumbers \pagestyle{empty} \...
1
vote
1answer
100 views

external cross-reference to a line number using lineno and xr-hyper

I try to reference a line number in source.tex from a dest.tex document. When (PdfLaTeX-)compiling dest, I get the following error. ! Extra \else. \@hyper@readexternallink ...#7\\{#3}{#2}{#7}\else ...
3
votes
1answer
47 views

Problems with line numbering? Line numbers clash with marginal notes

I am trying to put a numbering page inside the main text. The problem is that I am using margin notes, and want to "create" a space between the beginning of the margin notes space and the body of the ...
0
votes
1answer
42 views

Enumerate lines similarly to how equations are enumerated

Here is what I am trying to achieve. Just like equations get enumerated at the right side of the page when one uses \begin{equation} ... \end{equation}, is there a way to do the same for specific ...
0
votes
0answers
34 views

Error with line numbers

I am using IEEE journal template and after enabling the line number the text is showing error like the figure. I used this command to add line numbers \usepackage[switch,pagewise]{lineno} %\...
0
votes
1answer
53 views

Number one Eq. with (number+a,b) in an Eq. array?

I want to number two equations on one line of an equation array in the form of (number a, b), here the "number" should be the line number. Please see the following code, I try to achieve it with \eqno,...
1
vote
3answers
143 views

Paragraph and Line numbering with reledmac and sections

I want to have all my paragraphs numbered. I use the package reledmac that provides the numbering of both lines and paragraphs. Unfortunately, I cannot use \section together with it. What do I have ...
1
vote
1answer
100 views

Multiple columns in text block

I'd like to have a text with two columns and line-numbering every 5th line, starting new page each. Is there a command or package for that?
0
votes
0answers
48 views

Why there is a huge extra blank space at the beginning of this document? [duplicate]

After compiling following document, there is an extra blank space at the beginning of each page. I suspect there is an incompatibility between the lineno and pdfsync package. Is there a way to fix ...
3
votes
1answer
212 views

enumerating lines of bussproofs

EDIT: see below the original question Having got a great task of re-TeX-ing, i.e. transforming a PDF original of a lost LaTeX source back into LaTeX, I've got the recommendation to use bussproof.sty ...
2
votes
1answer
60 views

Why is \IF throwing an error?

I am writing algorithm but it is giving error. Please see the code given below: \documentclass{beamer} \usepackage{algorithm,algorithmic} \begin{document} \begin{frame} \begin{algorithmic} \STATE $...