From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/45115 Path: news.gmane.org!not-for-mail From: Ruini Xue Newsgroups: gmane.comp.tex.context Subject: why does not this style work? Date: Sun, 26 Oct 2008 15:55:52 +0000 (UTC) Message-ID: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1225036676 26981 80.91.229.12 (26 Oct 2008 15:57:56 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 26 Oct 2008 15:57:56 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Sun Oct 26 16:58:57 2008 connect(): Connection refused Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by lo.gmane.org with esmtp (Exim 4.50) id 1Ku80z-0003nC-SO for gctc-ntg-context-518@m.gmane.org; Sun, 26 Oct 2008 16:58:53 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id A96FF1FC07; Sun, 26 Oct 2008 16:57:42 +0100 (CET) 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 10851-09-5; Sun, 26 Oct 2008 16:56:46 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id E38D21FB49; Sun, 26 Oct 2008 16:56:45 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 240CD1FB49 for ; Sun, 26 Oct 2008 16:56:44 +0100 (CET) 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 12777-01-3 for ; Sun, 26 Oct 2008 16:56:05 +0100 (CET) Original-Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by ronja.ntg.nl (Postfix) with ESMTP id 3B40C1FB3C for ; Sun, 26 Oct 2008 16:56:05 +0100 (CET) Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1Ku7yD-0000Y8-7Z for ntg-context@ntg.nl; Sun, 26 Oct 2008 15:56:01 +0000 Original-Received: from tu131045.ip.tsinghua.edu.cn ([166.111.131.45]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 26 Oct 2008 15:56:01 +0000 Original-Received: from xueruini by tu131045.ip.tsinghua.edu.cn with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 26 Oct 2008 15:56:01 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 47 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: main.gmane.org User-Agent: Loom/3.14 (http://gmane.org/) X-Loom-IP: 166.111.131.45 (Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_5_5; zh-cn) AppleWebKit/525.18 (KHTML, like Gecko) Version/3.1.2 Safari/525.20.1) X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 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-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:45115 Archived-At: I want to use a dedicated font size for the chapter title, so I wrote this piece of code: %%%%%%%%%%%%%%%%%% \def\mybig% {\dosingleempty\dosanhao} \def\dosanhao[#1]% {\switchtobodyfont[24pt]} \setuphead [chapter] [style=\mybig] \starttext \chapter{hello, world} \stoptext %%%%%%%%%%%%%%%%% However, the error is: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ! Use of \dosanhao doesn't match its definition. \doifnextcharelse ...token =#1\def \!!stringa {#2} \def \!!stringb {#3}\futur... \@@kochapterstyle ->\mybig \bf \doconvertfont #1->\edef \p!defined {#1 }\ifx \p!defined \empty \else \@EA \d... \dosetfontattribute ...me #1#2\@EA \endcsname \fi \empty \doplaceheadnumbertext ...bute {\??ko #1}\c!style \dosetcolorattribute {\??k... \dodododoconstructhead ...{\finalsectionnumber }}} \writesection {#1}{#3}{#4}... l.11 \chapter{hello, world} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% If I replace the \mybig with \switchtobodyfont in style=xx, it works fine. What's the difference between them? and why the former does not work? -- ruini ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________