# How do FreeBSD users LaTeX?



## Allamgir (Oct 5, 2009)

I'm considering leaving Arch Linux for FreeBSD once 8 comes out, but I need a good LaTeX setup. How do the other TeX-ies around here do it? I really shy away from many GUI solutions like Kile or Texmaker. The CLI is where it's at. However, if there's some super awesome GUI solution, I'll check it out as long as it works in a tiling wm (I like XMonad). 

Some things I would really like:
-Powerful syntax highlighting
-Easy compilation to PDF and side by side preview (not necessarily live, but I would like it to update whenever I compile)
-Time savers like autocompletion to end environments, placeholders, macros, etc.
-Look nice. If the GUI looks toally out of place on my system, I'll be hesitant to use it. I like the CLI because text is so consistent. 
-I'll post more if I think of any.

Vim? Vim-latexsuite? Emacs and AUCTeX? Gedit with a plugin? What is the best LaTeX solution around here?


----------



## Oxyd (Oct 5, 2009)

What is "the best" is highly subjective.  For me, editors/vim, print/latex for writing, with KPDF and KDVI for viewing (both from graphics/kdegraphics3) do the job.

What setup do you use on Arch?  You can most likely use exactly the same setup on FreeBSD as well.


----------



## RandomSF (Oct 5, 2009)

texlive is not hard to download and install is one of the better, more complete variants you'll find.


----------



## Allamgir (Oct 5, 2009)

Thanks for the replies!

Well, on Arch I haven't had a complete setup in a while (since I've been OS hopping for a while and FreeBSD has just piqued my interest). I've tried emacs + AUCTeX, but I found it complicated to set up â€” it's complicated to learn, but I don't mind that so much. At one point I just edited the tex source with vim and compiled separately, although I found it a slight hassle to type everything longhand and then open a new terminal to compile, then constantly update my PDF viewer by reopening the file.* Vim-latexsuite sounds interesting, but I couldn't find it in ports. Is it there/available somewhere else?




*What's a PDF viewer that updates automatically upon changes to the file?


----------



## RandomSF (Oct 5, 2009)

I use the AUCTeX plugin for vim and xpdf for viewing.  Just press R to refresh after compiling a new file.  No need to close and re-open.


----------



## Allamgir (Oct 5, 2009)

There's AUCTeX for vim? I definitely need to look this up! This is what you're talking about, right? It doesn't seem to have been updated in a while, so either that means it's dead or it's pretty much perfect (I'm hoping for the latter, since I haven't found vim-latex for FreeBSD in a way I can easily keep up to date). And I didn't know xpdf had that feature!


----------



## Oxyd (Oct 5, 2009)

Also in vim, you can just type :!latex source.tex to compile, later on it's just :! and the Up arrow which will recall the latex command from history.  Or you can write a Makefile and use the :make command. :e

As for completion, there are completion plugins for vim, although I'm not a big fan of them.  You may want to look for some, though.


----------



## RandomSF (Oct 5, 2009)

Yes, Allamgir, that's the one.  It may not be perfect, but most everything you would want is there and it's easy to modify.


----------



## vivek (Oct 5, 2009)

gedit user here. 
http://sourceforge.net/projects/gedit-latex/


----------



## Allamgir (Oct 6, 2009)

Gedit seems tempting, but doesn't it pull in a bunch of GNOME dependencies?


----------



## Allamgir (Oct 6, 2009)

Hey oxyd, I found this trick that when entering an external command in vim,
% means the file name. So I can just run :!pdflatex %

just thought you might like to know that


----------



## vermaden (Oct 6, 2009)

@Allamgir

I usually add print/tetex and print/makeindex pacakges and type whole document with plain *vi/vim*.

I also used *geany *in the past.



> -Powerful syntax highlighting


Works with both *vi/vim* and *geany*.



> -Easy compilation to PDF and side by side preview (not necessarily live, but I would like it to update whenever I compile)




```

```
I use *pdflatex *for that which is part of *tetex *port.

I also launch the new PDF every time I generate it, like that:


```
#! /bin/sh

READER=evince
TARGET=document
LATEX="pdflatex -halt-on-error"

  [ $? -eq 0 ] && ${LATEX}  ${TARGET}
  [ $? -eq 0 ] && bibtex    ${TARGET} &
  [ $? -eq 0 ] && makeindex ${TARGET}.idx &
  [ $? -eq 0 ] && ${LATEX}  ${TARGET} | tail
  [ $? -eq 0 ] && ${LATEX}  ${TARGET} | tail
  [ $? -eq 0 ] && ${READER} ${TARGET}.pdf &
```

I use it with simple *Makefile*, so everytime I want to create new PDF, I just type *make*, same for cleaning, a script for cleaning all generated stuff is cleared with *make clean*.



> -Time savers like autocompletion to end environments, placeholders, macros, etc.


If I remember *geany* autocompletes stuff, but *vi/vim* do not, at least not stock *vim*.

Also, about _macros_ you mentioned, I just use my functions in LaTeX, for code listings, for putting images and so ...


----------



## vivek (Oct 6, 2009)

Actually, I've Gnome installed and I liked the simplicity of gedit. YMMV.


----------



## dennylin93 (Oct 6, 2009)

I use Vim to do the editing, although I occasionally open up Texmaker. It's possible to set a key combination for building the PDF files in Vim.


----------



## graudeejs (Oct 6, 2009)

have you tried lyx? I like it


----------



## RandomSF (Oct 6, 2009)

Lyx, while nice for a beginner, makes LaTeX that is hard to maintain.  If you are working alone, it may work very well, but when several people are working on a doc and some of them work directly with the TeX doc, as experienced LaTeXers generally do, they will not be happy.


----------



## Oko (Oct 6, 2009)

Allamgir said:
			
		

> I'm considering leaving Arch Linux for FreeBSD once 8 comes out, but I need a good LaTeX setup. How do the other TeX-ies around here do it?


We don't. We are waiting Hiroki Sato to port TeXLive to FreeBSD from 2001 or something like that. In the mean time if you really need to use TeX with BSD you have two options. One is two switch to OpenBSD or more recently to NetBSD. The other one is to use unofficial port of Romain TartiÃ¨re which is not allowed to ports three because we do not want to hurt Mr. Sato's feelings.


----------



## Allamgir (Oct 6, 2009)

What's wrong with teTeX? Slackware uses that too.


----------



## vermaden (Oct 6, 2009)

Allamgir said:
			
		

> What's wrong with teTeX? Slackware uses that too.



I also use *tetex* without any problems, dunno whats the case generally.


----------



## Oko (Oct 6, 2009)

Allamgir said:
			
		

> What's wrong with teTeX? Slackware uses that too.


It is dead since 2005! TeXLive is only official distribution of TeX and friends for *nix. If you were serious TeX user you would know why teTeX is useless for advanced work.


----------



## Allamgir (Oct 6, 2009)

Normally I just write some essays and reports, etc. occasionally with some mathematics and Greek letters. I use the default font or Latin modern, and I set the margins with the geometry package. As long as tetex can handle that and maybe some more, I'm OK. 

But how have we not yet ported texlive? I would think the FreeBSD community could do it within 4 years!


----------



## vermaden (Oct 6, 2009)

Oko said:
			
		

> It is dead since 2005! TeXLive is only official distribution of TeX and friends for *nix. If you were serious TeX user you would know why teTeX is useless for advanced work.



Define _"advanced work"_.

I wrote my whole master's thesis in *tetex* and find it fully usable:
http://strony.toya.net.pl/~vermaden/tmp/thesis.pdf

But maybe I do not use some real advanced features, I do not feel like _\texitit{LaTeX}_ expert by any means.


----------



## Allamgir (Oct 6, 2009)

It looks like vermaden has plenty of graphics, non-English characters (which I normally don't need, but I hate when WYSIWYG or some other document/word processors have strange boxes and alignment issues with them), a well-organized table of contents and index, etc. I didn't really see any mathematics, but I would assume they work fine since the original TeX was designed to typeset math well way back in the 20th century 

So far what I'm planning to do now is use vim to edit .tex files by hand, maybe without any macros or helpers (if it really is a pain then I'll look at auctex.vim or something else), and use normal CLI commands to do my compiling. I'll view with xpdf since it has that awesome R for refresh feature.


----------



## jrick (Oct 7, 2009)

For me it's vim and Texlive (I installed it manually). I also prefer to use xelatex because of its excellent support for OpenType fonts.


----------



## mix_room (Oct 7, 2009)

vermaden said:
			
		

> But maybe I do not use some real advanced features



It is hard to say if you use advanced features or not. To me it looks like you have long document with some images included, where the images were taken from other sources 
	
	



```
\includegraphics[file.eps]
```

More complicated stuff would include drawing the images directly in LaTeX, tikz for example: http://www.texample.net/tikz/examples/timing-diagram. 

Basically anything where MS Office (or OpenOffice.org) would suffice is simply in my mind. TOC, well organized bibliography, etc etc are the basis on which LaTeX is built.


----------



## vermaden (Oct 7, 2009)

mix_room said:
			
		

> It is hard to say if you use advanced features or not. To me it looks like you have long document with some images included, where the images were taken from other sources
> 
> 
> 
> ...



Most of the graphics are SVG images exported as PDF in *Inkscape* (because I havent found a way to import SVG images into LaTeX), there are also some PNG/JPG.


```
mavio% [color="#0000ff"]cat functions.tex [/color]
% --< FUNCTIONS >-- %
% \code{df.output}{df -h}
% \cmd{cmd_xm_list.output}{Wynik polecenia xm list.}
% \nicequote{Stan Lee}{With great power comes great responsibility.}
% \notion{AMD-V}
% \todo{co to ja mialem tu zrobic?}
% \logo{150mm}{drawing.pdf}{opis}
% \imagequiet{150mm}{drawing.pdf}{opis}
% \image{drawing.pdf}{opis}
% \imagewidth{80mm}{drawing.pdf}{opis}
% \imageborder{drawing.pdf}{opis}
% \imageborderscale{drawing.pdf}{opis}
% \imageborderwidth{150mm}{drawing.pdf}{opis}

\definecolor{gray0}{rgb}{0.8, 0.8, 0.8}
\definecolor{gray1}{rgb}{0.4, 0.4, 0.4}

\newcommand{\nicequote}[2] % usage: \nicequote{Stan Lee}{With great power comes great responsibility.}
{
  \begin{quotation}
  \small
  \textit{"#2"}
  \end{quotation}
  \begin{flushright}
  \textbf{\textit{#1}}
  \end{flushright}
}

\newcommand{\code}[2] % usage: \code{df.output}{df -h}
{
  \begin{figure}[!h]
    \centering
    \fvset{frame=leftline}
    \fvset{framerule=1mm}
    \fvset{framesep=2mm}
    \fvset{rulecolor=\color{gray0}}
    \fvset{formatcom=\color{gray1}}
    \fvset{numbers=left}
    \fvset{numbersep=2mm}
    \VerbatimInput{#1}
    \caption{#2}
    \label{#1}
  \end{figure}
}

\newcommand{\cmd}[2] % usage: \cmd{cmd_xm_list.output}{Wynik polecenia xm list.}
{
  \begin{figure}[!h]
    \centering
    \fvset{frame=topline}
    \fvset{framerule=1mm}
    \fvset{framesep=2mm}
    \fvset{rulecolor=\color{gray0}}
    \fvset{formatcom=\color{gray1}}
    \VerbatimInput{#1}
    \caption{#2}
    \label{#1}
  \end{figure}
}

\newcommand{\logo}[3] % usage: \imagequiet{150mm}{drawing.pdf}{opis}
{
  \begin{figure}[!h]
    \makebox[\textwidth][r]
    {
      \includegraphics[width=#1]{#2}
    }
    \makebox[\textwidth][r]
    {
      #3
    }
  \end{figure}
}

\newcommand{\imagequiet}[3] % usage: \image{80mm}{drawing.pdf}{opis}
{
  \begin{figure}[!h]
    \centering
    \includegraphics[width=#1]{#2}
    \\
    \small{#3}
  \end{figure}
}

\newcommand{\image}[2] % usage: \image{drawing.pdf}{opis}
{
  \begin{figure}[!h]
    \centering
    \includegraphics[scale=0.75]{#1}
    \caption{#2}
    \label{#1}
  \end{figure}
}

\newcommand{\imagewidth}[3] % usage: \imagewidth{80mm}{drawing.pdf}{opis}
{
  \begin{figure}[!h]
    \centering
    \includegraphics[width=#1]{#2}
    \caption{#3}
    \label{#2}
  \end{figure}
}

\newcommand{\imageborder}[2] % usage: \imageborder{drawing.pdf}{opis}
{
  \begin{figure}[!h]
    \centering
    \setlength \fboxsep{2.0pt}
    \setlength \fboxrule{2.0pt}
    \fcolorbox{gray0}{white}{\includegraphics[scale=0.75]{#1}}
    \caption{#2}
    \label{#1}
  \end{figure}
}

\newcommand{\imageborderscale}[2] % usage: \imageborderscale{drawing.pdf}{opis}
{
  \begin{figure}[!h]
    \centering
    \setlength \fboxsep{2.0pt}
    \setlength \fboxrule{2.0pt}
    \fcolorbox{gray0}{white}{\includegraphics[width=150mm]{#1}}
    \caption{#2}
    \label{#1}
  \end{figure}
}

\newcommand{\imageborderwidth}[3] % usage: \imageborderwidth{150mm}{drawing.pdf}{opis}
{
  \begin{figure}[!h]
    \centering
    \setlength \fboxsep{2.0pt}
    \setlength \fboxrule{2.0pt}
    \fcolorbox{gray0}{white}{\includegraphics[width=#1]{#2}}
    \caption{#3}
    \label{#2}
  \end{figure}
}

\newcommand{\notion}[1] % usage: \notion{AMD-V}
{
  \index{#1}
  \textit{#1}\xspace
}

\newcommand{\todo}[1] % usage: \todo{co to ja mialem tu zrobic?}
{
  \textbf{TODO:} #1
  \xspace
}
```


```
mavio% [color="Blue"]cat thesis.skel [/color]
\documentclass[a4paper,11pt]{report}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[polish]{babel}
\selectlanguage{polish}
\usepackage{indentfirst} % for: (indent first parapgrapch after \section)
\usepackage{mathpazo}    % for: (nice font)
\usepackage{multicol}    % for: columns
\usepackage{color}       % for: \color
\usepackage{url}         % for: \url
\usepackage{fancyvrb}    % for: \VerbatimInput
\usepackage{natbib}      % for: \cite
\usepackage{graphicx}    % for: \includegraphics
\usepackage{xspace}      % for: \xspace (remove stupid spaces)
\usepackage{hyperref}    % for: \hypersetup
\usepackage{makeidx}     % for: \makeindex
\usepackage{setspace}    % for: \onehalfspacing (1.5 spacing)
\usepackage[font=small,labelfont=bf,up]{caption} % for: \caption
\makeindex
\onehalfspacing

\hoffset        = 0pt
\voffset        = 0pt
\oddsidemargin  = 0pt
\topmargin      = 0pt
\headheight     = 0pt
\headsep        = 20pt
\textheight     = 675pt
\textwidth      = 455pt
\marginparsep   = 0pt
\marginparwidth = 0pt
\footskip       = 15pt
\marginparpush  = 0pt

\hypersetup
{
  pdftitle={WIRTUALIZACJA SYSTEMÃ“W OPERACYJNYCH - SÅ‚awomir Wojciech Wojtczak},
  pdfauthor={SÅ‚awomir Wojciech Wojtczak},
  pdfsubject={WIRTUALIZACJA SYSTEMÃ“W OPERACYJNYCH},
  pdfcreator={vermaden},        % creator
  pdfkeywords={virtualization}, % keywords
  pdffitwindow=true,            % fit to window
  pdfnewwindow=true,            % links in new window
  unicode=true,                 % use unicode
  colorlinks=true,              % create color links
  linkcolor=black,              % color of internal links
  urlcolor=blue,                % color of external links
  citecolor=blue,               % color of bibliography links
  filecolor=blue                % color of file links
}

\input{functions.tex}

\begin{document}

\input{ch_cover/content.tex}

\small
\tableofcontents
\normalsize

\chapter*{WstÄ™p}
\addcontentsline{toc}{chapter}{WstÄ™p}
\input{ch_intro/content.tex}

\chapter{Wprowadzenie do wirtualizacji}
\input{ch_01/content.tex}

\chapter{DostÄ™pne maszyny wirtualne}
\input{ch_02/content.tex}

\chapter{WydajnoÅ›Ä‡ maszyn wirtualnych}
\input{ch_03/content.tex}

\chapter{PrzyszÅ‚oÅ›Ä‡ wirtualizacji}
\input{ch_04/content.tex}

\chapter{Podsumowanie}
\input{ch_05/content.tex}

\chapter*{Technikalia}
\addcontentsline{toc}{chapter}{Technikalia}
\input{ch_tech/content.tex}

\addcontentsline{toc}{chapter}{Bibliografia}
\bibliographystyle{plainnat} % other: unsrtnat/cell/jas99/abbrvnat
\bibliography{thesis.bib}
\input{SKEL}

\listoffigures
\addcontentsline{toc}{chapter}{Spis rysunkÃ³w}

\addcontentsline{toc}{chapter}{Indeks}
\printindex

\end{document}
```

Example snip from content.tex file, generally no magic there:

```
\vspace{20mm}

\section{Emulacja}

Na koniec wyjaÅ›nijmy jeszcze czym jest \notion{emulacja} systemu
operacyjnego. Polega ona na stworzeniu wirtualnego Å›rodowiska,
ktÃ³re w praktyce dla systemu guest jest postrzegane jako
kompletny komputer. Wszystkie elementy wirtualnego komputera sÄ…
programowo emulowane, miÄ™dzy innymi takie jak CPU, RAM, HDD,
GPU, BIOS i CD. Emulator, to wiÄ™c nic innego jak kolejna
aplikacja dziaÅ‚ajÄ…ca w trybie ring 3, co przedstawia
\textbf{rysunek \ref{ch_01/emulator.pdf}}. Potrzebuje on jednak
o wiele wiÄ™cej zasobÃ³w niÅ¼ typowa aplikacja aby realizowaÄ‡ swoje
zadania z sensownÄ… szybkoÅ›ciÄ….
\\

\imageborder{ch_01/emulator.pdf}{\textit{Emulator} jest po
prostu kolejnÄ… aplikacjÄ… dziaÅ‚ajÄ…cÄ… w systemie.}

WielkÄ… zaletÄ… emulacji jest moÅ¼liwoÅ›Ä‡ emulowania systemÃ³w, ktÃ³re
wymagajÄ… innej architektury sprzÄ™towej niÅ¼ architektura systemu
host, na przykÅ‚ad emulacja architektury PowerPC na
najpopularniejszej aktualnie architekturze i386, byÅ‚o to swego
czasu popularne dziÄ™ki emulatorowi \notion{PearPC}, ktÃ³ry byÅ‚
wykorzystywany do uruchamiania systemu \notion{Mac OS X} na
systemach Windows. Aktualnie najpopularniejszymi aplikacjami,
zapewniajÄ…cymi emulacjÄ™ sÄ… na \notion{QEMU} \footnote{QEMU wraz
z moduÅ‚em \textit{kqemu} moÅ¼e rÃ³wnieÅ¼ sÅ‚uÅ¼yÄ‡ jako maszyna
wirtualna} oraz \notion{Bochs}.
\\

(...)

\begin{itemize}
  \item \textbf{Equivalence (rÃ³wnowaÅ¼noÅ›Ä‡)} - Program dziaÅ‚ajÄ…cy
  pod kontrolÄ… wirtualizacji powinien zastaÄ‡ Å›rodowisko identyczne
  jak w przypadku bezpoÅ›redniego dziaÅ‚ania na tym sprzÄ™cie.

  \item \textbf{Resource Control (kontrola zasobÃ³w)} - Monitor
  musi posiadaÄ‡ peÅ‚nÄ… kontrolÄ™ nad wirtualizowanymi zasobami.

  \item \textbf{Efficiency (wydajnoÅ›Ä‡)} - Instrukcje w
  wiÄ™kszoÅ›ci muszÄ… byÄ‡ wykonywane bez interwencji monitora.
\end{itemize}
```



			
				mix_room said:
			
		

> More complicated stuff would include drawing the images directly in LaTeX, tikz for example: http://www.texample.net/tikz/examples/timing-diagram.
> 
> Basically anything where MS Office (or OpenOffice.org) would suffice is simply in my mind. TOC, well organized bibliography, etc etc are the basis on which LaTeX is built.



Ok, thanks for an example.

Generally it will be far easier (and faster) for me to draw something similar in *Inkscape* as SVG and then export it to PDF and inclide info LaTeX document, but maybe if you know LaTeX very good its faster.


----------



## vermaden (Oct 7, 2009)

-- I would do that in 1 post, but 10 000 character limit per post forces me to double post.



			
				Oko said:
			
		

> We don't. We are waiting Hiroki Sato to port TeXLive to FreeBSD from 2001 or something like that. In the mean time if you really need to use TeX with BSD you have two options. One is two switch to OpenBSD or more recently to NetBSD. The other one is to use unofficial port of Romain TartiÃ¨re which is not allowed to ports three because we do not want to hurt Mr. Sato's feelings.



There is no *texlive *in ports but ...

I have just downloaded texlive2008-20080822.iso from torrents (search for texlive2008 keyword), mounted it as usual, started installer install-tl and everything installed without any problems at /usr/local/texlive/2008


```
# [color="Blue"]cd /mnt[/color]
# [color="Blue"]ls bin | grep freebsd[/color]
amd64-freebsd
i386-freebsd
# [color="#0000ff"]./install-tl[/color]
======================> TeX Live installation procedure <=====================

=======> Note: Letters/digits in <angle brackets> indicate menu items <=======
=======>       for commands or configurable options                   <=======

 Detected platform: Intel x86 with FreeBSD
 
 <B> binary systems: 1 out of 15

 <S> Installation scheme (scheme-full)
     83 collections out of 84, disk space required: 1720 MB

 Customizing installation scheme:
   <C> standard collections
   <L> language collections

 <D> directories:
   TEXDIR (the main TeX directory):
     /usr/local/texlive/2008
   TEXMFLOCAL (directory for site-wide local files):
     /usr/local/texlive/texmf-local
   TEXMFSYSVAR (directory for variable and automatically generated data):
     /usr/local/texlive/2008/texmf-var
   TEXMFSYSCONFIG (directory for local config):
     /usr/local/texlive/2008/texmf-config
   TEXMFHOME (directory for user-specific files):
     ~/texmf

 <O> options:
   [ ] use letter size instead of A4 by default
   [X] create all format files
   [X] install macro/font doc tree
   [X] install macro/font source tree
   [ ] create symlinks in standard directories

 <V> set up for running from DVD

Other actions:
 <I> start installation to hard disk
 <H> help
 <Q> quit

Enter command:
```

After reading post install message and modifying my PATH:

```
See 
   /usr/local/texlive/2008/index.html 
 for links to documentation.  The TeX Live web site (http://tug.org/texlive/) 
 contains any updates and corrections.

 TeX Live is a joint project of the TeX user groups around the world;
 please consider supporting it by joining the group best for you. The
 list of groups is available on the web at http://tug.org/usergroups.html.

 Add /usr/local/texlive/2008/texmf/doc/man to MANPATH.
 Add /usr/local/texlive/2008/texmf/doc/info to INFOPATH.
 Most importantly, add /usr/local/texlive/2008/bin/i386-freebsd
 to your PATH for current and future sessions.

 Welcome to TeX Live!
```

My master's thesis built with *texlive *without any problems and looks the same as the one built using *tetex *package.


```
mavio% [color="Blue"]echo $PATH[/color]
/usr/local/texlive/2008/bin/i386-freebsd:/sbin:/bin:(...)

mavio% [color="#0000ff"]make[/color]
This is pdfTeXk, Version 3.1415926-1.40.9 (Web2C 7.5.7)
(...)
LaTeX2e <2005/12/01>
Babel <v3.8l>
(...)
This is makeindex, version 2.15 [20-Nov-2007] (kpathsea + Thai support).
This is BibTeX, Version 0.99c (Web2C 7.5.7)
Output written on thesis.pdf (89 pages, 2016890 bytes).
```

So there is an almost instant and easy way to have fully working *Tex Live 2008 *on FreeBSD.


----------



## vermaden (Jul 17, 2010)

Oko said:
			
		

> The other one is to use unofficial port of Romain TartiÃ¨re which is not allowed to ports three because we do not want to hurt Mr. Sato's feelings.



... so a 'great' news to all LaTeX/TeXLive users here, since Hiroki Sato has been elected to FreeBSD's core team for the next 2 years, if he suck so much, why he gets elected? (as other here say)

*source:* http://docs.freebsd.org/cgi/getmsg.cgi?fetch=11461+0+current/freebsd-announce


----------



## fronclynne (Jul 17, 2010)

vermaden said:
			
		

> ... so a 'great' news to all LaTeX/TeXLive users here, since Hiroki Sato has been elected to FreeBSD's core team for the next 2 years, if he suck so much, why he gets elected? (as other here say)
> 
> *source:* http://docs.freebsd.org/cgi/getmsg.cgi?fetch=11461+0+current/freebsd-announce



I'm dubious about Oko's *generous & factual* statements (running openBSD regularly can lead to some unexpected social side-effects, or so I hear), but instead of gum-flapping about political rumours why don't you try e-mailing the gentleman in question and asking him directly?


----------



## vermaden (Jul 18, 2010)

fronclynne said:
			
		

> but instead of gum-flapping about political rumours why don't you try e-mailing the gentleman in question and asking him directly?



I generally do not care about all that LaTeX stuff, my works are working with TeTeX package and I have TeXLive 2008 in case.


----------



## fronclynne (Jul 18, 2010)

vermaden said:
			
		

> I generally do not care about all that LaTeX stuff, my works are working with TeTeX package and I have TeXLive 2008 in case.



Ah, I just realised that you were probably arguing _against_ the slander.  My apologies.


----------



## vermaden (Jul 19, 2010)

@fronclynne

No problem mate


----------



## meine (May 19, 2020)

I just made my first LaTeX file in gvim with print/texlive-full and the Vim Latex-suite installed. Up til now I always used markdown and textproc/hs-pandoc, but want to learn more of this.

One thing I want to use is PGF and TikZ, but have to find out what packages I will have to download and where to put the files. Any hints on this are welcome!


----------



## Alain De Vos (May 20, 2020)

I think just,

```
\usepackage{pgfplots} %addplot
\pgfplotsset{compat=1.12}
\usepackage{tikz} %addplot
```


----------



## tuxador (May 20, 2020)

I've migrated 3 years ago from LaTeX /Texlive in GNU/Linux to ConTeXT, another tex derivative based on Luatex.
-  it's lightweight,the standalone version is about 250 MO including +200MO of fonts.
- it's tightly integrated with MetaPost for all the graphic stuff
-  and it can do typesetting in a grid which is excellent.
The syntax is clear and self explanatory, and there is little need to third party packages (called modules) making it's interface consistent.
ContextGarden


----------



## meine (May 20, 2020)

Alain De Vos said:


> I think just,
> 
> ```
> \usepackage{pgfplots} %addplot
> ...


Does that mean that I don't have to install any other packages or files than the print/texlive-full ?


----------



## hruodr (May 20, 2020)

As long as you can convert a graphic to encapsulated postscript, you will be able to embed it in a TeX document with standard tools (tex, dvips). For that you do not need to install texlive-bloat.

See under "Interaction with PostScript" here:






						Dvips: A DVI-to-PostScript translator
					

Dvips: A DVI-to-PostScript translator



					tug.org


----------



## SKull (May 20, 2020)

hruodr said:


> As long as you can convert a graphic to encapsulated postscript


Which is easily accomplished with ghostscript, for those wondering.


----------



## pinned (May 20, 2020)

meine said:


> One thing I want to use is PGF and TikZ, but have to find out what packages I will have to download and where to put the files. Any hints on this are welcome!



I first install print/texlive-full and then editors/texstudio

and in the  .tex file,

```
\usepackage[options]{pgf}
\usepackage[options]{tikz}
```


----------



## hruodr (May 20, 2020)

meine said:


> One thing I want to use is PGF and TikZ, but have to find out what packages I will have to download and where to put the files. Any hints on this are welcome!



If you do not want to use PGF and TikZ and do not want to download bloat, you can also write postscript, even inline in the TeX document if you want. Postscript is a language for doing that. You can google and find info.


----------



## ralphbsz (May 20, 2020)

hruodr said:


> ... For that you do not need to install texlive-bloat. ...


One man's bloat is another man's functionality. Sometimes vitally necessary functionality. I have written long documents in (La-)TeX before dvips was available (and all figures were added by using scissors and glue), with dvips (I think my PhD thesis was the first document at my university that went directly from the laser printer to the print shop, without first using scissors and glue), and with TikZ. They are all useful, but in different fashions. I seriously object to using the pejorative "bloat" to describe useful software.


----------



## hruodr (May 20, 2020)

ralphbsz said:


> I seriously object to using the pejorative "bloat" to describe useful software.



Well, let us not call the parts, not every part, but the whole a bloat. tetex was big and contained much more than enough for a normal user, texlive is an exaggeration without limits.

If you install texlive without any effort, without being selective, you have to download and install gigabytes that you do not need.

BTW. I found here an interesting source on PostScript with interesting links at the end:



			Mathematical Illustrations


----------



## blackhaz (May 20, 2020)

I am writing my stuff in TeXworks. KBibTeX to prepare bibliography. Both work absolutely fantastic and I wouldn't wish for anything else. One-button PDF generation, half a screen goes to the editor, another half to the preview. I have attached a couple of screenshots.

P.S. Holy cow this thread is ancient!


----------



## meine (May 21, 2020)

Meanwhile I played a little with a small file and some basic LaTeX code, and the result is great! Making some drawings with TikZ is relatively easy to begin with. Structuring the text and drawings is more straightforward than I thought (yes, I'll shut up when learning more complicated stuff ;-) 
This way I can make documents that go beyond the basic use of markdown, although it is a beautiful way to work.

TNX for your hints!


----------



## meine (May 21, 2020)

blackhaz said:


> P.S. Holy cow this thread is ancient!



Well, I'm not the one that gets easy with hypes, and with adding years I like doing things in a different way.

Glad this thread existed, so I knew where to find the expertise.


----------



## tuxador (May 21, 2020)

meine said:


> Meanwhile I played a little with a small file and some basic LaTeX code, and the result is great! Making some drawings with TikZ is relatively easy to begin with. Structuring the text and drawings is more straightforward than I thought (yes, I'll shut up when learning more complicated stuff ;-)
> This way I can make documents that go beyond the basic use of markdown, although it is a beautiful way to work.
> 
> TNX for your hints!


youu should try ConTeXT, you won't regret it 





						Wiki
					






					wiki.contextgarden.net


----------



## Alain De Vos (May 21, 2020)

The more i write latex the more packages i start to use. It does not mind. Just sometimes a little conflict.


----------



## hruodr (May 21, 2020)

For personal thinks I moved since years from LaTeX to plain TeX. The important thing for me was to keep the control. The original idea of Knuth was not that people use plain TeX, LaTeX, ConTeXt or anything else, but that they write their own formats. But LaTeX became the standard, for publications uniformity is demanded.


----------



## ralphbsz (May 21, 2020)

Actually, LaTeX is just as configurable as TeX is. The big difference is this: TeX is a formatting package. In a nutshell, you tell it: put this picture here. Make this paragraph right under the picture flow this way. Put a formula here, and put this number next to this formula. Print this line in bold and in a large font, and put this number in front.

LaTeX is a markup package. You don't tell it what to do, you tell it the structure of your document. I have this picture, put it where you think it will look good. This paragraph is the caption for the picture, do the right thing with it. Please number my formulas. The title of this chapter is this, do the appropriate stuff (large font, bold, chapter number). One of the beauty of LaTeX is: You do that, and the table of contents, list of figures, and such all work automagically.

Obviously, the distinction I made is exaggerated. Even in LaTeX source code, you still have lots of formatting commands, like \textbf{important} words get printed in boldface. And even native TeX has some structure commands.

Where raw TeX shines: documents where you need everything aligned just so, and are willing to spend hours tinkering with it. Like a single-page resume.

Where LaTeX shines: very large documents, where structure and cross-referencing and indexing and consistency is vital. My personal record was a 600-page document: It took 3 months to write, we had ~500 authors, and a team of 5 editors, I was the editor in charge of typesetting, graphs, and formatting. It needed a very heavyweight document processing infrastructure, and LaTeX was perfect, because we could do things like cross-referencing (in chapter 7, you say "see Section 3.A. on page 149), or a single coherent bibliography that was pulled from databases, or strict version control on figures (so an author couldn't just change a line in a graph, without some editor checking that the description remained correct: if the purple line goes down, the text can't say "up and to the right"), and stuff like that. For the final runs of running the document through latex and dvips, we used the most heavyweight machine we could afford at a time, an IBM RS/6000 that was large enough to fill a whole rack all by itself (it had several dozen disks, four CPUs, and lots of memory ... hundreds of megabytes). I remember that the final .ps output file was so large, we had to split it into 20-page groups, otherwise the print spoolers died. Then the US government printing office made us several thousand copies, which came back on a pallet by air freight (I was working for a government agency at the time).

A year later, one of our colleagues tried to do the same thing (about same complexity and length) using Microsoft word on Windows: the people they were working with were not comfortable with Unix and LaTeX, and wanted to submit text in Word. This was 1995, so the best they could do was to use Windows NT. Surprisingly enough, it worked pretty well too, and was not particularly more difficult.


----------



## hruodr (May 21, 2020)

We should not forget that TeX is a program of the end of the 1970s where there were computer users, not users of application boxes. Frequently I ask me, why I am programming in this capricious, primitive and complicated language when I only want to write a text. We use it till now perhaps only because LaTeX became a standard. I do not know a real alternative, but I suspect I would not use TeX if I would not have been using it since years and if there were not pressure from outside.


----------



## ralphbsz (May 21, 2020)

hruodr said:


> ... end of the 1970s where there were computer users, not users of application boxes.


That's actually incorrect. In the 70s, there were lots of computers. Thousands and thousands of them. Nearly all of them were application boxes. Most people who used computers didn't know how to program, nor were they expected to. They knew how to type commercial transactions into punched cards, how to load punched cards into the reader, how to run certain programs (like "accounts receivable" or "billing"), how to mount and unmount tapes to update databases, how to use the printed output of the programs. Probably 99% or 99.9% of the people who interacted with computers on a day-to-day basis had no idea how to modify its functionality, but they were very good at getting work done. For example, updating the database of how many widgets are in the warehouse, and printing invoices to the customers who had bought widgets.

I was one of those computer users, but I was also one of the programmers. I took piles of punched cards in the evening, put them into the card reader, loaded the correct forms for invoices in the line printers, pulled the correct database tapes from the shelf, and ran "billing" and "logistics". Sometimes  I would screw up, which is why we had backup tapes, and a shredder. But I was also the guy who would sit in front of a terminal during the day, and modify the COBOL source code to when the algorithm for calculating VAT (=sales tax) changed, or improve how we re-ordered widgets when we got close to running out of stock. It was only because I was working in a small company that I was able to see both sides ... being a computer user and a computer programmer. Technically, by title was "director of data processing" (Vorstandsmitglied fuer Datenverarbeitung), but that still meant that I had to mount tapes on the evening shift, and supervise the folks who operated the card punch (which were being replaced by terminals for data entry, with the same folks using both).

The myth that in the 60s and 70s people actually understood their computers is just a myth. 99% of people involved with computers used them as black boxes. Of the remaining 1% of programmers, most didn't really know how the magic smoke in the chip works, but they knew how to write in COBOL, FORTRAN, RPG-2, and get it to work. I was lucky, in that I took a series of "operating systems" classes in college (that was my minor), and built my own computers using microprocessors and wire wrap, and actually knew how to debug a program using a logic analyze or oscilloscope. From that I have drifted into making computers my profession.

There has always been a very small subset of people who try to understand computers at a deeper level, and who use them to build programs as a thing of beauty. Don Knuth and Leslie Lamport are two of the super-heroes of that very small group. It is interesting that they both were drawn to typesetting, which is what they are known best for, even though in reality, their accomplishments are much greater in other areas.



> Frequently I ask me, why I am programming in this capricious, primitive and complicated language when I only want to write a text.


The language is complicated, because it is simple. It is not the slightest bit capricious. However, it is primitive.

That's all completely on purpose. Don Knuth started to think deeply about what it means to typeset a piece of text. He started thinking about possible solutions. And he ended up deciding to solve the problem by creating a text macro expansion language (which is really all TeX is, with the minor side effects of leaving black ink on paper). And he made that macro expansion language very simple and logical. The description of how it does macro expansion fits on a few sheets of paper. One of the things he did, being the consummate theoretical computer scientist, was to include a complete (matter-of-fact Turing-complete!) processor in that macro expansion language. And the documentation of that macro expansion language, and its theory of operations, are documented in the source code of TeX itself. You can take the source code, run it through a program that's part of TeX, and prints its own documentation (that's how the "TeX: the program" series of books is generated, they are nothing but the source code of TeX in book form). So not only did he revolutionize how to typeset text, but he also revolutionized how to document programs, and how to write macro expansion engines. The reason the tool is actually usable at all is that Don is incredibly smart and a deep thinker (insert image of Don next to Rodin's "The Thinker" here), and he figures out the fundamental truths about the problems he works on (like when to tokenize a macro expansion, something that eventually gets all TeX users).

However, as is common when computer scientists try to solve real-world problems, the solution is borderline unusable. So much though that Don's friend Leslie ended up writing "a small macro package" to make TeX actually useful for real-world documents. Thence LaTeX.

There is a joke that really explains how this works. The owner of a small business needs some software to do billing and accounts receivable. He goes and hires a computer scientist, who tells him that it will take him three years to produce that software. While that seems like a long time and expensive, there is no alternative, so the business guy hires the computer scientist. After one year, he goes to ask for a progress report. Which is: I have nearly finished writing a source code editor, during the second year I will write a compiler for my new programming language, and in the third year the IO library and database. Having finished those preliminaries, writing "billing and accounts receivable" will take a week.

You think that is a joke? Yes, it is, but it is also the truth. For a real-world example, look at RMS. He was a second-rate computer scientist, who wanted to write an operating system, one that fits his particular political opinions (which include free software, free beer, and free love, not necessarily in that order). He was looking at the great computer scientists of the past, who had created towering edifices of great engineering (namely operating systems). Obviously, he was wrong: Neither Dijkstra nor Knuth wrote any famous OSes, and the guy who actually did (Fred Brooks) neither got girls nor booze out of the deal, and the resulting OS was a horrible mess and a giant cost overrun (and yes, I've had to use descendants of OS/360). But to an idealist like RMS, these details of reality don't matter. So what does he do to write that towering OS that will guarantee him a place in the pantheon? He started by writing an editor (emacs) and a compiler (gcc). What did he end up getting famously fired for? None of these projects, but proselytizing having sex with underage girls. Ultimately, his dream OS ended up being delivered by slapping the "GNU" label on Linux.


----------



## Jose (May 21, 2020)

Not everyone wrote lengthy and complex programs in the '80s




__





						More shell, less egg - All this
					






					leancrew.com


----------



## drhowarddrfine (May 21, 2020)

ralphbsz said:


> Sometimes I would screw up, which is why we had backup tapes, and a shredder.


To cover up those screw ups, I presume.


ralphbsz said:


> built my own computers using microprocessors and wire wrap, and actually knew how to debug a program using a logic analyze or oscilloscope.


Those were the good ol' days.

I found a cash register in my basement today, actually a touch screen computer, from my restaurant that we kept as a backup. I tried to get FreeBSD installed on it but it has a custom bios and wouldn't boot to a USB drive. So I took it apart and scavenged it for parts. A small hard drive, compact power supply, an LED display. I felt good and right at home.


----------



## hruodr (May 23, 2020)

But what is the lesson of the story?

C programs, or in this case Pascal/Web programs, are sure nice things, but a script with a language like perl or tcl may be easier to write, more compact, more readable, more flexible for transformations, and perhaps more efficient. It is like using libraries.



Jose said:


> Not everyone wrote lengthy and complex programs in the '80s
> 
> 
> 
> ...


----------

