Hello everyone, thank you very much for scite, I am using it as my preferred editor. Most of the time I use it for coding python, I enjoy the syntax highlighting and code folding.
For illustration purposes I would like to use the syntax highlighting also in printed documents or presentations. This works fine with the .rtf export. But for me the latex export does not work. The .tex-file I get can not be used by my latex compiler. I can fix this when I change the definitions of the \scitea, \sciteb etc. commands and when I chose a different preamble. I have attached a sample test.py with the test.tex file generated by scite. It is not so convinient to do the necessary changes by hand all the time, so I am thinking of writing a small script that does the work for me. But before I do that: Is this problem known? Is any development going on in that direction? Another problem still remains: The whitespace doesn't work correct with my settings. When I place some tabs in my python source to left align my comments on the right hand side of the code, it is not left aligned in my pdflatex'd document. Which scite-settings should I check to correct this? I also tried the .pdf-export. I also attached the result. Unfortunately all code is in one line. Regards Lars Friedrich -- Dipl.-Ing. Lars Friedrich Optical Measurement Technology Department of Microsystems Engineering -- IMTEK University of Freiburg Georges-Köhler-Allee 102 D-79110 Freiburg Germany phone: +49-761-203-7531 fax: +49-761-203-7537 room: 01 088 email: [EMAIL PROTECTED]
class myClass: def __init__(self): print 'hello' # just a test
\documentclass[a4paper]{article}
\usepackage[a4paper,margin=2cm]{geometry}
\usepackage[T1]{fontenc}
\usepackage{color}
\usepackage{alltt}
\usepackage{times}
\newcommand{\scitea}[1]{\noindent{\ttfamily{\textcolor[rgb]{0,5, 0,5, 0,5}{\colorbox[rgb]{1,0, 1,0, 1,0}{#1}}}}}
\newcommand{\sciteb}[1]{\noindent{\ttfamily{\textcolor[rgb]{0,0, 0,5, 0,0}{\colorbox[rgb]{1,0, 1,0, 1,0}{#1}}}}}
\newcommand{\scitee}[1]{\noindent{\ttfamily{\textcolor[rgb]{0,5, 0,0, 0,5}{\colorbox[rgb]{1,0, 1,0, 1,0}{#1}}}}}
\newcommand{\scitef}[1]{\noindent{\ttfamily{\textbf{\textcolor[rgb]{0,0, 0,0, 0,5}{\colorbox[rgb]{1,0, 1,0, 1,0}{#1}}}}}}
\newcommand{\scitei}[1]{\noindent{\ttfamily{\textbf{\textcolor[rgb]{0,0, 0,0, 1,0}{\colorbox[rgb]{1,0, 1,0, 1,0}{#1}}}}}}
\newcommand{\scitej}[1]{\noindent{\ttfamily{\textbf{\textcolor[rgb]{0,0, 0,5, 0,5}{\colorbox[rgb]{1,0, 1,0, 1,0}{#1}}}}}}
\newcommand{\scitek}[1]{\noindent{\ttfamily{\textbf{\textcolor[rgb]{0,0, 0,0, 0,0}{\colorbox[rgb]{1,0, 1,0, 1,0}{#1}}}}}}
\newcommand{\sciteib}[1]{\noindent{\ttfamily{\textcolor[rgb]{0,0, 0,0, 0,0}{\colorbox[rgb]{1,0, 1,0, 1,0}{#1}}}}}
\begin{document}
Source File: test.py
\noindent
\tiny{
\scitef{class}
\scitea{ }
\scitei{myClass}
\scitek{:}
\scitea{} \\
\scitea{\hspace*{8em}}
\scitef{def}
\scitea{ }
\scitej{\_\_init\_\_}
\scitek{(}
\scitel{self}
\scitek{):}
\scitea{} \\
\scitea{\hspace*{8em}\hspace*{8em}}
\scitef{print}
\scitea{ }
\scitee{'hello'}
\scitea{\hspace*{3em}}
\sciteb{\# just a test}
} %end tiny
\end{document}
test.pdf
Description: Adobe PDF document
_______________________________________________ Scite-interest mailing list [email protected] http://mailman.lyra.org/mailman/listinfo/scite-interest
