<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>The art of not being one with the universe &#187; LaTeX</title>
	<atom:link href="http://skjaeve.net/category/latex/feed" rel="self" type="application/rss+xml" />
	<link>http://skjaeve.net</link>
	<description>The life and ramblings of Mr. Skjæveland</description>
	<lastBuildDate>Sat, 19 Nov 2011 10:40:40 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Moving figures around</title>
		<link>http://skjaeve.net/2008/10/23/moving-around-figures</link>
		<comments>http://skjaeve.net/2008/10/23/moving-around-figures#comments</comments>
		<pubDate>Thu, 23 Oct 2008 13:17:19 +0000</pubDate>
		<dc:creator>Åsmund</dc:creator>
				<category><![CDATA[LaTeX]]></category>

		<guid isPermaLink="false">http://skjaeve.net/?p=523</guid>
		<description><![CDATA[A figure in LATEX needs a big block of text. Here's an example from my Cand.scient thesis:


\begin{figure}
  \centering
  \includegraphics{figurar/kpno_magmp_fd_20011220_1716}
  \caption{Magnetogram av solskiva, frå 20. 12. 2001. Svart tyder at
    synslinjekomponenten av ...]]></description>
			<content:encoded><![CDATA[<p>A figure in L<sup>A</sup>T<sub>E</sub>X needs a big block of text. Here&#8217;s an example from my Cand.scient thesis:</p>
<pre>
\begin{figure}
  \centering
  \includegraphics[width=0.6\textwidth]{figurar/kpno_magmp_fd_20011220_1716}
  \caption[Magnetogram av solskiva]{Magnetogram av solskiva, frå 20. 12. 2001. Svart tyder at
    synslinjekomponenten av det lokale magnetfeltet er retta mot
    sola, og kvitt tyder at komponenten er retta vekk frå sola.}
  \label{fig:magnetogram}
\end{figure}
</pre>
<p>Some disadvantages:</p>
<ol>
<li>It breaks the text flow when trying to read the document source. Even with a decent editor, it&#8217;s tricky to skip over the figure block.</li>
<li>It&#8217;s tricky to move figures around. It&#8217;s easy to miss a line when cut&#8217;n'pasting, and then nothing will compile. Figure blocks can be big.</li>
<li>In a long chapter with many figures, it&#8217;s bothersome to track down the right one for tweaking.</li>
</ol>
<p>A possible solution: Wrap the <code>figure</code> block in a <code>\newcommand{}</code>, and stuff it in the beginning of the file or in a separate file that you load with <code>\input{}</code>.</p>
<pre>\newcommand{\figmagnetogram}{
  \begin{figure}
    \centering
    \includegraphics[width=0.6\textwidth]{figurar/kpno_magmp_fd_20011220_1716}
    \caption[Magnetogram av solskiva]{Magnetogram av solskiva, frå 20. 12. 2001. Svart tyder at
      synslinjekomponenten av det lokale magnetfeltet er retta mot
      sola, og kvitt tyder at komponenten er retta vekk frå sola.}
    \label{fig:magnetogram}
  \end{figure}
}
</pre>
<p>Then inserting the figure into the text is as simple as<br />
<code>\figmagnetogram</code><br />
And moving one line around isn&#8217;t nearly as hard as a block of 10-20 lines.</p>
<p class="wp-flattr-button"></p>]]></content:encoded>
			<wfw:commentRss>http://skjaeve.net/2008/10/23/moving-around-figures/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

