[okular] [Bug 401944] Copy listings created in Latex not copied properly

2020-04-28 Thread Martin
https://bugs.kde.org/show_bug.cgi?id=401944

Martin  changed:

   What|Removed |Added

 Status|REPORTED|RESOLVED
 Resolution|--- |NOT A BUG

--- Comment #5 from Martin  ---
By default, the spacing between characters is made uniform so as to preserve
alignments (source:
https://tex.stackexchange.com/questions/99416/latex-source-code-listing-with-less-space-between-characters)

So this is not a problem of okular or any other library. This is to make the
listing clearer to read and the spaces are in the listing it self.

Setting "columns=fullflexible" solves the problem

\documentclass[10pt,a4paper]{article}
\usepackage[latin1]{inputenc}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{listings} % Syntax Highlining, Programmier sprachen
\begin{document}
\begin{lstlisting}[columns=fullflexible, language=bash,caption={Skript
um für Eclipse die Projektdateien zu erstellen}]
#!/bin/bash
sudo apt-get install libevdev-dev libglib2.0-dev
sudo apt-get install libpcre3 libpcre3-dev lzma lzma-dev
\end{lstlisting}
\end{document}

-- 
You are receiving this mail because:
You are the assignee for the bug.

[okular] [Bug 401944] Copy listings created in Latex not copied properly

2020-04-28 Thread Martin
https://bugs.kde.org/show_bug.cgi?id=401944

--- Comment #4 from Martin  ---
I tried with languate=C++ and it is the same.

I think you are right. When I mark the text, I am able to select spaces between
characters

-- 
You are receiving this mail because:
You are the assignee for the bug.

[okular] [Bug 401944] Copy listings created in Latex not copied properly

2020-04-28 Thread David Hurka
https://bugs.kde.org/show_bug.cgi?id=401944

--- Comment #3 from David Hurka  ---
No, I didn’t. But the same behavior appears in pdf.js, which is AFAIK not based
on poppler. So it must be a bug in listings. Did you try with other arguments
for the language option?

-- 
You are receiving this mail because:
You are the assignee for the bug.

[okular] [Bug 401944] Copy listings created in Latex not copied properly

2020-04-28 Thread Martin
https://bugs.kde.org/show_bug.cgi?id=401944

--- Comment #2 from Martin  ---
Did you write a bugreport for poppler or should I do that?

-- 
You are receiving this mail because:
You are the assignee for the bug.

[okular] [Bug 401944] Copy listings created in Latex not copied properly

2018-12-10 Thread David Hurka
https://bugs.kde.org/show_bug.cgi?id=401944

--- Comment #1 from David Hurka  ---
I'm sure this is not an okular bug, because it also happens with pdftotext.
pdftotext related to poppler, so it might be a poppler bug.

$ pdftotext /tmp/OkularBug.pdf
$ cat /tmp/OkularBug.txt
Listing 1: Skript um für Eclipse die Projektdateien zu erstellen
#! / b i n / b a s h
sudo apt−g e t i n s t a l l l i b e v d e v −dev l i b g l i b 2 .0− dev
sudo apt−g e t i n s t a l l l i b p c r e 3 l i b p c r e 3 −dev lzma lzma−dev

1

Looks like lstlisting with language=bash recognizes the dashes as short command
line option, and tries to do some formatting.

-- 
You are receiving this mail because:
You are the assignee for the bug.