From b04a635ce50752a3a7bdc61d555d16ea656d8ff8 Mon Sep 17 00:00:00 2001 From: Hardik Ghaghada Date: Tue, 31 Jul 2012 13:11:00 +0530 Subject: modified Latex scripts according to the new format & checklist --- Latex/Latex1/latex_install_script.rst | 143 ----------------- Latex/Latex1/latex_installation.rst | 217 +++++++++++++++++++++++++ Latex/Latex1/latex_installation.tex | 199 ++++++++++++++++------- Latex/Latex2/latex_intro.tex | 277 ++++++++++++++++++++------------ Latex/Latex2/latex_intro_script.rst | 145 ++++++++++------- Latex/Latex3/latex_basics.tex | 121 ++++++++++---- Latex/Latex4/Latex_Typesetting_Text.tex | 185 +++++++++++++-------- Latex/Latex4/Typesetting_Text_Latex.rst | 220 ++++++++++++++----------- Version_Control/vcs1/vcs1.rst | 41 +++-- script2col.rst | 222 +++++++++++++++++++++++++ 10 files changed, 1207 insertions(+), 563 deletions(-) delete mode 100644 Latex/Latex1/latex_install_script.rst create mode 100644 Latex/Latex1/latex_installation.rst create mode 100644 script2col.rst diff --git a/Latex/Latex1/latex_install_script.rst b/Latex/Latex1/latex_install_script.rst deleted file mode 100644 index bae8060..0000000 --- a/Latex/Latex1/latex_install_script.rst +++ /dev/null @@ -1,143 +0,0 @@ -.. Objectives -.. ---------- - -.. At the end of this tutorial, you will - -.. Install LaTeX on your computer. -.. Learn how to install a plug-in for a TeX editor. -.. Configure the TeX editor with the LaTeX plug-in. -.. Useful information on some LaTeX packages. -.. Compile a TeX file to pdf. - -.. Prerequisites -.. ------------- - -.. You'll need a TeX distribution. -.. A good text editor and a DVI or PDF viewer. -.. Updated Linux distribution as Operating System. -.. Working internet connection (for installation over the network). - - -.. Author : Kiran Isukapatla < kiran [at] fossee [dot] in > - Internal Reviewer : Kiran Isukapatla < kiran [at] fossee [dot] in > - External Reviewer : - Langauge Reviewer : - Checklist OK? : 25-Feb-2012 - -Script --------- - -.. L1 - -{{{Show the first slide containing title, name of the production team along with the logo of MHRD}}} - -.. R1 - -Hello friends, welcome to the tutorial on 'LaTeX Installation'. - -.. L2 - -{{{Show the slide containing the objectives}}} - -.. R2 - -At the end of this tutorial you will be able to - -1. Install LaTeX on your computer. -#. Learn how to install a plug-in for a TeX editor. -#. Configure the TeX editor with the LaTeX plug-in. -#. Useful information on some LaTeX packages. -#. Compile a TeX file to pdf. - -.. L3 - -{{{Show the slide 'Prerequisites'}}} - -.. R3 - -Before beginning this tutorial, make sure to have a Linux Distribution as Operating System on your computer. You would then require a TeX distribution and a Text editor of your choice. You would require a working Internet connection (for installation over the network). - -.. L4 - -{{{Show the slide 'TeX Distribution'}}} - -.. R4 - -TeX Live is an easy way to get up and running with the TeX document production system. It provides a comprehensive TeX system with binaries for most flavors of Unix, including GNU/Linux, and also Windows. - -.. L5 - -{{{Show the slide 'Installation'}}} - -.. R5 - -There are multiple ways of installation. You may download a LaTeX distribution and run the installer. -An other way is to install using the command: 'sudo apt-get install texlive' (or) 'sudo apt-get install texlive-full'. - -.. L6 - -{{{Move onto next slide of 'Installation'}}} - -.. R6 - -We may also install LaTeX using a package manager like 'Synaptic Package Manager in Ubuntu'. -Using 'Synaptic Package Manager': Open the 'Package Manager' > Search for 'texlive-full' > Mark for installation and apply. - - -.. L7 - -{{{Show the slide 'LaTeX Plug-in'}}} - -.. R7 - -We may use a Text editor (as per your choice) as LaTeX editor. However, we require a plug-in to do this. -We would like to illustrate the same using Gedit. -Install the plug-in: 'sudo apt-get install gedit-latex-plugin'. -To activate the plug-in: Click (Edit > Preferences > Plugins > Check LaTeX Plugin). - -.. L8 - -{{{Show the slide 'LaTeX Packages'}}} - -.. R8 - -Add-on features for LaTeX are known as packages. Dozens of these are pre-installed with LaTeX and can be used in your documents immediately. -Listed here are a few popular ones and their usage. - - -.. L9 - -{{{Show the slide 'Compilation'}}} - -.. R9 - -A given LaTeX document may be compiled using the command: 'pdflatex filename.tex' -This produces an output file, in the pdf format. - - -.. L10 - -{{{Show the slide 'Summary'}}} - -.. R10 - -This brings us to the end of the tutorial. In this tutorial, we have -learnt to, - -1. Install LaTeX on your computer. -#. How to install a plug-in for a TeX editor. -#. Configure the TeX editor with the LaTeX plug-in. -#. Choose a LaTeX packages as per requirement. -#. Compile a TeX file to pdf. - - -.. L11 - -{{{Show the thank you slide}}} - -.. R11 - -Hope you have enjoyed this tutorial and found it useful. -Thank you. - - diff --git a/Latex/Latex1/latex_installation.rst b/Latex/Latex1/latex_installation.rst new file mode 100644 index 0000000..867210a --- /dev/null +++ b/Latex/Latex1/latex_installation.rst @@ -0,0 +1,217 @@ +.. Objectives +.. ---------- + +.. At the end of this tutorial, you will + +.. Install LaTeX on your computer. +.. Learn how to install a plug-in for a TeX editor. +.. Configure the TeX editor with the LaTeX plug-in. +.. Useful information on some LaTeX packages. +.. Compile a TeX file to pdf. + +.. Prerequisites +.. ------------- + +.. You'll need a TeX distribution. +.. A good text editor and a DVI or PDF viewer. +.. Updated Linux distribution as Operating System. +.. Working internet connection (for installation over the network). + + +.. Author : Kiran Isukapatla < kiran [at] fossee [dot] in > + Internal Reviewer : Kiran Isukapatla < kiran [at] fossee [dot] in > + External Reviewer : + Langauge Reviewer : + Checklist OK? : 25-Feb-2012 + +Script +-------- + +.. L1 + +{{{Show the first slide containing title, name of the production team along +with the logo of MHRD}}} + +.. R1 + +Hello friends, welcome to the tutorial on 'LaTeX Installation'. + +.. L2 + +{{{Show the slide containing the objectives}}} + +.. R2 + +At the end of this tutorial you will, + +1. Learn how to install LaTeX. +#. Learn how to install a TeX editor plug-in. +#. Know how to configure the TeX editor for LaTeX. +#. Know some useful information on LaTeX packages. +#. Be able to compile a TeX file to pdf. + +.. L3 + +{{{Show the slide 'Prerequisites'}}} + +.. R3 + +Before beginning this tutorial, you will need a TeX distribution, a good text +editor, DVI or PDF viewer. Also make sure to have a Linux Distribution as +Operating System on your computer & a working internet connection for +installing LaTeX over internet. + +.. L4 + +{{{Show the slide 'TeX Distribution'}}} + +.. R4 + +TeX Live is an easy way to get up and running with the TeX document production +system. It provides a comprehensive TeX system with binaries for most flavors +of Unix, including GNU/Linux, and also Windows. + +.. L5 + +{{{Show the slide 'Installation'}}} + +.. R5 + +There are multiple ways of installation. You may download a LaTeX distribution +and run the installer. +An other way is to install using the command: 'sudo apt-get install texlive' +(or) 'sudo apt-get install texlive-full'. + +.. L6 + +{{{Move onto next slide of 'Installation'}}} + +.. R6 + +We may also install LaTeX using a package manager like 'Synaptic Package +Manager in Ubuntu'. +Using 'Synaptic Package Manager': Open the 'Package Manager' > Search for +'texlive-full' > Mark for installation and apply. + + +.. L7 + +{{{Show the slide 'LaTeX Plug-in'}}} + +.. R7 + +We may use a Text editor (as per your choice) as LaTeX editor. +However, we require a plug-in to do this. +We would like to illustrate the same using Gedit. +Install the plug-in: 'sudo apt-get install gedit-latex-plugin'. +To activate the plug-in: Click (Edit > Preferences > Plugins > +Check LaTeX Plugin). + +.. L8 + +{{{Show the slide 'LaTeX Packages'}}} + +.. R8 + +Add-on features for LaTeX are known as packages. Dozens of these are +pre-installed with LaTeX and can be used in your documents immediately. +Listed here are a few popular ones and their usage. + + +.. L9 + +{{{Show the slide 'Compilation'}}} + +.. R9 + +A given LaTeX document may be compiled to pdf using the command: +'pdflatex filename.tex' +This produces an output file, in the pdf format. + + +.. L10 + +{{{Show the slide 'Summary'}}} + +.. R10 + +This brings us to the end of the tutorial. In this tutorial, we have +learnt to, + +1. Install LaTeX on your computer. +#. Install/Configure TeX editor with LaTeX plug-in. +#. Choose a LaTeX packages as per requirement. +#. Compile a TeX file to pdf. + +.. L11 + +{{{ Show the slide 'Exercise' }}} + +.. R11 + +1. How can we check the version of the LaTeX package installed ? +2. How can we check if the plug-in is properly configured with TeX editor ? + +.. L12 + +{{{ Show the slide 'Solutions' }}} + +.. R12 + +1. Use the command latex with -v option to check the version installed +2. In the editor select the edit menu and follow the sequence + + +.. L13 + +{{{ Show the SDES & FOSSEE slide }}} + +.. R13 + +Software Development techniques for Engineers and Scientists - SDES, is an +initiative by FOSSEE. For more information, please visit the given link. + +Free and Open-source Software for Science and Engineering Education - FOSSEE, is +based at IIT Bombay which is funded by MHRD as part of National Mission on +Education through ICT. + +.. L14 + +{{{ Show the ``About the Spoken Tutorial Project'' slide }}} + +.. R14 + +Watch the video available at the following link. It summarises the Spoken +Tutorial project.If you do not have good bandwidth, you can download and +watch it. + +.. L15 + +{{{ Show the `` Spoken Tutorial Workshops'' slide }}} + +.. R15 + +The Spoken Tutorial Project Team conducts workshops using spoken tutorials, +gives certificates to those who pass an online test. + +For more details, contact contact@spoken-tutorial.org + +.. L16 + +{{{ Show the Acknowledgements slide }}} + +.. R16 + +Spoken Tutorial Project is a part of the "Talk to a Teacher" project. +It is supported by the National Mission on Education through ICT, MHRD, +Government of India. More information on this mission is available at the +given link. + +.. L17 + +{{{ Show the Thankyou slide }}} + +.. R17 + +Hope you have enjoyed this tutorial and found it useful. +Thank you! diff --git a/Latex/Latex1/latex_installation.tex b/Latex/Latex1/latex_installation.tex index ca64d44..22e0286 100644 --- a/Latex/Latex1/latex_installation.tex +++ b/Latex/Latex1/latex_installation.tex @@ -5,74 +5,86 @@ % Copyright (c) 2009, FOSSEE, IIT Bombay %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\documentclass[14pt,compress]{beamer} - +\documentclass[17pt,compress]{beamer} +\usepackage{beamerthemesplit} \mode { \usetheme{Warsaw} \useoutertheme{infolines} \setbeamercovered{transparent} + \setbeamertemplate{navigation symbols}{} } +% Taken from Fernando's slides. +\usepackage{ae,aecompl} +\usepackage[scaled=.95]{helvet} \usepackage[english]{babel} \usepackage[latin1]{inputenc} -%\usepackage{times} \usepackage[T1]{fontenc} -% Taken from Fernando's slides. -\usepackage{ae,aecompl} -\usepackage{mathpazo,courier,euler} -\usepackage[scaled=.95]{helvet} +% change the alerted colour to LimeGreen +\definecolor{LimeGreen}{RGB}{50,205,50} +\setbeamercolor{structure}{fg=LimeGreen} +\author[FOSSEE]{} +\institute[IIT Bombay]{} +\date[]{} +% \setbeamercovered{transparent} -\definecolor{darkgreen}{rgb}{0,0.5,0} +% theme split +\usepackage{verbatim} +\newenvironment{colorverbatim}[1][]% +{% +\color{blue} +\verbatim +}% +{% +\endverbatim +}% +\usepackage{mathpazo,courier,euler} \usepackage{listings} -\lstset{language=bash, +\lstset{language=sh, basicstyle=\ttfamily\bfseries, - commentstyle=\color{red}\itshape, - stringstyle=\color{darkgreen}, showstringspaces=false, - keywordstyle=\color{blue}\bfseries} - -\newcommand{\inctime}[1]{\addtocounter{time}{#1}{\tiny \thetime\ m}} + keywordstyle=\color{black}\bfseries} -\newcommand{\typ}[1]{\lstinline{#1}} +% logo +\logo{\includegraphics[height=1.30 cm]{../images/3t-logo.pdf}} +\logo{\includegraphics[height=1.30 cm]{../images/fossee-logo.pdf} -\newcommand{\kwrd}[1]{ \texttt{\textbf{\color{blue}{#1}}} } - -\setbeamercolor{emphbar}{bg=blue!20, fg=black} -\newcommand{\emphbar}[1] +\hspace{7.5cm} +\includegraphics[scale=0.99]{../images/fossee-logo.pdf}\\ +\hspace{281pt} +\includegraphics[scale=0.80]{../images/3t-logo.pdf}} \begin{document} -\begin{frame} +\sffamily \bfseries +\title +[\LaTeX \: Installation] +{\LaTeX \:Installation} +\author +[FOSSEE] +{\small Talk to a Teacher\\{\color{blue}\url{http://spoken-tutorial.org}}\\\vspace{0.25cm}National Mission on Education + through ICT\\{\color{blue}\url{ http://sakshat.ac.in}} \\ [1.65cm] + Contributed by FOSSEE Team \\IIT Bombay \\[0.3cm] +} -\begin{center} -\vspace{12pt} -\textcolor{blue}{\huge {\LaTeX}: Installation} -\end{center} -\vspace{18pt} -\begin{center} -\vspace{10pt} -\includegraphics[scale=0.95]{fossee-logo.png}\\ -\vspace{5pt} -\scriptsize Developed by FOSSEE Team, IIT-Bombay. \\ -\scriptsize Funded by National Mission on Education through ICT\\ -\scriptsize MHRD,Govt. of India\\ -\includegraphics[scale=0.15]{images/iitb-logo.jpg}\\ -\end{center} +% slide 1 +\begin{frame} + \titlepage \end{frame} \begin{frame} \frametitle{Objectives} - At the end of this session, you will + At the end of this tutorial you will, \begin{itemize} - \item Learn how to install LaTeX - \item Learn how to install a TeX editor plug-in - \item Know how to configure the TeX editor for LaTeX - \item Know some useful information on LaTeX packages. - \item Be able to complie a TeX file to pdf. + \item Learn to install LaTeX + \item Learn to install a TeX editor plug-in + \item Learn to configure the TeX editor for LaTeX + \item Know few LaTeX packages. + \item Be able to compile a TeX file to pdf. \end{itemize} \end{frame} @@ -82,9 +94,9 @@ Prerequisites for Installation of LaTeX \begin{itemize} \item You'll need a TeX distribution. - \item A good text editor and a DVI or PDF viewer. - \item Updated Linux distribution as Operating System. - \item Working Internet connection (recommended, for installation over the network). + \item Good text editor, DVI or PDF viewer. + \item Updated Linux distribution as OS. + \item Working Internet connection (for installation over the network). \end{itemize} \end{frame} @@ -96,8 +108,8 @@ \end{itemize} Acquire TeX Live in many ways \begin{itemize} - \item Getting TeX Live on DVD (recommended, for installation from media). - \item Installing TeX Live over the Internet (recommended, for installation over the network). + \item Getting TeX Live on DVD (for installation from media). + \item Installing TeX Live over the network. \end{itemize} \end{frame} @@ -115,7 +127,7 @@ \end{frame} \begin{frame}[fragile] - \frametitle{Installation} + \frametitle{Installation..} Using a Package Manager \begin{itemize} \item Open \emph{Package Manager} @@ -137,17 +149,23 @@ \frametitle{LaTeX Packages} Recommended LaTeX Packages \begin{itemize} - \item \emph{latex-beamer} : Beamer package is used to create presentations. - \item \emph{TeXPower} : Is a bundle of style and class files for creating dynamic online presentations with LaTeX. - \item \emph{Prosper} : A LaTeX class for writing transparencies. - \item \emph{texlive-pictures} : This is a LaTeX package for drawing graphics. - \item \emph{texlive-latex-extra} : This is a large collection of add-on packages for LaTeX. + \item \emph{latex-beamer} : to create presentations. + \item \emph{TeXPower} : for dynamic online presentations. + \item \emph{Prosper} : class for writing transparencies. + \end{itemize} +\end{frame} + +\begin{frame}[fragile] + \frametitle{LaTeX Packages..} + \begin{itemize} + \item \emph{texlive-pictures} : for drawing graphics. + \item \emph{texlive-latex-extra} : add-on packages \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{Compilation} - LaTeX distribution installed, you may compile a LaTeX document + LaTeX distribution installed, you may compile a LaTeX document to pdf file \begin{itemize} \item \emph{pdflatex filename.tex} : Compiles the LaTeX document. \item Output : PDF file. @@ -158,23 +176,86 @@ \begin{frame}[fragile] \frametitle{Summary} \begin{itemize} - \item Installing a LaTeX distribution. - \item Install/Configure LaTeX Plug-in. - \item Recommended LaTeX Packages. - \item Compile a LaTeX document. + \item Install LaTeX on your computer. + \item Install/Configure TeX editor with LaTeX plug-in. + \item Choose a LaTeX package as per requirement. + \item Compile a TeX file to PDF. + \end{itemize} +\end{frame} + +\begin{frame}[fragile] + \frametitle{Exercise} + \begin{itemize} + \item How can we check the version of the LaTeX package installed ? + \item How can we check if the plug-in is properly configured with TeX + editor ? + \end{itemize} +\end{frame} + +\begin{frame}[fragile] + \frametitle{Solutions} + \begin{itemize} + \item Use the command \textit {latex -v} to check the version installed + \item Edit > Preferences > Plugins > Check LaTeX Plug-in \end{itemize} \end{frame} \begin{frame} -\begin{block}{} +\frametitle{SDES \& FOSSEE} +\begin{center} +\begin{itemize} +\item \small{SDES}\\ +\small{\color{LimeGreen}Software Development techniques for Engineers and Scientists} \\ +\scriptsize An initiative by FOSSEE. \\ +\vspace{3pt} +\scriptsize For more information on SDES, please visit {\color{blue}\url{http://fossee.in/sdes}}\\ +\vspace{12pt} +\item \small{FOSSEE}\\ +\small {\color{LimeGreen}Free and Open-source Software for \\Science and Engineering Education} \\ +\scriptsize Based at IIT Bombay, Funded by MHRD.\\ +\vspace{3pt} +\scriptsize Part of National Mission on Education through ICT (NME-ICT). \\ +\end{itemize} +\end{center} +\end{frame} + +\begin{frame} +\frametitle{About the Spoken Tutorial Project} +\begin{itemize} +\item Watch the video available at {\color{blue}\url{http://spoken-tutorial.org /What\_is\_a\_Spoken\_Tutorial}} +\item It summarises the Spoken Tutorial project +\item If you do not have good bandwidth, you can download and watch it +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Spoken Tutorial Workshops}The Spoken Tutorial Project Team +\begin{itemize} +\item Conducts workshops using spoken tutorials +\item Gives certificates to those who pass an online test +\item For more details, please write to \\ \hspace {0.5cm}{\color{blue}contact@spoken-tutorial.org} +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Acknowledgements} +\begin{itemize} +\item Spoken Tutorial Project is a part of the Talk to a Teacher project +\item It is supported by the National Mission on Education through ICT, MHRD, Government of India +\item More information on this Mission is available at: \\{\color{blue}\url{http://spoken-tutorial.org/NMEICT-Intro}} +\end{itemize} +\end{frame} + +\begin{frame} + \begin{block}{} \begin{center} - \textcolor{blue}{\Large THANK YOU!} + {\Large THANK YOU!} \end{center} \end{block} \begin{block}{} \begin{center} For more Information, visit our website\\ - \url{http://fossee.in/} + {\color{blue}\url{http://fossee.in/}} \end{center} \end{block} \end{frame} diff --git a/Latex/Latex2/latex_intro.tex b/Latex/Latex2/latex_intro.tex index eca5367..c1bda6b 100644 --- a/Latex/Latex2/latex_intro.tex +++ b/Latex/Latex2/latex_intro.tex @@ -5,75 +5,100 @@ % Copyright (c) 2009, FOSSEE, IIT Bombay %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\documentclass[12pt,compress]{beamer} - +\documentclass[17pt,compress]{beamer} +\usepackage{beamerthemesplit} \mode { \usetheme{Warsaw} \useoutertheme{infolines} \setbeamercovered{transparent} + \setbeamertemplate{navigation symbols}{} } +% Taken from Fernando's slides. +\usepackage{ae,aecompl} +\usepackage[scaled=.95]{helvet} \usepackage[english]{babel} \usepackage[latin1]{inputenc} -%\usepackage{times} \usepackage[T1]{fontenc} -% Taken from Fernando's slides. -\usepackage{ae,aecompl} -\usepackage{mathpazo,courier,euler} -\usepackage[scaled=.95]{helvet} - -\definecolor{darkgreen}{rgb}{0,0.5,0} +% change the alerted colour to LimeGreen +\definecolor{LimeGreen}{RGB}{50,205,50} +\setbeamercolor{structure}{fg=LimeGreen} +\author[FOSSEE]{} +\institute[IIT Bombay]{} +\date[]{} +% \setbeamercovered{transparent} + +% theme split +\usepackage{verbatim} +\newenvironment{colorverbatim}[1][]% +{% +\color{blue} +\verbatim +}% +{% +\endverbatim +}% +\usepackage{mathpazo,courier,euler} \usepackage{listings} \lstset{language=sh, basicstyle=\ttfamily\bfseries, - commentstyle=\color{red}\itshape, - stringstyle=\color{darkgreen}, showstringspaces=false, - keywordstyle=\color{blue}\bfseries} -\newcommand{\inctime}[1]{\addtocounter{time}{#1}{\tiny \thetime\ m}} + keywordstyle=\color{black}\bfseries} + +% logo +\logo{\includegraphics[height=1.30 cm]{../images/3t-logo.pdf}} +\logo{\includegraphics[height=1.30 cm]{../images/fossee-logo.pdf} +\hspace{7.5cm} +\includegraphics[scale=0.99]{../images/fossee-logo.pdf}\\ +\hspace{281pt} +\includegraphics[scale=0.80]{../images/3t-logo.pdf}} \newcommand{\typ}[1]{\lstinline{#1}} -\newcommand{\kwrd}[1]{ \texttt{\textbf{\color{blue}{#1}}} } -\title {Introduction to {\LaTeX}} -\author {FOSSEE} -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% DOCUMENT STARTS + \begin{document} -\begin{frame} +\sffamily \bfseries +\title +[Introduction to \LaTeX] +{Introduction to \LaTeX} +\author +[FOSSEE] +{\small Talk to a Teacher\\{\color{blue}\url{http://spoken-tutorial.org}}\\\vspace{0.25cm}National Mission on Education + through ICT\\{\color{blue}\url{ http://sakshat.ac.in}} \\ [1.65cm] + Contributed by FOSSEE Team \\IIT Bombay \\[0.3cm] +} -\begin{center} -\vspace{12pt} -\textcolor{blue}{\huge Introduction to {\LaTeX}} -\end{center} -\vspace{18pt} -\begin{center} -\vspace{10pt} -\includegraphics[scale=0.95]{../images/fossee-logo.png}\\ -\vspace{5pt} -\scriptsize Developed by FOSSEE Team, IIT-Bombay. \\ -\scriptsize Funded by National Mission on Education through ICT\\ -\scriptsize MHRD,Govt. of India\\ -\includegraphics[scale=0.30]{../images/iitb-logo.png}\\ -\end{center} +% slide 1 +\begin{frame} + \titlepage \end{frame} \begin{frame} \frametitle{Objectives} \label{sec-2} -At the end of this tutorial, you will be able to, +At the end of this tutorial, you will, \begin{itemize} \item Get acquainted to LaTeX. -\item Know why we prefer LaTeX ?? -\item Know about the advantages and disadvantages of typesetting documents using the LaTeX approach. -\item Have a description, of a typical work flow; which uses LaTeX to typeset documents. -\item Recognize and differentiate between LaTeX commands, LaTeX comments and special characters, spacing and actual document content. -\item Create and compile a very simple LaTeX document. +\item Know why we prefer LaTeX. +\item Know the advantages and disadvantages of typesetting documents in LaTeX. +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Objectives..} +\label{sec-2} + +\begin{itemize} +\item Get a brief idea on typical work flow that uses LaTeX to typeset +documents. +\item Know about LaTeX commands, comments, + special characters, spacing, actual content. +\item Be able to create and compile a simple LaTeX document. \end{itemize} \end{frame} @@ -81,61 +106,55 @@ At the end of this tutorial, you will be able to, \frametitle{Pre-requisite} \label{sec-3} - Spoken tutorial on - + Spoken tutorial on - \begin{itemize} -\item Installing {\LaTeX}. +\item {\LaTeX} Installation. \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{Introduction} - \begin{block}{{\LaTeX} - Introduction} \begin{itemize} - \item Typesetting program - \begin{itemize} - \item What is typesetting? - \end{itemize} - \item Excellently Typeset Documents - specially Math - \item Anything from one page articles to huge books - \item Pronounced \emph{Lah-tech} or \emph{Lay-tech} + \item Donald E. Knuth. + \item Typesetting program. + \item Excellently Typeset Documents - specially Math. + \item Anything from one page articles to huge books. + \item Pronounced \emph{Lah-tech} or \emph{Lay-tech}. \end{itemize} - \end{block} \end{frame} \begin{frame}[fragile] \frametitle{Why {\LaTeX}?} \begin{itemize} - \item Excellent visual quality! - \item Handles the typesetting; Lets you focus on content - \item Makes writing math extremely simple - \item It is a standard -- widely used in Scientific community + \item Excellent visual quality. + \item Handles typesetting; lets you focus on content. + \item Makes writing Math extremely simple. + \item It is a standard -- widely used in Scientific community. \end{itemize} - \begin{block}{} - \[\tilde{N}_{\mathbf{x}}\times \mathbf{r}(\mathbf{x}) f_{1k}(\mathbf{x},t) - \frac{1}{2} \tilde{N} \tilde{N}:\mathbf{BB}^{T}P(\mathbf{x},t) = -m_{k}f_{1k}(\mathbf{x},t) + 2 \mathop{\mathbf{\aa}}_{j=1}^{K} f_{1j}(\mathbf{x},t)m_{j}P_{k|j} \] - \end{block} + \[\tilde{N}_{\mathbf{x}}\times \mathbf{r}(\mathbf{x}) f_{1k} \] \end{frame} \begin{frame}[fragile] - \frametitle{Why \LaTeX? \ldots} + \frametitle{Why \LaTeX?..} \begin{itemize} - \item {\LaTeX} is a document based mark-up - \item Mark-up $\rightarrow$ a system of annotating text, adding extra - information to specify structure and presentation of text - \item Document based markup $\rightarrow$ you don't have to worry - about each element individually - \item Allows you to focus on content, rather than appearance. + \item It is a document based mark-up. + \item Mark-up: annotating text, adding + information to specify structure and presentation of text. + \item Document based markup: don't have to worry + about individual elements. + \item Allows you to focus on content. \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{Advantages of using \LaTeX } \begin{itemize} - \item Easy availablity of professional templates. + \item Availability of professional templates. \item Typesetting complex formulae in a convenient environment. - \item Can start typesetting with very little effort. - \item Presence of a lot of add-on packages. - \item Encourages creation of well structured texts. + \item Typesetting with very little effort. + \item Lot of add-on packages available. + \item Easy creation of well structured texts. \end{itemize} \end{frame} @@ -150,8 +169,8 @@ At the end of this tutorial, you will be able to, \begin{frame}[fragile] \frametitle{\LaTeX \ input file format} \begin{itemize} - \item \LaTeX takes ASCII text file as input. - \item We can compile \LaTeX files into DVI,Postscript or PDF files. + \item \LaTeX \: takes ASCII text file as input. + \item We can compile \LaTeX \: files into DVI, Postscript or PDF files. \item \alert{Note:} \typ{latex} vs. \typ{pdflatex} \end{itemize} \end{frame} @@ -162,21 +181,19 @@ At the end of this tutorial, you will be able to, \item {\LaTeX} is case sensetive. \item Commands begin with a \typ{\\} \item Environments have a \typ{\\begin} and \typ{\\end} - \item Any content after the \typ{\\end\{document\}} is ignored + \item Any content after the \typ{\\end\{document\}} is ignored. \end{itemize} \end{frame} \begin{frame}[fragile] - \frametitle{Commands,Comments\&Special Characters \ldots} + \frametitle{Commands,Comments\&Special Characters..} \begin{itemize} - \item Anything that follows a \typ{\%} symbol till end of the line - is a comment + \item Anything after \typ{\%} symbol till end of the line + is a comment. \item Special characters (\typ{\~ \# \$ \^ \& \_ \{ \}}) are escaped by a \typ{\\} - \item \typ{\\} symbol is inserted using \typ{\\textbackslash} - command - %\item \textbackslash newline or \textbackslash \textbackslash\ is used to insert newlines. - \item \typ{\\newline} or \typ{\\\\} is used to insert newlines. + \item \typ{\\} is inserted using \typ{\\textbackslash}, + \typ{\\newline} or \typ{\\\\} to insert newlines. \end{itemize} \end{frame} @@ -188,26 +205,20 @@ At the end of this tutorial, you will be able to, \begin{verbatim} \documentclass{article} \begin{document} - SciPy is open-source software for mathematics, science, and engineering. + SciPy is open-source software for mathematics, science, and + engineering. \end{document} \end{verbatim} } \end{frame} \begin{frame}[fragile] - \frametitle{Compiling to DVI } - \begin{center} - \alert{latex temp.tex} - \end{center} -\end{frame} - -\begin{frame}[fragile] - \frametitle{Compiling to PDF } - \begin{center} - \alert{pdflatex temp.tex} - \end{center} + \frametitle{Compiling to DVI and PDF} \begin{center} - \em Note: Throughout this course, we shall use pdflatex to compile our documents. + \alert{latex temp.tex} \\ + \alert{pdflatex temp.tex} \\ + \em Note: Throughout this course, we shall use pdflatex to compile our + documents. \end{center} \end{frame} @@ -219,10 +230,21 @@ At the end of this tutorial, you will be able to, \begin{itemize} \item About LaTeX. \item why we prefer LaTeX. - \item about the advantages and disadvantages of typesetting documents using the LaTeX approach. - \item A description, of a typical work flow; which uses LaTeX to typeset documents. - \item The ability to recognize and differentiate between LaTeX commands, LaTeXcomments and special characters, spacing and actual document content. - \item Created and compiled a very simple LaTeX document. + \item advantages and disadvantages of typesetting documents using + LaTeX approach. +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Summary..} +\label{sec-8} + +\begin{itemize} + \item About a typical work flow; which uses LaTeX to typeset + documents. + \item About LaTeX commands, comments, special characters, spacing, + actual document content. + \item How to create and compile a simple LaTeX document. \end{itemize} \end{frame} @@ -231,9 +253,11 @@ At the end of this tutorial, you will be able to, \frametitle{Self assessment questions} \label{sec-9} \begin{enumerate} - \item Convert the temp.dvi created during the course of this tutorial to temp\_1.ps using the dvips command. Verify that the two files indeed look the same. + \item Convert temp.dvi created in the tutorial to temp\_1.ps + using dvips command. Verify that both files look same. \vspace{8pt} - \item Convert the temp.dvi created during the course of this tutorial to temp\_1.pdf using the dvipdfm command. Verify that the two files indeed look the same. + \item Convert this temp.dvi file to temp\_1.pdf using dvipdfm command. + Verify both the files look same. \end{enumerate} \end{frame} @@ -242,35 +266,76 @@ At the end of this tutorial, you will be able to, \label{sec-10} \begin{enumerate} \item We can use the following command to convert temp.dvi to temp\_1.ps\\ - \begin{block}{} \begin{center} dvips -o temp\_1.ps temp.dvi \end{center} - \end{block} \vspace{15pt} \item We can use the following command to convert temp.dvi to temp\_1.pdf\\ - \begin{block}{} \begin{center} - dvipdfm -o temp\_1.pdf temp.dvi + dvipdfm -o temp\_1.pdf temp.dvi \end{center} - \end{block} \end{enumerate} \end{frame} +\begin{frame} +\frametitle{SDES \& FOSSEE} +\begin{center} +\begin{itemize} +\item \small{SDES}\\ +\small{\color{LimeGreen}Software Development techniques for Engineers and Scientists} \\ +\scriptsize An initiative by FOSSEE. \\ +\vspace{3pt} +\scriptsize For more information on SDES, please visit {\color{blue}\url{http://fossee.in/sdes}}\\ +\vspace{12pt} +\item \small{FOSSEE}\\ +\small {\color{LimeGreen}Free and Open-source Software for \\Science and Engineering Education} \\ +\scriptsize Based at IIT Bombay, Funded by MHRD.\\ +\vspace{3pt} +\scriptsize Part of National Mission on Education through ICT (NME-ICT). \\ +\end{itemize} +\end{center} +\end{frame} + +\begin{frame} +\frametitle{About the Spoken Tutorial Project} +\begin{itemize} +\item Watch the video available at {\color{blue}\url{http://spoken-tutorial.org /What\_is\_a\_Spoken\_Tutorial}} +\item It summarises the Spoken Tutorial project +\item If you do not have good bandwidth, you can download and watch it +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Spoken Tutorial Workshops}The Spoken Tutorial Project Team +\begin{itemize} +\item Conducts workshops using spoken tutorials +\item Gives certificates to those who pass an online test +\item For more details, please write to \\ \hspace {0.5cm}{\color{blue}contact@spoken-tutorial.org} +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Acknowledgements} +\begin{itemize} +\item Spoken Tutorial Project is a part of the Talk to a Teacher project +\item It is supported by the National Mission on Education through ICT, MHRD, Government of India +\item More information on this Mission is available at: \\{\color{blue}\url{http://spoken-tutorial.org/NMEICT-Intro}} +\end{itemize} +\end{frame} + \begin{frame} \begin{block}{} \begin{center} - \textcolor{blue}{\Large THANK YOU!} + {\Large THANK YOU!} \end{center} \end{block} \begin{block}{} \begin{center} - For more Information, visit our website\\ - \url{http://fossee.in/} + For more Information, visit our website\\ + {\color{blue}\url{http://fossee.in/}} \end{center} \end{block} \end{frame} - \end{document} diff --git a/Latex/Latex2/latex_intro_script.rst b/Latex/Latex2/latex_intro_script.rst index a5cdc57..1e5b9f7 100644 --- a/Latex/Latex2/latex_intro_script.rst +++ b/Latex/Latex2/latex_intro_script.rst @@ -49,11 +49,11 @@ At the end of this tutorial, you will #. Know why we prefer LaTeX? #. Know the advantages and disadvantages of typesetting documents using the LaTeX approach. -#. Have a description of a typical work flow; which uses LaTeX to typeset +#. Get a brief idea on typical work flow; which uses LaTeX to typeset documents. -#. Recognize and differentiate between LaTeX commands, LaTeX comments and +#. Know LaTeX commands, LaTeX comments and special characters, spacing and actual document content. -#. Be able to create and compile a very simple LaTeX document. +#. Be able to create and compile a simple LaTeX document. .. L3 @@ -63,7 +63,7 @@ At the end of this tutorial, you will Before beginning this tutorial, we would suggest having a working installation of LaTeX on your computer. You can do this by completing the tutorial on -"Installing LaTeX". +"LaTeX Installation". .. L4 @@ -72,7 +72,7 @@ of LaTeX on your computer. You can do this by completing the tutorial on .. R4 LaTeX began as TeX, a computer program originally created by -Donald E. Knuth. Its was designed mainly to aid typesetting +Donald E. Knuth. It was designed mainly to aid typesetting of text and mathematical formulae. It is a typesetting program that produces excellently typeset documents. @@ -95,7 +95,7 @@ technology. Why we prefer LaTeX? (a) LaTeX offers excellent visual quality. (b) Handles typesetting and lets you focus on content. -(c) Makes writing complex math equation extremely simple. +(c) Makes writing complex Math equation(S) extremely simple. (d) It is also a standard used widely, especially by the scientific community. .. L6 @@ -105,14 +105,14 @@ Why we prefer LaTeX? .. R6 We can define LaTex as a document based markup language. This sentence is -deceptively simple, as it reveals a lot about LaTex. We now break this sentence +deceptively simple, as it reveals a lot about LaTeX. We now break this sentence up as follows Mark-up: a system of annotating text, adding extra information to specify structure and presentation of text. Document based markup: you don’t have to worry about each element individually. This is essentially a fancy way of saying,LaTeX handles typesetting and lets -you focus on content. +you focus on content rather than appearance. .. L7 @@ -121,7 +121,7 @@ you focus on content. .. R7 Some of the advantages of using LaTeX approach to typesetting are -(1) Easy availability of professionally crafted layouts. +(1) Easy availability of professionally crafted layouts/templates. (2) Typesetting of mathematical formulae is supported in a convenient environment. (3) Typesetting for most cases can be done with very little learning curve @@ -138,8 +138,8 @@ of the document. Some of the disadvantages of using LaTeX approach to typesetting are (1) Designing a whole new layout is difficult. -(2) LaTeX is not a word processor, that is the document author is not expected -to worry about presentation details like the size of font, for example. +(2) LaTeX is not a word processor, for example, the document author +is not expected to worry about presentation details like the size of font. .. L9 @@ -149,17 +149,18 @@ to worry about presentation details like the size of font, for example. LaTeX input files are simple ASCII text files that are processed by a TeX processing engine. -Next comes the question compiling LaTeX input files and viewing the output +Next comes the question of compiling LaTeX input files and viewing the output typeset document. The process is a little different from other markup languages like HTML. -We compile ASCII text files into typeset files that are normally DVI,Postscript -or PDF files. +We compile ASCII text files into typeset files that are normally DVI, +Postscript or PDF files. The latex command converts LaTeX input files into dvi files. We can view DVI files on Gnu/Linux using xdvi. -Further DVI files can be converted either to a post script file, using the +Further, DVI files can be converted either to a post script file, using the dvips command or to a PDF file using the dvipdfm command. The command pdflatex is used to convert LaTeX input files directly to pdf files. -The resultant PDF files can be viewed using standard tools on most platforms +The resultant PDF files can be viewed using standard applications +on most platforms (Eg: evince on Gnu/Linux). PDF file are also widely supported. .. L10 @@ -168,47 +169,43 @@ The resultant PDF files can be viewed using standard tools on most platforms .. R10 -LaTeX, like most utilities in Linux, LaTeX is case sensitive. Commands begin +Like most utilities in Linux, LaTeX is case sensitive. Commands begin with a backslash. LaTeX environments have a begin and end marker. The begin and end document commands, mark the beginning and the end of the content of the LaTeX document. The text in between the begin and end commands is typeset in -the output document.Any content after \end{document} is ignored. The type of +the output document.Any content after <\end{document}> is ignored. The type of document that is being currently typeset in LaTex, is identified with the documentclass command. LaTeX then, typesets the document accordingly. -All the commands in LaTeX begin with a \. An environment begins with a begin +All the commands in LaTeX begin with a \\. An environment begins with a begin command and ends with an end command. -So, as expected LaTeX ignores anything that is written after the \end{document} -command. Essentially, anything written after the \end{document} command turns -out to be a comment. - .. L11 {{{ Show the "Commands,Comments&Special Characters ..." slide }}} .. R11 -But, how do we write comments with in the document. % is -the character to indicate comments. Anything written after a % symbol in a +But, how do we write comments with in the document. % character is used +to indicate comments. Anything written after a % symbol in a line, is ignored. But what if we wanted to insert the % symbol in the document? We can do so by -escaping it with a \ (backslash). % is one of the many special characters in -LaTeX. The others are shown on the screen. All of them, except the \ itself, -can be inserted by escaping it with a \. To insert a \ in our document, we use -the command \textbackslash. +escaping it with a \\ (backslash). % is one of the many special characters in +LaTeX. The others are shown on the screen. All of them, except the \\ itself, +can be inserted by escaping it with a \\. To insert a \\ in our document, +we use the command \textbackslash. -What would happen if we escape a \ with a \? +What would happen if we escape a \\ with a \\? A double backslash is actually another command. It inserts a new line in the typeset document. Normally LaTeX automatically spaces the given input optimally. -But, sometimes we have to insert manual line breaks. The \\ command or \newline -command is used to insert a newline in the output document. Line breaks in the -input document, do not translate into line breaks in the output document. A +But, sometimes we have to insert manual line breaks. The <\\\\> +command or <\newline> +command is used to insert a newline in the output document. A single line break in the input document, doesn't cause any change in the output document. -A single empty line causes a change in paragraphs in the output. (Multiple -empty lines are equivalent to a single empty line.) Similarly, multiple spaces +A single empty line causes a change in paragraphs in the output. Multiple +empty lines are equivalent to a single empty line. Similarly, multiple spaces are treated as a single space. .. L12 @@ -223,7 +220,7 @@ content shown on the screen in a text editor. Save the file as temp.tex .. L13 {{{continue from paused state}}} -{{{ Show the "Compiling to DVI" slide }}} +{{{ Show the "Compiling to DVI & PDF" slide }}} .. R13 @@ -234,30 +231,24 @@ The first alternative is to compile LaTeX input file into a DVI file. We use the latex command for this purpose. For compiling the LaTeX input file temp.tex into a DVI file, we use the following command -latex temp.tex. + The output file would be temp.dvi. -.. L14 - -{{{ Show the "Compiling to PDF" slide }}} - -.. R14 - The other alternative is to create PDF files from LaTeX input files. We use the pdflatex command for this purpose. For compiling the LaTeX input file temp.tex into a PDF file, we use the following command -pdflatex temp.tex + Please note that, throughout this course we shall be using pdflatex to compile our documents. -.. L15 +.. L14 {{{ Show the "Summary" slide }}} -.. R15 +.. R14 This brings us to the end of this tutorial. In this tutorial, we have learnt @@ -269,28 +260,29 @@ This brings us to the end of this tutorial. In this tutorial, we have learnt documents. #. The ability to recognize and differentiate between LaTeX commands, LaTeX comments and special characters, spacing and actual document content. -#. Created and compiled a very simple LaTeX document. +#. To Create and compile a simple LaTeX document. -.. L16 +.. L15 {{{ Show the "Self assessment questions" slide }}} -.. R16 +.. R15 Here are some self assessment questions for you to solve - 1. Convert the temp.dvi created during the course of this tutorial to temp_1.ps -using the dvips command. Verify that the two files indeed look the same. + 1. Convert the temp.dvi created during the course of this tutorial to + temp_1.ps using the dvips command. Verify that the two files + indeed look the same. 2. Convert the temp.dvi created during the course of this tutorial to temp_1.pdf using the dvipdfm command. Verify that the two files indeed look the same. -.. L17 +.. L16 {{{ Show the "Solutions" slide }}} -.. R17 +.. R16 And the answers, @@ -298,11 +290,56 @@ And the answers, 2. dvipdfm -o temp_1.pdf temp.dvi +.. L17 + +{{{ Show the SDES & FOSSEE slide }}} + +.. R17 + +Software Development techniques for Engineers and Scientists - SDES, is an +initiative by FOSSEE. For more information, please visit the given link. + +Free and Open-source Software for Science and Engineering Education - FOSSEE, is +based at IIT Bombay which is funded by MHRD as part of National Mission on +Education through ICT. + .. L18 -{{{ Show the "Thank you" slide }}} +{{{ Show the ``About the Spoken Tutorial Project'' slide }}} .. R18 +Watch the video available at the following link. It summarises the Spoken +Tutorial project.If you do not have good bandwidth, you can download and +watch it. + +.. L19 + +{{{ Show the `` Spoken Tutorial Workshops'' slide }}} + +.. R19 + +The Spoken Tutorial Project Team conducts workshops using spoken tutorials, +gives certificates to those who pass an online test. + +For more details, contact contact@spoken-tutorial.org + +.. L20 + +{{{ Show the Acknowledgements slide }}} + +.. R20 + +Spoken Tutorial Project is a part of the "Talk to a Teacher" project. +It is supported by the National Mission on Education through ICT, MHRD, +Government of India. More information on this mission is available at the +given link. + +.. L21 + +{{{ Show the Thankyou slide }}} + +.. R21 + Hope you have enjoyed this tutorial and found it useful. Thank you! diff --git a/Latex/Latex3/latex_basics.tex b/Latex/Latex3/latex_basics.tex index d09aa92..64e5ad7 100644 --- a/Latex/Latex3/latex_basics.tex +++ b/Latex/Latex3/latex_basics.tex @@ -1,4 +1,13 @@ -\documentclass{beamer} +\documentclass[17pt,compress]{beamer} +\usepackage{beamerthemesplit} +\mode +{ + \usetheme{Warsaw} + \useoutertheme{infolines} + \setbeamercovered{transparent} + \setbeamertemplate{navigation symbols}{} +} + \usepackage[T1]{fontenc} \usepackage{fixltx2e} \usepackage{graphicx} @@ -26,21 +35,51 @@ postbreak = \space\dots } +% Taken from Fernando's slides. +\usepackage{ae,aecompl} +\usepackage[scaled=.95]{helvet} -\mode -{ - \usetheme{Warsaw} - \useoutertheme{infolines} - \setbeamercovered{transparent} -} +\usepackage[english]{babel} +\usepackage[latin1]{inputenc} +\usepackage[T1]{fontenc} -\newcommand{\inctime}[1]{\addtocounter{time}{#1}{\tiny \thetime\ m}} +% change the alerted colour to LimeGreen +\definecolor{LimeGreen}{RGB}{50,205,50} +\setbeamercolor{structure}{fg=LimeGreen} +\author[FOSSEE]{} +\institute[IIT Bombay]{} +\date[]{} +% \setbeamercovered{transparent} + +% theme split +\usepackage{verbatim} +\newenvironment{colorverbatim}[1][]% +{% +\color{blue} +\verbatim +}% +{% +\endverbatim +}% + +\usepackage{mathpazo,courier,euler} +\usepackage{listings} +\lstset{language=sh, + basicstyle=\ttfamily\bfseries, + showstringspaces=false, + keywordstyle=\color{black}\bfseries} +% logo +\logo{\includegraphics[height=1.30 cm]{../images/3t-logo.pdf}} +\logo{\includegraphics[height=1.30 cm]{../images/fossee-logo.pdf} + +\hspace{7.5cm} +\includegraphics[scale=0.99]{../images/fossee-logo.pdf}\\ +\hspace{281pt} +\includegraphics[scale=0.80]{../images/3t-logo.pdf}} \newcommand{\typ}[1]{\lstinline{#1}} -\newcommand{\kwrd}[1]{ \texttt{\textbf{\color{blue}{#1}}} } -\title {{\LaTeX} basics and structure} -\author {FOSSEE} + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % DOCUMENT STARTS \begin{document} @@ -66,9 +105,11 @@ \label{sec-2} At the end of this tutorial, you will be able to, \begin{itemize} - \item Understand basic structure of a LaTeX document, its various document classes and loading packages that add new features to the LaTeX system. + \item Understand basic structure of a LaTeX document, its various document + classes and loading packages that add new features to the LaTeX system. \item Create a LaTeX document with a title and an abstract. - \item Create numbered and non-numbered sections and subsections in a LaTeX document. + \item Create numbered and non-numbered sections and subsections + in a LaTeX document. \item Create an appendix in a LaTeX document. \item Create a table of content in a LaTeX document. \end{itemize} @@ -92,7 +133,8 @@ \begin{verbatim} \documentclass{article} \begin{document} - SciPy is open-source software for mathematics, science, and engineering. + SciPy is open-source software for mathematics, science, and + engineering. \end{document} \end{verbatim} } @@ -160,7 +202,8 @@ \author{FOSSEE} \date{June 2010} \begin{document} - SciPy is open-source software for mathematics, science, and engineering. + SciPy is open-source software for mathematics, science, + and engineering. \end{document} \end{verbatim} } @@ -177,7 +220,8 @@ \date{June 2010} \begin{document} \maketitle - SciPy is open-source software for mathematics, science, and engineering. + SciPy is open-source software for mathematics, science, + and engineering. \end{document} \end{verbatim} } @@ -198,9 +242,11 @@ \begin{document} \maketitle \begin{abstract} - This document shows a glimpse of the features of Scipy that will be explored during this course. + This document shows a glimpse of the features of Scipy that will + be explored during this course. \end{abstract} - SciPy is open-source software for mathematics, science, and engineering. + SciPy is open-source software for mathematics, science, + and engineering. \end{document} \end{verbatim} } @@ -282,7 +328,8 @@ \frametitle{Appendices} \begin{itemize} \item \lstinline{\appendix} command indicates the beginning of appendices. - \item Any content after \lstinline{\appendix}, will be added to the appendix. + \item Any content after \lstinline{\appendix}, will be added + to the appendix. \item Use sectioning commands to add sections. \end{itemize} \end{frame} @@ -314,8 +361,13 @@ \begin{frame}[fragile] \frametitle{\typ{Exercise 1}} \begin{center} - Write a LaTeX script that creates a document of type article, which contains both a table of content and an appendix. The table of content should be at the beginning of the document and the appendix at the end. - The book should contain two chapters, with the first chapter containing two numbered and two un-numbered sections. The first un-numbered section should be present in the table of content. + Write a LaTeX script that creates a document of type article, which + contains both a table of content and an appendix. + The table of content should be at the beginning of the document + and the appendix at the end. + The book should contain two chapters, with the first chapter containing + two numbered and two un-numbered sections. The first un-numbered + section should be present in the table of content. \end{center} \end{frame} @@ -341,7 +393,8 @@ Numbered-Section 2 Text \section*{Un-numbered Section3} \addcontentsline{toc}{section}{Numbered Subsection1} - First un-numbered Section Text.\\This appears in the table of content + First un-numbered Section Text.\\This appears in the + table of content \section*{Un-numbered Section4} Second un-numbered Section Text \appendix @@ -358,10 +411,12 @@ \label{sec-8} In this tutorial, we have, \begin{itemize} - \item Gained an understanding of the basic structure of a LaTeX document, its various document classes and loading packages that add new features to + \item Gained an understanding of the basic structure of a LaTeX document, + its various document classes and loading packages that add new features to \item the LaTeX system. \item Created a LaTeX document with a title and an abstract. - \item Created both numbered and non-numbered sections and subsections in a LaTeX document. + \item Created both numbered and non-numbered sections and subsections + in a LaTeX document. \item Created an appendix in a LaTeX document. \item Created a table of content in a LaTeX document. \end{itemize} @@ -372,7 +427,9 @@ \label{sec-9} {\footnotesize \begin{enumerate} - \item Is the LaTeX code given below a valid input file (File compiles successfully and produces the intended result, that is to produce a book with two chapters and an appendix. + \item Is the LaTeX code given below a valid input file (File compiles +successfully and produces the intended result, that is to produce a book + with two chapters and an appendix. {\tiny \begin{center} \begin{verbatim} @@ -392,7 +449,10 @@ \end{verbatim} \end{center} } - \item subsection command can be placed at any arbitrary level. If they get numbered by default using the appropriate setcounter command and secnumdepth parameter, do they automatically appear in the table of content ?? + \item subsection command can be placed at any arbitrary level. + If they get numbered by default using the appropriate setcounter +command and secnumdepth parameter, do they automatically appear in the +table of content ?? \end{enumerate} } \end{frame} @@ -401,9 +461,14 @@ \frametitle{\typ{Solutions}} \label{sec-10} \begin{enumerate} -\item Although the given file looks syntactically valid, the output file is not what we expected. This is mainly because we are trying to use the section command to create sections in the appendix, for a document whose type is given as a book. +\item Although the given file looks syntactically valid, the output file is + not what we expected. This is mainly because we are trying to use the + section command to create sections in the appendix, for a document whose + type is given as a book. \vspace{15pt} -\item No, the \textbackslash tableofcontents command normally shows only numbered section headings, and only down to the level defined by the tocdepth counter. +\item No, the \textbackslash tableofcontents command normally shows only + numbered section headings, and only down to the level defined by the + tocdepth counter. \end{enumerate} \end{frame} diff --git a/Latex/Latex4/Latex_Typesetting_Text.tex b/Latex/Latex4/Latex_Typesetting_Text.tex index 5576521..ef4d6f9 100644 --- a/Latex/Latex4/Latex_Typesetting_Text.tex +++ b/Latex/Latex4/Latex_Typesetting_Text.tex @@ -5,63 +5,74 @@ % Copyright (c) 2009, FOSSEE, IIT Bombay %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\documentclass[14pt,compress]{beamer} - +\documentclass[17pt,compress]{beamer} +\usepackage{beamerthemesplit} \mode { \usetheme{Warsaw} \useoutertheme{infolines} \setbeamercovered{transparent} + \setbeamertemplate{navigation symbols}{} } +% Taken from Fernando's slides. +\usepackage{ae,aecompl} +\usepackage[scaled=.95]{helvet} \usepackage[english]{babel} \usepackage[latin1]{inputenc} -%\usepackage{times} \usepackage[T1]{fontenc} -% Taken from Fernando's slides. -\usepackage{ae,aecompl} -\usepackage{mathpazo,courier,euler} -\usepackage[scaled=.95]{helvet} +% change the alerted colour to LimeGreen +\definecolor{LimeGreen}{RGB}{50,205,50} +\setbeamercolor{structure}{fg=LimeGreen} +\author[FOSSEE]{} +\institute[IIT Bombay]{} +\date[]{} +% \setbeamercovered{transparent} -\definecolor{darkgreen}{rgb}{0,0.5,0} +% theme split +\usepackage{verbatim} +\newenvironment{colorverbatim}[1][]% +{% +\color{blue} +\verbatim +}% +{% +\endverbatim +}% +\usepackage{mathpazo,courier,euler} \usepackage{listings} -\lstset{language=bash, +\lstset{language=sh, basicstyle=\ttfamily\bfseries, - commentstyle=\color{red}\itshape, - stringstyle=\color{darkgreen}, showstringspaces=false, - keywordstyle=\color{blue}\bfseries} + keywordstyle=\color{black}\bfseries} -\newcommand{\inctime}[1]{\addtocounter{time}{#1}{\tiny \thetime\ m}} +% logo +\logo{\includegraphics[height=1.30 cm]{../images/3t-logo.pdf}} +\logo{\includegraphics[height=1.30 cm]{../images/fossee-logo.pdf} +\hspace{7.5cm} +\includegraphics[scale=0.99]{../images/fossee-logo.pdf}\\ +\hspace{281pt} +\includegraphics[scale=0.80]{../images/3t-logo.pdf}} \newcommand{\typ}[1]{\lstinline{#1}} -\newcommand{\kwrd}[1]{ \texttt{\textbf{\color{blue}{#1}}} } - -\setbeamercolor{emphbar}{bg=blue!20, fg=black} -\newcommand{\emphbar}[1] - - \begin{document} -\begin{frame} +\sffamily \bfseries +\title +[{\LaTeX}: Typesetting Text] +{{\LaTeX}: Typesetting Text} +\author +[FOSSEE] +{\small Talk to a Teacher\\{\color{blue}\url{http://spoken-tutorial.org}}\\\vspace{0.25cm}National Mission on Education + through ICT\\{\color{blue}\url{ http://sakshat.ac.in}} \\ [1.65cm] + Contributed by FOSSEE Team \\IIT Bombay \\[0.3cm] +} -\begin{center} -\vspace{12pt} -\textcolor{blue}{\huge {\LaTeX}: Typesetting Text} -\end{center} -\vspace{18pt} -\begin{center} -\vspace{10pt} -\includegraphics[scale=0.95]{../images/fossee-logo.png}\\ -\vspace{5pt} -\scriptsize Developed by FOSSEE Team, IIT-Bombay. \\ -\scriptsize Funded by National Mission on Education through ICT\\ -\scriptsize MHRD,Govt. of India\\ -\includegraphics[scale=0.15]{../images/iitb-logo.jpg}\\ -\end{center} +\begin{frame} + \titlepage \end{frame} \begin{frame} @@ -90,38 +101,34 @@ \item Use \'~ (apostrophe) for right quote \item For double quotes, use them twice \end{itemize} - \tiny See rev11 of \typ{hg} \end{frame} \begin{frame}[fragile] - \frametitle{Fonts - Emphasis, Fixed width, \ldots} + \frametitle{Fonts - Emphasis, Fixed width} \begin{itemize} \item \lstinline{\emph} gives emphasized or italic text \item \typ{flushleft} to have text left aligned \item \typ{flushright}, \typ{center} \end{itemize} - \tiny See rev12 of \typ{hg} \end{frame} \begin{frame}[fragile] - \frametitle{Fonts - Emphasis, Fixed width, \ldots} + \frametitle{Fonts - Emphasis, Fixed width..} \begin{itemize} \item \lstinline{\texttt} gives fixed width font \item \lstinline{\textbf} bold face font \item \lstinline{--} en dash (--); \lstinline{---} em dash (---). \end{itemize} - \tiny See rev13 of \typ{hg} \end{frame} \begin{frame}[fragile] \frametitle{Lists} \begin{itemize} - \item \lstinline{enumerate} environment is used for numbered lists - \item \lstinline{itemize} environment gives un-numbered lists - \item Each item in the list is specified using \lstinline{\item} - \item Nested lists are also easily handled, as expected + \item \lstinline{enumerate} is used for numbered lists + \item \lstinline{itemize} gives un-numbered lists + \item New item in list is specified using \lstinline{\item} + \item Nested lists are also easily handled \end{itemize} - \tiny See rev14 of \typ{hg} \end{frame} \begin{frame}[fragile] @@ -129,7 +136,6 @@ \begin{itemize} \item \typ{\\footnote} command adds a footnote \end{itemize} - \tiny See rev15 of \typ{hg} \end{frame} \begin{frame}[fragile] @@ -139,48 +145,46 @@ \item \lstinline+\ref{labelname}+ is used to refer to that element \item Compile twice \end{itemize} - \tiny See rev15 of \typ{hg} \end{frame} \begin{frame}[fragile] \frametitle{Including code} \begin{itemize} - \item Instead of using \lstinline{\texttt} we could use - \lstinline{\verbatim} + \item We could use \lstinline{\verbatim} \item \lstinline+listings+ is a powerful package \item \lstinline+\usepackage{listings}+ needs to be added - \item Tell {\LaTeX} the language to be used, using \typ{\\lstset} + \item Spefify language either by using + \small\typ{\\lstinputlisting[language=Python]} or \typ{\\lstset} \end{itemize} - \tiny See rev16 of \typ{hg} \end{frame} \begin{frame}[fragile] - \frametitle{Including code} + \frametitle{Including code..} \begin{itemize} \item Use \lstinline+\lstlisting+ for a block of code \item \typ{\\lstinline} for inline code \end{itemize} - \tiny See rev16 of \typ{hg} \end{frame} \begin{frame}[fragile] \frametitle{Summary...} \begin{itemize} - \item Put Quotation Marks around text - \item How to Emphasize and give fixed width to fonts. - \item Use numbered and un-numbered lists - \item Add Footnotes, Labels and References - \item Use the listings package to include code + \item Put Quotation Marks around text. + \item Emphasize and give fixed width to fonts. + \item Use numbered and un-numbered lists. + \item Add Footnotes, Labels and References. + \item To include code. \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{Evaluation} \begin{enumerate} -\item Which environment is used including a block of code? -\item What are the basic lists that make environments? -\item Joe has numerous used labels inside his Latex document. But all the references to label names come up as question marks. What might be the problem? +\item Which environment is used to include a block of code? +\item Joe has numerous used labels inside his Latex document. +But all the references to label names come up as question marks. +What might be the problem? \end{enumerate} \end{frame} \begin{frame} @@ -189,26 +193,67 @@ \begin{enumerate} \item lstlistings \vspace{15pt} -\item -\begin{enumerate} -\item itemize(for unorderd lists) -\item enumerate(for ordered lists) -\item description(lists where you want to specify your own label) -\end{enumerate} -\item While using labels, the latex document should be compiled twice for the references to show up. +\item While using labels, the latex document should be compiled +twice for the references to show up. \end{enumerate} \end{frame} + \begin{frame} +\frametitle{SDES \& FOSSEE} +\begin{center} +\begin{itemize} +\item \small{SDES}\\ +\small{\color{LimeGreen}Software Development techniques for Engineers and Scientists} \\ +\scriptsize An initiative by FOSSEE. \\ +\vspace{3pt} +\scriptsize For more information on SDES, please visit {\color{blue}\url{http://fossee.in/sdes}}\\ +\vspace{12pt} +\item \small{FOSSEE}\\ +\small {\color{LimeGreen}Free and Open-source Software for \\Science and Engineering Education} \\ +\scriptsize Based at IIT Bombay, Funded by MHRD.\\ +\vspace{3pt} +\scriptsize Part of National Mission on Education through ICT (NME-ICT). \\ +\end{itemize} +\end{center} +\end{frame} -\begin{block}{} +\begin{frame} +\frametitle{About the Spoken Tutorial Project} +\begin{itemize} +\item Watch the video available at {\color{blue}\url{http://spoken-tutorial.org /What\_is\_a\_Spoken\_Tutorial}} +\item It summarises the Spoken Tutorial project +\item If you do not have good bandwidth, you can download and watch it +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Spoken Tutorial Workshops}The Spoken Tutorial Project Team +\begin{itemize} +\item Conducts workshops using spoken tutorials +\item Gives certificates to those who pass an online test +\item For more details, please write to \\ \hspace {0.5cm}{\color{blue}contact@spoken-tutorial.org} +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Acknowledgements} +\begin{itemize} +\item Spoken Tutorial Project is a part of the Talk to a Teacher project +\item It is supported by the National Mission on Education through ICT, MHRD, Government of India +\item More information on this Mission is available at: \\{\color{blue}\url{http://spoken-tutorial.org/NMEICT-Intro}} +\end{itemize} +\end{frame} + +\begin{frame} + \begin{block}{} \begin{center} - \textcolor{blue}{\Large THANK YOU!} + {\Large THANK YOU!} \end{center} \end{block} \begin{block}{} \begin{center} For more Information, visit our website\\ - \url{http://fossee.in/} + {\color{blue}\url{http://fossee.in/}} \end{center} \end{block} \end{frame} diff --git a/Latex/Latex4/Typesetting_Text_Latex.rst b/Latex/Latex4/Typesetting_Text_Latex.rst index 281613a..38e527c 100644 --- a/Latex/Latex4/Typesetting_Text_Latex.rst +++ b/Latex/Latex4/Typesetting_Text_Latex.rst @@ -13,11 +13,11 @@ Script .. L1 -{{{ Show the first slide containing title, name of the production team along with the logo of MHRD}}} +{{{ Show the first title slide }} .. R1 -Hello friends and welcome to the second tutorial on Latex. +Hello friends and welcome to the second tutorial on Typsetting Text in Latex. .. L2 @@ -27,7 +27,7 @@ Hello friends and welcome to the second tutorial on Latex. At the end of this tutorial you will be able to: -1. Learn to typeset your document using LaTEX. +1. Learn how to typeset your document using LaTEX. #. Use lists, listings in your document for formatting text. @@ -37,185 +37,223 @@ At the end of this tutorial you will be able to: .. R3 -Please make sure that you have gone through the following tutorials before you continue on this tutorial: +Please make sure that you have gone through the following tutorials before you +continue on this tutorial: + +1. LaTeX Part 1 - Getting Started +2. LaTeX Part 2 - Introduction +3. LaTeX Part 3 - Structuring the Content + .. L4 {{{Show the slide 'Quotation Marks'}}} .. R4 - -Look at the quotation marks for the text, Sigh Pie. We see that they are not formatted properly. +How can we add Quotation Marks to our document ? +For this, we use ` (accent) character for the left quote & +' (apostrophe) character for the right quote. +For double quotes, we use them twice. .. L5 -{{{Show rev11 of hg}}} +{{{Show the slide Fonts-emphasizes, fixed width}}} .. R5 -To place quotation marks in LaTeX, we use ` character for the left quote & ' character for the right quote. For double quotes, we use them twice. +The \emph command is used to give the text an emphasized & italic effect. +In tabular structures LaTeX doesn't add multiple spaces between words. +Just like multiple empty lines, multiple spaces are considered +as a single space. +Also, LaTeX starts a new paragraph at the beginning of the table. +To avoid this, we use the 'flushleft environment' to have left aligned text. +Similarly 'flushright' & 'center' to have right & center aligned text +respectively. .. L6 -{{{Show the slide 'Fonts'}}} +{{{Show the slide Fonts-emphasizes, fixed width..}}} .. R6 -The names of the software tools, Scilab, Matlab, etc. appear in italics or 'emphasized' as it is called in LaTeX. +'\texttt' is used to change text to fixed width font & +'\textbf' is used to change text to bold face +We could also change the separating - (hyphen) to -- (n-dash) or --- (em-dash) +to improve the appearance of the document. .. L7 -{{{Show rev12 of hg}}} +{{{Show the slide Lists }}} .. R7 -To emphasize text, the \emph command is used. - -.. R8 - -Let's try and form a tabular structure by separating the left and right columns using spaces. On compiling, we find that LaTeX doesn't add multiple spaces between words. Just like multiple empty lines, multiple spaces are considered as a single space. +The 'enumerate' environment adds numbered lists to our document and +the itemise environment adds un-numbered lists. \item command adds +a new entry to a list. Note, that LaTeX can easily handle nested lists. +In fact, most environments can be embedded within other environments, +without any problems. -Also, you would have noticed that LaTeX starts a new paragraph at the beginning of the table. To avoid this, we use the 'flushleft environment'. .. L8 -{{{Show slides second part of 'Fonts'}}} +{{{Show slide 'Footnotes'}}} -.. R9 +.. R8 -'\textbf' is used to change text to bold face and '\texttt' is used to change text to fixed width font. +LaTeX provides a footnote command to add a footnote. +In case we wish to add another Appendix before the section the footnote has +to be edited. To avoid this, LaTeX provides a handy system +of labels and referencing. .. L9 -{{{Show rev13 of hg}}} - -.. R10 - -We could also change the separating - (hyphen) to -- (n-dash) or --- (em-dash), to improve the appearance of the document. - -.. L10 - -{{{Show the slides Lists }}} - -.. R11 - -The section on 'Use of Scipy' in this course, contains lists. Now, let us add lists to our document. +{{{Show the slide 'Labels and References'}}} -.. L11 +.. R9 -{{{Show rev14 of hg}}} +We can create labels for any elements in the document and then refer them +anywhere in the document. +\\label{labelname} command is used to create a lable for a particular element. +Then, to refer to that element with a lable \\ref{labelname} command is used. -.. R12 +But, remember that when you compile the document first time you will see +question marks instead of the element you have refered using lables. +Do not worry, you just have to compile the document once again to make the +elements refered by labels to appear. -The 'enumerate' environment adds numbered lists to our document and the itemise environment adds un-numbered lists. \item command adds a new entry to a list. Note, that LaTeX can easily handle nested lists. In fact, most environments can be embedded within other environments, without any problems. +So, whenever you use the labels & references remember to compile the document +twice. +.. L10 -.. L12 +{{{Show the slide 'Include Code'}}} -{{{Show slides 'Footnotes'}}} +.. R10 -.. R13 +Now let us see how we can include code in our Latex document. +LaTeX by default provides the verbatim environment to include +pre-formatted text. +But, we shall look at using the listings package, specifically meant for +including code in our document. -Let's now add the footnote to pylab. LaTeX provides a footnote command to add a footnote. +First of all, we need to tell LaTeX, that we want to use the +listings package in our document. We do this by adding the directive +\usepackage{listings} to the preamble of our document. +Then, we specify the language of the code that we are going to embed +into our document. This can be done in two ways, +directly specifying it while declaration \lstinputlisting[language=Python] or +we can use the 'lstset' command. -.. L13 +.. L11 -{{{Show rev15 of hg}}} +{{{Show slide 'Including code..'}}} -.. R14 +.. R11 -In case we wish to add another Appendix before the section on using pylab, the footnote has to be edited. To avoid this, LaTeX provides a handy system of labels and referencing. +Now, to put a line of code (inline and not as a separate block), +we use the \lstinline command. To embed a block of code, we use +the lstlisting environment (\begin{lstlisting} and \end{lstlisting}). -.. L14 +.. L12 -{{{Show the slide 'Labels and References'}}} +{{{Show the 'summary' slide'}}} -.. R15 +.. R12 -First, we add a label to the section that we wish to refer in this footnote. Then, we change the footnote, and add the reference to this label instead of the character A. If you look at the output after compiling the document once, you will see that the footnote has question marks instead of the section number. You will have to compile once again, for the section number to appear in the footnote. +This brings us to the end of the tutorial. In this tutorial, we have +learnt to, -.. L15 +1. Put Quotation Marks around text. -{{{Show rev15 of hg}}} +#. Emphasize and give fixed width to fonts. +#. Use numbered and un-numbered lists. -.. R16 +#. Add Footnotes, Labels and References. -LaTeX by default provides the verbatim environment to include pre-formatted text. You may try this during the lab session. We shall look at using the listings package, specifically meant for including code in our document. +#. To include code. -.. L16 +.. L13 -{{{Show the slide 'Include Code'}}} +{{{Show self assessment questions slide}}} -.. R17 +.. R13 -First of all, we need to tell LaTeX, that we want to use the listings package in our document. We do this by adding the directive \usepackage{listings} to the preamble of our document. +Here are some self assessment questions for you to solve. -Then, we set the language of the code that we are going to embed into our document. For this, we use the 'lstset' command. +1. Which environment is used to include a block of code? -.. L17 +#. Joe has numerous used labels inside his Latex document. +But all the references to label names come up as question marks. +What might be the problem? -{{{Show rev16 of hg}}} -.. L18 +.. L14 -{{{Show slide 'Including code'}}} +{{{Show the solutions slide to self assessment questions }}} -.. R18 +.. R14 -Now, to put a line of code (inline and not as a separate block), we use the \lstinline command. We change the name pylab in the footnote to use lstinline instead of the texttt. To embed a block of code, we use the lstlisting environment (\begin{lstlisting} and \end{lstlisting}). +And the answers are, -.. L19 +1. Use the lstlistings package to include code. -{{{Show rev16 of hg}}} +#. While using labels, the latex document should be compiled twice +for the references to show up. -.. R19 -For example, let's add the code to the Appendix of our document. -.. L20 +.. L15 -{{{Show the 'summary' slide'}}} +{{{ Show the SDES & FOSSEE slide }}} -.. R20 +.. R15 -This brings us to the end of the tutorial. In this tutorial, we have -learnt to, +Software Development techniques for Engineers and Scientists - SDES, is an +initiative by FOSSEE. For more information, please visit the given link. -1. Put Quotation Marks around text. +Free and Open-source Software for Science and Engineering Education - FOSSEE, is +based at IIT Bombay which is funded by MHRD as part of National Mission on +Education through ICT. -#. Emphasize and give fixed width to fonts. +.. L16 -#. Use numbered and un-numbered lists. +{{{ Show the About the Spoken Tutorial Project slide }}} -#. Add Footnotes, Labels and References. +.. R16 -#. Use the listings package to include code. +Watch the video available at the following link. It summarises the Spoken +Tutorial project.If you do not have good bandwidth, you can download and +watch it. -.. L21 +.. L17 -{{{Show self assessment questions slide}}} +{{{ Show the Spoken Tutorial Workshops slide }}} -.. R21 +.. R17 -Here are some self assessment questions for you to solve. +The Spoken Tutorial Project Team conducts workshops using spoken tutorials, +gives certificates to those who pass an online test. -.. L22 +For more details, contact contact@spoken-tutorial.org -{{{Show the solutions slide to self assessment questions }}} +.. L18 -.. R22 +{{{ Show the Acknowledgements slide }}} -And the answers are, +.. R18 +Spoken Tutorial Project is a part of the "Talk to a Teacher" project. +It is supported by the National Mission on Education through ICT, MHRD, +Government of India. More information on this mission is available at the +given link. -.. L23 +.. L19 -{{{Show the thank you slide}}} +{{{ Show the Thankyou slide }}} -.. R23 +.. R19 Hope you have enjoyed this tutorial and found it useful. -Thank you. - +Thank you! diff --git a/Version_Control/vcs1/vcs1.rst b/Version_Control/vcs1/vcs1.rst index bd222bb..4442553 100644 --- a/Version_Control/vcs1/vcs1.rst +++ b/Version_Control/vcs1/vcs1.rst @@ -6,13 +6,15 @@ .. Author : Primal Pappachan Internal Reviewer : Kiran Isukapatla Date: May 10 , 2012 + -------- Script -------- .. L1 -{{{ Show the first slide containing title, name of the production team along with the logo of MHRD}}} +{{{ Show the first slide containing title, name of the production team along +with the logo of MHRD}}} i.. R1 @@ -39,7 +41,11 @@ At the end of this tutorial you will be able to .. R3 -First, let's understand what 'Version Control' is. 'Version control' is a way to track files over time and share them. This allows access to earlier versions of a file(s) if and when required. It therefore enables us to make changes to the content of a file, view it's change log and collaborate on a single piece of work with a team of people. +First, let's understand what 'Version Control' is. 'Version control' is a way +to track files over time and share them. This allows access to earlier +versions of a file(s) if and when required. It therefore enables us to make +changes to the content of a file, view it's change log and collaborate on a +single piece of work with a team of people. .. L4 @@ -50,7 +56,10 @@ First, let's understand what 'Version Control' is. 'Version control' is a way to Let's look at an example of home-brewed Version Control system. -Version control is a way of backing up files, before making changes. Most people would have cooked up their own version control system, without realizing, there were tools built by others, that performs the task in a more organized and systematic way. +Version control is a way of backing up files, before making changes. +Most people would have cooked up their own version control system, +without realizing, there were tools built by others, +that performs the task in a more organized and systematic way. .. L5 @@ -61,12 +70,9 @@ Version control is a way of backing up files, before making changes. Most people Let's look at the various problems associated with this set-up. 1. Name and changes made are not related or linked. - #. Can’t track sequence of changes made to a file. - #. Does not scale. - .. L6 {{{Show the slide 'The need for Version Control'}}} @@ -75,15 +81,21 @@ Let's look at the various problems associated with this set-up. Now, let's move to identifying the needs for a 'Version Control System'. -We have seen that one of the main motivations to use a Version Control system is the ability to go back to a working version of a file, when something goes wrong. Below are a few more advantages of using an automated version control system. +We have seen that one of the main motivations to use a Version Control system +is the ability to go back to a working version of a file, +when something goes wrong. +Below are a few more advantages of using an automated version control system. -1. By tracking the history of a project, any person may see the evolution of a project. +1. By tracking the history of a project, any person may see the evolution of +a project. #. Allows for effective collaboration on a project, as everything is shared. -#. Helps to identify which additions have broken down a project and thus aids in efficient tracking down of the bugs. +#. Helps to identify which additions have broken down a project and thus +aids in efficient tracking down of the bugs. -#. It is good for a one man show as it is for a big group of people working on a project. +#. It is good for a one man show as it is for a big group of people working +on a project. .. L7 @@ -92,7 +104,11 @@ We have seen that one of the main motivations to use a Version Control system is .. R7 -It is, in some ways, similar to playing a video game. We generally play games in stages. While playing, we save the game at some instances as per our choice. We continue playing, but we could, if necessary, choose to go back to one of the saved states and start over. In this manner, we could change the state of the game. +It is, in some ways, similar to playing a video game. We generally play games +in stages. While playing, we save the game at some instances as per our choice. +We continue playing, but we could, if necessary, choose to go back to one of +the saved states and start over. In this manner, we could change the state of +the game. .. L8 @@ -114,7 +130,8 @@ Some of the Version Control tools available and used widely are: cvs, svn, git and so on. -Each of these tools have their own merits and demerits. In this tutorial we shall learn how to use mercurial or hg. +Each of these tools have their own merits and demerits. +In this tutorial we shall learn how to use mercurial or hg. .. L9 diff --git a/script2col.rst b/script2col.rst new file mode 100644 index 0000000..c61565f --- /dev/null +++ b/script2col.rst @@ -0,0 +1,222 @@ +.. Objectives +.. ---------- + +.. At the end of this tutorial, you will + +.. 1. Get acquainted to LaTeX. +.. #. Know why we prefer LaTeX? +.. #. Know the advantages and disadvantages of typesetting documents +.. using the LaTeX approach. +.. #. Have a description, of a typical work flow; which uses LaTeX to typeset +.. documents. +.. #. Recognise and differenciate between LaTeX commands, LaTeX comments and +.. special characters, spacing and actual document content. +.. #. Create and compile a very simple LaTeX document. + +.. Prerequisites +.. ------------- + +.. 1. Installing LaTeX + + +.. Author : Harish Badrinath < harish [at] fossee [dot] in > + Internal Reviewer : Kiran Isukapatla < kiran [at] fossee [dot] in > + External Reviewer : + Langauge Reviewer : + Checklist OK? : 25-Feb-2012 + +Script +------ + + + ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the first slide containing title, name of the production | Hello Friends and welcome to the tutorial on 'Introduction to LaTeX'. | +| team along with the logo of MHRD }}} | | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Objectives" slide }}} | At the end of this tutorial, you will | +| | | +| | 1. Get acquainted to LaTeX. | +| | #. Know why we prefer LaTeX? | +| | #. Know the advantages and disadvantages of typesetting documents | +| | using the LaTeX approach. | +| | #. Get a brief idea on typical work flow; which uses LaTeX to typeset | +| | documents. | +| | #. Know LaTeX commands, LaTeX comments and | +| | special characters, spacing and actual document content. | +| | #. Be able to create and compile a simple LaTeX document. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Pre-requisite" slide }}} | Before beginning this tutorial, we would suggest having a working installation | +| | of LaTeX on your computer. You can do this by completing the tutorial on | +| | "LaTeX Installation". | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Introduction" slide }}} | LaTeX began as TeX, a computer program originally created by | +| | Donald E. Knuth. It was designed mainly to aid typesetting | +| | of text and mathematical formulae. | +| | | +| | It is a typesetting program that produces excellently typeset documents. | +| | Typesetting is placing text onto a page with all the style formatting defined, | +| | so that the content looks as intended. It is extensively used for producing | +| | high quality scientific and mathematical documents. It may also be used for | +| | producing other kinds of documents, ranging from simple one page articles to | +| | complete books. | +| | | +| | LaTeX is pronounced Lah-tech or Lay-tec. | +| | TeX is pronounced Tech. TeX is also the first syllable in the Greek word for | +| | technology. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Why LaTeX?" slide }}} | Why we prefer LaTeX? | +| | (a) LaTeX offers excellent visual quality. | +| | (b) Handles typesetting and lets you focus on content. | +| | (c) Makes writing complex Math equation(S) extremely simple. | +| | (d) It is also a standard used widely, especially by the scientific community. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Why LaTeX? ..." slide }}} | We can define LaTex as a document based markup language. This sentence is | +| | deceptively simple, as it reveals a lot about LaTeX. We now break this sentence | +| | up as follows | +| | Mark-up: a system of annotating text, adding extra information to specify | +| | structure and presentation of text. | +| | Document based markup: you don’t have to worry about each element individually. | +| | | +| | This is essentially a fancy way of saying,LaTeX handles typesetting and lets | +| | you focus on content rather than appearance. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Advantages of using LaTeX" slide }}} | Some of the advantages of using LaTeX approach to typesetting are | +| | (1) Easy availability of professionally crafted layouts/templates. | +| | (2) Typesetting of mathematical formulae is supported in a convenient | +| | environment. | +| | (3) Typesetting for most cases can be done with very little learning curve | +| | using easy to use/understand commands, that only specify the logical structure | +| | of the document. | +| | (4) Presence of lots of add-on packages. | +| | (5) It encourages creation of well structured texts. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Disadvantages of using LaTeX" slide }}} | Some of the disadvantages of using LaTeX approach to typesetting are | +| | (1) Designing a whole new layout is difficult. | +| | (2) LaTeX is not a word processor, for example, the document author | +| | is not expected to worry about presentation details like the size of font. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "LaTeX input file format" slide }}} | LaTeX input files are simple ASCII text files that are processed by a TeX | +| | processing engine. | +| | Next comes the question of compiling LaTeX input files and viewing the output | +| | typeset document. | +| | The process is a little different from other markup languages like HTML. | +| | We compile ASCII text files into typeset files that are normally DVI, | +| | Postscript or PDF files. | +| | The latex command converts LaTeX input files into dvi files. | +| | We can view DVI files on Gnu/Linux using xdvi. | +| | Further, DVI files can be converted either to a post script file, using the | +| | dvips command or to a PDF file using the dvipdfm command. | +| | The command pdflatex is used to convert LaTeX input files directly to pdf files. | +| | The resultant PDF files can be viewed using standard applications | +| | on most platforms | +| | (Eg: evince on Gnu/Linux). PDF file are also widely supported. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Commands,Comments&Special Characters" slide }}} | Like most utilities in Linux, LaTeX is case sensitive. Commands begin | +| | with a backslash. LaTeX environments have a begin and end marker. The begin and | +| | end document commands, mark the beginning and the end of the content of the | +| | LaTeX document. The text in between the begin and end commands is typeset in | +| | the output document.Any content after <\end{document}> is ignored. The type of | +| | document that is being currently typeset in LaTex, is identified with the | +| | documentclass command. LaTeX then, typesets the document accordingly. | +| | | +| | All the commands in LaTeX begin with a \\. An environment begins with a begin | +| | command and ends with an end command. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Commands,Comments&Special Characters ..." slide }}} | But, how do we write comments with in the document. % character is used | +| | to indicate comments. Anything written after a % symbol in a | +| | line, is ignored. | +| | But what if we wanted to insert the % symbol in the document? We can do so by | +| | escaping it with a \\ (backslash). % is one of the many special characters in | +| | LaTeX. The others are shown on the screen. All of them, except the \\ itself, | +| | can be inserted by escaping it with a \\. To insert a \\ in our document, | +| | we use the command \textbackslash. | +| | | +| | What would happen if we escape a \\ with a \\? | +| | A double backslash is actually another command. It inserts a new line in the | +| | typeset document. Normally LaTeX automatically spaces the given input optimally. | +| | But, sometimes we have to insert manual line breaks. The <\\\\> | +| | command or <\newline> | +| | command is used to insert a newline in the output document. A | +| | single line break in the input document, doesn't cause any change in the | +| | output document. | +| | | +| | A single empty line causes a change in paragraphs in the output. Multiple | +| | empty lines are equivalent to a single empty line. Similarly, multiple spaces | +| | are treated as a single space. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Typesetting a minimal document" slide }}} | Now, try to create a simple LaTeX document. Pause the tutorial and type the | +| | content shown on the screen in a text editor. Save the file as temp.tex | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{continue from paused state}}} | Now we compile the commands in the LaTeX input file that is, temp.tex into a | +| {{{ Show the "Compiling to DVI & PDF" slide }}} | typeset file. | +| | | +| | The first alternative is to compile LaTeX input file into a DVI | +| | file. We use the latex command for this purpose. For compiling the LaTeX input | +| | file temp.tex into a DVI file, we use the following command | +| | | +| | | +| | | +| | The output file would be temp.dvi. | +| | | +| | The other alternative is to create PDF files from LaTeX input files. | +| | We use the pdflatex command for this purpose. For compiling the LaTeX input | +| | file temp.tex into a PDF file, we use the following command | +| | | +| | | +| | | +| | Please note that, throughout this course we shall be using pdflatex to compile | +| | our documents. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Summary" slide }}} | This brings us to the end of this tutorial. In this tutorial, we have learnt | +| | | +| | 1. About LaTeX. | +| | #. why we prefer LaTeX. | +| | #. About the advantages and disadvantages of typesetting documents | +| | using the LaTeX approach. | +| | #. A description, of a typical work flow; which uses LaTeX to typeset | +| | documents. | +| | #. The ability to recognize and differentiate between LaTeX commands, LaTeX | +| | comments and special characters, spacing and actual document content. | +| | #. To Create and compile a simple LaTeX document. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Self assessment questions" slide }}} | Here are some self assessment questions for you to solve | +| | | +| | 1. Convert the temp.dvi created during the course of this tutorial to | +| | temp_1.ps using the dvips command. Verify that the two files | +| | indeed look the same. | +| | | +| | 2. Convert the temp.dvi created during the course of this tutorial to | +| | temp_1.pdf using the dvipdfm command. Verify that the two files indeed look the | +| | same. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the "Solutions" slide }}} | And the answers, | +| | | +| | 1. dvips -o temp_1.ps temp.dvi | +| | | +| | 2. dvipdfm -o temp_1.pdf temp.dvi | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the SDES & FOSSEE slide }}} | Software Development techniques for Engineers and Scientists - SDES, is an | +| | initiative by FOSSEE. For more information, please visit the given link. | +| | | +| | Free and Open-source Software for Science and Engineering Education - FOSSEE, is | +| | based at IIT Bombay which is funded by MHRD as part of National Mission on | +| | Education through ICT. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the ``About the Spoken Tutorial Project'' slide }}} | Watch the video available at the following link. It summarises the Spoken | +| | Tutorial project.If you do not have good bandwidth, you can download and | +| | watch it. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the `` Spoken Tutorial Workshops'' slide }}} | The Spoken Tutorial Project Team conducts workshops using spoken tutorials, | +| | gives certificates to those who pass an online test. | +| | | +| | For more details, contact contact@spoken-tutorial.org | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the Acknowledgements slide }}} | Spoken Tutorial Project is a part of the "Talk to a Teacher" project. | +| | It is supported by the National Mission on Education through ICT, MHRD, | +| | Government of India. More information on this mission is available at the | +| | given link. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{ Show the Thankyou slide }}} | Hope you have enjoyed this tutorial and found it useful. | +| | Thank you! | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -- cgit From 8dfb36c8626f56f96b4be431596a7a902b410955 Mon Sep 17 00:00:00 2001 From: hardythe1 Date: Wed, 8 Aug 2012 14:58:43 +0530 Subject: Modified scripts & slides according to the new checklist --- Latex/Latex1/latex_installation.rst | 85 +++--- Latex/Latex1/latex_installation.tex | 91 +++--- Latex/Latex2/latex_intro.tex | 121 ++++---- Latex/Latex2/latex_intro_script.rst | 82 ++--- Latex/Latex3/latex_basics.tex | 207 +++++-------- Latex/Latex3/latex_basics_and_structure_script.rst | 56 ++-- Latex/Latex4/Latex_Typesetting_Text.tex | 36 +-- Latex/Latex4/Typesetting_Text_Latex.rst | 65 ++-- Latex/Latex5/FTF_Latex.rst | 253 +++++++++++----- Latex/Latex5/Latex_FTF.tex | 269 ++++++++++++----- script2col.rst | 333 +++++++++------------ 11 files changed, 834 insertions(+), 764 deletions(-) diff --git a/Latex/Latex1/latex_installation.rst b/Latex/Latex1/latex_installation.rst index 867210a..303a3e0 100644 --- a/Latex/Latex1/latex_installation.rst +++ b/Latex/Latex1/latex_installation.rst @@ -1,29 +1,4 @@ -.. Objectives -.. ---------- - -.. At the end of this tutorial, you will - -.. Install LaTeX on your computer. -.. Learn how to install a plug-in for a TeX editor. -.. Configure the TeX editor with the LaTeX plug-in. -.. Useful information on some LaTeX packages. -.. Compile a TeX file to pdf. - -.. Prerequisites -.. ------------- - -.. You'll need a TeX distribution. -.. A good text editor and a DVI or PDF viewer. -.. Updated Linux distribution as Operating System. -.. Working internet connection (for installation over the network). - - -.. Author : Kiran Isukapatla < kiran [at] fossee [dot] in > - Internal Reviewer : Kiran Isukapatla < kiran [at] fossee [dot] in > - External Reviewer : - Langauge Reviewer : - Checklist OK? : 25-Feb-2012 - +-------- Script -------- @@ -80,11 +55,12 @@ of Unix, including GNU/Linux, and also Windows. There are multiple ways of installation. You may download a LaTeX distribution and run the installer. An other way is to install using the command: 'sudo apt-get install texlive' -(or) 'sudo apt-get install texlive-full'. +for a subset Latex functionality or 'sudo apt-get install texlive-full' to +install Tex Live with all the functionalities (a complete distribution). .. L6 -{{{Move onto next slide of 'Installation'}}} +{{{Show the slide 'Installation..'}}} .. R6 @@ -116,24 +92,36 @@ Check LaTeX Plugin). Add-on features for LaTeX are known as packages. Dozens of these are pre-installed with LaTeX and can be used in your documents immediately. Listed here are a few popular ones and their usage. - +Latex-beamer package is used to create presentations. +TexPower package is used to create dynamic presentation online. +Prosper is a Latex class which helps writing transparencies and high quality +presentations. .. L9 -{{{Show the slide 'Compilation'}}} +{{{Show the slide 'LaTeX Packages..'}}} .. R9 +Also graphic packages like texlive-pictures are available for drawing +graphics & texlive-latex-extra for additional add-on packages. + +.. L10 + +{{{Show the slide 'Compilation'}}} + +.. R10 + A given LaTeX document may be compiled to pdf using the command: 'pdflatex filename.tex' This produces an output file, in the pdf format. -.. L10 +.. L11 {{{Show the slide 'Summary'}}} -.. R10 +.. R11 This brings us to the end of the tutorial. In this tutorial, we have learnt to, @@ -143,30 +131,33 @@ learnt to, #. Choose a LaTeX packages as per requirement. #. Compile a TeX file to pdf. -.. L11 +.. L12 {{{ Show the slide 'Exercise' }}} -.. R11 +.. R12 1. How can we check the version of the LaTeX package installed ? 2. How can we check if the plug-in is properly configured with TeX editor ? -.. L12 +.. L13 {{{ Show the slide 'Solutions' }}} -.. R12 +.. R13 1. Use the command latex with -v option to check the version installed -2. In the editor select the edit menu and follow the sequence +2. In the editor select the edit menu and follow the sequence: +Edit > Preferences > Plugins > Check +LaTeX Plug-in -.. L13 + +.. L14 {{{ Show the SDES & FOSSEE slide }}} -.. R13 +.. R14 Software Development techniques for Engineers and Scientists - SDES, is an initiative by FOSSEE. For more information, please visit the given link. @@ -175,43 +166,43 @@ Free and Open-source Software for Science and Engineering Education - FOSSEE, is based at IIT Bombay which is funded by MHRD as part of National Mission on Education through ICT. -.. L14 +.. L15 {{{ Show the ``About the Spoken Tutorial Project'' slide }}} -.. R14 +.. R15 Watch the video available at the following link. It summarises the Spoken Tutorial project.If you do not have good bandwidth, you can download and watch it. -.. L15 +.. L16 {{{ Show the `` Spoken Tutorial Workshops'' slide }}} -.. R15 +.. R16 The Spoken Tutorial Project Team conducts workshops using spoken tutorials, gives certificates to those who pass an online test. For more details, contact contact@spoken-tutorial.org -.. L16 +.. L17 {{{ Show the Acknowledgements slide }}} -.. R16 +.. R17 Spoken Tutorial Project is a part of the "Talk to a Teacher" project. It is supported by the National Mission on Education through ICT, MHRD, Government of India. More information on this mission is available at the given link. -.. L17 +.. L18 {{{ Show the Thankyou slide }}} -.. R17 +.. R18 Hope you have enjoyed this tutorial and found it useful. Thank you! diff --git a/Latex/Latex1/latex_installation.tex b/Latex/Latex1/latex_installation.tex index 22e0286..062bf64 100644 --- a/Latex/Latex1/latex_installation.tex +++ b/Latex/Latex1/latex_installation.tex @@ -1,10 +1,3 @@ -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% LateX -% -% Author: FOSSEE -% Copyright (c) 2009, FOSSEE, IIT Bombay -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \documentclass[17pt,compress]{beamer} \usepackage{beamerthemesplit} \mode @@ -62,8 +55,8 @@ \sffamily \bfseries \title -[\LaTeX \: Installation] -{\LaTeX \:Installation} +[\LaTeX: \: Installation] +{\LaTeX: \:Installation} \author [FOSSEE] {\small Talk to a Teacher\\{\color{blue}\url{http://spoken-tutorial.org}}\\\vspace{0.25cm}National Mission on Education @@ -83,8 +76,8 @@ \item Learn to install LaTeX \item Learn to install a TeX editor plug-in \item Learn to configure the TeX editor for LaTeX - \item Know few LaTeX packages. - \item Be able to compile a TeX file to pdf. + \item Know few LaTeX packages + \item Be able to compile a TeX file to pdf \end{itemize} \end{frame} @@ -93,23 +86,21 @@ \frametitle{Prerequisites} Prerequisites for Installation of LaTeX \begin{itemize} - \item You'll need a TeX distribution. - \item Good text editor, DVI or PDF viewer. - \item Updated Linux distribution as OS. - \item Working Internet connection (for installation over the network). + \item You'll need a TeX distribution + \item Good text editor, DVI or PDF viewer + \item Updated Linux distribution as OS + \item Working Internet connection (for installation over the network) \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{TeX Distribution} - TeX Live - \begin{itemize} - \item Easy way to get up and running with the TeX document production system. - \end{itemize} - Acquire TeX Live in many ways + TeX Live, \begin{itemize} - \item Getting TeX Live on DVD (for installation from media). - \item Installing TeX Live over the network. + \item Easy way to get up and running with the TeX document production system + \item Acquire TeX Live in many ways + \item Getting TeX Live on DVD (for installation from media) + \item Installing TeX Live over the network \end{itemize} \end{frame} @@ -117,12 +108,12 @@ \frametitle{Installation} Running the installer \begin{itemize} - \item Run the \emph{install-tl} script to install. - \end{itemize} + \item Run the \emph{install-tl} script to install Commands - \begin{itemize} - \item \emph{sudo apt-get install texlive} : Basic subset of TeX Live's functionality. - \item \emph{sudo apt-get install texlive-full} : Complete TeX Live distribution. + \item \emph{sudo apt-get install texlive}: + Basic subset of TeX Live's functionality + \item \emph{sudo apt-get install texlive-full}: + Complete TeX Live distribution \end{itemize} \end{frame} @@ -141,7 +132,8 @@ Gedit has a plug-in for LaTeX which converts Gedit into a LaTeX editor \begin{itemize} \item \emph{sudo apt-get install gedit-latex-plugin} : Installs plug-in - \item \emph Activate the plug-in : Click (Edit > Preferences > Plugins > Check LaTeX Plugin) + \item \emph Activate the plug-in: + Click (Edit > Preferences > Plugins > Check LaTeX Plugin) \end{itemize} \end{frame} @@ -149,16 +141,16 @@ \frametitle{LaTeX Packages} Recommended LaTeX Packages \begin{itemize} - \item \emph{latex-beamer} : to create presentations. - \item \emph{TeXPower} : for dynamic online presentations. - \item \emph{Prosper} : class for writing transparencies. + \item \emph{latex-beamer} : to create presentations + \item \emph{TeXPower} : for dynamic online presentations + \item \emph{Prosper} : class for writing transparencies \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{LaTeX Packages..} \begin{itemize} - \item \emph{texlive-pictures} : for drawing graphics. + \item \emph{texlive-pictures} : for drawing graphics \item \emph{texlive-latex-extra} : add-on packages \end{itemize} \end{frame} @@ -167,8 +159,8 @@ \frametitle{Compilation} LaTeX distribution installed, you may compile a LaTeX document to pdf file \begin{itemize} - \item \emph{pdflatex filename.tex} : Compiles the LaTeX document. - \item Output : PDF file. + \item \emph{pdflatex filename.tex} : Compiles the LaTeX document + \item Output : PDF file \end{itemize} \end{frame} @@ -176,10 +168,10 @@ \begin{frame}[fragile] \frametitle{Summary} \begin{itemize} - \item Install LaTeX on your computer. - \item Install/Configure TeX editor with LaTeX plug-in. - \item Choose a LaTeX package as per requirement. - \item Compile a TeX file to PDF. + \item Install LaTeX on your computer + \item Install/Configure TeX editor with LaTeX plug-in + \item Choose a LaTeX package as per requirement + \item Compile a TeX file to PDF \end{itemize} \end{frame} @@ -205,16 +197,19 @@ \begin{center} \begin{itemize} \item \small{SDES}\\ -\small{\color{LimeGreen}Software Development techniques for Engineers and Scientists} \\ +\small{\color{LimeGreen}Software Development techniques + for Engineers and Scientists} \\ \scriptsize An initiative by FOSSEE. \\ \vspace{3pt} -\scriptsize For more information on SDES, please visit {\color{blue}\url{http://fossee.in/sdes}}\\ +\scriptsize For more information on SDES, please visit +{\color{blue}\url{http://fossee.in/sdes}}\\ \vspace{12pt} \item \small{FOSSEE}\\ -\small {\color{LimeGreen}Free and Open-source Software for \\Science and Engineering Education} \\ +\small {\color{LimeGreen}Free and Open-source Software for \\ +Science and Engineering Education} \\ \scriptsize Based at IIT Bombay, Funded by MHRD.\\ \vspace{3pt} -\scriptsize Part of National Mission on Education through ICT (NME-ICT). \\ +\scriptsize Part of National Mission on Education through ICT (NME-ICT) \\ \end{itemize} \end{center} \end{frame} @@ -222,7 +217,8 @@ \begin{frame} \frametitle{About the Spoken Tutorial Project} \begin{itemize} -\item Watch the video available at {\color{blue}\url{http://spoken-tutorial.org /What\_is\_a\_Spoken\_Tutorial}} +\item Watch the video available at +{\color{blue}\url{http://spoken-tutorial.org /What\_is\_a\_Spoken\_Tutorial}} \item It summarises the Spoken Tutorial project \item If you do not have good bandwidth, you can download and watch it \end{itemize} @@ -233,7 +229,8 @@ \begin{itemize} \item Conducts workshops using spoken tutorials \item Gives certificates to those who pass an online test -\item For more details, please write to \\ \hspace {0.5cm}{\color{blue}contact@spoken-tutorial.org} +\item For more details, please write to \\ \hspace {0.5cm} +{\color{blue}contact@spoken-tutorial.org} \end{itemize} \end{frame} @@ -241,8 +238,10 @@ \frametitle{Acknowledgements} \begin{itemize} \item Spoken Tutorial Project is a part of the Talk to a Teacher project -\item It is supported by the National Mission on Education through ICT, MHRD, Government of India -\item More information on this Mission is available at: \\{\color{blue}\url{http://spoken-tutorial.org/NMEICT-Intro}} +\item It is supported by the National Mission on Education through +ICT, MHRD, Government of India +\item More information on this Mission is available at: \\ +{\color{blue}\url{http://spoken-tutorial.org/NMEICT-Intro}} \end{itemize} \end{frame} diff --git a/Latex/Latex2/latex_intro.tex b/Latex/Latex2/latex_intro.tex index c1bda6b..7d34bfc 100644 --- a/Latex/Latex2/latex_intro.tex +++ b/Latex/Latex2/latex_intro.tex @@ -1,10 +1,3 @@ -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% Introduction to LaTeX -% -% Author: FOSSEE -% Copyright (c) 2009, FOSSEE, IIT Bombay -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \documentclass[17pt,compress]{beamer} \usepackage{beamerthemesplit} \mode @@ -63,11 +56,12 @@ \sffamily \bfseries \title -[Introduction to \LaTeX] -{Introduction to \LaTeX} +[\LaTeX: \:Installation] +{\LaTeX: \:Installation} \author [FOSSEE] -{\small Talk to a Teacher\\{\color{blue}\url{http://spoken-tutorial.org}}\\\vspace{0.25cm}National Mission on Education +{\small Talk to a Teacher\\{\color{blue}\url{http://spoken-tutorial.org}} +\\\vspace{0.25cm}National Mission on Education through ICT\\{\color{blue}\url{ http://sakshat.ac.in}} \\ [1.65cm] Contributed by FOSSEE Team \\IIT Bombay \\[0.3cm] } @@ -83,9 +77,9 @@ At the end of this tutorial, you will, \begin{itemize} -\item Get acquainted to LaTeX. -\item Know why we prefer LaTeX. -\item Know the advantages and disadvantages of typesetting documents in LaTeX. +\item Get acquainted to LaTeX +\item Know why we prefer LaTeX +\item Know the advantages and disadvantages of typesetting documents in LaTeX \end{itemize} \end{frame} @@ -95,10 +89,10 @@ At the end of this tutorial, you will, \begin{itemize} \item Get a brief idea on typical work flow that uses LaTeX to typeset -documents. +documents \item Know about LaTeX commands, comments, - special characters, spacing, actual content. -\item Be able to create and compile a simple LaTeX document. + special characters, spacing, actual content +\item Be able to create and compile a simple LaTeX document \end{itemize} \end{frame} @@ -106,31 +100,31 @@ documents. \frametitle{Pre-requisite} \label{sec-3} - Spoken tutorial on - + Spoken tutorial on, \begin{itemize} -\item {\LaTeX} Installation. +\item {\LaTeX} Installation \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{Introduction} \begin{itemize} - \item Donald E. Knuth. - \item Typesetting program. - \item Excellently Typeset Documents - specially Math. - \item Anything from one page articles to huge books. - \item Pronounced \emph{Lah-tech} or \emph{Lay-tech}. + \item Donald E. Knuth + \item Typesetting program + \item Excellently Typeset Documents - specially Math + \item Anything from one page articles to huge books + \item Pronounced \emph{Lah-tech} or \emph{Lay-tech} \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{Why {\LaTeX}?} \begin{itemize} - \item Excellent visual quality. - \item Handles typesetting; lets you focus on content. - \item Makes writing Math extremely simple. - \item It is a standard -- widely used in Scientific community. + \item Excellent visual quality + \item Handles typesetting; lets you focus on content + \item Makes writing Math extremely simple + \item It is a standard -- widely used in Scientific community \end{itemize} \[\tilde{N}_{\mathbf{x}}\times \mathbf{r}(\mathbf{x}) f_{1k} \] \end{frame} @@ -138,31 +132,31 @@ documents. \begin{frame}[fragile] \frametitle{Why \LaTeX?..} \begin{itemize} - \item It is a document based mark-up. + \item It is a document based mark-up \item Mark-up: annotating text, adding - information to specify structure and presentation of text. + information to specify structure and presentation of text \item Document based markup: don't have to worry - about individual elements. - \item Allows you to focus on content. + about individual elements + \item Allows you to focus on content \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{Advantages of using \LaTeX } \begin{itemize} - \item Availability of professional templates. - \item Typesetting complex formulae in a convenient environment. - \item Typesetting with very little effort. - \item Lot of add-on packages available. - \item Easy creation of well structured texts. + \item Availability of professional templates + \item Typesetting complex formulae in a convenient environment + \item Typesetting with very little effort + \item Lot of add-on packages available + \item Easy creation of well structured texts \end{itemize} \end{frame} \begin{frame}[fragile] \frametitle{Disadvantages of using \LaTeX } \begin{itemize} - \item Designing whole new layout is difficult. - \item LaTeX is not a word processor. + \item Designing whole new layout is difficult + \item LaTeX is not a word processor \end{itemize} \end{frame} @@ -170,7 +164,7 @@ documents. \frametitle{\LaTeX \ input file format} \begin{itemize} \item \LaTeX \: takes ASCII text file as input. - \item We can compile \LaTeX \: files into DVI, Postscript or PDF files. + \item We can compile \LaTeX \: files into DVI, Postscript or PDF files \item \alert{Note:} \typ{latex} vs. \typ{pdflatex} \end{itemize} \end{frame} @@ -178,10 +172,10 @@ documents. \begin{frame}[fragile] \frametitle{Commands,Comments\&Special Characters } \begin{itemize} - \item {\LaTeX} is case sensetive. + \item {\LaTeX} is case sensetive \item Commands begin with a \typ{\\} \item Environments have a \typ{\\begin} and \typ{\\end} - \item Any content after the \typ{\\end\{document\}} is ignored. + \item Any content after the \typ{\\end\{document\}} is ignored \end{itemize} \end{frame} @@ -189,11 +183,11 @@ documents. \frametitle{Commands,Comments\&Special Characters..} \begin{itemize} \item Anything after \typ{\%} symbol till end of the line - is a comment. + is a comment \item Special characters (\typ{\~ \# \$ \^ \& \_ \{ \}}) are escaped by a \typ{\\} \item \typ{\\} is inserted using \typ{\\textbackslash}, - \typ{\\newline} or \typ{\\\\} to insert newlines. + \typ{\\newline} or \typ{\\\\} to insert newlines \end{itemize} \end{frame} @@ -218,7 +212,7 @@ documents. \alert{latex temp.tex} \\ \alert{pdflatex temp.tex} \\ \em Note: Throughout this course, we shall use pdflatex to compile our - documents. + documents \end{center} \end{frame} @@ -226,12 +220,12 @@ documents. \frametitle{Summary} \label{sec-8} - In this tutorial, we have learnt, + In this tutorial we have learnt, \begin{itemize} - \item About LaTeX. - \item why we prefer LaTeX. - \item advantages and disadvantages of typesetting documents using - LaTeX approach. + \item About LaTeX + \item Why we prefer LaTeX + \item Advantages and disadvantages of typesetting documents using + LaTeX approach \end{itemize} \end{frame} @@ -241,10 +235,10 @@ documents. \begin{itemize} \item About a typical work flow; which uses LaTeX to typeset - documents. + documents \item About LaTeX commands, comments, special characters, spacing, - actual document content. - \item How to create and compile a simple LaTeX document. + actual document content + \item How to create and compile a simple LaTeX document \end{itemize} \end{frame} @@ -283,16 +277,19 @@ documents. \begin{center} \begin{itemize} \item \small{SDES}\\ -\small{\color{LimeGreen}Software Development techniques for Engineers and Scientists} \\ +\small{\color{LimeGreen}Software Development techniques for +Engineers and Scientists} \\ \scriptsize An initiative by FOSSEE. \\ \vspace{3pt} -\scriptsize For more information on SDES, please visit {\color{blue}\url{http://fossee.in/sdes}}\\ +\scriptsize For more information on SDES, please visit +{\color{blue}\url{http://fossee.in/sdes}}\\ \vspace{12pt} \item \small{FOSSEE}\\ -\small {\color{LimeGreen}Free and Open-source Software for \\Science and Engineering Education} \\ +\small {\color{LimeGreen}Free and Open-source Software for \\ +Science and Engineering Education} \\ \scriptsize Based at IIT Bombay, Funded by MHRD.\\ \vspace{3pt} -\scriptsize Part of National Mission on Education through ICT (NME-ICT). \\ +\scriptsize Part of National Mission on Education through ICT (NME-ICT) \\ \end{itemize} \end{center} \end{frame} @@ -300,7 +297,8 @@ documents. \begin{frame} \frametitle{About the Spoken Tutorial Project} \begin{itemize} -\item Watch the video available at {\color{blue}\url{http://spoken-tutorial.org /What\_is\_a\_Spoken\_Tutorial}} +\item Watch the video available at {\color{blue}\url{http://spoken-tutorial.org + /What\_is\_a\_Spoken\_Tutorial}} \item It summarises the Spoken Tutorial project \item If you do not have good bandwidth, you can download and watch it \end{itemize} @@ -311,7 +309,8 @@ documents. \begin{itemize} \item Conducts workshops using spoken tutorials \item Gives certificates to those who pass an online test -\item For more details, please write to \\ \hspace {0.5cm}{\color{blue}contact@spoken-tutorial.org} +\item For more details, please write to \\ \hspace {0.5cm} +{\color{blue}contact@spoken-tutorial.org} \end{itemize} \end{frame} @@ -319,8 +318,10 @@ documents. \frametitle{Acknowledgements} \begin{itemize} \item Spoken Tutorial Project is a part of the Talk to a Teacher project -\item It is supported by the National Mission on Education through ICT, MHRD, Government of India -\item More information on this Mission is available at: \\{\color{blue}\url{http://spoken-tutorial.org/NMEICT-Intro}} +\item It is supported by the National Mission on Education through ICT, MHRD, +Government of India +\item More information on this Mission is available at: \\ +{\color{blue}\url{http://spoken-tutorial.org/NMEICT-Intro}} \end{itemize} \end{frame} diff --git a/Latex/Latex2/latex_intro_script.rst b/Latex/Latex2/latex_intro_script.rst index 1e5b9f7..855869c 100644 --- a/Latex/Latex2/latex_intro_script.rst +++ b/Latex/Latex2/latex_intro_script.rst @@ -1,30 +1,4 @@ -.. Objectives -.. ---------- - -.. At the end of this tutorial, you will - -.. 1. Get acquainted to LaTeX. -.. #. Know why we prefer LaTeX? -.. #. Know the advantages and disadvantages of typesetting documents -.. using the LaTeX approach. -.. #. Have a description, of a typical work flow; which uses LaTeX to typeset -.. documents. -.. #. Recognise and differenciate between LaTeX commands, LaTeX comments and -.. special characters, spacing and actual document content. -.. #. Create and compile a very simple LaTeX document. - -.. Prerequisites -.. ------------- - -.. 1. Installing LaTeX - - -.. Author : Harish Badrinath < harish [at] fossee [dot] in > - Internal Reviewer : Kiran Isukapatla < kiran [at] fossee [dot] in > - External Reviewer : - Langauge Reviewer : - Checklist OK? : 25-Feb-2012 - +------ Script ------ @@ -83,8 +57,8 @@ producing other kinds of documents, ranging from simple one page articles to complete books. LaTeX is pronounced Lah-tech or Lay-tec. -TeX is pronounced Tech. TeX is also the first syllable in the Greek word for -technology. +'TeX' is pronounced Tech. 'TeX' is also the first syllable in the Greek word +for technology. .. L5 @@ -100,7 +74,7 @@ Why we prefer LaTeX? .. L6 -{{{ Show the "Why LaTeX? ..." slide }}} +{{{ Show the "Why LaTeX?.." slide }}} .. R6 @@ -111,7 +85,7 @@ Mark-up: a system of annotating text, adding extra information to specify structure and presentation of text. Document based markup: you don’t have to worry about each element individually. -This is essentially a fancy way of saying,LaTeX handles typesetting and lets +This is essentially a fancy way of saying, LaTeX handles typesetting and lets you focus on content rather than appearance. .. L7 @@ -182,7 +156,7 @@ command and ends with an end command. .. L11 -{{{ Show the "Commands,Comments&Special Characters ..." slide }}} +{{{ Show the "Commands,Comments&Special Characters.." slide }}} .. R11 @@ -247,26 +221,36 @@ our documents. .. L14 {{{ Show the "Summary" slide }}} - + .. R14 This brings us to the end of this tutorial. In this tutorial, we have learnt 1. About LaTeX. -#. why we prefer LaTeX. -#. About the advantages and disadvantages of typesetting documents +#. Why we prefer LaTeX. +#. The advantages and disadvantages of typesetting documents using the LaTeX approach. + +.. L15 + +{{{ Show the "Summary.." slide }}} + +.. R15 + +This brings us to the end of this tutorial. In this tutorial, we have learnt + #. A description, of a typical work flow; which uses LaTeX to typeset documents. #. The ability to recognize and differentiate between LaTeX commands, LaTeX comments and special characters, spacing and actual document content. #. To Create and compile a simple LaTeX document. -.. L15 + +.. L16 {{{ Show the "Self assessment questions" slide }}} -.. R15 +.. R16 Here are some self assessment questions for you to solve @@ -278,11 +262,11 @@ Here are some self assessment questions for you to solve temp_1.pdf using the dvipdfm command. Verify that the two files indeed look the same. -.. L16 +.. L17 {{{ Show the "Solutions" slide }}} -.. R16 +.. R17 And the answers, @@ -290,11 +274,11 @@ And the answers, 2. dvipdfm -o temp_1.pdf temp.dvi -.. L17 +.. L18 {{{ Show the SDES & FOSSEE slide }}} -.. R17 +.. R18 Software Development techniques for Engineers and Scientists - SDES, is an initiative by FOSSEE. For more information, please visit the given link. @@ -303,43 +287,43 @@ Free and Open-source Software for Science and Engineering Education - FOSSEE, is based at IIT Bombay which is funded by MHRD as part of National Mission on Education through ICT. -.. L18 +.. L19 {{{ Show the ``About the Spoken Tutorial Project'' slide }}} -.. R18 +.. R19 Watch the video available at the following link. It summarises the Spoken Tutorial project.If you do not have good bandwidth, you can download and watch it. -.. L19 +.. L20 {{{ Show the `` Spoken Tutorial Workshops'' slide }}} -.. R19 +.. R20 The Spoken Tutorial Project Team conducts workshops using spoken tutorials, gives certificates to those who pass an online test. For more details, contact contact@spoken-tutorial.org -.. L20 +.. L21 {{{ Show the Acknowledgements slide }}} -.. R20 +.. R21 Spoken Tutorial Project is a part of the "Talk to a Teacher" project. It is supported by the National Mission on Education through ICT, MHRD, Government of India. More information on this mission is available at the given link. -.. L21 +.. L22 {{{ Show the Thankyou slide }}} -.. R21 +.. R22 Hope you have enjoyed this tutorial and found it useful. Thank you! diff --git a/Latex/Latex3/latex_basics.tex b/Latex/Latex3/latex_basics.tex index 64e5ad7..4d66ddb 100644 --- a/Latex/Latex3/latex_basics.tex +++ b/Latex/Latex3/latex_basics.tex @@ -7,40 +7,12 @@ \setbeamercovered{transparent} \setbeamertemplate{navigation symbols}{} } - -\usepackage[T1]{fontenc} -\usepackage{fixltx2e} -\usepackage{graphicx} -\usepackage{longtable} -\usepackage{float} -\usepackage{wrapfig} -\usepackage{soul} -\usepackage{textcomp} -\usepackage{marvosym} -\usepackage{wasysym} -\usepackage{latexsym} -\usepackage{amssymb} -\usepackage{hyperref} -\tolerance=1000 -\usepackage[english]{babel} \usepackage{ae,aecompl} -\usepackage{mathpazo,courier,euler} \usepackage[scaled=.95]{helvet} -\usepackage{listings} -\lstset{ - language=TeX, - basicstyle=\ttfamily\bfseries, - commentstyle=\ttfamily\color{blue}, - stringstyle=\ttfamily\color{orange}, - showstringspaces=false, - breaklines=true, - postbreak = \space\dots -} - % Taken from Fernando's slides. \usepackage{ae,aecompl} \usepackage[scaled=.95]{helvet} \usepackage[english]{babel} -\usepackage[latin1]{inputenc} +%\usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} % change the alerted colour to LimeGreen @@ -52,7 +24,7 @@ % \setbeamercovered{transparent} % theme split -\usepackage{verbatim} + \newenvironment{colorverbatim}[1][]% {% \color{blue} @@ -61,14 +33,15 @@ {% \endverbatim }% - +\usepackage{verbatim} \usepackage{mathpazo,courier,euler} \usepackage{listings} \lstset{language=sh, basicstyle=\ttfamily\bfseries, showstringspaces=false, keywordstyle=\color{black}\bfseries} - +\newcommand{\typ}[1]{\lstinline{#1}} +%\newcommand{\kwrd}[1]{ \texttt{\textbf{\color{blue}{#1}}} } % logo \logo{\includegraphics[height=1.30 cm]{../images/3t-logo.pdf}} \logo{\includegraphics[height=1.30 cm]{../images/fossee-logo.pdf} @@ -77,27 +50,25 @@ \includegraphics[scale=0.99]{../images/fossee-logo.pdf}\\ \hspace{281pt} \includegraphics[scale=0.80]{../images/3t-logo.pdf}} -\newcommand{\typ}[1]{\lstinline{#1}} - - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % DOCUMENT STARTS \begin{document} + +\sffamily \bfseries +\title +[{\LaTeX}: Basics and Structure] +{{\LaTeX}: Basics and Structure} +\author +[FOSSEE] +{\small Talk to a Teacher\\{\color{blue}\url{http://spoken-tutorial.org}} +\\\vspace{0.25cm}National Mission on Education + through ICT\\{\color{blue}\url{ http://sakshat.ac.in}} \\ [1.65cm] + Contributed by FOSSEE Team \\IIT Bombay \\[0.3cm] +} + +% slide 1 \begin{frame} - \begin{center} - \vspace{12pt} - \textcolor{blue}{\huge {\LaTeX} basics and structure} - \end{center} - \vspace{18pt} - \begin{center} - \vspace{10pt} - \includegraphics[scale=0.95]{../images/fossee-logo.png}\\ - \vspace{5pt} - \scriptsize Developed by FOSSEE Team, IIT-Bombay. \\ - \scriptsize Funded by National Mission on Education through ICT\\ - \scriptsize MHRD,Govt. of India\\ - \includegraphics[scale=0.30]{../images/iitb-logo.png}\\ - \end{center} + \titlepage \end{frame} \begin{frame} @@ -105,24 +76,31 @@ \label{sec-2} At the end of this tutorial, you will be able to, \begin{itemize} - \item Understand basic structure of a LaTeX document, its various document - classes and loading packages that add new features to the LaTeX system. - \item Create a LaTeX document with a title and an abstract. + \item Understand basic structure of a LaTeX document, + its various document classes and loading packages + \item Create a LaTeX document with a title and an abstract + \end{itemize} +\end{frame} + +\begin{frame} + \frametitle{Objectives..} + \begin{itemize} \item Create numbered and non-numbered sections and subsections - in a LaTeX document. - \item Create an appendix in a LaTeX document. - \item Create a table of content in a LaTeX document. + in a LaTeX document + \item Create an appendix in a LaTeX document + \item Create a table of content in a LaTeX document \end{itemize} \end{frame} + \begin{frame} \frametitle{Pre-requisite} \label{sec-3} - Spoken tutorial on - + Spoken tutorial on, \begin{itemize} -\item Introduction to {\LaTeX}. +\item {\LaTeX} Introduction \end{itemize} \end{frame} @@ -133,56 +111,44 @@ \begin{verbatim} \documentclass{article} \begin{document} - SciPy is open-source software for mathematics, science, and - engineering. + SciPy is open-source software for mathematics, + science, and engineering. \end{document} \end{verbatim} } \end{frame} -\begin{frame}[fragile] - \frametitle{\typ{documentclass command}} - \begin{center} - \begin{verbatim} - \documentclass{article} - \end{verbatim} - \end{center} -\end{frame} - -\begin{frame}[fragile] - \frametitle{\typ{documentclass command}\ \ldots} - \begin{center} - \begin{verbatim} - \documentclass [parameters] {DocumentClass} - \end{verbatim} - \end{center} -\end{frame} \begin{frame}[fragile] - \frametitle{\typ{documentclass command: A Closer look}} + \frametitle{\typ{documentclass command}} \begin{itemize} \item Used to select the \emph{class} of our document \item Some available classes - \typ{article}, \typ{proc}, - \typ{report}, \typ{book}, \typ{slides}, \typ{letter}. - \item For example: - \typ{\\documentclass\[12pt,a4paper,draft\]\{report\}}\\ - The parameters within \typ{\[ \]} are optional. + \typ{report}, \typ{book}, \typ{slides}, \typ{letter} + \end{itemize} +\end{frame} + +\begin{frame}[fragile] + \frametitle{\typ{documentclass command}..} + \begin{itemize} + \item Example: + \typ{\\documentclass} + \typ{\[12pt,a4paper,draft\]\{report\}}\\ + \tiny The parameters within \typ{\[ \]} are optional. \begin{itemize} - \item \typ{12pt} -- sets the font size of main font and others are - relatively, adjusted. \typ{10pt} is the default. + \item \typ{12pt} -- sets the font size of main font \item \typ{a4paper} -- specify paper size - \item \typ{draft} -- marks hyphenation and justification problems in - typesetting with a square in the margin + \item \typ{draft} -- makes LaTeX indicate hyphenation and justification + problems \end{itemize} \end{itemize} \end{frame} + \begin{frame}[fragile] \frametitle{\typ{usepackage command}} \begin{center} - \begin{verbatim} - \usepackage[options]{...} - \end{verbatim} + \lstinline{\usepackage[options]}\{...\} \end{center} \end{frame} @@ -202,8 +168,7 @@ \author{FOSSEE} \date{June 2010} \begin{document} - SciPy is open-source software for mathematics, science, - and engineering. + SciPy is open-source software for mathematics, science, and engineering. \end{document} \end{verbatim} } @@ -220,8 +185,7 @@ \date{June 2010} \begin{document} \maketitle - SciPy is open-source software for mathematics, science, - and engineering. + SciPy is open-source software for mathematics, science, and engineering. \end{document} \end{verbatim} } @@ -242,11 +206,9 @@ \begin{document} \maketitle \begin{abstract} - This document shows a glimpse of the features of Scipy that will - be explored during this course. + This document shows a glimpse of the features of Scipy that will be explored during this course. \end{abstract} - SciPy is open-source software for mathematics, science, - and engineering. + SciPy is open-source software for mathematics, science, and engineering. \end{document} \end{verbatim} } @@ -328,8 +290,7 @@ \frametitle{Appendices} \begin{itemize} \item \lstinline{\appendix} command indicates the beginning of appendices. - \item Any content after \lstinline{\appendix}, will be added - to the appendix. + \item Any content after \lstinline{\appendix}, will be added to the appendix. \item Use sectioning commands to add sections. \end{itemize} \end{frame} @@ -361,13 +322,8 @@ \begin{frame}[fragile] \frametitle{\typ{Exercise 1}} \begin{center} - Write a LaTeX script that creates a document of type article, which - contains both a table of content and an appendix. - The table of content should be at the beginning of the document - and the appendix at the end. - The book should contain two chapters, with the first chapter containing - two numbered and two un-numbered sections. The first un-numbered - section should be present in the table of content. + Write a LaTeX script that creates a document of type article, which contains both a table of content and an appendix. The table of content should be at the beginning of the document and the appendix at the end. + The book should contain two chapters, with the first chapter containing two numbered and two un-numbered sections. The first un-numbered section should be present in the table of content. \end{center} \end{frame} @@ -393,8 +349,7 @@ Numbered-Section 2 Text \section*{Un-numbered Section3} \addcontentsline{toc}{section}{Numbered Subsection1} - First un-numbered Section Text.\\This appears in the - table of content + First un-numbered Section Text.\\This appears in the table of content \section*{Un-numbered Section4} Second un-numbered Section Text \appendix @@ -411,12 +366,10 @@ \label{sec-8} In this tutorial, we have, \begin{itemize} - \item Gained an understanding of the basic structure of a LaTeX document, - its various document classes and loading packages that add new features to + \item Gained an understanding of the basic structure of a LaTeX document, its various document classes and loading packages that add new features to \item the LaTeX system. \item Created a LaTeX document with a title and an abstract. - \item Created both numbered and non-numbered sections and subsections - in a LaTeX document. + \item Created both numbered and non-numbered sections and subsections in a LaTeX document. \item Created an appendix in a LaTeX document. \item Created a table of content in a LaTeX document. \end{itemize} @@ -427,9 +380,7 @@ \label{sec-9} {\footnotesize \begin{enumerate} - \item Is the LaTeX code given below a valid input file (File compiles -successfully and produces the intended result, that is to produce a book - with two chapters and an appendix. + \item Is the LaTeX code given below a valid input file (File compiles successfully and produces the intended result, that is to produce a book with two chapters and an appendix. {\tiny \begin{center} \begin{verbatim} @@ -449,10 +400,7 @@ successfully and produces the intended result, that is to produce a book \end{verbatim} \end{center} } - \item subsection command can be placed at any arbitrary level. - If they get numbered by default using the appropriate setcounter -command and secnumdepth parameter, do they automatically appear in the -table of content ?? + \item subsection command can be placed at any arbitrary level. If they get numbered by default using the appropriate setcounter command and secnumdepth parameter, do they automatically appear in the table of content ?? \end{enumerate} } \end{frame} @@ -461,31 +409,28 @@ table of content ?? \frametitle{\typ{Solutions}} \label{sec-10} \begin{enumerate} -\item Although the given file looks syntactically valid, the output file is - not what we expected. This is mainly because we are trying to use the - section command to create sections in the appendix, for a document whose - type is given as a book. +\item Although the given file looks syntactically valid, the output file is not what we expected. This is mainly because we are trying to use the section command to create sections in the appendix, for a document whose type is given as a book. \vspace{15pt} -\item No, the \textbackslash tableofcontents command normally shows only - numbered section headings, and only down to the level defined by the - tocdepth counter. +\item No, the \textbackslash tableofcontents command normally shows only numbered section headings, and only down to the level defined by the tocdepth counter. \end{enumerate} \end{frame} \begin{frame} + \begin{block}{} \begin{center} - \textcolor{blue}{\Large THANK YOU!} + {\Large THANK YOU!} \end{center} \end{block} - \begin{block}{} - \begin{center} - For more Information, visit our website\\ - \url{http://fossee.in/} - \end{center} +\begin{block}{} + \begin{center} + For more Information, visit our website\\ + {\color{blue}\url{http://fossee.in/}} + \end{center} \end{block} \end{frame} \end{document} + diff --git a/Latex/Latex3/latex_basics_and_structure_script.rst b/Latex/Latex3/latex_basics_and_structure_script.rst index d1db08b..68aa33d 100644 --- a/Latex/Latex3/latex_basics_and_structure_script.rst +++ b/Latex/Latex3/latex_basics_and_structure_script.rst @@ -1,40 +1,14 @@ -.. Objectives -.. ---------- - -.. At the end of this tutorial, you will be able to - -.. 1. Understand basic structure of a LaTeX document, its various document -.. classes and loading packages that add new features to the LaTeX system. -.. #. Create a LaTeX document with a title and an abstract. -.. #. Create numbered and non-numbered sections and sub-sections in a LaTeX -.. document. -.. #. Create an appendix in a LaTeX document. -.. #. Create a 'table of contents' in a LaTeX document. - -.. Prerequisites -.. ------------- - -.. 1. Introduction to LaTeX - - -.. Author : Harish Badrinath < harish [at] fossee [dot] in > - Internal Reviewer : Kiran Isukapatla < kiran [at] fossee [dot] in > - External Reviewer : - Langauge Reviewer : - Checklist OK? : 26-Feb-2012 - +------ Script ------ .. L1 -{{{ Show the first slide containing the title, name of the production -team along with the logo of MHRD }}} +{{{ Show the title slide }}} .. R1 -Hello friends and welcome to the tutorial on "Basics of LaTeX and its -document structure". +Hello friends and welcome to the tutorial on "LaTeX: Basics & Structure". .. L2 @@ -42,16 +16,26 @@ document structure". .. R2 -At the end of this tutorial, you will be able to +At the end of this tutorial, you will be able to, 1. Understand basic structure of a LaTeX document, its various document classes and loading packages that add new features to the LaTeX system. #. Create a LaTeX document with a title and an abstract. -#. Create numbered and non-numbered sections and subsections in a LaTeX + +.. L2 + +{{{ Show the "Objectives.." slide }}} + +.. R2 + +At the end of this tutorial, you will be able to + +3. Create numbered and non-numbered, sections and subsections in a LaTeX document. -#. Create an 'appendix' in a LaTeX document. +#. Create an appendix in a LaTeX document. #. Create a table of content in a LaTeX document. + .. L3 {{{ Show the "Pre-requisite" slide }}} @@ -80,10 +64,9 @@ before the \begin{document} command is called the preamble, and is used to "configure" the LaTeX typesetter and change various parameters for typesetting. In our current example, the preamble is empty. We will add preamble content in the later part of the tutorial. -This is processed by a TeX processor that generates an output file. Now, we -begin to look into each line in the example in more detail. -The first line reads +We will now see in the first line of the example we just showed, +the <\\documentclass{article}> command. .. L5 @@ -123,7 +106,8 @@ report, book, slides and letter. the default. a4paper: specifies the paper size draft: marks hyphenation and justification problems in typesetting -with a square in the margin +with a square in the margin. +makes LaTeX indicate hyphenation and justification problems with a small square in the right-hand margin of the problem line so they can be located quickly by a human. It also suppresses the inclusion of images and shows only a frame where they would normally occur. .. L8 diff --git a/Latex/Latex4/Latex_Typesetting_Text.tex b/Latex/Latex4/Latex_Typesetting_Text.tex index ef4d6f9..dced171 100644 --- a/Latex/Latex4/Latex_Typesetting_Text.tex +++ b/Latex/Latex4/Latex_Typesetting_Text.tex @@ -77,20 +77,20 @@ \begin{frame} \frametitle{Objectives} - At the end of this session, you will be able to: + At the end of this session, you will learn how to: \begin{itemize} - \item Learn how to typeset your document using {\LaTeX} + \item Typeset your document using {\LaTeX} \item Use lists, listings in your document for formatting text \end{itemize} \end{frame} \begin{frame} - \frametitle{Prerequisite} + \frametitle{Prerequisites} Spoken Tutorial on: \begin{itemize} - \item {\LaTeX} Part 1 - Getting Started - \item {\LaTeX} Part 2 - Introduction - \item {\LaTeX} Part 3 - Structuring the Content + \item {\LaTeX} Installation + \item {\LaTeX} Introduction + \item {\LaTeX} Basics \& Structuring \end{itemize} \end{frame} @@ -108,7 +108,7 @@ \begin{itemize} \item \lstinline{\emph} gives emphasized or italic text \item \typ{flushleft} to have text left aligned - \item \typ{flushright}, \typ{center} + \item \typ{flushright}, \typ{center} to have text right and center aligned respectively \end{itemize} \end{frame} @@ -141,25 +141,25 @@ \begin{frame}[fragile] \frametitle{Labels and References} \begin{itemize} - \item \lstinline+\label{labelname}+ is used to label an element - \item \lstinline+\ref{labelname}+ is used to refer to that element + \item \lstinline+\label{label-name}+ is used to label an element + \item \lstinline+\ref{label-name}+ is used to refer to that element \item Compile twice \end{itemize} \end{frame} \begin{frame}[fragile] - \frametitle{Including code} + \frametitle{Code Inclusion} \begin{itemize} \item We could use \lstinline{\verbatim} \item \lstinline+listings+ is a powerful package \item \lstinline+\usepackage{listings}+ needs to be added - \item Spefify language either by using + \item Specify language either by using \small\typ{\\lstinputlisting[language=Python]} or \typ{\\lstset} \end{itemize} \end{frame} \begin{frame}[fragile] - \frametitle{Including code..} + \frametitle{Code Inclusion..} \begin{itemize} \item Use \lstinline+\lstlisting+ for a block of code \item \typ{\\lstinline} for inline code @@ -168,13 +168,13 @@ \begin{frame}[fragile] - \frametitle{Summary...} + \frametitle{Summary} \begin{itemize} - \item Put Quotation Marks around text. + \item Add Quotation Marks to text. \item Emphasize and give fixed width to fonts. \item Use numbered and un-numbered lists. \item Add Footnotes, Labels and References. - \item To include code. + \item Include code. \end{itemize} \end{frame} @@ -182,7 +182,7 @@ \frametitle{Evaluation} \begin{enumerate} \item Which environment is used to include a block of code? -\item Joe has numerous used labels inside his Latex document. +\item Joe has used numerous labels inside his Latex document. But all the references to label names come up as question marks. What might be the problem? \end{enumerate} @@ -193,7 +193,7 @@ What might be the problem? \begin{enumerate} \item lstlistings \vspace{15pt} -\item While using labels, the latex document should be compiled +\item While using labels, the Latex document should be compiled twice for the references to show up. \end{enumerate} \end{frame} @@ -212,7 +212,7 @@ twice for the references to show up. \small {\color{LimeGreen}Free and Open-source Software for \\Science and Engineering Education} \\ \scriptsize Based at IIT Bombay, Funded by MHRD.\\ \vspace{3pt} -\scriptsize Part of National Mission on Education through ICT (NME-ICT). \\ +\scriptsize Part of National Mission on Education through ICT (NME-ICT) \\ \end{itemize} \end{center} \end{frame} diff --git a/Latex/Latex4/Typesetting_Text_Latex.rst b/Latex/Latex4/Typesetting_Text_Latex.rst index 38e527c..2aee9aa 100644 --- a/Latex/Latex4/Typesetting_Text_Latex.rst +++ b/Latex/Latex4/Typesetting_Text_Latex.rst @@ -17,7 +17,7 @@ Script .. R1 -Hello friends and welcome to the second tutorial on Typsetting Text in Latex. +Hello friends and welcome to the tutorial on Typesetting Text in Latex. .. L2 @@ -25,24 +25,24 @@ Hello friends and welcome to the second tutorial on Typsetting Text in Latex. .. R2 -At the end of this tutorial you will be able to: +At the end of this tutorial you will learn how to: -1. Learn how to typeset your document using LaTEX. +1. Typeset your document using LaTEX. #. Use lists, listings in your document for formatting text. .. L3 -{{{Show the slide 'Prerequisite'}}} +{{{Show the slide 'Prerequisites'}}} .. R3 Please make sure that you have gone through the following tutorials before you continue on this tutorial: -1. LaTeX Part 1 - Getting Started -2. LaTeX Part 2 - Introduction -3. LaTeX Part 3 - Structuring the Content +1. Latex Installation +2. Latex Introduction +3. Latex Basics & Structuring .. L4 @@ -50,7 +50,7 @@ continue on this tutorial: {{{Show the slide 'Quotation Marks'}}} .. R4 -How can we add Quotation Marks to our document ? +Let us begin with how to add qutation marks to our document. For this, we use ` (accent) character for the left quote & ' (apostrophe) character for the right quote. For double quotes, we use them twice. @@ -61,8 +61,8 @@ For double quotes, we use them twice. .. R5 -The \emph command is used to give the text an emphasized & italic effect. -In tabular structures LaTeX doesn't add multiple spaces between words. +The <\emph> command is used to give the text an emphasized & italic effect. +In tabular structures, LaTeX doesn't add multiple spaces between words. Just like multiple empty lines, multiple spaces are considered as a single space. Also, LaTeX starts a new paragraph at the beginning of the table. @@ -76,8 +76,8 @@ respectively. .. R6 -'\texttt' is used to change text to fixed width font & -'\textbf' is used to change text to bold face +<'\texttt'> is used to change text to fixed width font & +<'\textbf'> is used to change text to bold face. We could also change the separating - (hyphen) to -- (n-dash) or --- (em-dash) to improve the appearance of the document. @@ -88,7 +88,7 @@ to improve the appearance of the document. .. R7 The 'enumerate' environment adds numbered lists to our document and -the itemise environment adds un-numbered lists. \item command adds +the itemise environment adds un-numbered lists. <\item> command adds a new entry to a list. Note, that LaTeX can easily handle nested lists. In fact, most environments can be embedded within other environments, without any problems. @@ -101,7 +101,7 @@ without any problems. .. R8 LaTeX provides a footnote command to add a footnote. -In case we wish to add another Appendix before the section the footnote has +In case we wish to add another Appendix before the section, the footnote has to be edited. To avoid this, LaTeX provides a handy system of labels and referencing. @@ -113,20 +113,21 @@ of labels and referencing. We can create labels for any elements in the document and then refer them anywhere in the document. -\\label{labelname} command is used to create a lable for a particular element. -Then, to refer to that element with a lable \\ref{labelname} command is used. +<\\label{label-name}> command is used to create a label for a particular +element. Then, to refer to that element with a label, <\\ref{label-name}> +command is used. -But, remember that when you compile the document first time you will see -question marks instead of the element you have refered using lables. +But, remember that when you compile the document first time, you will see +question marks instead of the element you have referred using labels. Do not worry, you just have to compile the document once again to make the -elements refered by labels to appear. +elements referred by labels to appear. So, whenever you use the labels & references remember to compile the document twice. .. L10 -{{{Show the slide 'Include Code'}}} +{{{Show the slide 'Code Inclusion'}}} .. R10 @@ -138,22 +139,22 @@ including code in our document. First of all, we need to tell LaTeX, that we want to use the listings package in our document. We do this by adding the directive -\usepackage{listings} to the preamble of our document. +<\usepackage{listings}> to the preamble of our document. Then, we specify the language of the code that we are going to embed into our document. This can be done in two ways, -directly specifying it while declaration \lstinputlisting[language=Python] or -we can use the 'lstset' command. +directly specifying it while declaration <\lstinputlisting[language=Python]> +or we can use the <'lstset'> command. .. L11 -{{{Show slide 'Including code..'}}} +{{{Show slide 'Code Inclusion..'}}} .. R11 Now, to put a line of code (inline and not as a separate block), -we use the \lstinline command. To embed a block of code, we use -the lstlisting environment (\begin{lstlisting} and \end{lstlisting}). +we use the <\lstinline> command. To embed a block of code, we use +the lstlisting environment <(\begin{lstlisting} and \end{lstlisting})>. .. L12 @@ -164,7 +165,7 @@ the lstlisting environment (\begin{lstlisting} and \end{lstlisting}). This brings us to the end of the tutorial. In this tutorial, we have learnt to, -1. Put Quotation Marks around text. +1. Add Quotation Marks around text. #. Emphasize and give fixed width to fonts. @@ -172,7 +173,7 @@ learnt to, #. Add Footnotes, Labels and References. -#. To include code. +#. Include code. .. L13 @@ -184,7 +185,7 @@ Here are some self assessment questions for you to solve. 1. Which environment is used to include a block of code? -#. Joe has numerous used labels inside his Latex document. +2. Joe has used numerous labels inside his Latex document. But all the references to label names come up as question marks. What might be the problem? @@ -199,7 +200,7 @@ And the answers are, 1. Use the lstlistings package to include code. -#. While using labels, the latex document should be compiled twice +2. While using labels, the latex document should be compiled twice for the references to show up. @@ -213,8 +214,8 @@ for the references to show up. Software Development techniques for Engineers and Scientists - SDES, is an initiative by FOSSEE. For more information, please visit the given link. -Free and Open-source Software for Science and Engineering Education - FOSSEE, is -based at IIT Bombay which is funded by MHRD as part of National Mission on +Free and Open-source Software for Science and Engineering Education - FOSSEE, +is based at IIT Bombay which is funded by MHRD as part of National Mission on Education through ICT. .. L16 diff --git a/Latex/Latex5/FTF_Latex.rst b/Latex/Latex5/FTF_Latex.rst index b213709..732842d 100644 --- a/Latex/Latex5/FTF_Latex.rst +++ b/Latex/Latex5/FTF_Latex.rst @@ -1,23 +1,14 @@ - -.. Prerequisites -.. ------------- - -.. None - -.. Author : Primal Pappachan - Internal Reviewer : Kiran Isukapatla, Sushma Dubey - Date: Jan 15, 2012 -------- Script -------- .. L1 -{{{ Show the first slide containing title, name of the production team along with the logo of MHRD}}} +{{{ Show the title slide}}} .. R1 -Hello friends and welcome to the second tutorial on Latex. +Hello friends and welcome to the tutorial on Latex: Tables & Figures. .. L2 @@ -25,71 +16,105 @@ Hello friends and welcome to the second tutorial on Latex. .. R2 -1. Learn how to add figures to your document +In this tutorial we will learn how to: -#. Include tabular environments +1. Add figures in Latex document. + +#. Include tabular environments in Latex document. .. L3 -{{{Show the slide 'Prerequisite'}}} +{{{Show the slide 'Prerequisites'}}} .. R3 -Please make sure that you have gone through the following tutorials before you continue on this tutorial +Please make sure that you have gone through the following tutorials before you +continue on this tutorial: + +1. Latex Installation +#. Latex Introduction +#. Latex Basics & Structuring +#. Latex Typesetting Text .. L4 {{{Show the slide 'Figures'}}} .. R4 - -To include graphics in a LaTeX document, we need to use the graphicx package. Add the \usepackage{graphicx} directive to the preamble of the document. - -To add the graphic, use the includegraphics command. The relative path of the image that we wish to include is passed as an argument to includegraphics. It takes an optional argument of scaling the image. - -.. L5 - -{{{Show rev17 of hg}}} - -.. R5 - -We use a scale of 0.4 to scale our image. +Let us start with seeing how to include 'figures' in a Latex document. +To include graphics in a LaTeX document, we need to use the package. +To use this package, we have to add the <\\usepackage{graphicx}> directive +to the preamble of the document. + +Then, to add a graphic, use the <\\includegraphics> command. +The relative path of the image that we wish to include is passed as an +argument to includegraphics. You can see two images in each slide of this +presentation, these images are included using <\\includegraphics> command. +It takes an optional argument, to scale an image. For our images a scale +of 0.80 is used. -.. L6 +.. L5 {{{Show slide 'includegraphics'}}} -.. R6 +.. R5 -It takes other optional arguments. +<\\includegraphics> command also takes other optional arguments such as: -1. width=x, height=x +1. -If only the height or width is specified, the image is scaled, maintaining the aspect ratio. +If only the height or width is specified, the image is scaled, +maintaining the aspect ratio. -#. keepaspectratio +#. -This parameter can either be set to true or false. When set to true, the image is scaled according to both width and height, without changing the aspect ratio, so that it does not exceed both the width and the height dimensions. +This parameter can either be set to true or false. +When set to true, the image is scaled according to both width and height, +without changing the aspect ratio, so that it does not exceed both the +width and the height dimensions. -#. angle=x +#. This option can be used to rotate the image by x degrees, counter-clockwise. + +.. L6 + +{{{Show slide 'includegraphics..'}}} + +.. R6 + +Here is the complete syntax for <\\includegraphics> command with +the optional arguments we just talked about and the relative path +to the image. + .. L7 {{{Show the slide 'Floats'}}} .. R7 -Figures (and tables) are treated specially because, they cannot be broken across pages. They are "floated" across to the next page, if they donot fit on the current page, filling the current page with text. To make our graphic into a float, we should enlose it within a figure environment. The figure environment takes an additional parameter for the location of the float. +Graphics (and tables) are treated specially because, +they cannot be split into pages. +They are "floated" across to the next page, +if they do not fit on the current page, filling the current page with text. +To make our graphic into a float, we should enlose it within +a figure environment. The figure environment takes an additional parameter +for the location of the float. .. L8 -\begin{figure}[hbtp!] +{{{Show the slide 'Floats..'}}} .. R8 -The specifiers htbp are permissions to place the float at various locations. t for top of page, b for bottom of page, p for a separate page for floats and h for here, as in the same place where the command appears in the source. ! mark overrides a few of LaTeX's internal parameters for good position of floats. +The specifiers 't','b','p','h' & '!' are permissions to place the float at +various locations. +'t' for top of page, 'b' for bottom of page, 'p' for a separate page for +floats and 'h' for here, as in pproximately at the same point it occurs in +the source text. '!' mark overrides few of LaTeX's internal parameters +for good position of floats. + .. L9 @@ -97,37 +122,51 @@ The specifiers htbp are permissions to place the float at various locations. t f .. R9 -The figure environment also, allows us to add a caption to the graphic using the \caption command. +The figure environment also, allows us to add a caption to the graphic +using the <\\caption> command. This command will be placed within the figure +environment. +To keep the graphic center aligned in the page, +we use the center environment within the figure environment. +To label a figure, we just add a <\\label> command within the +figure environment. +Note that the label to a figure should be added after the caption command. +Figures are auto numbered. -To place the graphic in the center aligned in the page, we use the center environment. +.. L10 -To label a figure, we just add a label with in the figure environment. Note, that the label to a figure should be added after the caption command. +{{{Show the slide Captions and References..}}} -.. L9 - -{{{Show rev17 of hg}}} +.. R10 -.. R9 +Here, you can see a sample code that shows the use of figure environment +with caption & label. +It explains how to include image, how to center align it. +Also shows, how to add caption and label to an image. +You can note that the label is added after the caption, as we mentioned +earlier. -Figures are auto numbered -.. L10 +.. L11 {{{Show the slide 'Tables'}}} -.. R10 - -Now, let us look at the other kind of floats - Tables. We shall convert the list of sub-packages in the sub-packages section to a table. +.. R11 -To begin a table, we use the tabular environment. And to make this a float, it is enclosed in the table environment. The table environment also allows us to add captions to the table and Tables are also auto numbered. +Now, let us look at how to include Tables in our document. +To typeset content in a tabular format, we use the tabular environment. +And to make it a float, it is enclosed in the table environment. +The table environment also allows us to add captions & labels to the table, +just as we added in the figure environment. +Tables are also auto numbered. -.. L11 +.. L12 {{{Show the slide 'tabular'}}} -.. R11 +.. R12 -The tabular environment takes as arguments the columns and the formatting of each column. The possible arguments to the tabular environment are +The tabular environment takes the columns, and the formatting of each column, +as arguments. The possible arguments to the tabular environment are 1. l for left justified column content @@ -135,31 +174,47 @@ The tabular environment takes as arguments the columns and the formatting of eac #. c for centered column content -#. | for produces a vertical line. +#. | (pipe) produces a vertical line. -It also takes an optional parameter that specifies the position of the table; t for top, b for bottom, or c for center. -.. L12 +.. L13 -{{{Show rev18 of hg}}} +{{{Show the slide 'tabular..'}}} -.. R12 +.. R13 -Each column of a table is separated by an & symbol and each row is separated by a new line. The \hline command allows you to draw horizontal lines between two rows of the table. +Tabular also takes an optional parameter that specifies the position +of the table; 't' for top, 'b' for bottom, or 'c' for center. +Each column of a table is separated by an '&' (ampersand) symbol and +each row is separated by a new line. + +The <\\hline> command allows you to draw horizontal lines between +two rows of the table. -.. L13 +.. L14 + +{{{Show the slide 'tabular..'}}} + +.. R14 + +A sample code that shows the complete use of the tabular +environment with all arguments and options. + + +.. L15 {{{Show the slide 'List of Tables, Figures'}}} -.. R13 +.. R15 -You could also add a listoftables or listoffigures to the document, similar to the way we added table of contents. +You could also add a list of tables or list of figures to the document, +using <\\listoftables> & <\\listoffigures> commands respectively. -.. L14 +.. L16 {{{Show the 'summary' slide'}}} -.. R20 +.. R16 This brings us to the end of the tutorial. In this tutorial, we have learnt to, @@ -169,37 +224,85 @@ learnt to, #. Include tabular environments in a LateX document -.. L21 +.. L17 {{{Show self assessment questions slide}}} -.. R21 +.. R17 -Here are some self assessment questions for you to solve +Here are some self assessment questions for you to solve, -.. L22 +1. Which input parameter is used in the figure environment to make it float + to the bottom of the page ? +#. What is the mandatory argument in tabular environment specification ? + +.. L18 {{{Show the solutions slide to self assessment questions }}} -.. R22 +.. R18 And the answers, +1. Input parameter `b' is passed as argument, to make it float to the bottom + of the page. +#. It is mandatory to specify alignment of each column in tabular + environment. -.. L23 -{{{Show the thank you slide}}} +.. L19 -.. R23 +{{{ Show the SDES & FOSSEE slide }}} -Hope you have enjoyed this tutorial and found it useful. -Thank you +.. R19 +Software Development techniques for Engineers and Scientists - SDES, is an +initiative by FOSSEE. For more information, please visit the given link. +Free and Open-source Software for Science and Engineering Education - FOSSEE, +is based at IIT Bombay which is funded by MHRD as part of National Mission on +Education through ICT. +.. L20 +{{{ Show the About the Spoken Tutorial Project slide }}} +.. R20 +Watch the video available at the following link. It summarises the Spoken +Tutorial project.If you do not have good bandwidth, you can download and +watch it. + +.. L21 + +{{{ Show the Spoken Tutorial Workshops slide }}} + +.. R21 + +The Spoken Tutorial Project Team conducts workshops using spoken tutorials, +gives certificates to those who pass an online test. + +For more details, contact contact@spoken-tutorial.org + +.. L22 + +{{{ Show the Acknowledgements slide }}} + +.. R22 + +Spoken Tutorial Project is a part of the "Talk to a Teacher" project. +It is supported by the National Mission on Education through ICT, MHRD, +Government of India. More information on this mission is available at the +given link. + +.. L23 + +{{{ Show the Thankyou slide }}} + +.. R23 + +Hope you have enjoyed this tutorial and found it useful. +Thank you! diff --git a/Latex/Latex5/Latex_FTF.tex b/Latex/Latex5/Latex_FTF.tex index c7c50ae..e992ac5 100644 --- a/Latex/Latex5/Latex_FTF.tex +++ b/Latex/Latex5/Latex_FTF.tex @@ -4,8 +4,8 @@ % Author: FOSSEE % Copyright (c) 2009, FOSSEE, IIT Bombay %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - -\documentclass{beamer} +\documentclass[17pt,compress]{beamer} +\usepackage{beamerthemesplit} \usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} \usepackage{fixltx2e} @@ -24,6 +24,7 @@ \usepackage[english]{babel} \usepackage{ae,aecompl} \usepackage{mathpazo,courier,euler} \usepackage[scaled=.95]{helvet} \usepackage{listings} + \lstset{ language=TeX, basicstyle=\ttfamily\bfseries, @@ -34,58 +35,94 @@ postbreak = \space\dots } -\newcommand{\typ}[1]{\lstinline{#1}} - \mode { \usetheme{Warsaw} \useoutertheme{infolines} \setbeamercovered{transparent} + \setbeamertemplate{navigation symbols}{} } +% Taken from Fernando's slides. +\usepackage{ae,aecompl} +\usepackage[scaled=.95]{helvet} +\usepackage[english]{babel} +\usepackage[latin1]{inputenc} +\usepackage[T1]{fontenc} + +% change the alerted colour to LimeGreen +\definecolor{LimeGreen}{RGB}{50,205,50} +\setbeamercolor{structure}{fg=LimeGreen} +\author[FOSSEE]{} +\institute[IIT Bombay]{} +\date[]{} +% \setbeamercovered{transparent} -\setbeamercolor{emphbar}{bg=blue!20, fg=black} -\newcommand{\emphbar}[1] +% theme split +\usepackage{verbatim} +\newenvironment{colorverbatim}[1][]% +{% +\color{blue} +\verbatim +}% +{% +\endverbatim +}% + +\usepackage{mathpazo,courier,euler} +\usepackage{listings} +\lstset{language=sh, + basicstyle=\ttfamily\bfseries, + showstringspaces=false, + keywordstyle=\color{black}\bfseries} + +% logo +\logo{\includegraphics[height=1.30 cm]{../images/3t-logo.pdf}} +\logo{\includegraphics[height=1.30 cm]{../images/fossee-logo.pdf} + +\hspace{7.5cm} +\includegraphics[scale=0.99]{../images/fossee-logo.pdf}\\ +\hspace{281pt} +\includegraphics[scale=0.80]{../images/3t-logo.pdf}} +\newcommand{\typ}[1]{\lstinline{#1}} \begin{document} -\begin{frame} +\sffamily \bfseries +\title +[{\LaTeX}: Tables \& Figures] +{{\LaTeX}: Tables \& Figures} +\author +[FOSSEE] +{\small Talk to a Teacher\\{\color{blue}\url{http://spoken-tutorial.org}} +\\\vspace{0.25cm}National Mission on Education + through ICT\\{\color{blue}\url{ http://sakshat.ac.in}} \\ [1.65cm] + Contributed by FOSSEE Team \\IIT Bombay \\[0.3cm] +} -\begin{center} -\vspace{12pt} -\textcolor{blue}{\huge {\LaTeX}:Tables, Figures and Floats} -\end{center} -\vspace{18pt} -\begin{center} -\vspace{10pt} -\includegraphics[scale=0.95]{../images/fossee-logo.png}\\ -\vspace{5pt} -\scriptsize Developed by FOSSEE Team, IIT-Bombay. \\ -\scriptsize Funded by National Mission on Education through ICT\\ -\scriptsize MHRD,Govt. of India\\ -\includegraphics[scale=0.15]{../images/iitb-logo.jpg}\\ -\end{center} +\begin{frame} + \titlepage \end{frame} \begin{frame} \frametitle{Objectives} - At the end of this session, you will be able to: + In this tutorial we will learn how to: \begin{itemize} - \item Learn how to add figures to your document - \item Include tabular environments + \item Add graphics in Latex document + \item Include tabular environments in Latex document \end{itemize} \end{frame} \begin{frame} - \frametitle{Prerequisite} + \frametitle{Prerequisites} Spoken Tutorial on: \begin{enumerate} - \item {\LaTeX} - Getting Started + \item {\LaTeX} - Installation \item {\LaTeX} - Introduction - \item {\LaTeX} - Structuring the Content + \item {\LaTeX} - Basics \& Structuring \item {\LaTeX} - Typesetting Text \end{enumerate} \end{frame} @@ -98,70 +135,94 @@ \item To add a graphic, use \lstinline{\includegraphics} command \item Use relative path to the image \end{itemize} - \tiny See rev17 of \typ{hg} \end{frame} \begin{frame}[fragile] - \frametitle{\lstinline{includgraphics}} + \frametitle{\lstinline{includegraphics}} It takes following optional arguments \begin{itemize} - \item \lstinline+scale+ --- specifies the factor by which to scale - the image - \item \lstinline+height+, \lstinline+width+ --- If only one of them + \item \lstinline+height+, \lstinline+width+ -- If only one of them is specified, aspect ratio is maintained - \item \lstinline+keepaspectratio+ --- boolean value to keep aspect + \item \lstinline+keepaspectratio+ -- boolean value to keep aspect ratio or not - \item \lstinline+angle+ --- specify by what angle the image should + \item \lstinline+angle+ -- specify by what angle the image should be rotated \end{itemize} \end{frame} +\begin{frame}[fragile] + \frametitle{\lstinline{includegraphics..}} + Syntax for \lstinline{includegraphics} command with optional arguments and + relative path to the image: + \begin{itemize} + \item \lstinline{\includegraphics[]}\{ \} + \end{itemize} +\end{frame} + \begin{frame}[fragile] \frametitle{Floats} \begin{itemize} - \item Graphics (\& Tables) are special because they cannot be broken - across pages - \item They are ``floated'' to the next page, if they don't fit in - the current page + \item Graphics (\& Tables) are special + \item They are ``floated'' to the next page \item Enclose graphic within \lstinline+figure+ environment to make it float \item Figure environment takes additional parameter for location of float \end{itemize} - \begin{table} - \caption{Permission Specifiers} - - \begin{tabular}{|c|c|} +\end{frame} + +\begin{frame}[fragile] + \frametitle{Floats..} +\begin{table} + \begin{tabular}{|c|l} Specifier & Permission\\\hline t & Top of page\\ b & Bottom of page\\ p & Separate page for floats\\ - h & here (the same place where command appears in source)\\ - ! & override \LaTeX's internal parameters for good position + h & Here (the same place)\\ + ! & Overrides internal parameters \end{tabular} \end{table} \end{frame} + \begin{frame} \frametitle{Captions and References} \begin{itemize} - \item Figure environment allows us add a caption - \item To place the image in the center we enclose it in the + \item \lstinline+caption+ to add captions to figures + \item To place the image in the center, we enclose it in the \lstinline+center+ environment \item We can label images too - \item label should be added after the caption command + \item Add label after caption command \item Figures are auto numbered \end{itemize} - \tiny See rev17 of \typ{hg} \end{frame} +\begin{frame}[fragile] + \frametitle{Captions and References..} + Sample code to include caption and label in a center aligned figure: + \vspace{8pt} + {\tiny + \begin{verbatim} + \begin{figure} + \begin{center} + \includegraphics{some image} + \end{center} + \caption{A caption for some image !} + \label{Label for some image !} + \end{figure} + \end{verbatim} + } +\end{frame} + + \begin{frame}[frame] \frametitle{Tables} \begin{itemize} \item \lstinline+tabular+ is used to typeset a table \item It is enclosed in a \lstinline+table+ environment to make it a float - \item \lstinline+table+ environment also gives captions, auto + \item \lstinline+table+ environment also gives captions, labels \& auto numbering \end{itemize} \end{frame} @@ -170,12 +231,9 @@ \begin{frame}[fragile] \frametitle{\lstinline+tabular+} \begin{itemize} - \item tabular takes formatting of each column as argument + \item Tabular takes formatting of each column as argument \end{itemize} - \begin{table} - \caption{tabular environment} - \begin{tabular}{|l|l|} \lstinline+l+ & left justified column content\\\hline \lstinline+r+ & right justified column content\\\hline @@ -183,18 +241,41 @@ \lstinline+|+ & produces a vertical line\\ \end{tabular} \end{table} - \begin{itemize} - \item also takes an optional parameter for specifying position of +\end{frame} + +\begin{frame}[fragile] + \frametitle{\lstinline+tabular+..} +\begin{itemize} + \item Also takes an optional parameter for specifying position of table \item \lstinline+t+ for top, \lstinline+b+ for bottom, \lstinline+c+ for center - \item each column of table is separated by \& - \item each row is separated by newline \lstinline{\\} + \item Seperate each column of a table by '\&' + \item Each row is separated by newline \lstinline{\\} \item \lstinline+\hline+ give a horizontal line between two rows \end{itemize} - \tiny See rev18 of \typ{hg} \end{frame} + +\begin{frame}[fragile] + \frametitle{\lstinline+tabular+..} + A sample code that shows complete use of tabular environment: + \vspace{8pt} + {\tiny + \begin{verbatim} + \begin{center} + \begin{tabular}{ l | c || r | } + \hline + 1 & 2 & 3 \\ \hline + 4 & 5 & 6 \\ \hline + 7 & 8 & 9 \\ + \hline + \end{tabular} + \end{center} + \end{verbatim} + } +\end{frame} + \begin{frame}[fragile] \frametitle{List of Tables, Figures} \begin{itemize} @@ -204,7 +285,8 @@ \end{frame} \begin{frame}[fragile] - \frametitle{Summary...} + \frametitle{Summary} + We learned how to, \begin{itemize} \item Add graphics to a LateX document \item Include tabular environments in a LateX document @@ -214,9 +296,9 @@ \begin{frame}[fragile] \frametitle{Evaluation} \begin{enumerate} -\item Why the figures and tables are called as floats? -\item What are the input parameters the figure environment take to make it float? -\item What is the mandatory arguement in tabular environment specification? +\item Which input parameter is used in the figure environment to make it float + to the bottom of the page ? +\item What is the mandatory argument in tabular environment specification ? \end{enumerate} \end{frame} \begin{frame} @@ -224,34 +306,71 @@ \frametitle{Solutions} \begin{enumerate} \vspace{15pt} -\item Figures and tables are called as floats because they float to the nearest location. -\item The following can be used as parameters to a figure environment to make it float. +\item Input parameter `b' is passed as argument, to make it float to the bottom + of the page. +\item It is mandatory to specify alignment of each column in tabular + environment. +\end{enumerate} +\end{frame} + +\begin{frame} +\frametitle{SDES \& FOSSEE} +\begin{center} \begin{itemize} -\item t - Top of the page. -\item b - Bottom of the page. -\item p - Separate pages for float -\item h - Here(the place where command appears) -\item !- To override Latex internal parameters for good position +\item \small{SDES}\\ +\small{\color{LimeGreen}Software Development techniques for Engineers and Scientists} \\ +\scriptsize An initiative by FOSSEE. \\ +\vspace{3pt} +\scriptsize For more information on SDES, please visit {\color{blue}\url{http://fossee.in/sdes}}\\ +\vspace{12pt} +\item \small{FOSSEE}\\ +\small {\color{LimeGreen}Free and Open-source Software for \\Science and Engineering Education} \\ +\scriptsize Based at IIT Bombay, Funded by MHRD.\\ +\vspace{3pt} +\scriptsize Part of National Mission on Education through ICT (NME-ICT) \\ \end{itemize} +\end{center} +\end{frame} -\item Alignment of each column -\end{enumerate} +\begin{frame} +\frametitle{About the Spoken Tutorial Project} +\begin{itemize} +\item Watch the video available at {\color{blue}\url{http://spoken-tutorial.org /What\_is\_a\_Spoken\_Tutorial}} +\item It summarises the Spoken Tutorial project +\item If you do not have good bandwidth, you can download and watch it +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{Spoken Tutorial Workshops}The Spoken Tutorial Project Team +\begin{itemize} +\item Conducts workshops using spoken tutorials +\item Gives certificates to those who pass an online test +\item For more details, please write to \\ \hspace {0.5cm}{\color{blue}contact@spoken-tutorial.org} +\end{itemize} \end{frame} \begin{frame} +\frametitle{Acknowledgements} +\begin{itemize} +\item Spoken Tutorial Project is a part of the Talk to a Teacher project +\item It is supported by the National Mission on Education through ICT, MHRD, Government of India +\item More information on this Mission is available at: \\{\color{blue}\url{http://spoken-tutorial.org/NMEICT-Intro}} +\end{itemize} +\end{frame} -\begin{block}{} +\begin{frame} + \begin{block}{} \begin{center} - \textcolor{blue}{\Large THANK YOU!} + {\Large THANK YOU!} \end{center} \end{block} \begin{block}{} \begin{center} For more Information, visit our website\\ - \url{http://fossee.in/} + {\color{blue}\url{http://fossee.in/}} \end{center} \end{block} \end{frame} \end{document} - diff --git a/script2col.rst b/script2col.rst index c61565f..d7f8dd5 100644 --- a/script2col.rst +++ b/script2col.rst @@ -1,213 +1,156 @@ -.. Objectives -.. ---------- - -.. At the end of this tutorial, you will - -.. 1. Get acquainted to LaTeX. -.. #. Know why we prefer LaTeX? -.. #. Know the advantages and disadvantages of typesetting documents -.. using the LaTeX approach. -.. #. Have a description, of a typical work flow; which uses LaTeX to typeset -.. documents. -.. #. Recognise and differenciate between LaTeX commands, LaTeX comments and -.. special characters, spacing and actual document content. -.. #. Create and compile a very simple LaTeX document. - -.. Prerequisites -.. ------------- - -.. 1. Installing LaTeX - - -.. Author : Harish Badrinath < harish [at] fossee [dot] in > - Internal Reviewer : Kiran Isukapatla < kiran [at] fossee [dot] in > - External Reviewer : - Langauge Reviewer : - Checklist OK? : 25-Feb-2012 - +-------- Script ------- +-------- +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the first slide containing title, name of the production | Hello Friends and welcome to the tutorial on 'Introduction to LaTeX'. | -| team along with the logo of MHRD }}} | | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Objectives" slide }}} | At the end of this tutorial, you will | -| | | -| | 1. Get acquainted to LaTeX. | -| | #. Know why we prefer LaTeX? | -| | #. Know the advantages and disadvantages of typesetting documents | -| | using the LaTeX approach. | -| | #. Get a brief idea on typical work flow; which uses LaTeX to typeset | -| | documents. | -| | #. Know LaTeX commands, LaTeX comments and | -| | special characters, spacing and actual document content. | -| | #. Be able to create and compile a simple LaTeX document. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Pre-requisite" slide }}} | Before beginning this tutorial, we would suggest having a working installation | -| | of LaTeX on your computer. You can do this by completing the tutorial on | -| | "LaTeX Installation". | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Introduction" slide }}} | LaTeX began as TeX, a computer program originally created by | -| | Donald E. Knuth. It was designed mainly to aid typesetting | -| | of text and mathematical formulae. | -| | | -| | It is a typesetting program that produces excellently typeset documents. | -| | Typesetting is placing text onto a page with all the style formatting defined, | -| | so that the content looks as intended. It is extensively used for producing | -| | high quality scientific and mathematical documents. It may also be used for | -| | producing other kinds of documents, ranging from simple one page articles to | -| | complete books. | -| | | -| | LaTeX is pronounced Lah-tech or Lay-tec. | -| | TeX is pronounced Tech. TeX is also the first syllable in the Greek word for | -| | technology. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Why LaTeX?" slide }}} | Why we prefer LaTeX? | -| | (a) LaTeX offers excellent visual quality. | -| | (b) Handles typesetting and lets you focus on content. | -| | (c) Makes writing complex Math equation(S) extremely simple. | -| | (d) It is also a standard used widely, especially by the scientific community. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Why LaTeX? ..." slide }}} | We can define LaTex as a document based markup language. This sentence is | -| | deceptively simple, as it reveals a lot about LaTeX. We now break this sentence | -| | up as follows | -| | Mark-up: a system of annotating text, adding extra information to specify | -| | structure and presentation of text. | -| | Document based markup: you don’t have to worry about each element individually. | -| | | -| | This is essentially a fancy way of saying,LaTeX handles typesetting and lets | -| | you focus on content rather than appearance. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Advantages of using LaTeX" slide }}} | Some of the advantages of using LaTeX approach to typesetting are | -| | (1) Easy availability of professionally crafted layouts/templates. | -| | (2) Typesetting of mathematical formulae is supported in a convenient | +| {{{ Show the title slide}}} | Hello friends and welcome to the tutorial on Latex: Tables & Figures. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide containing the objectives}}} | In this tutorial we will learn how to: | +| | | +| | 1. Add figures in Latex document. | +| | | +| | #. Include tabular environments in Latex document. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'Prerequisites'}}} | Please make sure that you have gone through the following tutorials before you | +| | continue on this tutorial: | +| | | +| | 1. Latex Installation | +| | #. Latex Introduction | +| | #. Latex Basics & Structuring | +| | #. Latex Typesetting Text | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'Figures'}}} | Let us start with seeing how to include 'figures' in a Latex document. | +| | To include graphics in a LaTeX document, we need to use the package. | +| | To use this package, we have to add the <\\usepackage{graphicx}> directive | +| | to the preamble of the document. | +| | | +| | Then, to add a graphic, use the <\\includegraphics> command. | +| | The relative path of the image that we wish to include is passed as an | +| | argument to includegraphics. You can see two images in each slide of this | +| | presentation, these images are included using <\\includegraphics> command. | +| | It takes an optional argument, to scale an image. For our images a scale | +| | of 0.80 is used. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show slide 'includegraphics'}}} | <\\includegraphics> command also takes other optional arguments such as: | +| | | +| | 1. | +| | | +| | If only the height or width is specified, the image is scaled, | +| | maintaining the aspect ratio. | +| | | +| | #. | +| | | +| | This parameter can either be set to true or false. | +| | When set to true, the image is scaled according to both width and height, | +| | without changing the aspect ratio, so that it does not exceed both the | +| | width and the height dimensions. | +| | | +| | #. | +| | | +| | This option can be used to rotate the image by x degrees, counter-clockwise. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show slide 'includegraphics..'}}} | Here is the complete syntax for <\\includegraphics> command with | +| | the optional arguments we just talked about and the relative path | +| | to the image. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'Floats'}}} | Graphics (and tables) are treated specially because, | +| | they cannot be split into pages. | +| | They are "floated" across to the next page, | +| | if they do not fit on the current page, filling the current page with text. | +| | To make our graphic into a float, we should enlose it within | +| | a figure environment. The figure environment takes an additional parameter | +| | for the location of the float. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'Floats..'}}} | The specifiers 't','b','p','h' & '!' are permissions to place the float at | +| | various locations. | +| | 't' for top of page, 'b' for bottom of page, 'p' for a separate page for | +| | floats and 'h' for here, as in pproximately at the same point it occurs in | +| | the source text. '!' mark overrides few of LaTeX's internal parameters | +| | for good position of floats. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide Captions and References}}} | The figure environment also, allows us to add a caption to the graphic | +| | using the <\\caption> command. This command will be placed within the figure | | | environment. | -| | (3) Typesetting for most cases can be done with very little learning curve | -| | using easy to use/understand commands, that only specify the logical structure | -| | of the document. | -| | (4) Presence of lots of add-on packages. | -| | (5) It encourages creation of well structured texts. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Disadvantages of using LaTeX" slide }}} | Some of the disadvantages of using LaTeX approach to typesetting are | -| | (1) Designing a whole new layout is difficult. | -| | (2) LaTeX is not a word processor, for example, the document author | -| | is not expected to worry about presentation details like the size of font. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "LaTeX input file format" slide }}} | LaTeX input files are simple ASCII text files that are processed by a TeX | -| | processing engine. | -| | Next comes the question of compiling LaTeX input files and viewing the output | -| | typeset document. | -| | The process is a little different from other markup languages like HTML. | -| | We compile ASCII text files into typeset files that are normally DVI, | -| | Postscript or PDF files. | -| | The latex command converts LaTeX input files into dvi files. | -| | We can view DVI files on Gnu/Linux using xdvi. | -| | Further, DVI files can be converted either to a post script file, using the | -| | dvips command or to a PDF file using the dvipdfm command. | -| | The command pdflatex is used to convert LaTeX input files directly to pdf files. | -| | The resultant PDF files can be viewed using standard applications | -| | on most platforms | -| | (Eg: evince on Gnu/Linux). PDF file are also widely supported. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Commands,Comments&Special Characters" slide }}} | Like most utilities in Linux, LaTeX is case sensitive. Commands begin | -| | with a backslash. LaTeX environments have a begin and end marker. The begin and | -| | end document commands, mark the beginning and the end of the content of the | -| | LaTeX document. The text in between the begin and end commands is typeset in | -| | the output document.Any content after <\end{document}> is ignored. The type of | -| | document that is being currently typeset in LaTex, is identified with the | -| | documentclass command. LaTeX then, typesets the document accordingly. | -| | | -| | All the commands in LaTeX begin with a \\. An environment begins with a begin | -| | command and ends with an end command. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Commands,Comments&Special Characters ..." slide }}} | But, how do we write comments with in the document. % character is used | -| | to indicate comments. Anything written after a % symbol in a | -| | line, is ignored. | -| | But what if we wanted to insert the % symbol in the document? We can do so by | -| | escaping it with a \\ (backslash). % is one of the many special characters in | -| | LaTeX. The others are shown on the screen. All of them, except the \\ itself, | -| | can be inserted by escaping it with a \\. To insert a \\ in our document, | -| | we use the command \textbackslash. | -| | | -| | What would happen if we escape a \\ with a \\? | -| | A double backslash is actually another command. It inserts a new line in the | -| | typeset document. Normally LaTeX automatically spaces the given input optimally. | -| | But, sometimes we have to insert manual line breaks. The <\\\\> | -| | command or <\newline> | -| | command is used to insert a newline in the output document. A | -| | single line break in the input document, doesn't cause any change in the | -| | output document. | -| | | -| | A single empty line causes a change in paragraphs in the output. Multiple | -| | empty lines are equivalent to a single empty line. Similarly, multiple spaces | -| | are treated as a single space. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Typesetting a minimal document" slide }}} | Now, try to create a simple LaTeX document. Pause the tutorial and type the | -| | content shown on the screen in a text editor. Save the file as temp.tex | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{continue from paused state}}} | Now we compile the commands in the LaTeX input file that is, temp.tex into a | -| {{{ Show the "Compiling to DVI & PDF" slide }}} | typeset file. | -| | | -| | The first alternative is to compile LaTeX input file into a DVI | -| | file. We use the latex command for this purpose. For compiling the LaTeX input | -| | file temp.tex into a DVI file, we use the following command | -| | | -| | | -| | | -| | The output file would be temp.dvi. | -| | | -| | The other alternative is to create PDF files from LaTeX input files. | -| | We use the pdflatex command for this purpose. For compiling the LaTeX input | -| | file temp.tex into a PDF file, we use the following command | -| | | -| | | -| | | -| | Please note that, throughout this course we shall be using pdflatex to compile | -| | our documents. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Summary" slide }}} | This brings us to the end of this tutorial. In this tutorial, we have learnt | -| | | -| | 1. About LaTeX. | -| | #. why we prefer LaTeX. | -| | #. About the advantages and disadvantages of typesetting documents | -| | using the LaTeX approach. | -| | #. A description, of a typical work flow; which uses LaTeX to typeset | -| | documents. | -| | #. The ability to recognize and differentiate between LaTeX commands, LaTeX | -| | comments and special characters, spacing and actual document content. | -| | #. To Create and compile a simple LaTeX document. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Self assessment questions" slide }}} | Here are some self assessment questions for you to solve | -| | | -| | 1. Convert the temp.dvi created during the course of this tutorial to | -| | temp_1.ps using the dvips command. Verify that the two files | -| | indeed look the same. | -| | | -| | 2. Convert the temp.dvi created during the course of this tutorial to | -| | temp_1.pdf using the dvipdfm command. Verify that the two files indeed look the | -| | same. | -+----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the "Solutions" slide }}} | And the answers, | -| | | -| | 1. dvips -o temp_1.ps temp.dvi | -| | | -| | 2. dvipdfm -o temp_1.pdf temp.dvi | +| | To keep the graphic center aligned in the page, | +| | we use the center environment within the figure environment. | +| | To label a figure, we just add a <\\label> command within the | +| | figure environment. | +| | Note that the label to a figure should be added after the caption command. | +| | Figures are auto numbered. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide Captions and References..}}} | Here, you can see a sample code that shows the use of figure environment | +| | with caption & label. | +| | It explains how to include image, how to center align it. | +| | Also shows, how to add caption and label to an image. | +| | You can note that the label is added after the caption, as we mentioned | +| | earlier. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'Tables'}}} | Now, let us look at how to include Tables in our document. | +| | To typeset content in a tabular format, we use the tabular environment. | +| | And to make it a float, it is enclosed in the table environment. | +| | The table environment also allows us to add captions & labels to the table, | +| | just as we added in the figure environment. | +| | Tables are also auto numbered. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'tabular'}}} | The tabular environment takes the columns, and the formatting of each column, | +| | as arguments. The possible arguments to the tabular environment are | +| | | +| | 1. l for left justified column content | +| | | +| | #. r for right justified column content | +| | | +| | #. c for centered column content | +| | | +| | #. | (pipe) produces a vertical line. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'tabular..'}}} | Tabular also takes an optional parameter that specifies the position | +| | of the table; 't' for top, 'b' for bottom, or 'c' for center. | +| | Each column of a table is separated by an '&' (ampersand) symbol and | +| | each row is separated by a new line. | +| | | +| | The <\\hline> command allows you to draw horizontal lines between | +| | two rows of the table. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'tabular..'}}} | A sample code that shows the complete use of the tabular | +| | environment with all arguments and options. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the slide 'List of Tables, Figures'}}} | You could also add a list of tables or list of figures to the document, | +| | using <\\listoftables> & <\\listoffigures> commands respectively. | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the 'summary' slide'}}} | This brings us to the end of the tutorial. In this tutorial, we have | +| | learnt to, | +| | | +| | 1. Add graphics to a LateX document | +| | | +| | #. Include tabular environments in a LateX document | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show self assessment questions slide}}} | Here are some self assessment questions for you to solve, | +| | | +| | 1. Which input parameter is used in the figure environment to make it float | +| | to the bottom of the page ? | +| | #. What is the mandatory argument in tabular environment specification ? | ++----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ +| {{{Show the solutions slide to self assessment questions }}} | And the answers, | +| | | +| | 1. Input parameter `b' is passed as argument, to make it float to the bottom | +| | of the page. | +| | #. It is mandatory to specify alignment of each column in tabular | +| | environment. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ | {{{ Show the SDES & FOSSEE slide }}} | Software Development techniques for Engineers and Scientists - SDES, is an | | | initiative by FOSSEE. For more information, please visit the given link. | | | | -| | Free and Open-source Software for Science and Engineering Education - FOSSEE, is | -| | based at IIT Bombay which is funded by MHRD as part of National Mission on | +| | Free and Open-source Software for Science and Engineering Education - FOSSEE, | +| | is based at IIT Bombay which is funded by MHRD as part of National Mission on | | | Education through ICT. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the ``About the Spoken Tutorial Project'' slide }}} | Watch the video available at the following link. It summarises the Spoken | +| {{{ Show the About the Spoken Tutorial Project slide }}} | Watch the video available at the following link. It summarises the Spoken | | | Tutorial project.If you do not have good bandwidth, you can download and | | | watch it. | +----------------------------------------------------------------------------------+----------------------------------------------------------------------------------+ -| {{{ Show the `` Spoken Tutorial Workshops'' slide }}} | The Spoken Tutorial Project Team conducts workshops using spoken tutorials, | +| {{{ Show the Spoken Tutorial Workshops slide }}} | The Spoken Tutorial Project Team conducts workshops using spoken tutorials, | | | gives certificates to those who pass an online test. | | | | | | For more details, contact contact@spoken-tutorial.org | -- cgit