Changeset a14187f for doc/LaTeXmacros/common.tex
- Timestamp:
- Aug 3, 2016, 11:33:36 AM (8 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- e93bc13
- Parents:
- ac43954 (diff), aea7168 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/LaTeXmacros/common.tex
rac43954 ra14187f 11 11 %% Created On : Sat Apr 9 10:06:17 2016 12 12 %% Last Modified By : Peter A. Buhr 13 %% Last Modified On : Tue Jul 12 20:37:57201614 %% Update Count : 2 0613 %% Last Modified On : Tue Aug 2 17:02:02 2016 14 %% Update Count : 228 15 15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 17 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%18 16 19 17 \setlength{\textheight}{9in} 20 18 %\oddsidemargin 0.0in 21 \renewcommand{\topfraction}{0.8} % float must be greater than X of the page before it is forced onto its own page22 \renewcommand{\bottomfraction}{0.8} % float must be greater than X of the page before it is forced onto its own page19 \renewcommand{\topfraction}{0.8} % float must be greater than X of the page before it is forced onto its own page 20 \renewcommand{\bottomfraction}{0.8} % float must be greater than X of the page before it is forced onto its own page 23 21 \renewcommand{\floatpagefraction}{0.8} % float must be greater than X of the page before it is forced onto its own page 24 \renewcommand{\textfraction}{0.0} % the entire page maybe devoted to floats with no text on the page at all25 26 \lefthyphenmin=4 22 \renewcommand{\textfraction}{0.0} % the entire page maybe devoted to floats with no text on the page at all 23 24 \lefthyphenmin=4 % hyphen only after 4 characters 27 25 \righthyphenmin=4 28 26 … … 38 36 % Names used in the document. 39 37 40 \newcommand{\CFA}{C$\mathbf\forall$\xspace} 41 \newcommand{\CFL}{Cforall\xspace} 38 \newcommand{\CFA}{C$\mathbf\forall$\xspace} % set language symbolic name 39 \newcommand{\CFL}{Cforall\xspace} % set language text name 42 40 \newcommand{\CC}{\rm C\kern-.1em\hbox{+\kern-.25em+}\xspace} % CC symbolic name 43 41 \newcommand{\CCeleven}{\rm C\kern-.1em\hbox{+\kern-.25em+}11\xspace} % C++11 symbolic name 44 \ def\c11{ISO/IEC C} % C11 name (cannot have numbers in latex command name)42 \newcommand{\Celeven}{C11\xspace} % C11 symbolic name 45 43 46 44 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% … … 52 50 \setlength{\parindentlnth}{\parindent} 53 51 54 \newlength{\gcolumnposn} 52 \newlength{\gcolumnposn} % temporary hack because lstlisting does handle tabs correctly 55 53 \newlength{\columnposn} 56 54 \setlength{\gcolumnposn}{2.5in} … … 63 61 %\patchcmd{\lsthk@TextStyle}{\let\lst@DefEsc\@empty}{}{}{\errmessage{failed to patch}} 64 62 65 \usepackage{pslatex} 66 \usepackage{relsize} 63 \usepackage{pslatex} % reduce size of san serif font 64 \usepackage{relsize} % must be after change to small or selects old size 67 65 68 66 % reduce size of chapter/section titles … … 120 118 121 119 % inline text and lowercase index: \Index{inline and lowercase index text} 120 \newcommand{\Index}{\@ifstar\@sIndex\@Index} 122 121 % inline text and as-in index: \Index[as-is index text]{inline text} 122 \newcommand{\@Index}[2][\@empty]{\lowercase{\def\temp{#2}}#2\ifx#1\@empty\index{\temp}\else\index{#1@{\protect#2}}\fi} 123 123 % inline text but index with different as-is text: \Index[index text]{inline text} 124 \newcommand{\Index}{\@ifstar\@sIndex\@Index}125 \newcommand{\@Index}[2][\@empty]{\lowercase{\def\temp{#2}}#2\ifx#1\@empty\index{\temp}\else\index{#1@{\protect#2}}\fi}126 124 \newcommand{\@sIndex}[2][\@empty]{#2\ifx#1\@empty\index{#2}\else\index{#1@{\protect#2}}\fi} 127 125 128 % cannot use ©126 % inline text and code index (cannot use ©) 129 127 \newcommand{\Indexc}[1]{\lstinline$#1$\index{#1@\lstinline$#1$}} 128 % code index (cannot use ©) 130 129 \newcommand{\indexc}[1]{\index{#1@\lstinline$#1$}} 131 130 … … 137 136 \newcommand{\@newterm}[2][\@empty]{\lowercase{\def\temp{#2}}{\newtermFontInline{#2}}\ifx#1\@empty\index{\temp}\else\index{#1@{\protect#2}}\fi} 138 137 \newcommand{\@snewterm}[2][\@empty]{{\newtermFontInline{#2}}\ifx#1\@empty\index{#2}\else\index{#1@{\protect#2}}\fi} 138 139 % Latin abbreviation 140 \newcommand{\abbrevFont}{\textit} % set empty for no italics 141 \newcommand*{\eg}{% 142 \@ifnextchar{,}{\abbrevFont{e}.\abbrevFont{g}.}% 143 {\@ifnextchar{:}{\abbrevFont{e}.\abbrevFont{g}.}% 144 {\abbrevFont{e}.\abbrevFont{g}.,\xspace}}% 145 }% 146 \newcommand*{\ie}{% 147 \@ifnextchar{,}{\abbrevFont{i}.\abbrevFont{e}.}% 148 {\@ifnextchar{:}{\abbrevFont{i}.\abbrevFont{e}.}% 149 {\abbrevFont{i}.\abbrevFont{e}.,\xspace}}% 150 }% 151 \newcommand*{\etc}{% 152 \@ifnextchar{.}{\abbrevFont{etc}}% 153 {\abbrevFont{etc}.\xspace}% 154 }% 139 155 \makeatother 140 156 … … 145 161 \endlist 146 162 }% quote2 163 147 164 \newenvironment{rationale}{% 148 165 \begin{quote2}\noindent$\Box$\enspace … … 188 205 \newcommand{\VPageref}[2][page]{\ifx#1\@empty\else{#1}\nobreakspace\fi\pageref{#2}} 189 206 190 % Go programming language 207 % Go programming language: https://github.com/julienc91/listings-golang/blob/master/listings-golang.sty 191 208 \lstdefinelanguage{Golang}{ 192 209 morekeywords=[1]{package,import,func,type,struct,return,defer,panic, recover,select,var,const,iota,},% … … 204 221 } 205 222 206 % CFA programming language, based on ANSI C 223 % CFA programming language, based on ANSI C (with some gcc additions) 207 224 \lstdefinelanguage{CFA}[ANSI]{C}{ 208 225 morekeywords={_Alignas,_Alignof,__alignof,__alignof__,asm,__asm,__asm__,_At,_Atomic,__attribute,__attribute__,auto, 209 226 _Bool,catch,catchResume,choose,_Complex,__complex,__complex__,__const,__const__,disable,dtype,enable,__extension__, 210 fallthr u,finally,forall,ftype,_Generic,_Imaginary,inline,__label__,lvalue,_Noreturn,otype,restrict,_Static_assert,227 fallthrough,fallthru,finally,forall,ftype,_Generic,_Imaginary,inline,__label__,lvalue,_Noreturn,otype,restrict,_Static_assert, 211 228 _Thread_local,throw,throwResume,trait,try,typeof,__typeof,__typeof__,}, 212 229 }% … … 215 232 language=CFA, 216 233 columns=fullflexible, 217 basicstyle=\linespread{0.9}\sf, 218 stringstyle=\tt, 219 tabsize=4, 220 xleftmargin=\parindentlnth, 221 extendedchars=true, 222 escapechar=§, 223 mathescape=true, 224 keepspaces=true, 225 showstringspaces=false, 226 showlines=true, 227 aboveskip=4pt, 234 basicstyle=\linespread{0.9}\sf, % reduce line spacing and use sanserif font 235 stringstyle=\tt, % use typewriter font 236 tabsize=4, % 4 space tabbing 237 xleftmargin=\parindentlnth, % indent code to paragraph indentation 238 extendedchars=true, % allow ASCII characters in the range 128-255 239 escapechar=§, % escape to latex in CFA code 240 mathescape=true, % allow $...$ LaTeX math escapes in code 241 %keepspaces=true, % 242 showstringspaces=false, % do not show spaces with cup 243 showlines=true, % show blank lines at end of code 244 aboveskip=4pt, % spacing above/below code block 228 245 belowskip=3pt, 229 moredelim=**[is][\color{red}]{®}{®}, 230 moredelim=**[is][\color{blue}]{ß}{ß}, 246 moredelim=**[is][\color{red}]{®}{®}, % red highlighting 247 moredelim=**[is][\color{blue}]{ß}{ß}, % blue highlighting 231 248 moredelim=**[is][\color{OliveGreen}]{¢}{¢}, % green highlighting 232 249 moredelim=[is][\lstset{keywords={}}]{¶}{¶}, % temporarily turn off keywords … … 242 259 \renewcommand\thebibliography[1]{ 243 260 \Oldthebibliography{#1} 244 \setlength{\parskip}{0pt} % reduce vertical spacing between references261 \setlength{\parskip}{0pt} % reduce vertical spacing between references 245 262 \setlength{\itemsep}{5pt plus 0.3ex} 246 263 }% 247 248 \newcommand*{\eg}{\textit{e.g}.\@\xspace}249 \newcommand*{\ie}{\textit{i.e}.\@\xspace}250 251 \makeatletter252 \newcommand*{\etc}{%253 \@ifnextchar{.}%254 {\textit{etc}}%255 {\textit{etc}.\@\xspace}%256 }257 \makeatother258 264 259 265 % Local Variables: %
Note: See TracChangeset
for help on using the changeset viewer.