From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.help Subject: Re: Bookmarks in EWW Date: Wed, 25 Mar 2020 10:06:57 -0400 Message-ID: References: <878sjrfh2m.fsf@mbork.pl> <871rpipzwa.fsf@web.de> <87tv2d3zii.fsf@web.de> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="73280"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: help-gnu-emacs@gnu.org To: Michael Heerdegen Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Wed Mar 25 15:07:27 2020 Return-path: Envelope-to: geh-help-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 1jH6gp-000IwJ-C2 for geh-help-gnu-emacs@m.gmane-mx.org; Wed, 25 Mar 2020 15:07:27 +0100 Original-Received: from localhost ([::1]:36868 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jH6go-0000xH-Dk for geh-help-gnu-emacs@m.gmane-mx.org; Wed, 25 Mar 2020 10:07:26 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:60192) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jH6gQ-0000vl-9t for help-gnu-emacs@gnu.org; Wed, 25 Mar 2020 10:07:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jH6gO-0007s6-Qr for help-gnu-emacs@gnu.org; Wed, 25 Mar 2020 10:07:01 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:44117) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1jH6gO-0007r5-KV for help-gnu-emacs@gnu.org; Wed, 25 Mar 2020 10:07:00 -0400 Original-Received: from pmg1.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id C927A100492; Wed, 25 Mar 2020 10:06:59 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id 205F810040C; Wed, 25 Mar 2020 10:06:58 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1585145218; bh=Rppc+SvYpkqEGhG/ISie8iCrySCTzCchwW8YJ29QslI=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=oOMBFTJu02883LX17qpxahB9t5kIUUwdIWe0Kvz7OAcEaqs5JfJztJN21OmuUo8vt fTvBQXukExLU4GTuRwKjZclINkhZXIb7+MRi1/iMUNsg07P1OngYfUSjuu9LZ2IEEC VRNnHqvvBKtXwfyyhBkRLIdtVfMzxynUAoqFcOali2Cd19w9/WHg9ZXnKJfYfMRY4x KbMyip+Zvnu0BGINVBmovRJ9Bdg1a4xRvU3DnekFZw2sjHupPFjOVJW00PDqldHF59 wgGF1BL7bNE9Gy6svan4TG3kBTf2+/6wwu/xoib3K1U8WgBBXapxRcQcJIFeHUatHK SVfeMW1uXe1ow== Original-Received: from alfajor (unknown [104.247.241.114]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id C481D1200DF; Wed, 25 Mar 2020 10:06:57 -0400 (EDT) In-Reply-To: <87tv2d3zii.fsf@web.de> (Michael Heerdegen's message of "Wed, 25 Mar 2020 04:05:25 +0100") X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 132.204.25.50 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:122655 Archived-At: > Ok, I've thrown something together (draft!) and tested quickly: Thanks. > + ;; Emacs bookmarks support > + (defvar bookmark-make-record-function) > + (setq-local bookmark-make-record-function #'eww-bookmark-make-record) No need for the `defvar` here. > Does it make sense that these bookmarks save a text part? Surely makes > sense for some cases, e.g. locally saved documentation in html, but > makes not much sense for e.g. newspaper sites. As you say, it's useful for pages which don't change (or not much), and it should be harmless for those pages that change too frequently. > Do I need to declare `bookmark-make-record-function' as special when > setting with `setq-local' (that's what doc-view does)? No. buffer-localness is a concept that only applies to dynamically scoped variables anyway, so if you need it it's a sign that we should improve something somewhere. > Do I have to add a NEWS entry? I think it deserves a mention, yes. Stefan