<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-4805987410501728034</id><updated>2012-01-07T02:15:16.256-08:00</updated><category term='tables'/><category term='packages'/><category term='Vim'/><category term='commands'/><category term='typography'/><category term='Editorial'/><category term='documentclass'/><title type='text'>XeTeX and LaTeX</title><subtitle type='html'>Beginner’s XeTeX/LaTeX troubles</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>16</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-5817162051460636843</id><published>2011-03-03T11:48:00.000-08:00</published><updated>2011-03-03T11:48:52.345-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='documentclass'/><title type='text'>Author per chapter (a.k.a. Proceedings)</title><content type='html'>I never understood why there is no proper Latex class for typesetting proceedings or journals when Latex or Xetex is getting increasingly popular among scientists. The biggest trouble you will have whey you will try to typeset something like this is to get the authors' names into the Table of Contents and into the headers while having each author's contribution to the volume as a chapter which shall not appear numbered anywhere.&lt;br /&gt;&lt;br /&gt;The best (and only) template I could find was &lt;a href="http://www.slac.stanford.edu/econf/editors/fulltext-template/instructions.html"&gt;eConf Full-Text Proceeding Instructions and Templates&lt;/a&gt; but even these were nowhere near to what I needed because this requires you to typeset your Table of Contents manually. Yuck!&lt;br /&gt;&lt;br /&gt;After much googling I found that there really is no good solution for typesetting a compiled volume where every \chapter would have its own author. The most useful posts in discussions recommended using the memoir.cls and modifying it as needed.&lt;br /&gt;&lt;br /&gt;It looks like nobody has ever published his take on modyfiying the memoir.cls for typesetting proceedings or journal volumes where each chapter would have its author and the names of these authors would appear in the ToC and the headers. Therefore I publish here something which you can use right away for typesetting proceedings with authored chapters. To achieve this, my modified memoir.cls (called proceedings.cls) does following things:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Disables chapter numbering and also removes the "0." before section number&lt;/li&gt;&lt;li&gt;Writes the author and his home institute under the chapter title&lt;/li&gt;&lt;li&gt;Does not typeset the page number on the initial page of the chapter&lt;/li&gt;&lt;li&gt;Shows the short version of the chapter title in even head&lt;/li&gt;&lt;li&gt;Shows the author's name in the odd head&lt;/li&gt;&lt;li&gt;Shows the author's name above the chapter's title in the table of contents&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;You can have a look at an example &lt;a href="http://dl.dropbox.com/u/860437/Xetex/proceedings.pdf"&gt;pdf&lt;/a&gt; which shows such a minimal dummy proceedings containing two papers. The pdf was generated by xelatexing &lt;a href="http://dl.dropbox.com/u/860437/Xetex/proceedings.tex"&gt;this&lt;/a&gt; source document. To compile it yourself, you will need my modified version of the document class memoir.cls which I called &lt;a href="http://dl.dropbox.com/u/860437/Xetex/proceedings.cls"&gt;proceedings.cls&lt;/a&gt;. Put them all in one directory and compile with &lt;em&gt;xelatex&lt;/em&gt; (at least that's what I did).&lt;br /&gt;&lt;br /&gt;I had to refrain from using the normal \chapter command. My proceedings.cls provides you the \Chapter command (defined in lines 2844–2857) which must be used as &lt;br /&gt;&lt;br /&gt;\Chapter{&amp;lt;Author's name&amp;gt;}{&amp;lt;Author's home institute&amp;gt;}{&amp;lt;Full title of the paper&amp;gt;}{&amp;lt;Short title to appear in the header&amp;gt;}&lt;br /&gt;&lt;br /&gt;You will probably need to modify it when setting the vertical space between the Author's name and the Chapter title in the Table of Contents and on the title page of the paper.&lt;br /&gt;&lt;br /&gt;I got rid of the chapter numbering the hard way by deleting it of the documentclass's commands \thechapter and \thesection (lines 2580 and 2581 of proceedings.cls)&lt;br /&gt;&lt;br /&gt;If you would like to change anything about the headers or footers, you change that in the pagestyle &lt;em&gt;proceedings&lt;/em&gt; which I defined in lines 2024–2039 of the proceedings.cls&lt;br /&gt;&lt;br /&gt;I know that my solution is far from elegant because internally it uses the \chapter* command which makes chapters which don't appear in the table of contents and right after that it "manually" adds the chapter's title with the author's name to ToC. I also know that rather than replacing the chapter number with {} it would be more elegant not to let typeset it at all. I also wish I could have a command like e.g. \chapterauthor which would be used as a place holder in the definition of the header and get updated with every \Chapter (or even \chapter) rather than redefining the whole header with every new \Chapter. &lt;br /&gt;&lt;br /&gt;Alas, I have spent so many days with this that right now I am not going to spend any more time with this. If you are an experienced document class designer please do it better, publish it somewhere, and let me know. Thank you.&lt;br /&gt;&lt;br /&gt;Unexperienced Xetex users may use and modify the proceedings.cls as they need. If you have questions where and how to modify certain things in it please ask me &lt;a href="mailto:sven.siegmund@gmail.com"&gt;directly&lt;/a&gt; or in the comments.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-5817162051460636843?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/5817162051460636843/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=5817162051460636843' title='10 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5817162051460636843'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5817162051460636843'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2011/03/author-per-chapter-aka-proceedings.html' title='Author per chapter (a.k.a. Proceedings)'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>10</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-5443615773774517935</id><published>2010-01-06T23:55:00.000-08:00</published><updated>2010-01-07T00:13:54.409-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='typography'/><category scheme='http://www.blogger.com/atom/ns#' term='packages'/><title type='text'>Subscript and superscript in text mode</title><content type='html'>I often need to write various thing in subscript and superscript which have nothing to do with maths so I don't want to have them written in math mode. For LaTeX users there is no easy way to write subscript and superscript in text mode.&lt;br /&gt;XeTeX, however, has prepared some macros for this. Assuming you have &lt;code&gt;\usepackage{xltxtra}&lt;/code&gt; in the preamble, you can use the commands&lt;br /&gt;&lt;br /&gt;&lt;code&gt;\textsubscript{}&lt;/code&gt;&lt;br /&gt;&lt;code&gt;\textsuperscript{}&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;if you want something like &lt;code&gt;C_2&lt;/code&gt; you write &lt;code&gt;C\textsubscript{2}&lt;/code&gt;. Of course if you use this a lot, it is much more convenient two write some shorthand command to use instead these long ones.&lt;br /&gt;&lt;br /&gt;Those of you who still write in LaTeX may find a solution &lt;a href="http://anthony.liekens.net/index.php/LaTeX/SubscriptAndSuperscriptInTextMode"&gt;here&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-5443615773774517935?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/5443615773774517935/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=5443615773774517935' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5443615773774517935'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5443615773774517935'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2010/01/subscript-and-superscript-in-text-mode.html' title='Subscript and superscript in text mode'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>5</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-5549514955966232400</id><published>2009-07-23T00:55:00.000-07:00</published><updated>2009-09-04T11:52:26.925-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='typography'/><category scheme='http://www.blogger.com/atom/ns#' term='commands'/><title type='text'>Typesetting tilde or backslash</title><content type='html'>Typesetting a tilde in Latex or Xetex is not so easy. It's a reserved character (non breakable fixed width space) and &lt;code&gt;\~&lt;/code&gt; produces a diacritic. Typing this diacritic alone, i.e. &lt;code&gt;\~{}&lt;/code&gt; still produces a tilde which is small and high above the base line. When you follow most of the recommendations in Latex books, you probably write tilde by &lt;code&gt;$\sim$&lt;/code&gt; or any other more complicated variant thereof to work in both text and math environment. This produces a tilde nice and big, not too high above the baseline. What you also see is the recommendation to write tilde in the verbatim mode. For me these two are still not acceptable because they usually switch the font and you really see that the font of it looks alien to the surrounding text. Why should I switch the font when I want to write a tilde in the text mode? I want to get a nice tilde in the normal font which is not a diacritic. Font designers strived to match the appearance of the tilde glyph to the rest of the font so why shouldn't I use it?&lt;br /&gt;&lt;br /&gt;Fortunately, there is a macro for typing the kind of tilde I need: &lt;code&gt;\textasciitilde{}&lt;/code&gt;. It is just not generally known. This produces a tilde in the text mode which uses the tilde glyph from the font just as the font designers shaped it. It's similar to the command &lt;code&gt;\textbackslash{}&lt;/code&gt; which is more widely known for typsetting backslash in text mode.&lt;br /&gt;&lt;br /&gt;When you are in text mode, use these commands and spread the word.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-5549514955966232400?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/5549514955966232400/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=5549514955966232400' title='8 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5549514955966232400'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5549514955966232400'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2009/07/typesetting-tilde-or-backslash.html' title='Typesetting tilde or backslash'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>8</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-2982231599330752235</id><published>2009-05-20T01:59:00.000-07:00</published><updated>2009-06-08T07:25:40.405-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='commands'/><title type='text'>Phantomas command</title><content type='html'>Recently I have found that there is a useful TeX command \phantom{Phantom Text} which behaves just like it would typeset its argument except that nothing is typeset and there is a blank space of the corresponding dimensions.&lt;br /&gt;&lt;br /&gt;When I have been using it I imagined it would be sometimes even more useful to have a command which can put some other stuff in the reserved space instead of the phantom stuff.&lt;br /&gt;&lt;br /&gt;Luckily, some smart guys have already &lt;a href="http://groups.google.com/group/comp.text.tex/browse_thread/thread/1a29057215c920cd/a7cdb36114c25c8d?lnk=gst&amp;q=phantom-ish#a7cdb36114c25c8d"&gt;written&lt;/a&gt; such a command. &lt;br /&gt;&lt;br /&gt;Here is a modified version of their minimal example which illustrates nicely the use of this command:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;\documentclass{article}&lt;br /&gt;\usepackage{calc} % for the \phantomas command&lt;br /&gt;&lt;br /&gt;% The following command is a better version of \phantom and requires the "calc" package&lt;br /&gt;% Credits: Jean-Côme Charpentier &amp; Scott Pakin&lt;br /&gt;% Source: comp.text.tex, "Phantom-ish command"&lt;br /&gt;% usage: \phantomas[l]{phantom words which will be overwritten}{with these words}&lt;br /&gt;% the optional parameter [l] says that the words "with these words" will appear aligned left to the reserved space&lt;br /&gt;% another optional parameter is [r] for aligning the words right&lt;br /&gt;% if no optional parameter is given, the words will be centred in the reserved space&lt;br /&gt;\newcommand*\phantomas[3][c]{% &lt;br /&gt;   \ifmmode &lt;br /&gt;     \makebox[\widthof{$#2$}][#1]{$#3$}% &lt;br /&gt;   \else &lt;br /&gt;     \makebox[\widthof{#2}][#1]{#3}% &lt;br /&gt;   \fi &lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;\begin{document}&lt;br /&gt;&lt;br /&gt;A long entry another long entry and our last long entry\par &lt;br /&gt;\phantomas{A long entry}{centred} \phantomas[l]{another long entry}{on the left} &lt;br /&gt;\phantomas[r]{and our last long entry}{on the right} &lt;br /&gt;&lt;br /&gt;$\sin^2 x + \cos^2 x = 1$\par &lt;br /&gt;$\phantomas{\sin^2 x + \cos^2 x}{f(x)} = 1$\par &lt;br /&gt;$\phantomas[l]{\sin^2 x + \cos^2 x}{f(x)} = 1$\par &lt;br /&gt;$\phantomas[r]{\sin^2 x + \cos^2 x}{f(x)} = 1$ &lt;br /&gt;&lt;br /&gt;\end{document}&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-2982231599330752235?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/2982231599330752235/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=2982231599330752235' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/2982231599330752235'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/2982231599330752235'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2009/05/phantomas-command.html' title='Phantomas command'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-5932245781711312566</id><published>2009-02-25T11:19:00.000-08:00</published><updated>2009-02-25T11:21:12.806-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='typography'/><category scheme='http://www.blogger.com/atom/ns#' term='packages'/><title type='text'>First gloss line in italics (gb4e)</title><content type='html'>The solution is in the gb4e manual on page 7:&lt;br /&gt;&lt;br /&gt;% first gloss line in italics:&lt;br /&gt;\let\eachwordone=\it&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-5932245781711312566?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/5932245781711312566/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=5932245781711312566' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5932245781711312566'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5932245781711312566'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2009/02/first-gloss-line-in-italics-gb4e.html' title='First gloss line in italics (gb4e)'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-2061849500680752629</id><published>2009-02-25T11:17:00.000-08:00</published><updated>2009-02-25T11:24:03.609-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tables'/><title type='text'>Table lines starting with square bracket</title><content type='html'>this one does not compile: &lt;br /&gt;&lt;br /&gt;\documentclass{article} &lt;br /&gt;\begin{document} &lt;br /&gt;\begin{tabular}{ll} &lt;br /&gt;        a &amp; b \\ &lt;br /&gt;        [c] &amp; d \\ &lt;br /&gt;\end{tabular} &lt;br /&gt;\end{document}&lt;br /&gt;&lt;br /&gt;if required, one can specify the vertical gap between lines in a table using &lt;br /&gt;  &lt;code&gt;\\[len]&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;LaTeX removed the newline and whitespace to interpret the table as having a &lt;code&gt;\\[c]&lt;/code&gt; entry, and there exists no length "c".&lt;br /&gt;&lt;br /&gt;So the solution is to write the initial square bracket into curly braces. This way it is not interpreted as the beginning of the optional argument of the newline command.&lt;br /&gt;&lt;br /&gt;\documentclass{article} &lt;br /&gt;\begin{document} &lt;br /&gt;\begin{tabular}{ll} &lt;br /&gt;        a &amp; b \\ &lt;br /&gt;        {[}c] &amp; d \\ &lt;br /&gt;\end{tabular} &lt;br /&gt;\end{document}&lt;br /&gt;&lt;br /&gt;Thanks to Werner Grundlingh for showing me the problem source.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-2061849500680752629?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/2061849500680752629/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=2061849500680752629' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/2061849500680752629'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/2061849500680752629'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2009/02/table-lines-starting-with-square.html' title='Table lines starting with square bracket'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>5</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-8262583429954046055</id><published>2008-04-10T08:10:00.000-07:00</published><updated>2008-04-10T08:19:44.676-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Vim'/><title type='text'>Filetype recognition in Vim</title><content type='html'>If your LaTeX suite does not want to load when you create a new.tex file, it is probably due to the following line missing in the _vimrc file:&lt;br /&gt;&lt;br /&gt;" Prevents Vim 7.0 from setting filetype to 'plaintex'&lt;br /&gt;let g:tex_flavor='latex'&lt;br /&gt;&lt;br /&gt;Thanks to &lt;a href="http://phaseportrait.blogspot.com/2008/03/vim-latex-vim-70-and-filetype-plugin.html"&gt;Phase Portrait&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-8262583429954046055?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/8262583429954046055/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=8262583429954046055' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/8262583429954046055'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/8262583429954046055'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/04/filetype-recognition-in-vim.html' title='Filetype recognition in Vim'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-7890717418092505712</id><published>2008-04-10T06:49:00.000-07:00</published><updated>2008-04-10T06:53:54.652-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Vim'/><title type='text'>Vim for XeTeX/LaTeX</title><content type='html'>If you want to use the LaTeX suite in Vim and you get a an error message like this:&lt;br /&gt;&lt;br /&gt;::call histdel("/", -1)|let @/=g:Tex_LastSearchPattern  &lt;br /&gt;&lt;br /&gt;&lt;a href="http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=312816"&gt;here&lt;/a&gt; is the solution.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-7890717418092505712?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/7890717418092505712/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=7890717418092505712' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/7890717418092505712'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/7890717418092505712'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/04/vim-for-xetexlatex.html' title='Vim for XeTeX/LaTeX'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-1702161767526122466</id><published>2008-03-16T08:02:00.000-07:00</published><updated>2008-03-16T08:04:36.373-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tables'/><title type='text'>First word of a paragraph</title><content type='html'>Today, with all the troubles around tables, I learned that the first word of a paragraph never gets hyphenated. (Thanks, Ulrike) Just in case you wonder why your table header does not get automatically hyphenated, you know &amp;hellip;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-1702161767526122466?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/1702161767526122466/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=1702161767526122466' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/1702161767526122466'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/1702161767526122466'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/03/first-word-of-paragraph.html' title='First word of a paragraph'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-6101576322029632679</id><published>2008-03-16T05:59:00.000-07:00</published><updated>2008-03-16T06:42:42.215-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tables'/><title type='text'>Tables</title><content type='html'>Everything I learned about tables in an introductory LaTeX is ok but not sufficient. &lt;br /&gt;&lt;br /&gt;Very nice and up-to-date &lt;a href="http://www.tug.org/pracjourn/2007-1/mori/mori.pdf"&gt;Table guide&lt;/a&gt; has been written by Lapo Filippo Mori and I warmly recommend it to everybody.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-6101576322029632679?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/6101576322029632679/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=6101576322029632679' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/6101576322029632679'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/6101576322029632679'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/03/tables.html' title='Tables'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-5471324235176158605</id><published>2008-03-07T06:29:00.001-08:00</published><updated>2008-03-08T06:08:28.081-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='packages'/><title type='text'>Block comment</title><content type='html'>If you need to comment out a block of text, use the &lt;em&gt;verbatim&lt;/em&gt; package. That provides the &lt;em&gt;comment&lt;/em&gt; environment:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;\begin{comment}&lt;br /&gt;&amp;hellip;&lt;br /&gt;\end{comment}&lt;br /&gt;&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-5471324235176158605?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/5471324235176158605/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=5471324235176158605' title='14 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5471324235176158605'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/5471324235176158605'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/03/block-comment.html' title='Block comment'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>14</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-3247696161448845555</id><published>2008-03-07T05:24:00.000-08:00</published><updated>2008-03-07T05:26:37.323-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='packages'/><category scheme='http://www.blogger.com/atom/ns#' term='tables'/><title type='text'>Line spacing in tables</title><content type='html'>If you need more space between the lines in a table use the &lt;em&gt;array&lt;/em&gt; package and put the following line somewhere between \begin{table} and \begin{tabular}&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;\setlength{\extrarowheight}{length}&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;Instead of “length” you write the desired space, e.g. “3pt”&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-3247696161448845555?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/3247696161448845555/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=3247696161448845555' title='6 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/3247696161448845555'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/3247696161448845555'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/03/line-spacing-in-tables.html' title='Line spacing in tables'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>6</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-476664039497860560</id><published>2008-03-05T03:58:00.000-08:00</published><updated>2008-03-05T09:45:10.058-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='commands'/><title type='text'>Assign another catcode</title><content type='html'>The actual and more elegant solution for my problem with verbatim text in argument position decribed in the &lt;a href="http://xelatex.blogspot.com/2008/03/verbatim-text-as-command-argument.htmlhttp://xelatex.blogspot.com/2008/03/verbatim-text-as-command-argument.htmlhttp://xelatex.blogspot.com/2008/03/verbatim-text-as-command-argument.html"&gt;previous post&lt;/a&gt; is much simpler. Since the underscore “_” is the only nasty character which does not allow me to write things like “NA071112-01_E.008” as an argument of my \ru command the best solution for me is to assign the underscore another catcode (thanks to Enrico Gregorio). This simply achieved by &amp;hellip;&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;\catcode`\_=12&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;&amp;hellip; in the preamble. Thereby the underscore looses its subscript function (category code 8) and is treated like any other puctuation character (category code 12).&lt;br /&gt;&lt;br /&gt;As a linguist I do not need the underscore as a shortcut for subscript in math mode. If I want, I can still do it by “\sb” instead of the “_”. (\sb is actually short enough.)&lt;br /&gt;&lt;br /&gt;I then can define my \ru just like this:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;\providecommand{\ru}[1]{#1}&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;(I may want to fill it with additional commands later.)&lt;br /&gt;&lt;br /&gt;I get the feeling that changing the category code of certain special characters may be the most accessible (if not the only) way of accepting verbatim text as an argument of a command.&lt;br /&gt;&lt;br /&gt;This whole thing around my \ru command motivates me to go through some introduction to TeX. Very nice explanation of catcodes and their purpose I found in Eijkhout’s &lt;a href="http://www.ctan.org/get/info/texbytopic/TeXbyTopic.pdf"&gt;TeX by Topic&lt;/a&gt; on p. 29.&lt;br /&gt;&lt;br /&gt;D. E. Knuth certainly was a smart guy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-476664039497860560?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/476664039497860560/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=476664039497860560' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/476664039497860560'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/476664039497860560'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/03/assign-another-catcode.html' title='Assign another catcode'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-167095285830485897</id><published>2008-03-05T03:48:00.000-08:00</published><updated>2008-03-05T09:41:57.225-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='packages'/><category scheme='http://www.blogger.com/atom/ns#' term='commands'/><title type='text'>Verbatim text as command argument</title><content type='html'>In my dissertation I will refer to the &lt;a href="http://www.ethnologue.com/show_language.asp?code=ngh"&gt;N|uu&lt;/a&gt; text corpus. The corpus has reference units which are called e.g. NA071112-01_E.008. I thought all the references to the text corpus are markup-worthy entities so I needed a command like \ru (short for reference unit) to markup those references with it like this: \ru{NA071112-01_E.008}.&lt;br /&gt;&lt;br /&gt;As you know, the underscore “_” is a special character used in math mode for subscript. So it is not allowed to occur as a part of some string. I did not want to write \ru{NA071112-01\_E.008} instead. I looked for a way to feed commands verbatim text arguments. &lt;br /&gt;&lt;br /&gt;I stumbled upon the &lt;a href="http://www.ctan.org/get/macros/latex/contrib/fancyvrb/fancyvrb.pdf"&gt;fancyvrb&lt;/a&gt; package, which looks really promising for this, especially in the documentation on p. 17 where some magic &lt;em&gt;aftersave&lt;/em&gt; is used. But the aftersave parameter is heavily underdocumented there. That’s just my luck. I could not find out what aftersave actually does and if it will enable me to write someting like \ru{NA071112-01_E.008}. &lt;br /&gt;&lt;br /&gt;I then sought help at &lt;a href="http://groups.google.com/group/comp.text.tex"&gt;comp.text.tex&lt;/a&gt; (topic: &lt;a href="http://groups.google.com/group/comp.text.tex/browse_thread/thread/5181394aac194063/56cd22c87f1c136a?lnk=raot"&gt;fancyvrb problems&lt;/a&gt;) and Enrico Gregorio was so kind to write me this TeX code:&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;\def\ruspeciallist{\do\_} % add the special characters you need with "\do\X" (X is the characater)&lt;br /&gt;&lt;br /&gt;\def\rucatcodes{\def\do##1{\catcode`##1=12 }\ruspeciallist}&lt;br /&gt;\newbox\rubox&lt;br /&gt;\def\ru{\afterassignment\dorusetup\let\next= } &lt;br /&gt;\def\dorusetup{\setbox\rubox=\hbox\bgroup &lt;br /&gt;  \rucatcodes \aftergroup\dorufinish} &lt;br /&gt;\def\dorufinish{\box\rubox}&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;An extensively commented version is also &lt;a href="http://groups.google.com/group/comp.text.tex/msg/5c0fec054239c518"&gt;there&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;In the last line between “\dorufinish{” and “\box\rubox}” come all the commands you want to apply the the argument of \ru. BUT:&lt;br /&gt;&lt;br /&gt;Enrico: “A limit of this approach is that the string is never read as an &lt;br /&gt;argument, so that it is not available for, say, writing an index &lt;br /&gt;entry: we have it only in typeset form, inside the box.”&lt;br /&gt;&lt;br /&gt;Ok, this certainly is a nice piece of code but it does not essentially allow verbatim text to be an argument of a command. It is just a work-around to get that verbatim text typeset somehow (and that's what I have originally asked for in the newsgroup). So, in that sense, verbatim text as argument still is an open issue.&lt;br /&gt;&lt;br /&gt;Enrico — after I told him I actually may want to index that stuff — suggested a much simpler and elegant &lt;a href="http://xelatex.blogspot.com/2008/03/assign-another-catcode.html"&gt;solution&lt;/a&gt; for my particular needs. &lt;br /&gt;&lt;br /&gt;Anyway, if anybody of you readers finds out how to use the aftersave of fancyvrb package do inform me in the comments to this post. I’d really like to know. I think it has something to do with TeX’s \expandafter.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-167095285830485897?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/167095285830485897/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=167095285830485897' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/167095285830485897'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/167095285830485897'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/03/verbatim-text-as-command-argument.html' title='Verbatim text as command argument'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-2413347528746739799</id><published>2008-03-05T02:21:00.000-08:00</published><updated>2008-03-05T03:08:08.503-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='commands'/><title type='text'>Newcommand with an optional argument</title><content type='html'>I don’t know why this feature is not implemented in LaTeX. You can very easily define your own commands, but they may take only a fixed number of arguments (up to 9). Bad luck, because the first command I needed to write for my dissertation had to have an optional argument:&lt;br /&gt;&lt;br /&gt;Linguists traditionally write words and sounds from a language of interest in italics, e.g. the &lt;a href="http://www.ethnologue.com/show_language.asp?code=ngh"&gt;N|uu&lt;/a&gt; word &lt;i&gt;ainki&lt;/i&gt;. Often it is followed by an enquoted translation, e.g. &lt;i&gt;ainki&lt;/i&gt; ‘father’, &lt;i&gt;xainki&lt;/i&gt; ‘mother’, &lt;i&gt;n|ai&lt;/i&gt; ‘see’, and &lt;i&gt;kx’ain&lt;/i&gt; ‘laugh’ all contain the diphthong &lt;i&gt;ai&lt;/i&gt;.&lt;br /&gt;&lt;br /&gt;So I wanted to write me a command \nuu by which I could write either just the N|uu word in italics or the word in italics followed by the enquoted translation. I would use it either just as \nuu{ainki} for &lt;i&gt;ainki&lt;/i&gt; or as \nuu[father]{ainki} for &lt;i&gt;ainki&lt;/i&gt; ‘father’.&lt;br /&gt;&lt;br /&gt;Later, when I learn how to make an index of all N|uu words written in my document, I probably will just add an indexing command into the \nuu command definition. For now the optional argument was trouble enough. I did not expect that it will involve hardcore TeX programming.&lt;br /&gt;&lt;br /&gt;Fortunately good people from the xetex@tug.org mailing list have suggested some solutions for this and the most bullet-proof and versatile was this (thanks to Morten Høgholm and Ross Moore):&lt;br /&gt;&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;\documentclass{article}&lt;br /&gt;&lt;br /&gt;\makeatletter&lt;br /&gt;\long\def\tlist@if@empty@nTF #1{%&lt;br /&gt; \expandafter\ifx\expandafter\\\detokenize{#1}\\%&lt;br /&gt;  \expandafter\@firstoftwo&lt;br /&gt; \else&lt;br /&gt;  \expandafter\@secondoftwo&lt;br /&gt; \fi&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;\providecommand*\nuu[2][]{%&lt;br /&gt; \textit{#2}%&lt;br /&gt; \tlist@if@empty@nTF{#1}{}{ `#1'}% only the false code executed&lt;br /&gt;}&lt;br /&gt;\makeatother&lt;br /&gt;&lt;br /&gt;\begin{document}&lt;br /&gt;\nuu{ainki} \nuu[mother]{xainki} \nuu[goat]{mudi}&lt;br /&gt;\end{document}&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;I use \providecommand instead of \newcommand. I feel safer. “It works like \newcommand, but if the command is already defined, LaTeX2e will silently ignore it.” (Oetiker et al., &lt;a href="http://www.ctan.org/get/info/lshort/english/lshort.pdf"&gt;lshort.pdf&lt;/a&gt;, p. 109.)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-2413347528746739799?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/2413347528746739799/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=2413347528746739799' title='12 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/2413347528746739799'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/2413347528746739799'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/03/newcommand-with-optional-argument.html' title='Newcommand with an optional argument'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>12</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4805987410501728034.post-8221144202927179262</id><published>2008-03-05T01:26:00.000-08:00</published><updated>2008-03-05T04:51:10.228-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Editorial'/><title type='text'>LaTeX’s new era started: XeTeX</title><content type='html'>My serious interest in LaTeX started in February 2008 when I realized that there is a Unicode-capable version of it at last, called XeTeX. Since I use primarily Windows, I immediately downloaded MiKTeX 2.7.2960 and installed it full with all possible packages to make sure I won’t need to install any additional stuff. The installation files took 625.5 &lt;a href="http://en.wikipedia.org/wiki/Byte#Names_for_different_units"&gt;MiB&lt;/a&gt;, the MiKTeX installation 1.1 &lt;a href="http://en.wikipedia.org/wiki/Byte#Names_for_different_units"&gt;GiB&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;I started to learn with XeTeX right away, before knowing LaTeX. XeTeX source file differs from LaTeX practically just by few commands in the preamble for a more comfortable font selection (through the &lt;a href="http://www.ctan.org/get/macros/xetex/latex/fontspec/fontspec.pdf"&gt;fontspec&lt;/a&gt; package) and in the document body by the respective font selection commands. Another difference is that XeTeX source is preferably encoded in UTF-16 or at least UTF-8 and when typesetting the document you run xelatex instead of pdflatex. Hence the URL of this blog: &lt;a href="http://xelatex.blogspot.com"&gt;http://xelatex.blogspot.com&lt;/a&gt;. (Actually it is because xetex.blogspot.com was already taken by some inactive dude.) ;-)&lt;br /&gt;&lt;br /&gt;After a week of reading and experimenting with XeTeX I took a LaTeX Beginner’s course at the University of Leipzig and learned some useful startup suff about LaTeX and also the troubles with encoding and fonts LaTeXers have to face, which are a piece of cake and joy for XeTeX.&lt;br /&gt;&lt;br /&gt;More and more I feel that the native Unicode support of XeTeX (at least fot the Basic Multilingual Plane) and its comfortable access to system’s OTF/TTF fonts is a real breakthrough. Many more scientists in the world can use it and need not to stick with MS Word which is until now pretty much the only wide-spread &lt;STRIKE&gt;typesetting&lt;/STRIKE&gt; word-processing software to support Unicode.&lt;br /&gt;&lt;br /&gt;The actual &lt;a href="http://scripts.sil.org/xetex"&gt;XeTeX homepage&lt;/a&gt; is at SIL, but a very nice &lt;a href="http://www.cstug.cz/aktivity/2007/CSTUG-talk.pdf"&gt;presentation&lt;/a&gt; of its features (which I hereby recommend to everybody) is found at &lt;a href="http://www.cstug.cz/"&gt;CSTUG&lt;/a&gt;. (There is also a &lt;a href="http://video.fi.muni.cz/public/xetex/xetex.avi"&gt;video recording&lt;/a&gt; of the whole XeTeX presentation by its developer Jonathan Kew. - Which imo is not worth watching.)&lt;br /&gt;&lt;br /&gt;I plan to write my dissertation in XeTeX so there will be a lot of practical stuff to deal with. My field of study is Linguistics, so Linguists which certainly will switch to XeTeX en mass will find valuable information here.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4805987410501728034-8221144202927179262?l=xelatex.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://xelatex.blogspot.com/feeds/8221144202927179262/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4805987410501728034&amp;postID=8221144202927179262' title='6 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/8221144202927179262'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4805987410501728034/posts/default/8221144202927179262'/><link rel='alternate' type='text/html' href='http://xelatex.blogspot.com/2008/03/latexs-new-era-started-xetex.html' title='LaTeX’s new era started: XeTeX'/><author><name>Sven Siegmund</name><uri>https://profiles.google.com/112290787165402179395</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//lh5.googleusercontent.com/-c0GEQXMCou0/AAAAAAAAAAI/AAAAAAAAAAA/UE7iGVhuN7I/s512-c/photo.jpg'/></author><thr:total>6</thr:total></entry></feed>
