From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/20428 Path: news.gmane.org!not-for-mail From: =?ISO-8859-15?Q?Peter_M=FCnster?= Newsgroups: gmane.comp.tex.context Subject: Re: LaTeX emulation Date: Wed, 18 May 2005 19:17:30 +0200 (CEST) Message-ID: References: <23d0689705051711357c01e36c@mail.gmail.com> <428A4EF4.1020701@wxs.nl> <428A6C98.4070100@gmail.com> Reply-To: ntg-context@ntg.nl NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: sea.gmane.org 1116436814 12155 80.91.229.2 (18 May 2005 17:20:14 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 18 May 2005 17:20:14 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Wed May 18 19:20:10 2005 Return-path: Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by ciao.gmane.org with esmtp (Exim 4.43) id 1DYSBa-0006lT-0D for gctc-ntg-context-518@m.gmane.org; Wed, 18 May 2005 19:18:22 +0200 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 5520412792; Wed, 18 May 2005 19:19:07 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 03530-01-3; Wed, 18 May 2005 19:19:03 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 832B91281B; Wed, 18 May 2005 19:19:03 +0200 (CEST) Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 4749F1281B for ; Wed, 18 May 2005 19:19:02 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 03530-01-2 for ; Wed, 18 May 2005 19:19:01 +0200 (CEST) Original-Received: from postfix3-1.free.fr (postfix3-1.free.fr [213.228.0.44]) by ronja.ntg.nl (Postfix) with ESMTP id 5DBA012792 for ; Wed, 18 May 2005 19:19:01 +0200 (CEST) Original-Received: from gaston.free.fr (rennes-1-62-147-97-52.dial.proxad.net [62.147.97.52]) by postfix3-1.free.fr (Postfix) with ESMTP id 241C11734AA for ; Wed, 18 May 2005 19:18:59 +0200 (CEST) Original-Received: by gaston.free.fr (Postfix, from userid 500) id 02C1913C049; Wed, 18 May 2005 19:17:31 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by gaston.free.fr (Postfix) with ESMTP id 2FB8714809F for ; Wed, 18 May 2005 19:17:31 +0200 (CEST) X-X-Sender: peter@gaston.free.fr Original-To: mailing list for ConTeXt users In-Reply-To: X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.5 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on smtp.ntg.nl X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:20428 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:20428 On Wed, 18 May 2005, Maurice Diamantini wrote: > What kind of stuff do we need for, say, an "article" LaTeX class? Hello, I like the LaTeX-KOMA-classes. Here some setups, that I used for my brother's thesis: \doifmodeelse{A4}{% \setuppapersize[A4]\setupbodyfont[12pt]}{% \setuppapersize[A5]\setupbodyfont[9pt]} \setupheader[style=\it] \setuphead[chapter,title][header=nomarking] \setupindenting[small] \define[1]\LeftAligned{\startalignment[right,broad]#1\stopalignment} \setuphead[title,chapter,section,subsection,subsubsection][% textcommand=\LeftAligned,textstyle=bold,numberstyle=bold] \setuplist[chapter][style=bold,before=\blank] \setupcombinedlist[content][alternative=c] \setuppagenumbering[location=footer] \definemakeup[title][standard,align=middle] \setupbodyfontenvironment[default][em=italic] \doifmodeelse{oneside}{\setupheadertexts[chapter]}{% \setupheadertexts[][section][chapter][] \setuppagenumbering[alternative=doublesided]} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% This is an emulation of \usepackage[DIVcalc]{typearea} in LaTeX. \def\BCOR{3mm}% eventual binding correction newdimen\PageWidth \PageWidth=\paperwidth \doifmode{BCOR}{\PageWidth=\dimexpr(\PageWidth-\BCOR)} \edef\Ratio{\withoutpt{\the\dimexpr(2\paperheight/(\PageWidth/32768))}} \setbox\scratchbox\hbox{\dorecurse{26}{\character\recurselevel}} \newdimen\Width \newdimen\Height \newdimen\Back \Width=\dimexpr(2.6\wd\scratchbox) \Height=\dimexpr(\Ratio\Width) \doifmodeelse{oneside}{\Back=\dimexpr((\PageWidth - \Width) / 2)}% {\Back=\dimexpr((\PageWidth - \Width) / 3)} \doifmode{BCOR}{\Back=\dimexpr(\Back + \BCOR)} \edef\Top{\the\dimexpr((\paperheight - \Height) / 3 - 3\lineheight)} \Height=\dimexpr(\Height + 8\lineheight) \setuplayout[backspace=\the\Back,height=\the\Height,width=\the\Width, header=2\lineheight,headerdistance=\lineheight, footer=2\lineheight,footerdistance=3\lineheight,topspace=\Top] %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \setupalign[line] \def\upperrightdoublesixquote{\kern-.125em``}% german quotes \def\emph#1{{\em#1}} \def\texttwosuperior{$^2$} \setupcaptions[width=\makeupwidth, style={\switchtobodyfont[small]\setupinterlinespace}] Cheers, Peter -- http://pmrb.free.fr/contact/