From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#32281: shr.el align support patch Date: Tue, 07 Aug 2018 18:07:50 +0300 Message-ID: <83bmaeqkop.fsf@gnu.org> References: <6177421532613989@iva7-bd007c44f58e.qloud-c.yandex.net> <87wot4xl3g.fsf@gmail.com> <83bmafsf3l.fsf@gnu.org> <4760541533603112@sas1-890ba5c2334a.qloud-c.yandex.net> NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1533654478 18427 195.159.176.226 (7 Aug 2018 15:07:58 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 7 Aug 2018 15:07:58 +0000 (UTC) Cc: npostavs@gmail.com, 32281@debbugs.gnu.org To: Bad Blue Bull Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Aug 07 17:07:54 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fn3aR-0004fM-FK for geb-bug-gnu-emacs@m.gmane.org; Tue, 07 Aug 2018 17:07:51 +0200 Original-Received: from localhost ([::1]:39514 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fn3cX-0002KJ-Mk for geb-bug-gnu-emacs@m.gmane.org; Tue, 07 Aug 2018 11:10:01 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58200) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fn3be-0000nR-HW for bug-gnu-emacs@gnu.org; Tue, 07 Aug 2018 11:09:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fn3ba-0003nD-AA for bug-gnu-emacs@gnu.org; Tue, 07 Aug 2018 11:09:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:38785) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fn3ba-0003n3-5R for bug-gnu-emacs@gnu.org; Tue, 07 Aug 2018 11:09:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fn3bZ-0007ZV-Te for bug-gnu-emacs@gnu.org; Tue, 07 Aug 2018 11:09:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 07 Aug 2018 15:09:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 32281 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 32281-submit@debbugs.gnu.org id=B32281.153365448429027 (code B ref 32281); Tue, 07 Aug 2018 15:09:01 +0000 Original-Received: (at 32281) by debbugs.gnu.org; 7 Aug 2018 15:08:04 +0000 Original-Received: from localhost ([127.0.0.1]:43803 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fn3ae-0007Y5-2E for submit@debbugs.gnu.org; Tue, 07 Aug 2018 11:08:04 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:38582) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fn3ac-0007Xa-Dj for 32281@debbugs.gnu.org; Tue, 07 Aug 2018 11:08:02 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fn3aT-0003Hc-1h for 32281@debbugs.gnu.org; Tue, 07 Aug 2018 11:07:56 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:52664) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fn3aS-0003HW-TE; Tue, 07 Aug 2018 11:07:52 -0400 Original-Received: from [176.228.60.248] (port=2516 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fn3aS-0000KU-CG; Tue, 07 Aug 2018 11:07:52 -0400 In-reply-to: <4760541533603112@sas1-890ba5c2334a.qloud-c.yandex.net> (message from Bad Blue Bull on Tue, 07 Aug 2018 03:51:52 +0300) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:149316 Archived-At: > From: Bad Blue Bull > Cc: "32281@debbugs.gnu.org" <32281@debbugs.gnu.org> > Date: Tue, 07 Aug 2018 03:51:52 +0300 > > Why did you decide to use u+2028 and u+2029 for these purposes? Emacs > doesn't yet support these characters as Unicode intended, so using > them might have unexpected effects, and might produce different effect > if we start supporting them in the future. > > I need to use a character to mark places where lines must be split (specified by
tags and end of list > items), also a character to mark end of a paragraph to be filled (a mark can be used for this purpose but docs > warn against it). These chars will be removed when a paragraph gets filled, I don't see them cause any trouble > in the future and those values can easily be altered to diffirent ones if it happens. I'm not sure I understand why you needed a character for that role. fill-region-as-paragraph accepts buffer positions, and re-search-forward can be told not to search beyond a certain buffer position. So you should be able to record the positions in some variables, and use them instead of inserting characters that need to be deleted afterwards. The disadvantage of inserting characters that were not there in the first place is that if the user types C-g at some unfortunate moment, these characters might be left in the buffer (unless you complicate the code by arranging for them to be deleted in that case). Using buffer positions avoids all those complications. Am I missing some reason why you needed characters as markers? Thanks.