I am trying to input code listings with unicode characters and everything seems to work (more or less) except some unicode characters being displayed out of order. For example instead of
służąca do obsługi
I get
łżąsuca do łobsugi
How can I fix that?
EDIT: I was asked for providing some code, but unfortunately I doubt it will be any helpful. Basically code like this:
\documentclass[11pt,polish]{article}
\usepackage{fontspec}
\usepackage{listings}
\usepackage{xunicode}
\usepackage{xltxtra}
\usepackage{babel}
\setmainfont{Charis SIL} % Some font with good unicode support
\begin{document}
\begin{lstlisting}
służący
\end{lstlisting}
\end{document}
will output this:
łżą
sucy
(yes there is a line break, I don't know where it came from, when I input code in form of a file there are characters out of order, but no line breaks).
listings
package problem like others have explained. LyX uses native engines for display in editor, not LaTeX.