{line-numbering} is about numbering the text lines of documents or parts of them. Popular packages are `lineno` and {ledmac}.
3
votes
1answer
452 views
Code over two Pages and continue counting Lines
I'm using Minted to show my Javascript Code. It seems not possible to spread a code with Minted over two pages.
So i do it like shown in Algorithm over two pages, with itemized lists. But the Code ...
3
votes
3answers
407 views
adding captions outside of a figure or table?
For my thesis, I have written a computer program that reads in a parameter file. I want to show the parameter file in my thesis but am not sure what the best way to go about this is.
Ultimately, I ...
2
votes
1answer
88 views
Resetting line count in dtx files
I'm writing a dtx file containing several source files. Is there a way to reset the line counter when commenting the code of a different file?
My dtx file looks something like this:
....
%\iffalse
...
3
votes
2answers
279 views
algorithmic + babel with Hebrew conflict: Numbering missing
If I use algorithmic with babel, having both Hebrew and English, the line numbers go missing. Using MikTeX 2.9.
\documentclass{article}
\usepackage[hebrew,english]{babel}
\usepackage{algorithm}
...
4
votes
1answer
173 views
SLatex and line numbering?
I'm using SLaTeX to typeset some Racket source code. I would like to have line numbers along the left edge, so that I can refer to them in my document. However, I haven't yet discovered the option ...
6
votes
1answer
547 views
mdframed with tikz method: putting line numbers outside of frame
I want to number the lines in a mdframed environment with the line numbers appearing on the left of the frame, outside of it.
\documentclass{article}
\usepackage[framemethod=latex]{mdframed}
...
4
votes
1answer
498 views
Custom line numbers in lstlisting environment
I am using the lstlisting environment to display code and it works great, however for my current application I need something like:
line 1;
3.1: line 2;
line 3;
3.1.5: line 4;
...
10
votes
1answer
521 views
How to count number of lines in PDF document?
I'm using the lineno package to print line numbers (each page starts with number one) in the draft of my document:
\usepackage[switch*, pagewise]{lineno}
Is there a way to read out the number of ...
4
votes
2answers
375 views
lineno and syntax package incompatibilities
I'm using the syntax package from the mdwtools version 1996/05/17 1.07. I
successfully set the properties to show a grammar definition properly but then
when I try to combine it with the lineno ...
9
votes
1answer
1k views
Show the number of lines in margin
How to show the number of lines in a short passage like that:
(EVEN PAGE STYLE)
margin
...
3
votes
1answer
388 views
Suppress line numbering for specific lines in listings package
I would like to suppress the line numbering for specific lines in listings package by identifying the specific lines using some kind of command.
6
votes
2answers
863 views
Suppress line numbering for empty lines in listings package
The listings package quite nicely formats my pseudo code listings. Is there a way that one can specify that line numbering should be suppressed for empty lines?
2
votes
2answers
233 views
Wrong numbering of lines in lstlistings when using escaped commands
I'm using the listings package to format some Java code in my document.
I want it to number lines (1 number every 5 lines), and I need to highlight some keywords inside the code with the following ...
8
votes
1answer
2k views
Algorithm spanning more than one page
I have an algorithm which is too long to fit on one page. Someone suggested splitting the algortithm manually and then altering the second algorithm's line numbers to follow on the first. I know ...
5
votes
1answer
812 views
In listings, how to show referenced linenumbers instead of standard ascending linenumbers
I'm just writing on my master thesis and have a (specific) problem with lstlisting package in LaTeX.
I'm referring to the Random.class-file in Java and only want to print some specific line-ranges, ...
2
votes
2answers
223 views
Why is the ledmac line number misaligned with the final item?
Here's a minimal document showing the problem:
\documentclass{article}
\usepackage{ledmac}
\begin{document}
\firstlinenum{1}
\linenumincrement{1}
\beginnumbering
\pstart
\begin{itemize}
\item This ...
3
votes
1answer
258 views
Lineno \internallinenumbers - how to make a line number label within a figure?
This concerns the "lineno" package. The \linelabel directive works within the ordinary linenumbers environment. How to create a line number label within a internallinenumbers environment to be able to ...
3
votes
2answers
782 views
Changing side of line numbering in two columns documents
I'm trying to type some report and I have a small problem with the twocolums document class and the line numbering in listings.
The document is on two columns :
...
6
votes
1answer
408 views
verselinenumbersleft with twocolumn
Situation: a poem in the verse environment of the verse package, while the entire page is set with the twocolumn option. Line numbering is enabled via \poemlines{1} and set to the left by ...
6
votes
1answer
2k views
First line number in lstinputlisting environment
I use the following code to display line 23-45 of sort.cpp:
\lstinputlisting[language=C++,linerange=23-45]{sort.cpp}
However, the line numbering starts with 1 while I want it start at 23. I found ...
7
votes
1answer
833 views
Why doesn't lineno number a paragraph when it is followed by an indented equation?
While searching for the source of missing line numbers, I realized that paragraphs followed immediately by an equation have no line number, but this is fixed when a space is included,
e.g. the ...
2
votes
0answers
152 views
Source code line numbers in PDF [duplicate]
Possible Duplicate:
Extended draft mode which includes source information for manual print-out to source synchronisation
I am writing a document in LaTeX which I compile to PDF, which I ...
2
votes
4answers
517 views
How to place a program and a text side by side?
My first question is how you write a program in LaTeX, with and without a line number for each line.
The second question is, because often my program is not too large, I want to save some space for ...
7
votes
1answer
880 views
LaTeX minted package: numbering lines does not work [closed]
I'm having a problem with the minted package. When I try to add line numbering to the minted command, I get the following error:
! Package keyval Error: stepnumber undefined.
See the keyval package ...
5
votes
1answer
942 views
Listing with line numbers inside a table
I typeset a lot of listings (using the listings package) inside (array-based) tabular environments. This works like a charm, however, breaks when I pass the numbers= option to the listing:
...
5
votes
1answer
5k views
How to put a line number every line of algorithmic
I am looking for a way to have a number for every line in algorithmic:
\documentclass{article}
\usepackage{algorithm}
\usepackage{algorithmic}
\begin{document}
\begin{algorithm}
...
6
votes
1answer
613 views
Line numbers in pseudocode in figures - using lineno in figures
can someone show an example how to obtain line numbers in the alltt environment in figures, possibly using the lineno package?
I've tried:
\begin{figure}[h]
\begin{alltt}
{\linenumbers
def insert(k, ...
12
votes
1answer
861 views
How to number all lines in a draft?
I want to have a draft of a document I am writing, with the line numbers aside. I looked at some options like lineno, but this way it skips some lines. Is there a simple workaround or another package ...
4
votes
2answers
864 views
Number every line of pages
When editing documents it is convenient to have all the lines on a page numbered (on the left margin) so that the reviewer can refer to them in his report. How can I achieve this with LaTeX?
4
votes
2answers
837 views
How to add paragraph line number in right margin
In passages, the line numbers are given on the right side of the paragraph. Like this:
How could this be implemented in LaTeX?
9
votes
2answers
941 views
Lineno - numbering abstract's lines.
The package lineno.sty is not numbering my abstract's lines. Any suggestions?
Thanks.
\documentclass[a4paper,12pt]{amsart}
\usepackage{indentfirst}
\usepackage{hyperref}
\usepackage{showkeys}
...
1
vote
1answer
385 views
line numbering of minipages
I can't manage to add linenumbers left of the boxes. Can anybody help me?
\documentclass{article}
\begin{document}
\fbox{\fbox{
\begin{minipage}{0.8\linewidth}
\textbf{def} mapper (key, value):
...
7
votes
1answer
678 views
Line length in fancyvrb
What I'm doing: Typsetting source code using pygments.
What is happening: the code typsets fine, but because pygments puts the code into a Verbatim environment, some of the lines are far too long.
...
14
votes
1answer
6k views
Adding line numbers to latex and respecting equations
It's often convenient to add line numbers to a page automatically and the lineno package generally does the trick. But I've had two problems with it
It doesn't seem to align the line numbers with ...