From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: ken Newsgroups: gmane.emacs.help Subject: Re: Understanding Word and Sentence Boundaries Date: Tue, 11 Dec 2012 06:18:59 -0500 Message-ID: <50C716A3.7070302@mousecar.com> References: <4C2691F1.5020802@mousecar.com> Reply-To: gebser@mousecar.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1355224777 4876 80.91.229.3 (11 Dec 2012 11:19:37 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 11 Dec 2012 11:19:37 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Deniz Dogan Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Dec 11 12:19:50 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TiNsH-00064e-V0 for geh-help-gnu-emacs@m.gmane.org; Tue, 11 Dec 2012 12:19:46 +0100 Original-Received: from localhost ([::1]:44826 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TiNs5-0003aT-8a for geh-help-gnu-emacs@m.gmane.org; Tue, 11 Dec 2012 06:19:33 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:34288) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TiNrv-0003Zz-1F for help-gnu-emacs@gnu.org; Tue, 11 Dec 2012 06:19:28 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TiNrk-0005Hy-Q1 for help-gnu-emacs@gnu.org; Tue, 11 Dec 2012 06:19:22 -0500 Original-Received: from mout.perfora.net ([74.208.4.194]:61769) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TiNrk-0005He-JU for help-gnu-emacs@gnu.org; Tue, 11 Dec 2012 06:19:12 -0500 Original-Received: from dellap.mousecar.net (dsl093-011-016.cle1.dsl.speakeasy.net [66.93.11.16]) by mrelay.perfora.net (node=mrus4) with ESMTP (Nemesis) id 0M0hHi-1SsLTU3QMg-00ufIG; Tue, 11 Dec 2012 06:19:08 -0500 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:10.0.11) Gecko/20121120 Thunderbird/10.0.11 In-Reply-To: X-Provags-ID: V02:K0:E0yRD9kNa7Womg05n8rmlNEnQKHImg97Mq50q+eCgKk vf4auay7g4SL1YmS0L/WNYcWv+78P8xg7KYs9bOa99T6tMJE69 jDqeUZzPxFqf4xWi7A/H2cXwS8ptW/6B7vvFI8PSBsIBi+qSxr UNfF9aVeVToiQDW/JUaT6k44EjqKJRpQcbCmSuG9w1ZD6yUakp k3VPEnGHs9+FRxupRM1zeA98MYJb9+E5N4oYP/fuAo1Pe7Xsy/ 7SZquwsT2AWyQCVKmYqm2ayaNs20iNKBxrn/pMqbPtB6L/mWqG S0sED/F+0UnVysh3LzEo/RlRigiZ40dhgHfaSV1/y8t+wMFvs/ XYx/TUM+zN44qBBfmAcuH3HErG2+4Ro1gqs85yfYK X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 74.208.4.194 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:88128 Archived-At: On 06/26/2010 11:05 PM Deniz Dogan wrote: > 2010/6/27 ken: >> >> On 06/26/2010 06:53 AM Paul Drummond wrote: >>> Thanks for the responses guys. >>> >>> I think the point I am trying to make here is that it's a *big* task to >>> fix word boundaries for every case (every word-related key binding >>> multiplied by each language/major mode I use!). >>> >>> I presume that Emacs hackers either a) put up with it or b) spend a lot >>> of time fixing each case until they are happy. >>> >>> I suspect the answer is b. ;-) >>> >>> I wish there was a single minor-mode that fixes all the word boundary >>> issues for every major-mode I use! I can but dream. Or maybe I will >>> get round to doing it myself one day! ;) >>> >>> Cheers, >>> Paul Drummond >> >> >> Is it possible to specify word boundaries for a particular mode? >> > > Yes, it's part of the syntax table. See e.g. `modify-syntax-entry'. Thanks for the pointer to that function. The behavior I see in need of repair is the role of so-called "comments" in sentence syntax. For instance, immediately before this sentence are two spaces... which should signify the end of the previous sentence. But functions like "forward-sentence" and "fill-paragraph" and "backward-sentence" don't recognize it. Said another way, the "" string obscures the relationship between the period before it and the two spaces after it and so fails to see that one sentence ends and another starts. This occurs in text-mode and seems to be inherited by other modes. If I'm reading "modify-syntax-entry" correctly, the default meanings of '<' and '>' are, respectively, beginning and end of comment, so modifying them wouldn't fix this problem. Or can this be remedied by a change in the syntax table? Or is this a bug?