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.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS,HTML_MESSAGE, MAILING_LIST_MULTI 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 7EF5623370 for ; Mon, 4 Nov 2024 16:55:35 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id 21255484BF0 for ; Mon, 4 Nov 2024 16:53:14 +0100 (CET) Authentication-Results: cgl.ntg.nl (amavisd-new); dkim=pass (1024-bit key) reason="pass (just generated, assumed good)" header.d=ntg.nl DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ntg.nl; h= content-type:content-type:list-unsubscribe:list-subscribe :list-post:list-owner:list-help:list-archive:archived-at:list-id :subject:subject:reply-to:precedence:in-reply-to:from:from :content-language:references:user-agent:mime-version:date:date :message-id:received:received:received:received:received :received; s=cgl; t=1730735593; x=1733327594; bh=xI6Jq/lMKpEL4G7 zhfrPvC03LvJcvE77Pjw7tBGmXpM=; b=PNTCAwVd7tt9pwSaf9vdbVOn3ILUCMu 1Oc+nae75t7wlB4OCBJCJo5MEdIVMyVcFJoGBEtBHbjE30KbEUXqfnN3AjmvSQtM nZA4vGQ8HBDRTuDfsZupZ+M0lKv1cfk64Hlr73uZDAzpBMnMA8NHdx770Rst/ZH8 UMWoZy+dczIM= 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 o4HqgH47jtk2 for ; Mon, 4 Nov 2024 16:53:13 +0100 (CET) Received: from cgl.ntg.nl (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id EB497484D71 for ; Mon, 4 Nov 2024 16:52:07 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by cgl.ntg.nl (Postfix) with ESMTP id A839A484A25 for ; Mon, 4 Nov 2024 16:51:23 +0100 (CET) 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 OREKjY09OoKl for ; Mon, 4 Nov 2024 16:51:22 +0100 (CET) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=166.84.1.89; helo=mailbackend.panix.com; envelope-from=context@rik.users.panix.com; receiver= Received: from mailbackend.panix.com (mailbackend.panix.com [166.84.1.89]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 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 4FA0F484A0E for ; Mon, 4 Nov 2024 16:51:22 +0100 (CET) Received: from [192.168.5.71] (syn-024-194-002-237.res.spectrum.com [24.194.2.237]) by mailbackend.panix.com (Postfix) with ESMTPSA id 4Xhwtc56v9z4dDM for ; Mon, 4 Nov 2024 10:51:20 -0500 (EST) Message-ID: <8cf8a268-9e1d-41fb-a345-bac6fcae47d7@rik.users.panix.com> Date: Mon, 4 Nov 2024 10:51:20 -0500 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Beta To: ntg-context@ntg.nl References: <9169ea95-51e5-4fd3-ae09-076037570800@rik.users.panix.com> Content-Language: en-US From: Rik Kabel In-Reply-To: Message-ID-Hash: ORUALINRX4AS7KV3CRHWOBFVGQDC35IA X-Message-ID-Hash: ORUALINRX4AS7KV3CRHWOBFVGQDC35IA X-MailFrom: ConTeXt@rik.users.panix.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.9 Precedence: list Reply-To: mailing list for ConTeXt users Subject: [NTG-context] Re: Zigzag left margin with italics 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="===============6460139153719935220==" This is a multi-part message in MIME format. --===============6460139153719935220== Content-Type: multipart/alternative; boundary="------------r5kgGFphCRSMcAyG57KlJeF4" Content-Language: en-US This is a multi-part message in MIME format. --------------r5kgGFphCRSMcAyG57KlJeF4 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 2024-11-04 01:35, Mikael Sundqvist wrote: > \startluacode > > local classes = fonts.protrusions.classes > local vectors = fonts.protrusions.vectors > > classes.rik = { > vector = 'rik', > factor = 1, > } > > vectors.rik = table.merged ( > vectors.quality, > { > [0x0054] = { 0.35, 0 }, -- T > }) > > \stopluacode That, of course, works (I would use 0.175 for Libertinus) but as you point out does not distinguish roman and italic. Perhaps instead of protrusion there is something that can be done with the bounding box of specific characters. -- Rik --------------r5kgGFphCRSMcAyG57KlJeF4 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit


On 2024-11-04 01:35, Mikael Sundqvist wrote:
\startluacode

local classes = fonts.protrusions.classes
local vectors = fonts.protrusions.vectors

classes.rik = {
    vector = 'rik',
    factor = 1,
}

vectors.rik = table.merged (
    vectors.quality,
    {
      [0x0054] = { 0.35, 0 }, -- T
    })

\stopluacode

That, of course, works (I would use 0.175 for Libertinus) but as you point out does not distinguish roman and italic.

Perhaps instead of protrusion there is something that can be done with the bounding box of specific characters.

--
Rik

--------------r5kgGFphCRSMcAyG57KlJeF4-- --===============6460139153719935220== 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://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 ___________________________________________________________________________________ --===============6460139153719935220==--