LoginSignup
3
3

More than 3 years have passed since last update.

Latex(documentstyle)

Posted at

Latexのdocumentstyleでハマったところ

documentstyleとdocumentclass

まず,Latexには大きく分けてdocumentstyleとdocumentclassの2つがある.簡単に違いは

  • sytle: LaTeX2.09(古い)
  • class: LaTex 2e(新しい)

新しいか,古いか,それだけ...ではなかった.

もうちょっと詳しく違いを

styleとclassでは新旧以外にも"お作法"に違いがある.
例えば,classでは画像を挿入したいときには一般的に\usepackage[dvips]{graphicx}というおまじないを書けば,includegraphicsできる.でも,styleはusepackageできない.usepackageを使おうとすると「は?ナニソレ,意味不なの使わないで」と怒られてしまう.
じゃあ,どうするの??
styleではdocumentstyle[ココ]ココgraphicxを書けばいいらしい!!つまり,こういうこと
documentstyle[graphicx]
これでincludegraphicsできる!その他のusepacageで使いたいものはココの部分に,を挟んで書き足していけばよいらしい.

\documentstyle[graphicx, hoge, hogehoge]{jarticle}

みたいな感じになる.(hoge, hogehogeは適当)

3
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
3