From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Visuwesh Newsgroups: gmane.emacs.bugs Subject: bug#58376: [PATCH] Set the PARENTS argument for language environments Date: Sun, 09 Oct 2022 20:36:16 +0530 Message-ID: <87sfjxox3r.fsf@gmail.com> References: <83wn9ajrud.fsf@gnu.org> <83tu4eji4l.fsf@gnu.org> <83edvhjt76.fsf@gnu.org> <838rlpjfmr.fsf@gnu.org> <87wn99oxtv.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30011"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: =?UTF-8?Q?=E0=A4=B8=E0=A4=AE=E0=A5=80=E0=A4=B0_?= =?UTF-8?Q?=E0=A4=B8=E0=A4=BF=E0=A4=82=E0=A4=B9?= Sameer Singh , 58376@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Oct 09 17:07:11 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ohXtX-0007bW-IC for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 09 Oct 2022 17:07:11 +0200 Original-Received: from localhost ([::1]:57920 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ohXtW-0006wo-4Z for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 09 Oct 2022 11:07:10 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58674) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohXtO-0006w2-VR for bug-gnu-emacs@gnu.org; Sun, 09 Oct 2022 11:07:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:45667) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ohXtN-0005H3-TS for bug-gnu-emacs@gnu.org; Sun, 09 Oct 2022 11:07:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ohXtN-0001LV-O7 for bug-gnu-emacs@gnu.org; Sun, 09 Oct 2022 11:07:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Visuwesh Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 09 Oct 2022 15:07:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 58376 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 58376-submit@debbugs.gnu.org id=B58376.16653279895134 (code B ref 58376); Sun, 09 Oct 2022 15:07:01 +0000 Original-Received: (at 58376) by debbugs.gnu.org; 9 Oct 2022 15:06:29 +0000 Original-Received: from localhost ([127.0.0.1]:44745 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohXsq-0001Kk-PE for submit@debbugs.gnu.org; Sun, 09 Oct 2022 11:06:29 -0400 Original-Received: from mail-pj1-f67.google.com ([209.85.216.67]:38632) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ohXso-0001KX-Gg for 58376@debbugs.gnu.org; Sun, 09 Oct 2022 11:06:26 -0400 Original-Received: by mail-pj1-f67.google.com with SMTP id x1-20020a17090ab00100b001fda21bbc90so11122981pjq.3 for <58376@debbugs.gnu.org>; Sun, 09 Oct 2022 08:06:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8GGVKQ/lY73q/fUSDAMNRn5P51pXauUpCpbpb10QkQA=; b=AXqRB+GysWwjiB0jwOU0Io/N+DI2Ijs/jDRmRhgAIwLsun4Oyk9qb2KImWxONEnyV/ J80SP6ybMo3BGUbhom7zLk3o7qjE4dloXPLpNPh2PbkQuuPFmhkFB+1PFcado7ekBzFS sZPHhB3MYHN8AcfWg72aLHLA8OPDpI1lhoFBFG69bCRG61tLjaQVudkxagc7pH+SnsfR UYyK+QqWXl1jKXoe5zV9H1gBR+Yn642rYO1YKd9bOmbvesX0GsuwR312oAP6w1tY7C/8 zWYGA485/+x34LbUGfjbGsCvNAVlUF4YsdRcgHSzHE+UJOT0RPTpcFcWTEaOglFAUoti 2VWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=8GGVKQ/lY73q/fUSDAMNRn5P51pXauUpCpbpb10QkQA=; b=xsgj1FFiTU4PLIRheZ6EFKcSBxYJXJBqWWWzfNAq5AkVyxbEajDCuSGyz/ChMHP/x0 IMPRoa/KzdRv0VPCM/Y61vHElt2ix6IcrDO8jXkFqgtlIcV6IfOlNsKF4Rb4XJhMKJXZ wFBMvGIu2J+vYDjhilucMuVZqv38+yKzaizcE9nA0zSgpaHNX76pEvEmfBjACNy7hB+g w38tKRHDg/Sk5YRIYRGHUWL6W87c6f1aNQr6LfRwLeeCzRAKOS0okCChUoc2kaS/IgpS ETblO83eYSlGEvoepCYjJUofgwzb54ZB4Ni0eKH0izQ8cSPw1gRjV7bYoeF+3K82gMdp hvog== X-Gm-Message-State: ACrzQf3ASl/oyCYi4nAdnzwHLef5Mv0bRcTsV24PaANDG/PCFOixhJvd ikqLuU8P5sWs/ICVvUWyd2Q= X-Google-Smtp-Source: AMsMyM4oHvEKmBfbeFREWCl7j5BjvfltcDvnGXJQ91MGoGyOtE/qZf0u8ciLprip4PsLhqh5uu9WYg== X-Received: by 2002:a17:90b:1c90:b0:203:b7b4:b1cf with SMTP id oo16-20020a17090b1c9000b00203b7b4b1cfmr27855060pjb.160.1665327980653; Sun, 09 Oct 2022 08:06:20 -0700 (PDT) Original-Received: from localhost ([115.240.90.130]) by smtp.gmail.com with ESMTPSA id l64-20020a622543000000b0053e38ac0ff4sm5060132pfl.115.2022.10.09.08.06.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 09 Oct 2022 08:06:19 -0700 (PDT) In-Reply-To: <87wn99oxtv.fsf@gmail.com> (Visuwesh's message of "Sun, 09 Oct 2022 20:20:36 +0530") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:244966 Archived-At: [=E0=AE=9E=E0=AE=BE=E0=AE=AF=E0=AE=BF=E0=AE=B1=E0=AF=81 =E0=AE=85=E0=AE=95= =E0=AF=8D=E0=AE=9F=E0=AF=8B=E0=AE=AA=E0=AE=B0=E0=AF=8D 09, 2022] Visuwesh w= rote: > [=E0=AE=9E=E0=AE=BE=E0=AE=AF=E0=AE=BF=E0=AE=B1=E0=AF=81 =E0=AE=85=E0=AE= =95=E0=AF=8D=E0=AE=9F=E0=AF=8B=E0=AE=AA=E0=AE=B0=E0=AF=8D 09, 2022] Eli Zar= etskii wrote: > >>> If I do something like: >>>=20 >>> (set-language-info-alist >>> "Kharoshthi" '((charset unicode) >>> (coding-system utf-8) >>> (coding-priority utf-8) >>> (input-method . "kharoshthi") >>> (sample-text . "Kharo=E1=B9=A3=E1=B9=ADh=C4=AB (=F0=90= =A8=91=F0=90=A8=AA=F0=90=A8=86=F0=90=A8=9B=F0=90=A8=81) =F0=90=A8=A3=F0=90= =A8=A8=F0=90=A8=B2=F0=90=A8=AA=F0=90=A8=86 =F0=90=A8=90=F0=90=A8=AA=F0=90= =A8=85=F0=90=A8=A8=F0=90=A8=81") >>> (documentation . "\ >>> Language environment for G=C4=81ndh=C4=81r=C4=AB, Sanskrit, and other l= anguages >>> using the Kharo=E1=B9=A3=E1=B9=ADh=C4=AB script.")) >>> '("Misc" "Indian")) >>>=20 >>> Then compile and open emacs -Q >>> Now opening Options>Multilingual Environment>Set Language Environment>I= ndian >>> It only has the Kharoshthi entry >>> Options>Multilingual Environment>Set Language Environment>Misc now also= has an Indian submenu with >>> only Kharoshthi entry. >> >> Hmm... Either we don't understand what PARENTS mean (could it mean >> a >> hierarchy of several menu levels?), or there is a bug. >> >> If you want to work on that, please do; otherwise I'll just install >> your original patch. > > Attached patch puts the "Kharosthi" item in both Indian and Misc > submenus without overwriting. > > > > The problem is that when looping, the variables setup-map and > describe-map gets outdated and causes the overwrite. The solution I > came up with was to update them both to their default after each > iteration. This involved moving the keymap-setting forms to a > separate > function. Hmm, I seethat the function can be cleaned up further. I will do it after my dinner.