all:	KBHFT.tex KBHFT.fig makefile QRCode.png;
	fig2dev -L pstex KBHFT.fig KBHFT.pstex
	fig2dev -L pstex_t -p KBHFT.pstex KBHFT.fig KBHFT.pstex_t
	latex KBHFT.tex
	latex KBHFT.tex
	dvips KBHFT.dvi -t letter -o KBHFT.ps
	ps2pdf KBHFT.ps KBHFT.pdf
	convert -density 300 -trim -scene 1 KBHFT.pdf \
		-background white KBHFT.png
	convert -geometry 400x400 -gamma 0.5 KBHFT.png KBHFT_400.jpg
	convert -geometry 320x320 -gamma 0.5 KBHFT.png KBHFT_320.jpg
	rm -f KBHFT.aux KBHFT.dvi KBHFT.log KBHFT.ps KBHFT.pstex \
		KBHFT.pstex_t KBHFT.out KBHFT.fig.bak

QRCode.png:	;
	qrencode -o QRCode.png -s 1 -m 1 \
		'http://www.math.toronto.edu/drorbn/Talks/Geneva-131024/'
