<?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>Guy Rutenberg &#187; LyX</title>
	<atom:link href="http://www.guyrutenberg.com/tag/lyx/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.guyrutenberg.com</link>
	<description>Keeping track of what I do</description>
	<lastBuildDate>Wed, 16 Jun 2010 19:53:40 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>\lyxframeend Undefined when Using Beamer with Lyx</title>
		<link>http://www.guyrutenberg.com/2009/07/22/lyxframeend-undefined-when-using-beamer-with-lyx/</link>
		<comments>http://www.guyrutenberg.com/2009/07/22/lyxframeend-undefined-when-using-beamer-with-lyx/#comments</comments>
		<pubDate>Wed, 22 Jul 2009 14:40:14 +0000</pubDate>
		<dc:creator>Guy</dc:creator>
				<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[Beamer]]></category>
		<category><![CDATA[Errors]]></category>
		<category><![CDATA[LyX]]></category>

		<guid isPermaLink="false">http://www.guyrutenberg.com/?p=411</guid>
		<description><![CDATA[I&#8217;m using LyX for the first time with Beamer. Making the title page was smooth. But when I&#8217;ve tried adding a new frame (using BeginFrame) I was confronted with the following error

 \lyxframeend
                 {}\lyxframe{Outline}
The control sequence at the end [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m using LyX for the first time with Beamer. Making the title page was smooth. But when I&#8217;ve tried adding a new frame (using BeginFrame) I was confronted with the following error</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;"> \lyxframeend
                 {}\lyxframe{Outline}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
misspelled it (e.g., `\hobx'), type `I' and the correct
spelling (e.g., `I\hbox'). Otherwise just continue,
and I'll forget about whatever was undefined.</pre></div></div>

<p>After comparing my document to example (working) beamer documents I&#8217;ve found out that you must have an EndFrame command after your last frame.Too bad it wasn&#8217;t documented anywhere I&#8217;ve found as this little thing drove me crazy.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.guyrutenberg.com/2009/07/22/lyxframeend-undefined-when-using-beamer-with-lyx/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Algorithm Float Label for Hebrew Document</title>
		<link>http://www.guyrutenberg.com/2009/06/18/algorithm-float-label-for-hebrew-document/</link>
		<comments>http://www.guyrutenberg.com/2009/06/18/algorithm-float-label-for-hebrew-document/#comments</comments>
		<pubDate>Thu, 18 Jun 2009 16:00:12 +0000</pubDate>
		<dc:creator>Guy</dc:creator>
				<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[Hebrew]]></category>
		<category><![CDATA[LyX]]></category>

		<guid isPermaLink="false">http://www.guyrutenberg.com/?p=379</guid>
		<description><![CDATA[For a while now I&#8217;ve refrained from using the very nice Algorithm environment for LaTeX papers I wrote in Hebrew due to the way it&#8217;s label was displayed. The English label was displayed in reverse.


For sometime before letting go of the issue, I&#8217;ve tried to correct the direction of the label. It could have been [...]]]></description>
			<content:encoded><![CDATA[<p>For a while now I&#8217;ve refrained from using the very nice Algorithm environment for LaTeX papers I wrote in Hebrew due to the way it&#8217;s label was displayed. The English label was displayed in reverse.</p>
<p><img src="http://www.guyrutenberg.com/wp-content/uploads/2009/06/algorithm-before.png" alt="algorithm-before" title="algorithm-before" width="230" height="150" class="aligncenter size-full wp-image-380" /><br />
<span id="more-379"></span><br />
For sometime before letting go of the issue, I&#8217;ve tried to correct the direction of the label. It could have been fixed by marking the float as English text in LyX (I use it for editing Hebrew papers, as it makes editing multi-lingual texts easy), effectively adding <code>\selectlanguage{english}</code> before the <code>\begin{algorithm}</code> line. However, it resulted in display mess in LyX and some LaTeX errors when compiling (also it seemed LaTeX could complete the first pass).</p>
<p>Today, I&#8217;ve decided to tackle and solve the problem for a new paper I&#8217;m writing. After searching a bit for a way to override the Algorithm environment label, I&#8217;ve found a general way to override a float label in LaTeX:</p>

<div class="wp_syntax"><div class="code"><pre class="latex" style="font-family:monospace;"><span style="color: #800000; font-weight: normal;">\floatname</span><span style="color: #E02020; ">{</span><span style="color: #2020C0; font-weight: normal;">floatname</span><span style="color: #E02020; ">}{</span><span style="color: #2020C0; font-weight: normal;">floatlabel</span><span style="color: #E02020; ">}</span></pre></div></div>

<p>So for our case it would look like this:</p>

<div class="wp_syntax"><div class="code"><pre class="latex" style="font-family:monospace;"><span style="color: #800000; font-weight: normal;">\floatname</span><span style="color: #E02020; ">{</span><span style="color: #2020C0; font-weight: normal;">algorithm</span><span style="color: #E02020; ">}{</span><span style="color: #2020C0; font-weight: normal;">אלגוריתם</span><span style="color: #E02020; ">}</span></pre></div></div>

<p>You should put it in your LaTeX preamble (Documents->Settings in LyX). This neatly fixes the problem (see screenshot below).</p>
<p><img src="http://www.guyrutenberg.com/wp-content/uploads/2009/06/algorithm-after.png" alt="algorithm-after" title="algorithm-after" width="303" height="163" class="aligncenter size-full wp-image-381" /></p>
]]></content:encoded>
			<wfw:commentRss>http://www.guyrutenberg.com/2009/06/18/algorithm-float-label-for-hebrew-document/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Displaying Non-Builtin Math Macros in LyX</title>
		<link>http://www.guyrutenberg.com/2009/05/13/displaying-non-builtin-math-macros-in-lyx/</link>
		<comments>http://www.guyrutenberg.com/2009/05/13/displaying-non-builtin-math-macros-in-lyx/#comments</comments>
		<pubDate>Wed, 13 May 2009 18:15:54 +0000</pubDate>
		<dc:creator>Guy</dc:creator>
				<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[LyX]]></category>

		<guid isPermaLink="false">http://www.guyrutenberg.com/?p=335</guid>
		<description><![CDATA[I believe LyX is a great tool for writing LaTeX document. It makes writing formulas very easy and it allows you to see the formula as you are writing, as opposed to seeing only LaTeX code. However LyX doesn&#8217;t support every LaTeX package and the macros it defines. Sure it doesn&#8217;t stop you from using [...]]]></description>
			<content:encoded><![CDATA[<p>I believe LyX is a great tool for writing LaTeX document. It makes writing formulas very easy and it allows you to see the formula as you are writing, as opposed to seeing only LaTeX code. However LyX doesn&#8217;t support every LaTeX package and the macros it defines. Sure it doesn&#8217;t stop you from using these macros in your formulas, but it doesn&#8217;t display nicely, you see the name of the macro instead of a schematic preview.</p>
<p>While LyX doesn&#8217;t support many of the great packages out there like mathtools (which I really hope it will someday), you can add some support to your documents. At the beginning of the document insert a comment, via Insert->Note->Comment. Inside the newly created comment insert a math-macro via Insert->Math->Macro. In the name part, put the name of the command you want to add support for. In the second box (caption LyX), use existing LyX commands to mimic how the macro will look like. For example, this is what it looks like for the <code>\coloneqq</code> macro (from the great <code>mathtools</code> package):<br />
<img src="http://www.guyrutenberg.com/wp-content/uploads/2009/05/math-macro.png" alt="math-macro" title="math-macro" width="279" height="67" class="aligncenter size-full wp-image-336" /></p>
<p>After adding the math macro in the comment, when you will use the macro inside formulas it will display nicely:<br />
<img src="http://www.guyrutenberg.com/wp-content/uploads/2009/05/math-macro2.png" alt="math-macro2" title="math-macro2" width="336" height="108" class="aligncenter size-full wp-image-339" /></p>
<p>A little explanation how things work. When you define a math macro in LyX, LyX does two things:</p>
<ol>
<li>Inserts LaTeX code to create the macro.</li>
<li>Displays the macro nicely when editing the document.</li>
</ol>
<p>While the latter is desirable, the former is problematic. If LyX inserts LaTeX code to define the existing macro, it will cause errors. So when you put the LyX macro in the comment environment, the code LyX generates gets ignored and only the second, desirable, outcome is achieved.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.guyrutenberg.com/2009/05/13/displaying-non-builtin-math-macros-in-lyx/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fixing Numbering Direction for Hebrew Text in LyX</title>
		<link>http://www.guyrutenberg.com/2009/01/14/fixing-numbering-direction-for-hebrew-text-in-lyx/</link>
		<comments>http://www.guyrutenberg.com/2009/01/14/fixing-numbering-direction-for-hebrew-text-in-lyx/#comments</comments>
		<pubDate>Wed, 14 Jan 2009 07:57:11 +0000</pubDate>
		<dc:creator>Guy</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Hebrew]]></category>
		<category><![CDATA[LyX]]></category>
		<category><![CDATA[RTL]]></category>

		<guid isPermaLink="false">http://www.guyrutenberg.com/?p=242</guid>
		<description><![CDATA[On Monday, I&#8217;ve submitted a patch to the LyX developers mailing list with a fix for the numbering direction in Hebrew text. In Hebrew text the dot appeared before the numbering symbol instead of after it as it should.

This behaviour has been this way for years (at least as long as I can remember).

My first [...]]]></description>
			<content:encoded><![CDATA[<p>On Monday, I&#8217;ve submitted a patch to the LyX developers mailing list with a fix for the numbering direction in Hebrew text. In Hebrew text the dot appeared before the numbering symbol instead of after it as it should.<br />
<img src="http://www.guyrutenberg.com/wp-content/uploads/2009/01/before-fix.png" alt="before-fix" title="before-fix" width="403" height="121" class="aligncenter size-full wp-image-243" /><br />
This behaviour has been this way for years (at least as long as I can remember).<br />
<span id="more-242"></span><br />
My first solution was a patch against the actual LyX code, but developers in the mailing list suggested the issue could be solved within the <code>po</code> file for Hebrew (<code>he.po</code>), as the po files are loaded for each paragraph depending on its language.</p>
<p>So I wrote a patch for the <code>he.po</code> file that fixes the problem.</p>

<div class="wp_syntax"><div class="code"><pre class="diff" style="font-family:monospace;">Index: he.po
===================================================================
<span style="color: #888822;">--- he.po	<span style="">&#40;</span>revision <span style="">28095</span><span style="">&#41;</span></span>
<span style="color: #888822;">+++ he.po	<span style="">&#40;</span>working copy<span style="">&#41;</span></span>
<span style="color: #440088;">@@ -<span style="">15050</span>,<span style="">15</span> +<span style="">15050</span>,<span style="">15</span> @@</span>
&nbsp;
 #: src/Buffer.cpp:<span style="">2902</span>
 msgid &quot;\\arabic<span style="">&#123;</span>enumi<span style="">&#125;</span>.&quot;
<span style="color: #991111;">-msgstr &quot;\\arabic<span style="">&#123;</span>enumi<span style="">&#125;</span>.&quot;</span>
<span style="color: #00b000;">+msgstr &quot;.\\arabic<span style="">&#123;</span>enumi<span style="">&#125;</span>&quot;</span>
&nbsp;
 #: src/Buffer.cpp:<span style="">2908</span>
 msgid &quot;\\roman<span style="">&#123;</span>enumiii<span style="">&#125;</span>.&quot;
<span style="color: #991111;">-msgstr &quot;\\roman<span style="">&#123;</span>enumiii<span style="">&#125;</span>.&quot;</span>
<span style="color: #00b000;">+msgstr &quot;.\\roman<span style="">&#123;</span>enumiii<span style="">&#125;</span>&quot;</span>
&nbsp;
 #: src/Buffer.cpp:<span style="">2911</span>
 msgid &quot;\\Alph<span style="">&#123;</span>enumiv<span style="">&#125;</span>.&quot;
<span style="color: #991111;">-msgstr &quot;\\Alph<span style="">&#123;</span>enumiv<span style="">&#125;</span>.&quot;</span>
<span style="color: #00b000;">+msgstr &quot;.\\Alph<span style="">&#123;</span>enumiv<span style="">&#125;</span>&quot;</span>
&nbsp;
 #: src/Buffer.cpp:<span style="">2928</span> src/insets/InsetCaption.cpp:<span style="">293</span>
 msgid &quot;Senseless!!! &quot;</pre></div></div>

<p>While this patch is against the SVN trunk (LyX 2.0), it could also be applied manually to older LyX versions.<br />
After yo apply the patch you should do the following (I assume that you are in the root of the LyX source tree):</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">cd po/
make he.gmo
cd ../
make install</pre></div></div>

<p>Now restart LyX and you will see the numbering appear as it should.<br />
<img src="http://www.guyrutenberg.com/wp-content/uploads/2009/01/after-fix.png" alt="after-fix" title="after-fix" width="426" height="108" class="aligncenter size-full wp-image-245" /></p>
]]></content:encoded>
			<wfw:commentRss>http://www.guyrutenberg.com/2009/01/14/fixing-numbering-direction-for-hebrew-text-in-lyx/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>LaTeX Error: Command \textquotedbl unavailable in encoding HE8</title>
		<link>http://www.guyrutenberg.com/2008/10/12/latex-error-command-textquotedbl-unavailable-in-encoding-he8/</link>
		<comments>http://www.guyrutenberg.com/2008/10/12/latex-error-command-textquotedbl-unavailable-in-encoding-he8/#comments</comments>
		<pubDate>Sun, 12 Oct 2008 17:08:48 +0000</pubDate>
		<dc:creator>Guy</dc:creator>
				<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Errors]]></category>
		<category><![CDATA[LyX]]></category>

		<guid isPermaLink="false">http://www.guyrutenberg.com/?p=115</guid>
		<description><![CDATA[I was testing today the SVN version of LyX 1.6.0 and 1.5.7. Due to a change in the way the double quotation mark (&#8220;) is handled, adding it to Hebrew text resulted in the following LaTeX error:

LaTeX Error: Command \textquotedbl unavailable in encoding HE8


This could be solved by adding the following line to your LaTeX [...]]]></description>
			<content:encoded><![CDATA[<p>I was testing today the SVN version of <a href="http://www.lyx.org">LyX</a> 1.6.0 and 1.5.7. Due to a change in the way the double quotation mark (&#8220;) is handled, adding it to Hebrew text resulted in the following LaTeX error:</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">LaTeX Error: Command \textquotedbl unavailable in encoding HE8</pre></div></div>

<p><span id="more-115"></span></p>
<p>This could be solved by adding the following line to your LaTeX preamble:</p>

<div class="wp_syntax"><div class="code"><pre class="latex" style="font-family:monospace;"><span style="color: #800000; font-weight: normal;">\<span style="color: #800000; font-weight: bold;">let</span></span><span style="color: #800000; font-weight: normal;">\textquotedbl</span>=&quot;</pre></div></div>

<p>This line will define the <code>\textquotedb</code> to be the double quotation mark, and the document will compile look the same as it looked in older versions of LyX.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.guyrutenberg.com/2008/10/12/latex-error-command-textquotedbl-unavailable-in-encoding-he8/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>

<!-- Dynamic Page Served (once) in 0.489 seconds -->
