From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Robert Pluim Newsgroups: gmane.emacs.bugs Subject: bug#73175: 30.0.60; toggling emacs-news-view-mode doesn't remove buttons Date: Tue, 24 Sep 2024 17:59:23 +0200 Message-ID: <877cb1dov8.fsf@gmail.com> References: <87y13yle65.fsf@gmail.com> <86y13m6esa.fsf@mail.linkov.net> <87o74ihfce.fsf@gmail.com> <874j6ah4mi.fsf@gmail.com> <86setpd07a.fsf@mail.linkov.net> <87o74de6wm.fsf@gmail.com> <86frppdys5.fsf@gnu.org> 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="29070"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 73175@debbugs.gnu.org, juri@linkov.net To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Sep 24 18:11:06 2024 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 1st882-0007N7-DX for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 24 Sep 2024 18:11:06 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1st87i-0000sl-HQ; Tue, 24 Sep 2024 12:10:47 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1st87a-0000sF-S1 for bug-gnu-emacs@gnu.org; Tue, 24 Sep 2024 12:10:40 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1st87Z-0001Js-LG for bug-gnu-emacs@gnu.org; Tue, 24 Sep 2024 12:10:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=nq26wywjUxclFr0pUrIg26m58POZYzUq80OjrU0kWqs=; b=fJgO6P7m8+QF/MEdNtOJ8GLopjH9E/wgC2VIyOlGc4fn2RFqr471zEv5i0e4tCybdymRAyJm8WSVVlTUOKjUjvyKn9F5WDOrYwlDBBppbRdyzC0Kr5EvLeJ2ijPoVWPy+n3n3QHJJrEghDQqNRu6CUxxOGqxK2SDtXK//5ErZrRg0eeW0cicV1zPuaoI0Y2P8Ba5pA9E44SetCMXBTH2mNxVZfhrNLnMyv/Cl5+5IXZeEIeDzWUm4KDHmm3viaiVTi/m9mqASFxqHVBXq4+3xH9IwOCBI9PYndKuJ5N3KfIi8lPoYLid3a+hyXAmZjOvNouORqMjOmgeav2LpWfQ7A==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1st87x-0003tI-Uk for bug-gnu-emacs@gnu.org; Tue, 24 Sep 2024 12:11:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Robert Pluim Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 24 Sep 2024 16:11:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 73175 X-GNU-PR-Package: emacs Original-Received: via spool by 73175-submit@debbugs.gnu.org id=B73175.172719421914318 (code B ref 73175); Tue, 24 Sep 2024 16:11:01 +0000 Original-Received: (at 73175) by debbugs.gnu.org; 24 Sep 2024 16:10:19 +0000 Original-Received: from localhost ([127.0.0.1]:52187 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1st879-0003if-0s for submit@debbugs.gnu.org; Tue, 24 Sep 2024 12:10:19 -0400 Original-Received: from mail-wr1-f49.google.com ([209.85.221.49]:43281) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1st7yB-00035p-Ph for 73175@debbugs.gnu.org; Tue, 24 Sep 2024 12:00:57 -0400 Original-Received: by mail-wr1-f49.google.com with SMTP id ffacd0b85a97d-37a413085cbso3076979f8f.1 for <73175@debbugs.gnu.org>; Tue, 24 Sep 2024 09:00:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1727193565; x=1727798365; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:from:to:cc:subject:date:message-id :reply-to; bh=nq26wywjUxclFr0pUrIg26m58POZYzUq80OjrU0kWqs=; b=bxHx0t1RB9dG6p7k6AwGPf5KcGflPZ9TNHWYicVN7t2M02cH94gLjF+XVrzQP1XBhS ja1YX+8m/M2mtPlWmWy9AZqEmZwDSITGregkv7PcRa9ExMWtJ6Y5Mpyl69lnE0DsMsUa lvqKbc9tvQi7iQti3I522EhPA3yhyjJNLFY5UZQHZaaFS2zAvJOeCe0U3Ev77AmqcPTy B4FjXp0c9Bm+NenuCBuwayTSZVv3NhmsqlEVEHUIlRFbRX16y5uaC2TIH6tTWh9EL7mz Qo+2hTJA4JC9vt69lNU1ytYOmWrz5JOsjz5PUluR2mx9UNWDDLqWanlBKlw35QvU5wKE xtfg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1727193565; x=1727798365; h=content-transfer-encoding:mime-version: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=nq26wywjUxclFr0pUrIg26m58POZYzUq80OjrU0kWqs=; b=g41UB/2tDUpQzbkpkFVaZ5B+rEZovSkAXQgLapLy9LPnggcgmUSRZrTlnrSGjL+/Wg RoOboRMIwYzstMMDCZ1nXiWA166JyZcVwW83A0j7ebAIkZOzcLM1w5mbnVNJqAXEAWQJ H9uEQA4P0qKh5VmaY34UXpd00u5RdKdFJ4G7fkTOt/hjTGy9tERIeDAyL5AqZlms+LvT STHs2Hkwk1bhJ5gSAjxQS5I4lKsdQw+PGqObQJ7O3mdnI3K4DNcTz9C1Z8x3nctNA+lO tOi9s8AwpYcMwJfE8zo0+rAxLwvORgV5+48bW5ncE29D3AHH5V4WexeRrfidqSmZiNGF C8Jw== X-Gm-Message-State: AOJu0YwhsVz0vY0izwlrfAVpRWhmr1IkrRPJbS9jzm2cEZnVwGmynp3o bQ/gAeYbNamabMoMsUQPj0hpUCK7LDKCtuuDbSCgYtjNBkineWEBByC9fA== X-Google-Smtp-Source: AGHT+IGyPe/wWrBhTVD0WES5gZ1/s0o9OEzdOck4VXuHcZ4Rxn7EfLfaejSkNxhiGzS+hiuMGAr3kg== X-Received: by 2002:adf:fd4b:0:b0:374:cee6:c298 with SMTP id ffacd0b85a97d-37c84e3eef8mr2214035f8f.21.1727193564543; Tue, 24 Sep 2024 08:59:24 -0700 (PDT) Original-Received: from rltb ([2a01:e0a:3f3:fb51:84a5:f5c1:da9c:5ef]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42e754c643csm160842915e9.45.2024.09.24.08.59.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Sep 2024 08:59:24 -0700 (PDT) In-Reply-To: <86frppdys5.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 24 Sep 2024 15:25:14 +0300") 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:292348 Archived-At: >>>>> On Tue, 24 Sep 2024 15:25:14 +0300, Eli Zaretskii said: >> Cc: 73175@debbugs.gnu.org >> From: Robert Pluim >> Date: Tue, 24 Sep 2024 11:29:45 +0200 >>=20 >> Hmm, `buttonize-region' isn=CA=BCt in the elisp manual. I=CA=BCm ass= uming >> emacs-30 is still open for documentation changes Eli> Yes, thanks. OK. Done. I=CA=BCve just remembered that button.el can use either overlays or text properties to make buttons, so `unbuttonize-region' should look like this: (defun unbuttonize-region (start end) "Remove all the buttons between START and END. This removes both text-property and overlay based buttons." (dolist (o (overlays-in start end)) (when (overlay-get o 'button) (delete-overlay o))) (with-silent-modifications (remove-text-properties start end (button--properties nil nil nil)) (add-face-text-property start end 'button nil))) Robert --=20