0

I am trying to get rid of strange spacing between words in lstlisting. enter image description here

\lstnewenvironment{code}[1][]%
  {\noindent\minipage{\linewidth}\medskip 
   \lstset{basicstyle=\ttfamily\small,#1,columns=fullflexible,  sensitive=true,     language=XML,    breaklines=true,

    morekeywords={rdf,rdfs,owl,SELECT,CONSTRUCT,DESCRIBE,ASK,WHERE,FROM,NAMED,PREFIX,BASE,OPTIONAL,FILTER,GRAPH,LIMIT,OFFSET,SERVICE,UNION,EXISTS,NOT,BINDINGS,MINUS,a}
   }}
  {\endminipage}

_

\begin{code}
<http://www.example.com/humans.rdfs#hasMother> a rdf:Property;
    rdfs:label "has for mother"@en,
\end{code}
1
  • Though I did answer your question, please don't remove your code since it might be of interest for future readers!
    – Skillmon
    Commented Jul 12, 2017 at 14:31

1 Answer 1

4

In \lstset use showstringspaces=false.

1
  • 1
    Good guesswork, but this is not how the site works. The code is necessary in order for the thread be useful to other readers.
    – egreg
    Commented Jul 12, 2017 at 14:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .