From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/116949 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: jbf via ntg-context Newsgroups: gmane.comp.tex.context Subject: how to change metadata halfway through document Date: Mon, 30 Jan 2023 11:14:41 +1100 Message-ID: <2bccdafe-3c8c-bb05-6fce-9e8fc012ea74@gmail.com> Reply-To: mailing list for ConTeXt users Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============4860910554764495517==" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22569"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2 Cc: jbf To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon Jan 30 01:15:21 2023 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane-mx.org Original-Received: from zapf.boekplan.nl ([5.39.185.232] helo=zapf.ntg.nl) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pMHpQ-0005fl-Nn for gctc-ntg-context-518@m.gmane-mx.org; Mon, 30 Jan 2023 01:15:20 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 126D93800C7; Mon, 30 Jan 2023 01:14:53 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id giYGKx1kNIiv; Mon, 30 Jan 2023 01:14:51 +0100 (CET) Original-Received: from zapf.ntg.nl (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 24346380863; Mon, 30 Jan 2023 01:14:51 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 62AF83800C7 for ; Mon, 30 Jan 2023 01:14:49 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zzw3W6eZRHFN for ; Mon, 30 Jan 2023 01:14:48 +0100 (CET) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=209.85.214.175; helo=mail-pl1-f175.google.com; envelope-from=roma83537@gmail.com; receiver= Original-Received: from mail-pl1-f175.google.com (mail-pl1-f175.google.com [209.85.214.175]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by zapf.ntg.nl (Postfix) with ESMTPS id 68AA210AC for ; Mon, 30 Jan 2023 01:14:48 +0100 (CET) Original-Received: by mail-pl1-f175.google.com with SMTP id b5so2721483plz.5 for ; Sun, 29 Jan 2023 16:14:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=subject:from:to:content-language:user-agent:mime-version:date :message-id:from:to:cc:subject:date:message-id:reply-to; bh=sR/1GnY0WM2lgUC1f8lHX1XK1tf/qdutT5ifZOrhb2c=; b=icTYZUg3RX8p6F7uQNw6n9+PjVmgo4aPnifepmsujRB5HZJpjrBXaK+BJFUM2xmM9m 0IlL16jQf6jbqZyTH1wgiYMGJWvPT7IWmoMdG1MsWEPrr3vBDvQOPY7z76pOAuFrWgA6 geH8Cbb+qUNJysIT5MeVMjChYiyw7fRu4ED+HjHsgQ9Uy2rgZsqprTitG6B5ELDHuWLJ kywVnnTFYPIJWmpdL0S8q50Wcc0UhlY3DMNnzMNIoWLCo2NvMYVIWng0uSED8Fnnz3E2 th1CskZDCmPl22rr47wftWSWDOLSpf2VjY6EpzD0mWUJiyRN0Rnv4gzRz1F9euQgBXU6 yaSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=subject:from:to:content-language:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=sR/1GnY0WM2lgUC1f8lHX1XK1tf/qdutT5ifZOrhb2c=; b=zR6BXQC36FARMmcYFfVO11pu1rBxr82aergcrEGhtUw1A5S0py0oX2c2OyQc6/l+6O VdwpYIjjMBrhbONuSt4+MPdDewyYucv/bTi3vro8+NQq3uVJmJPFiAZCYFrG/AnX2bjP r1jOsPfCzrtWQg8PUoOJL7BTqqnyWELhQ/H6YvxVJBIz6Wk8IRIZvxA43THKGR2p0Hre oEMInlBXLzesEQ5n/t89VjxgRjuGTfh6swWxHt8jZ/XNvsAuOnwu/+XI2rpuUzVdv78u icQKQMFDANwfQyjyIl7nihLrMaJT5VmAfqws7Wlps9CqzUGIdkz2EHGAe3HQOqb0cKM2 Z8/A== X-Gm-Message-State: AO0yUKWcfqUZBmz9mIbeicg+zIMB+LFCULH6g6nB+NCxafxYo35G5P1D avcj1S0kMs+4FuF9ctvAMotTXonrksQ= X-Google-Smtp-Source: AK7set+GbHghicFH0Sq4Qd9chMfo+DcSZEqUuQqvH25DPV2fnBSh0RCn+f9UxABiP9agdQuov2GyAg== X-Received: by 2002:a05:6a20:3ca1:b0:bd:14f4:7add with SMTP id b33-20020a056a203ca100b000bd14f47addmr1774152pzj.46.1675037686038; Sun, 29 Jan 2023 16:14:46 -0800 (PST) Original-Received: from ?IPV6:2405:6e00:490:baf6:7a9e:bfeb:31e0:e4e6? ([2405:6e00:490:baf6:7a9e:bfeb:31e0:e4e6]) by smtp.gmail.com with ESMTPSA id t6-20020a63b246000000b00499a90cce5bsm5784626pgo.50.2023.01.29.16.14.44 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 29 Jan 2023 16:14:45 -0800 (PST) Content-Language: en-US X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.26 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: "ntg-context" Xref: news.gmane.io gmane.comp.tex.context:116949 Archived-At: This is a multi-part message in MIME format. --===============4860910554764495517== Content-Type: multipart/alternative; boundary="------------rh6Jo72otawKLjNqq0Pl072r" Content-Language: en-US This is a multi-part message in MIME format. --------------rh6Jo72otawKLjNqq0Pl072r Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Am trying to understand how best to change the title metadata in headertext halfway through a document that has two parts: Constitutions and Regulations. My first attempt (did not work) \startsetups[headertext] \startdocument [metadata:title={Regulations}] \stopsetups \setupheadertexts [ ] [{\getmarking[chapter]\hskip1em \pagenumber}] [{\pagenumber \hskip1em \setup{headertext}}] [ ] My second attempt (quite crass, but it works!!) was to create a second \startdocument within the main \startdocument (obviously closing it towards the end but before the main \stopdocument), this time with [metadata:title={Regulations}] instead of the original [metadata:title={Constitutions}]. However, I have a strong feeling this is not a very elegant solution! Thoughts? Julian --------------rh6Jo72otawKLjNqq0Pl072r Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Am trying to understand how best to change the title metadata in headertext halfway through a document that has two parts: Constitutions and Regulations.

My first attempt (did not work)

\startsetups[headertext]

\startdocument

[metadata:title={Regulations}]

\stopsetups

\setupheadertexts

[ ] [{\getmarking[chapter]\hskip1em \pagenumber}]

[{\pagenumber \hskip1em \setup{headertext}}] [ ]

My second attempt (quite crass, but it works!!) was to create a second \startdocument within the main \startdocument (obviously closing it towards the end but before the main \stopdocument), this time with [metadata:title={Regulations}] instead of the original [metadata:title={Constitutions}]. However, I have a strong feeling this is not a very elegant solution!

Thoughts?

Julian

--------------rh6Jo72otawKLjNqq0Pl072r-- --===============4860910554764495517== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cHM6Ly93d3cubnRnLm5sL21haWxtYW4v bGlzdGluZm8vbnRnLWNvbnRleHQKd2VicGFnZSAgOiBodHRwczovL3d3dy5wcmFnbWEtYWRlLm5s IC8gaHR0cDovL2NvbnRleHQuYWFuaGV0Lm5ldAphcmNoaXZlICA6IGh0dHBzOi8vYml0YnVja2V0 Lm9yZy9waGcvY29udGV4dC1taXJyb3IvY29tbWl0cy8Kd2lraSAgICAgOiBodHRwczovL2NvbnRl eHRnYXJkZW4ubmV0Cl9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fCg== --===============4860910554764495517==--