From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/37620 Path: news.gmane.org!not-for-mail From: "Wolfgang Schuster" Newsgroups: gmane.comp.tex.context Subject: Re: selectively turn off captions Date: Fri, 30 Nov 2007 14:19:50 +0100 Message-ID: <115224fb0711300519u56241508ub4781b2791932d72@mail.gmail.com> References: <115224fb0711290815o61878902s508811cda01ebb10@mail.gmail.com> <474F3A83.9000804@wxs.nl> 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 1196428890 455 80.91.229.12 (30 Nov 2007 13:21:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 30 Nov 2007 13:21:30 +0000 (UTC) To: "mailing list for ConTeXt users" Original-X-From: ntg-context-bounces@ntg.nl Fri Nov 30 14:21:37 2007 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 1Iy5oG-0005aS-Fp for gctc-ntg-context-518@m.gmane.org; Fri, 30 Nov 2007 14:21:36 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id C8E721FAF3; Fri, 30 Nov 2007 14:21:17 +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 01126-02-5; Fri, 30 Nov 2007 14:21:07 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 2A77B1FB82; Fri, 30 Nov 2007 14:21:06 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 99E2C1FBBA for ; Fri, 30 Nov 2007 14:20:09 +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 32447-03-7 for ; Fri, 30 Nov 2007 14:19:52 +0100 (CET) Original-Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.175]) by ronja.ntg.nl (Postfix) with ESMTP id 251AE1FB0B for ; Fri, 30 Nov 2007 14:19:52 +0100 (CET) Original-Received: by ug-out-1314.google.com with SMTP id q2so850762uge for ; Fri, 30 Nov 2007 05:19:51 -0800 (PST) Original-Received: by 10.66.252.8 with SMTP id z8mr586054ugh.1196428790316; Fri, 30 Nov 2007 05:19:50 -0800 (PST) Original-Received: by 10.67.122.17 with HTTP; Fri, 30 Nov 2007 05:19:50 -0800 (PST) In-Reply-To: <474F3A83.9000804@wxs.nl> Content-Disposition: inline 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:37620 Archived-At: 2007/11/29, Hans Hagen : > Roger Mason wrote: > > Hi Wolfgang, > > > > "Wolfgang Schuster" writes: > > > >> \setupfloat[figure][default=none] > > > > Thanks, but that did not work. The only thing that seems to work is > > to put {none} for the caption. However, that means I'm not going to > > have captions in the manuscript version either. > > well, we can misuse the number= key ..... > > % patch, goes in cont-new.tex > > \unprotect > > \def\presetfloatvariables#1#2#3#4% > {\doifcommonelse > {#2} > {\v!left,\v!right,\v!inner,\v!outer,% > \v!inleft,\v!inright,\v!inmargin,% > \v!backspace,\v!cutspace,% > \v!innermargin,\v!outermargin,\v!inneredge,\v!outeredge,% > \v!leftmargin,\v!leftedge,\v!rightmargin,\v!rightedge} > {\global\parfloattrue} > {\global\parfloatfalse}% > \ifinsidecolumns > \global\parfloatfalse > \fi > \global\sidefloatshift\zeropoint > \global\sidefloatmaximum\zeropoint > \global\chardef\sidefloatmethod\floatparameter\c!sidemethod > \global\chardef\textfloatmethod\floatparameter\c!textmethod > \global\chardef\sidefloatalign\zerocount > \globallet\floatrotation\!!zerocount > \calculatefloatskips > \ifparfloat > \processaction > [\floatparameter\c!sidealign] > [\v!height=>\global\chardef\sidefloatalign\plusone,% > \v!line=>\global\chardef\sidefloatalign\plustwo,% (***) > \v!depth=>\global\chardef\sidefloatalign\plusthree,% > \v!grid=>\global\chardef\sidefloatalign4,% > \v!halfline=>\global\chardef\sidefloatalign5]% > % todo (test first): > \doifinset\v!lokaal{#2}{\chardef\sidefloatalign\zerocount}% > \ifcase\sidefloatalign\relax % todo: optie v!lokaal => \else > \doifinset\v!height {#2}{\global\chardef\sidefloatalign\plusone}% > \doifinset\v!line {#2}{\global\chardef\sidefloatalign\plustwo}% > \doifinset\v!depth {#2}{\global\chardef\sidefloatalign\plusthree}% > \doifinset\v!grid {#2}{\global\chardef\sidefloatalign4}% > \doifinset\v!halfline{#2}{\global\chardef\sidefloatalign5}% > meant for 'none' > \fi > \doifinset\v!high{#2}{\global\sidefloattopskip \zeropoint}% > \doifinset\v!low {#2}{\global\sidefloatbottomskip\zeropoint}% > \doifinset\v!fit {#2} > {\global\sidefloattopskip \zeropoint > \global\sidefloatbottomskip\zeropoint > \global\floatsideskip \zeropoint}% > \else > \processallactionsinset > [#2] > [ 90=>\globallet\floatrotation\commalistelement,% > 180=>\globallet\floatrotation\commalistelement,% > 270=>\globallet\floatrotation\commalistelement]% > \fi > \doifinsetelse\v!nonumber{#2} > {\global\nofloatnumbertrue} > {\doifelse{\floatcaptionparameter\c!number}\v!yes > {\global\nofloatnumberfalse} > {\global\nofloatnumbertrue}}% > \ConvertToConstant\doifelse{#4}{} > {\global\emptyfloatcaptiontrue} > {\global\emptyfloatcaptionfalse}% > \doifinsetelse\v!none{#2} > {\global\nofloatcaptiontrue} > {\ConvertToConstant\doifelse{#4}\v!none > {\global\nofloatcaptiontrue} > {\global\nofloatcaptionfalse}}% > \doif{\floatcaptionparameter\c!number}\v!none > {\global\nofloatcaptiontrue}% > \ifemptyfloatcaption \ifnofloatnumber > \global\nofloatcaptiontrue > \fi \fi} > > \protect > > \starttext > > \placefigure{}{} > > \setupcaptions[number=none] > > \placefigure{}{} > > \stoptext > > (I'll add that to the core, but only if you wikify it) and what is the difference in the output compared with my solution, the following works for me and I have no caption in the second figure. \starttext \placefigure{bla}{} \setupfloat[figure][default=none] \placefigure{bla}{} \stoptext Wolfgang ___________________________________________________________________________________ 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 ___________________________________________________________________________________