From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, HTML_MESSAGE,MAILING_LIST_MULTI,URIBL_SBL_A autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 16485 invoked from network); 12 Sep 2023 15:59:22 -0000 Received: from cgl.ntg.nl (5.39.185.202) by inbox.vuxu.org with ESMTPUTF8; 12 Sep 2023 15:59:22 -0000 Received: from localhost (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id 72EA2483099 for ; Tue, 12 Sep 2023 17:58:37 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at cgl.ntg.nl Received: from cgl.ntg.nl ([127.0.0.1]) by localhost (cgl.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id uG_qrb_SU2my for ; Tue, 12 Sep 2023 17:58:37 +0200 (CEST) Received: from cgl.ntg.nl (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id 312614830C3 for ; Tue, 12 Sep 2023 17:57:49 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id 1CED6482E55 for ; Tue, 12 Sep 2023 17:57:22 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at cgl.ntg.nl Received: from cgl.ntg.nl ([127.0.0.1]) by localhost (cgl.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id oe1G-EV9c2R5 for ; Tue, 12 Sep 2023 17:57:21 +0200 (CEST) Received: from CHE01-GV0-obe.outbound.protection.outlook.com (mail-gv0che01on2112.outbound.protection.outlook.com [40.107.23.112]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by cgl.ntg.nl (Postfix) with ESMTPS id 9CD96482DE5 for ; Tue, 12 Sep 2023 17:57:21 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=m3NlYZEi/khOtj3WTNHqmOzYBEYsWc90z0jee0tG2Ycinfc7g/XEZobGJ0VIVIcrWKqu4jnzre+d3Kva3h7Id8ZegSO2U2rt7MHLdcyD9y9XMaXT8yHph6wtL3HEwxMTl1O1Tc7aR2MC8Q47JHPTo2VzbATQvciIkWXC3LJHrO9AW6L2A4Jx7Sl4FW9Qm6G3aC8c4vChNnBml8f4Ez9vorJ1crxOFiwNT52skPqeLnELjHBO5WUBPufHndoJ67J9Vr3wHvRLiCmrs3MLe72RCBsZ3BCWwTYxtN4XoUs1/+zJ23DdFoZ42pPMyz1KTE3pT2601BYKVLxQKO82OzwByA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=SCgM3yelvMIP2TtTVWFSmp2mjCB/w4pHC/7hFHprDTk=; b=RjgTXlDd35feKdCBelsV7WqX2DrfVjbkB0ejQilnxNo+p10vNDJs/9QoeKsGgeghYVgsXvnaxpYYI/XiT2RlR7JoMjceeP0guJc2MC08bNxj4UJ1UQkRgnms5QOaM4hkGJMyL9aWpzyNhOHPkvRG7sADeHBbVikR+XEMNsTha0xivR23/vB8zgI2bj9RScrRrbbgfHgYvXCwE8SeT1OZCRzSBNyOj8Su0t/WLM1LaAr4ocWKzO4QQo54FxQ37wYEn8eFBxfdRKneVgJSoHIlKwNxzI3fX3nJUeQWBClaemNOLEfuHOyODl0Sv2PItNgRFD+ynWkJc0xX79CXx8eB5Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=unibe.ch; dmarc=pass action=none header.from=unibe.ch; dkim=pass header.d=unibe.ch; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=unibe.ch; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=SCgM3yelvMIP2TtTVWFSmp2mjCB/w4pHC/7hFHprDTk=; b=qK+KUZPjNPKBlvGP8z7zd6S5Dva01t23HKGuZ/HF/XG4A3StVhQa2QWCwFtliRUj84CDqx+hyBrnMpr8/XsDz1sHTkz53PEUqwQZ+BEb98msmhq1TbsyEmHumznl3LIeSc3sJ4iKMtgJowJlSLdNRfmUQtmF38DFnbtDgBZDd6ha6kimboTCQmPZzBjrppFdLSH7TLklsA7DWpcBKJg5uOve/bf/JYU81D4R5R0jjoLwcx7wPpSntPDYIRFzE8yEF1/FV2B68ladpQ2kbqaEocGjDLJH5fM9yv66GxNocwX/ObhSZOlUbD6SX2L3JZpboKzAjzxmsfoQGLVDnIMV4g== Received: from ZRAP278MB0495.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:2e::8) by ZRAP278MB0875.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:4a::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6768.35; Tue, 12 Sep 2023 15:57:20 +0000 Received: from ZRAP278MB0495.CHEP278.PROD.OUTLOOK.COM ([fe80::e676:cca3:8123:9797]) by ZRAP278MB0495.CHEP278.PROD.OUTLOOK.COM ([fe80::e676:cca3:8123:9797%2]) with mapi id 15.20.6768.036; Tue, 12 Sep 2023 15:57:20 +0000 From: To: Thread-Topic: Using structureuservariables before the heading Thread-Index: Adnli6zvCazPWV0rTeiRICxNQyFWqgABfOPw Date: Tue, 12 Sep 2023 15:57:19 +0000 Message-ID: References: In-Reply-To: Accept-Language: de-DE, en-US Content-Language: de-DE X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=unibe.ch; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: ZRAP278MB0495:EE_|ZRAP278MB0875:EE_ x-ms-office365-filtering-correlation-id: 0e6478cf-7038-4bb9-2b6e-08dbb3a8f212 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: gU8O9mBhmxbmxY+fe6rEdJDCBCbuhJz9QltNrWIHHE1sd199OwUnIATwXlOUdlFauW2s+RHG/uPpxk4/vIrkllsyMDkd0MSnNnow+3Si5ePAkNVyb96+8VejI9LcEX9Lg0IQy6xks6W9uWmZSW4BuPaUtUdEp8gIsoG9MwrVqdRpwtEmNuJd9OCn6VI4ncebusfiUtJKZ4pl+UiGUjjS2Sr7vm2NMGo34rsc1Sv2JlOmiHzFpcI1d4aAP3SrSJXytEkLI13VKZRIusfTXWLpDMjxjsSaZAaHRC5iEGzcyyqIjHH4sN1I44mGLt0EMVrTnSSRCkxMhGMNdJ+BlXYKn5NWn2+qMwXsrIRZ6U7/VDiXT5lWCD3CfTLi/FSo7pDXZsUsFso0QUQsWy8spVlzibhzZalqDLY0EYI8958NuOmCn2zBCgaqZ9NN2/XcMGKQ0eN1bMIa2XuBWWV9LNIzxKXDSVlmYyboVpDXZDeztbhEXDzO+UwyRfIPEq6NRSJs7/WAEeK8hROPA+DhusfvdV14+7shJ9pRDoZ0miiTLW/5cfDBVrhLfZf4ZjtHzMUdLQo3kOe0znm6ZNasvqPvpaiXLWZh+/qMWpe+4rktEBHpac/+uPYlm/julo9jswEI x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:ZRAP278MB0495.CHEP278.PROD.OUTLOOK.COM;PTR:;CAT:NONE;SFS:(13230031)(346002)(136003)(366004)(39860400002)(376002)(396003)(1800799009)(451199024)(186009)(6506007)(71200400001)(7696005)(9686003)(83380400001)(478600001)(66946007)(786003)(66476007)(6916009)(64756008)(8676002)(66446008)(66556008)(41300700001)(76116006)(52536014)(5660300002)(316002)(8936002)(2906002)(33656002)(86362001)(2940100002)(38100700002)(55016003)(38070700005)(122000001);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?jjIQOHm1nXc3BrEUebCUSL7Paa2k4ukfMV+6xyXwKj2QSTjar4ZX8dAd18FY?= =?us-ascii?Q?1r7AAlEVtwm0ot8y3vJeh6TbaTSFLOL46fmJbUpFsvRntOfA7GZsFFcGcEzu?= =?us-ascii?Q?Shv8Wfx4cDXSZW4HvVvVd4a3RUTpTN7LDdlF9cU4lN51fBYX74NI/+O3vMTP?= =?us-ascii?Q?SH/BYEfWVJtrLzVXr3qYLmbSqa9IeTOS02/PfzYpk9mk8dW8T6/cxjO9MDrW?= =?us-ascii?Q?6HfJ7mkfZW+/INSYlCy0BYmeE12i3okXS+a8QAAe5JnpRuzLzNjvPJntcRie?= =?us-ascii?Q?PMojwnxEF9G7a3tbCYMABo/MM5VT3P8sIaYbQEkIzO8c61PlPw8OR1IquNOd?= =?us-ascii?Q?FavIfwQmDENLv8TGyctZ8fa1evMvGSDmakmLAEwGqxHumJ8dbcGDli8c5Q5F?= =?us-ascii?Q?ngJWW7GuQtPwsjRfI4+vwDJ5v1qzFWa9NWcC+28BwoeNJDNzqXPzDnxWeQ/c?= =?us-ascii?Q?pfyw6KQ+aR5Pmws4YnsPSuIw5NI8cBWhWJGmh3RHnbsSs9apR2KatD7jTx/6?= =?us-ascii?Q?zy+T1tHOzSNfihdI9uk3Xu20ycHcSz6ZM9qcPZpZ0JkfVSc5djs4KrK8LpKb?= =?us-ascii?Q?8rtDG0ws9JR1JAjELGSbEIjllfupXKtfnv4Ygbp8zd3vygMJrd4QU6CfjZuF?= =?us-ascii?Q?cwyKiELDHZJXL81cUSoUoE5Gv0noKy3YSSqJuegdD7ycj8TKkPJalc/Kipgw?= =?us-ascii?Q?VatlV/qDECP6HIB/eqyEcGLaDDFC3cf0iDrbaCFA7BS+BZtFdSd93D12bMZb?= =?us-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sJTgiY+cJ?= MIME-Version: 1.0 X-OriginatorOrg: unibe.ch X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: ZRAP278MB0495.CHEP278.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-Network-Message-Id: 0e6478cf-7038-4bb9-2b6e-08dbb3a8f212 X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Sep 2023 15:57:20.0022 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: d400387a-212f-43ea-ac7f-77aa12d7977e X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: vPIZt4CoUcvHceBVPVShaGyBIbpresVIVmI6Fhh4rFGCEJ4CX4hvXWROI93P4wKTEkMkZyuNsHXLGH5vCAcBPQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: ZRAP278MB0875 Message-ID-Hash: MHXZOTNHS5EGCR75BZ7RUGXXHEAZA7VI X-Message-ID-Hash: MHXZOTNHS5EGCR75BZ7RUGXXHEAZA7VI X-MailFrom: denis.maier@unibe.ch X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.8 Precedence: list Reply-To: mailing list for ConTeXt users Subject: [NTG-context] Re: Using structureuservariables before the heading List-Id: mailing list for ConTeXt users Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: multipart/mixed; boundary="===============8364927700467526485==" --===============8364927700467526485== Content-Language: de-DE Content-Type: multipart/alternative; boundary="_000_ZRAP278MB0495A1784E69FA6F44A4F7D383F1AZRAP278MB0495CHEP_" --_000_ZRAP278MB0495A1784E69FA6F44A4F7D383F1AZRAP278MB0495CHEP_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Ok, \starttexdefinition allows blanks, apparently just like setups. But, it still fails exactly like the version with \def \setuphead[chapter][ before=3D{Before: \structureuservariable{author}\blank}, beforesection=3D{Beforesection: \structureuservariable{author}\blank}, insidesection=3D{Insidesection: \structureuservariable{author}\blank}, after=3D{After: \structureuservariable{author}\blank}, ] \def\myChapterCommand#1#2{\structureuservariable{author}\space\blank} \define[2]\myChapterCommand{\structureuservariable{author}\blank #1\space#2= } %\def\myChapterCommand#1#2{\structureuservariable{author}\blank #1\space#2}= % does not work % \starttexdefinition myChapterCommand #1 #2 % doesn't work either, but at = least blanks should work % \structureuservariable{author} % Test % \blank % #1\space#2 % \stoptexdefinition \starttext \myChapterCommand{1}{asdf} \startchapter[title=3DFirst][author=3DFirst Author] \input knuth \stopchapter \startchapter[title=3DSecond][author=3DSecond Author] \input knuth \stopchapter \setuphead[chapter] [ before=3D,after=3D,beforesection=3D,insidesection=3D, command=3D\myChapterCommand, ] \startchapter[title=3DThird][author=3D{Third Author}] \input knuth \stopchapter \stoptext Von: denis.maier@unibe.ch Gesendet: Dienstag, 12. September 2023 17:48 An: ntg-context@ntg.nl Betreff: [NTG-context] Using structureuservariables before the heading Hi, is it possible to access a structureuservariable before the heading's title= ? Using the key does not seem to work. As an aside, I've tried to use the < command > key to provide my own comman= d, but while \define works here (but ignores \blank), \def gives me an erro= r. Why is that? How would you add blanks to a user-defined command? Best, Denis \setuphead[chapter][ before=3D{Before: \structureuservariable{author}\blank}, beforesection=3D{Beforesection: \structureuservariable{author}\blank}, insidesection=3D{Insidesection: \structureuservariable{author}\blank}, after=3D{After: \structureuservariable{author}\blank}, ] \def\myChapterCommand#1#2{\structureuservariable{author}\space\blank} \define[2]\myChapterCommand{\structureuservariable{author}\blank #1\space#2= } %\def\myChapterCommand#1#2{\structureuservariable{author}\blank #1\space#2}= % does not work \starttext \macro{1}{2} \startchapter[title=3DFirst][author=3DFirst Author] \input knuth \stopchapter \startchapter[title=3DSecond][author=3DSecond Author] \input knuth \stopchapter \setuphead[chapter] [ before=3D,after=3D,beforesection=3D,insidesection=3D, command=3D\myChapterCommand, ] \startchapter[title=3DThird][author=3DThird Author] \input knuth \stopchapter \stoptext --_000_ZRAP278MB0495A1784E69FA6F44A4F7D383F1AZRAP278MB0495CHEP_ Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Ok, \starttexdefinition allows blanks, apparently ju= st like setups.

But, it still fails exactly like the version with \d= ef

 

 

\setuphead[chapter][=

    before=3D{Be= fore: \structureuservariable{author}\blank},

    beforesectio= n=3D{Beforesection: \structureuservariable{author}\blank},

    insidesectio= n=3D{Insidesection: \structureuservariable{author}\blank},

    after=3D{Aft= er: \structureuservariable{author}\blank},

    ]=

 

\def\myChapterCommand#1#2{\stru= ctureuservariable{author}\space\blank}

\define[2]\myChapterCommand{\st= ructureuservariable{author}\blank #1\space#2}

%\def\myChapterCommand#1#2{\str= uctureuservariable{author}\blank #1\space#2} % does not work

 

% \starttexdefinition myChapter= Command #1 #2 % doesn't work either, but at least blanks should work

%   \structureuservar= iable{author}

%   Test

%   \blank

%   #1\space#2

% \stoptexdefinition=

 

 

\starttext

 

\myChapterCommand{1}{asdf}=

 

\startchapter[title=3DFirst][au= thor=3DFirst Author]

\input knuth<= /p>

\stopchapter<= /p>

 

\startchapter[title=3DSecond][a= uthor=3DSecond Author]

\input knuth<= /p>

\stopchapter<= /p>

 

\setuphead[chapter]<= /span>

    [=

    before=3D,af= ter=3D,beforesection=3D,insidesection=3D,

    command=3D\m= yChapterCommand,

    ]

 

\startchapter[title=3DThird][author=3D{Third Author}= ]

\input knuth

\stopchapter

 

 

\stoptext

 

Von: denis.maier@unibe.ch <denis.maie= r@unibe.ch>
Gesendet: Dienstag, 12. September 2023 17:48
An: ntg-context@ntg.nl
Betreff: [NTG-context] Using structureuservariables before the headi= ng

 

Hi,

 

is it possible to access a stru= ctureuservariable before the heading’s title ?=

Using the «before» key does not seem to = work.

 

As an aside, I’ve tried to use the «&nbs= p;command » key to provide my own command, but while \define wor= ks here (but ignores \blank), \def gives me an error.

Why is that?

How would you add blanks to a u= ser-defined command?

 

Best,

Denis

 

 

 

\setuphead[chapter][=

    before=3D{Be= fore: \structureuservariable{author}\blank},

    beforesectio= n=3D{Beforesection: \structureuservariable{author}\blank},

    insidesectio= n=3D{Insidesection: \structureuservariable{author}\blank},

    after=3D{Aft= er: \structureuservariable{author}\blank},

    ]=

 

\def\myChapterCommand#1#2{\stru= ctureuservariable{author}\space\blank}

\define[2]\myChapterCommand{\st= ructureuservariable{author}\blank #1\space#2}

%\def\myChapterCommand#1#2{\str= uctureuservariable{author}\blank #1\space#2} % does not work

 

\starttext

\macro{1}{2}<= /p>

 

\startchapter[title=3DFirst][au= thor=3DFirst Author]

\input knuth<= /p>

\stopchapter<= /p>

 

\startchapter[title=3DSecond][a= uthor=3DSecond Author]

\input knuth<= /p>

\stopchapter<= /p>

 

\setuphead[chapter]<= /span>

    [=

    before=3D,af= ter=3D,beforesection=3D,insidesection=3D,

    command=3D\m= yChapterCommand,

    ]

 

\startchapter[title=3DThird][author=3DThird Author]<= o:p>

\input knuth<= /p>

\stopchapter<= /p>

 

 

\stoptext

--_000_ZRAP278MB0495A1784E69FA6F44A4F7D383F1AZRAP278MB0495CHEP_-- --===============8364927700467526485== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context webpage : https://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : https://contextgarden.net ___________________________________________________________________________________ --===============8364927700467526485==--