|
From: | ken |
Subject: | Re: Understanding Word and Sentence Boundaries |
Date: | Tue, 11 Dec 2012 06:18:59 -0500 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:10.0.11) Gecko/20121120 Thunderbird/10.0.11 |
On 06/26/2010 11:05 PM Deniz Dogan wrote:
2010/6/27 ken<gebser@mousecar.com>: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 DrummondIs 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.</tag> 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 "</tag>" 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?
[Prev in Thread] | Current Thread | [Next in Thread] |