development version newLISP 8.7.

Notices and updates
eddier
Posts: 289
Joined: Mon Oct 07, 2002 2:48 pm
Location: Blue Mountain College, MS US

Post by eddier »

Will Nigel's solution work Lutz? If it does I would like to make one suggestion. In the .tex file on the very next line after the \documentclass{article or whatever} put

Code: Select all

\usepackage{newcent}
This will make the fonts much cleaner and enable you to copy and paste text from the manual (if you click the [T] button on the toolbar).

Eddie

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

Hi Eddie,
I tried putting in \usepackage{newcent} in but it didn't change much - there possibly is something that needs to come out to let the package work. I tried taking out amsfonts but that didn't help. Anyone know the trick?

The pdf was a first try so perhaps changing use of styles, and by that fonts, in openoffice may help. Also in the long run letting latex do more and generating html and pdf etc from that may be the cleanest approach. Once a tidy latex file is achieved then Lyx may well import it cleanly and thus Lyx could be used as a friendlier editor.

Nigel

eddier
Posts: 289
Joined: Mon Oct 07, 2002 2:48 pm
Location: Blue Mountain College, MS US

Post by eddier »

If you can, show all of the stuff between \documentclass{.... and \begin{document}. Another suggestion is the ordering of the packages: try putting \usepackage{newcent} as the last package before \begin{document}

Eddie

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

Posted: http://users.cyberone.com.au/nbrown/new ... manual.tex

which is made by doing:
C:\writer2latex04>w2l.bat newlisp_manual.sxw

This is Writer2LaTeX, Version 0.4 (2005-07-01)

Starting conversion...
Done!
C:\writer2latex04>

Then loading as file into TexNicCenter and doing search&replace of \newline to nothing (ie delete \newline). This would remove a few valid formatting newlines but is a quick hack.

The .tex file upto \begin{document} is :

% This file was converted to LaTeX by Writer2LaTeX ver. 0.4
% see http://www.hj-gym.dk/~hj/writer2latex for more info
\documentclass[12pt,twoside]{article}
\usepackage[ascii]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[english]{babel}
\usepackage{amsmath,amssymb,amsfonts,textcomp}
\usepackage{color}
\usepackage{calc}
\usepackage{longtable}
\usepackage{hyperref}
\hypersetup{colorlinks=true, linkcolor=blue, filecolor=blue, pagecolor=blue, urlcolor=blue}
% Text styles
\newcommand\textstyleTeletype[1]{\textrm{#1}}
\newcommand\textstyleSourceText[1]{\texttt{#1}}
% Outline numbering
\setcounter{secnumdepth}{0}
% List styles
\newcommand\liststyleLii{%
\renewcommand\theenumi{\arabic{enumi}}
\renewcommand\labelenumi{\theenumi.}
\renewcommand\labelitemi{{\textbullet}}
\renewcommand\labelitemii{{\textbullet}}
\renewcommand\labelitemiii{{\textbullet}}
}
\newcommand\liststyleLiii{%
\renewcommand\theenumi{\arabic{enumi}}
\renewcommand\labelenumi{\theenumi.}
\renewcommand\labelitemi{{\textbullet}}
\renewcommand\labelitemii{{\textbullet}}
\renewcommand\labelitemiii{{\textbullet}}
}
\newcommand\liststyleLiv{%
\renewcommand\labelitemi{{\textbullet}}
\renewcommand\labelitemii{{\textbullet}}
\renewcommand\labelitemiii{{\textbullet}}
\renewcommand\labelitemiv{{\textbullet}}
}
\newcommand\liststyleLv{%
\renewcommand\theenumi{\arabic{enumi}}
\renewcommand\theenumii{\arabic{enumii}}
\renewcommand\theenumiii{\arabic{enumiii}}
\renewcommand\theenumiv{\arabic{enumiv}}
\renewcommand\labelenumi{\theenumi.}
\renewcommand\labelenumii{\theenumii.}
\renewcommand\labelenumiii{\theenumiii.}
\renewcommand\labelenumiv{\theenumiv.}
}
\newcommand\liststyleLvi{%
\renewcommand\theenumi{\arabic{enumi}}
\renewcommand\theenumii{\arabic{enumii}}
\renewcommand\theenumiii{\arabic{enumiii}}
\renewcommand\theenumiv{\arabic{enumiv}}
\renewcommand\labelenumi{\theenumi.}
\renewcommand\labelenumii{\theenumii.}
\renewcommand\labelenumiii{\theenumiii.}
\renewcommand\labelenumiv{\theenumiv.}
}
\newcommand\liststyleLvii{%
\renewcommand\labelitemi{{\textbullet}}
\renewcommand\labelitemii{{\textbullet}}
\renewcommand\labelitemiii{{\textbullet}}
\renewcommand\labelitemiv{{\textbullet}}
}
% Pages styles (master pages)
\makeatletter
\newcommand\ps@HTML{%
\renewcommand\@oddhead{}%
\renewcommand\@evenhead{}%
\renewcommand\@oddfoot{}%
\renewcommand\@evenfoot{}%
\setlength\paperwidth{20.999cm}\setlength\paperheight{29.699cm}\setlength\voffset{-1in}\setlength\hoffset{-1in}\setlength\topmargin{1cm}\setlength\headheight{12pt}\setlength\headsep{0cm}\setlength\footskip{12pt+0cm}\setlength\textheight{29.699cm-1cm-1cm-0cm-12pt-0cm-12pt}\setlength\oddsidemargin{2cm}\setlength\textwidth{20.999cm-2cm-1cm}
\renewcommand\thepage{\arabic{page}}
\setlength{\skip\footins}{0.101cm}\renewcommand\footnoterule{\vspace*{-0.018cm}\noindent\textcolor{black}{\rule{0.25\columnwidth}{0.018cm}}\vspace*{0.101cm}}
}
\makeatother
\pagestyle{HTML}
\setlength\tabcolsep{1mm}
\renewcommand\arraystretch{1.3}
\title{newLISP v8.7.1 Manual and Reference}
\begin{document}

Nigel

eddier
Posts: 289
Joined: Mon Oct 07, 2002 2:48 pm
Location: Blue Mountain College, MS US

Post by eddier »

I don't see any problems except that it is not loading the newcentury fonts.

You can kill the \usepackage[ascii]{inputenc} and \usepackage[T1]{fontenc} if you wish.

I even doubt wether you need the \usepackage{amsmath,amssymb,amsfonts,textcomp} since I don't think there's probably any serious math stuff going on in the manual. I have never had any font troubles with these packages except for textcomp. I'm not sure what that one does.

add

\usepackage{newcent}

where it will read

\title{newLISP v8.7.1 Manual and Reference}
\usepackage{newcent}
\begin{document}

Now, pdflatex newlisp_manual.tex twice.
The first pass gets the information for the table of contents and the links
The second pass will put that information back into the pdf file.

The text shown in acrobat should be clean and copyable.

Eddie

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

Hi Eddie,
I found it worked putting it here:

\renewcommand\labelitemiv{{\textbullet}}
}
\usepackage{newcent}
% Pages styles (master pages)
\makeatletter

The font is much clearer. Thanks!
see
http://users.cyberone.com.au/nbrown/new ... ewcent.pdf


Putting it between title and begin lost the Table of Contents.
I commented out: %\usepackage[ascii]{inputenc} OK but
commenting out \usepackage[T1]{fontenc} caused lots of error regarding \textquotedbl
commenting out \usepackage{amsmath,amssymb,amsfonts,textcomp} causes errors re \textquotesingle.

The updated .tex reads now:
% This file was converted to LaTeX by Writer2LaTeX ver. 0.4
% see http://www.hj-gym.dk/~hj/writer2latex for more info
\documentclass[12pt,twoside]{article}
%\usepackage[ascii]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[english]{babel}
\usepackage{amsmath,amssymb,amsfonts,textcomp}
\usepackage{color}
\usepackage{calc}
\usepackage{longtable}
\usepackage{hyperref}
\hypersetup{colorlinks=true, linkcolor=blue, filecolor=blue, pagecolor=blue, urlcolor=blue}
% Text styles
\newcommand\textstyleTeletype[1]{\textrm{#1}}
\newcommand\textstyleSourceText[1]{\texttt{#1}}
% Outline numbering
\setcounter{secnumdepth}{0}
% List styles
\newcommand\liststyleLii{%
\renewcommand\theenumi{\arabic{enumi}}
\renewcommand\labelenumi{\theenumi.}
\renewcommand\labelitemi{{\textbullet}}
\renewcommand\labelitemii{{\textbullet}}
\renewcommand\labelitemiii{{\textbullet}}
}
\newcommand\liststyleLiii{%
\renewcommand\theenumi{\arabic{enumi}}
\renewcommand\labelenumi{\theenumi.}
\renewcommand\labelitemi{{\textbullet}}
\renewcommand\labelitemii{{\textbullet}}
\renewcommand\labelitemiii{{\textbullet}}
}
\newcommand\liststyleLiv{%
\renewcommand\labelitemi{{\textbullet}}
\renewcommand\labelitemii{{\textbullet}}
\renewcommand\labelitemiii{{\textbullet}}
\renewcommand\labelitemiv{{\textbullet}}
}
\newcommand\liststyleLv{%
\renewcommand\theenumi{\arabic{enumi}}
\renewcommand\theenumii{\arabic{enumii}}
\renewcommand\theenumiii{\arabic{enumiii}}
\renewcommand\theenumiv{\arabic{enumiv}}
\renewcommand\labelenumi{\theenumi.}
\renewcommand\labelenumii{\theenumii.}
\renewcommand\labelenumiii{\theenumiii.}
\renewcommand\labelenumiv{\theenumiv.}
}
\newcommand\liststyleLvi{%
\renewcommand\theenumi{\arabic{enumi}}
\renewcommand\theenumii{\arabic{enumii}}
\renewcommand\theenumiii{\arabic{enumiii}}
\renewcommand\theenumiv{\arabic{enumiv}}
\renewcommand\labelenumi{\theenumi.}
\renewcommand\labelenumii{\theenumii.}
\renewcommand\labelenumiii{\theenumiii.}
\renewcommand\labelenumiv{\theenumiv.}
}
\newcommand\liststyleLvii{%
\renewcommand\labelitemi{{\textbullet}}
\renewcommand\labelitemii{{\textbullet}}
\renewcommand\labelitemiii{{\textbullet}}
\renewcommand\labelitemiv{{\textbullet}}
}
\usepackage{newcent}
% Pages styles (master pages)
\makeatletter
\newcommand\ps@HTML{%
\renewcommand\@oddhead{}%
\renewcommand\@evenhead{}%
\renewcommand\@oddfoot{}%
\renewcommand\@evenfoot{}%
\setlength\paperwidth{20.999cm}\setlength\paperheight{29.699cm}\setlength\voffset{-1in}\setlength\hoffset{-1in}\setlength\topmargin{1cm}\setlength\headheight{12pt}\setlength\headsep{0cm}\setlength\footskip{12pt+0cm}\setlength\textheight{29.699cm-1cm-1cm-0cm-12pt-0cm-12pt}\setlength\oddsidemargin{2cm}\setlength\textwidth{20.999cm-2cm-1cm}
\renewcommand\thepage{\arabic{page}}
\setlength{\skip\footins}{0.101cm}\renewcommand\footnoterule{\vspace*{-0.018cm}\noindent\textcolor{black}{\rule{0.25\columnwidth}{0.018cm}}\vspace*{0.101cm}}
}
\makeatother
\pagestyle{HTML}
\setlength\tabcolsep{1mm}
\renewcommand\arraystretch{1.3}
\title{newLISP v8.7.1 Manual and Reference}

\begin{document}


Latex still doesn't like the GPL formatting at the end - it uses a fancy table but the construct as is throws an error. I note near the end of conversion writer2latex gives an 'out of memory' error but continues and still does a reasonable job - obviously tweaking is in order.

Maybe a newlisp program to replace the html constructs in the html manual with latex format commands and then wrapping that in a latex style is the newlisp way to go! (imagine relying on java to do the newlisp manual). I'll add html2latex.lsp to my list of possible projects.


Nigel

eddier
Posts: 289
Joined: Mon Oct 07, 2002 2:48 pm
Location: Blue Mountain College, MS US

Post by eddier »

Hi Nigel,

Looks great! Strange that it lost the table of contents.
commenting out \usepackage[T1]{fontenc} caused lots of error regarding \textquotedbl
commenting out \usepackage{amsmath,amssymb,amsfonts,textcomp} causes errors re \textquotesingle.
I'm not sure why they do it that way? Maybe to avoid useing backquotes. In latex, the left single quote is ` and the left double quote is `` two of them. Yep I bet you got small black rectangle for double quotes when you commented them out no?
I'll add html2latex.lsp to my list of possible projects.
Sounds like a fun project!

I worked on a translator for document codes into both html and latex for a little. I plan to work on this some more after I have finished the college's IT Plan. Even if not for newLISP but for creating large documents at work.

Eddie

pjot
Posts: 733
Joined: Thu Feb 26, 2004 10:19 pm
Location: The Hague, The Netherlands
Contact:

Post by pjot »

The last PDF is very impressive! Very nice fonts, easy to the eyes. The PDF reads perfectly OK in Linux with Xpdf 3.01, including the hyperlinks.

Regards and thanks
Peter

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

I'm glad you like it Peter, Thanks for the help Eddie.

By the way, the cyberone servers (the ISP I use) seems to have gone down tonight for anyone trying to get the pdfs - I don't know if they are just changing their IP address and it is taking time for the DNS to propogate as I'm getting 'failure to resolve' errors but can access other sites.

Nigel

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

I'm posting some comments on newlisp_manual html tags on doc thread http://www.alh.net/newlisp/phpbb/viewto ... =5633#5633 .
They may help conversion to latex.

Nigel

Locked