Guest User

Untitled

a guest
May 24th, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.68 KB | None | 0 0
  1. documentclass{book}
  2. usepackage{siunitx}
  3. usepackage[acronym,toc]{glossaries} % use glossaries-package
  4.  
  5.  
  6. setlength{glsdescwidth}{15cm}
  7.  
  8. newglossary[slg]{symbolslist}{syi}{syg}{Symbolslist} % create add. symbolslist
  9.  
  10.  
  11. glsaddkey{unit}{glsentrytext{glslabel}}{glsentryunit}{GLsentryunit}{glsunit}{Glsunit}{GLSunit}
  12.  
  13. makeglossaries % activate glossaries- package
  14.  
  15.  
  16. % ==== EXEMPLARY ENTRY FOR SYMBOLS LIST =========================================
  17. newglossaryentry{sig}{name=ensuremath{sigma},
  18. description={This is a non-bold stress scalar},
  19. unit={si{megapascal}},
  20. type=symbolslist}
  21.  
  22. newglossaryentry{csig}{name=ensuremath{boldsymbol{sigma}},
  23. description={This is a bold Cauchy stress tensor},
  24. unit={si{megapascal}},
  25. type=symbolslist}
  26.  
  27.  
  28. % ==== EXEMPLARY ENTRY FOR ACRONYMS LIST ========================================
  29. newacronym{frp}{FRP}{Fiber Reinforced Polymers}
  30.  
  31.  
  32. newglossarystyle{symbunitlong}{%
  33. setglossarystyle{long3col}% base this style on the list style
  34. renewenvironment{theglossary}{% Change the table type --> 3 columns
  35. begin{longtable}{lp{0.6glsdescwidth}>{centeringarraybackslash}p{2cm}}}%
  36. {end{longtable}}%
  37. %
  38. renewcommand*{glossaryheader}{% Change the table header
  39. bfseries Sign & bfseries Description & bfseries Unit \
  40. hline
  41. endhead}
  42. renewcommand*{glossentry}[2]{% Change the displayed items
  43. glstarget{##1}{glossentryname{##1}} %
  44. & glossentrydesc{##1}% Description
  45. & glsunit{##1} tabularnewline
  46. }
  47. }
  48.  
  49.  
  50. begin{document}
  51.  
  52. glsaddall
  53.  
  54. printglossary[type=acronymtype,style=long] % list of acronyms
  55. printglossary[type=symbolslist,style=symbunitlong] % list of symbols
  56.  
  57. end{document}
Add Comment
Please, Sign In to add comment