From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: from cgl.ntg.nl (Cgl.ntg.nl [5.39.185.202]) by inbox.vuxu.org (Postfix) with ESMTP id 38ED22203D for ; Wed, 5 Jun 2024 16:35:11 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id 3643F484D91 for ; Wed, 5 Jun 2024 16:34:10 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at cgl.ntg.nl Authentication-Results: cgl.ntg.nl (amavisd-new); dkim=fail (2048-bit key) reason="fail (message has been altered)" header.d=gmail.com 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 7U8YSSpJu68F for ; Wed, 5 Jun 2024 16:34:09 +0200 (CEST) Received: from cgl.ntg.nl (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id AEB56484D42 for ; Wed, 5 Jun 2024 16:33:39 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id 03D78484D16 for ; Wed, 5 Jun 2024 16:33:12 +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 Bym4SanBQPFU for ; Wed, 5 Jun 2024 16:33:11 +0200 (CEST) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=209.85.208.47; helo=mail-ed1-f47.google.com; envelope-from=wolfgang.schuster.lists@gmail.com; receiver= Received: from mail-ed1-f47.google.com (mail-ed1-f47.google.com [209.85.208.47]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by cgl.ntg.nl (Postfix) with ESMTPS id AC332484D14 for ; Wed, 5 Jun 2024 16:33:11 +0200 (CEST) Received: by mail-ed1-f47.google.com with SMTP id 4fb4d7f45d1cf-57a32b0211aso2956115a12.2 for ; Wed, 05 Jun 2024 07:33:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1717597991; x=1718202791; darn=ntg.nl; h=content-transfer-encoding:content-language:in-reply-to:mime-version :user-agent:date:message-id:from:references:to:subject:from:to:cc :subject:date:message-id:reply-to; bh=mad/utEUmBr+0AM0DzsE59njJ7Tvtd6SL5tU017asps=; b=bUufb25w8XPuTZhNVBXi9fEpfKZ0qg+NcXXTSgUoERNNCmjlv6VZrTKM6gisSmhyZ4 QTB2t5/EE85ogdllE3i1LhJbmEPUmbFtxyPPfr9QPKu46fG1izCIWjF8aqyu/XAebGCg 6Waaub42e+TYAn/DmmlJGhEnJskMZUmv43b/cm96EUwBlob19i9xUgvZOuhVcpKjK77a iu6h7tWE8PYgB1/afVgIXDx/Az5aQtd0Tw1WpeeEyBzrkJJ2/MBFP/vmA/09byDRCYfb Wg60/JdlL45AwgnDA33VSmaM0n/p4Xe+uT/G6e/S7V2UwJmiR01p9APDDYRrkLUbV+0D pg7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717597991; x=1718202791; h=content-transfer-encoding:content-language:in-reply-to:mime-version :user-agent:date:message-id:from:references:to:subject :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=mad/utEUmBr+0AM0DzsE59njJ7Tvtd6SL5tU017asps=; b=vU+DFDZTgRoMpfBW+WoP0XtpjG3VShAsnNkMiFsKSTBjpdGp2MurxfBXldC6rC/WCp zRrCMDzB8aY1mp7iXEUuk1XtWi4sqK3MC+u8XYNDK3Z16ELPmiZIgkazgfAnC/Yizeoz zQg3DYOl34UkzKExyuKncF/tZ3kosZYXCWWcnhtShqW0qvNs3T6tPxtMK3zXHT0LSRx3 Yo/JSNTJa+p+u5MAn5kWzIiWseNnWhM6jbG7H54PFvHrhNevAb2HrGGT0FsEtVMvFhBN dUN7XaZaXMC8wVJlCwZCEuWCgH/vBhsN5zBwayLJWtZj/kd6WV4W0t+ieU305pyl4Y0a yFVw== X-Gm-Message-State: AOJu0YzFp5y5BUIMB+oHyUdWtv1o4KHkJNu0uOj2utYdiLBRGy+Scg9D z3JaKKxc05bgIXL8xOz1Hvf3r9ZSDQSSbu4+52BemxaGoV30CzFLR/OamA== X-Google-Smtp-Source: AGHT+IGqSfuKyExmhxL1/omyzhqkBGeu/AweTDAFy2vrtmP137J69FYup46NoetesBc29aEcMaLG0A== X-Received: by 2002:a17:906:4091:b0:a68:f1ca:db46 with SMTP id a640c23a62f3a-a699ffffd0amr167330066b.64.1717597990865; Wed, 05 Jun 2024 07:33:10 -0700 (PDT) Received: from ?IPv6:2a02:810d:a8bf:dc10::7141? ([2a02:810d:a8bf:dc10::7141]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a69127f2901sm427579066b.48.2024.06.05.07.33.10 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 05 Jun 2024 07:33:10 -0700 (PDT) To: mailing list for ConTeXt users , ai2472206007@yeah.net References: <171759621230.1996.13485003071861472801@cgl.ntg.nl> From: Wolfgang Schuster Message-ID: <4633504f-68b7-c26f-38a1-135f4e1f2ba9@gmail.com> Date: Wed, 5 Jun 2024 16:33:08 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 PostboxApp/7.0.60 MIME-Version: 1.0 In-Reply-To: <171759621230.1996.13485003071861472801@cgl.ntg.nl> Content-Language: en-US Message-ID-Hash: XS5UK6FT27CY6R6FQZTFTCAMFWFMFD5X X-Message-ID-Hash: XS5UK6FT27CY6R6FQZTFTCAMFWFMFD5X X-MailFrom: wolfgang.schuster.lists@gmail.com 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: After using a custom command in the title, the table of contents is not generated properly List-Id: mailing list for ConTeXt users Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii"; format="flowed" Content-Transfer-Encoding: 7bit ai2472206007@yeah.net schrieb am 05.06.2024 um 16:03: > As described, here is example: > > %%%%% > \def\cmd#1{{\tt\textslash #1}} > \def\cmdii#1{\tt #1} > \def\cmdiii#1{\rm #1} You can use \definehighlight to create a custom command for a style. The case where you want a slash before the text you have to use \definestartstop which allows you to set something before and after \definestartstop [cmdi] [style=\tt,left=\textslash] \definehighlight [cmdii] [style=\tt] \definehighlight [cmdiii] [style=\rm] Wolfgang ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl webpage : https://www.pragma-ade.nl / https://context.aanhet.net (mirror) archive : https://github.com/contextgarden/context wiki : https://wiki.contextgarden.net ___________________________________________________________________________________