From mboxrd@z Thu Jan 1 00:00:00 1970 From: Simon Guest Subject: Re: Word-counting in a subtree Date: Tue, 22 Aug 2017 20:31:23 +1200 Message-ID: References: <1709997.Ids7SHHmVx@bl4ckspoons> <87valgu71m.fsf@t3610> <4070576.EzaRnAn6cA@bl4ckspoons> Reply-To: sjg@cantab.net Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a113cecc2adee470557536b7a" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:40062) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dk4b0-00089V-Og for emacs-orgmode@gnu.org; Tue, 22 Aug 2017 04:31:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dk4aw-00034n-Ai for emacs-orgmode@gnu.org; Tue, 22 Aug 2017 04:31:34 -0400 Received: from mta01.prd.rdg.aluminati.org ([94.76.243.214]:58735) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dk4aw-00031C-1M for emacs-orgmode@gnu.org; Tue, 22 Aug 2017 04:31:30 -0400 Received: from mta01.prd.rdg.aluminati.org (localhost [127.0.0.1]) by mta01.prd.rdg.aluminati.org (Postfix) with ESMTP id 877A720EFA for ; Tue, 22 Aug 2017 09:31:26 +0100 (BST) Received: from localhost (localhost [127.0.0.1]) by mta01.prd.rdg.aluminati.org (Postfix) with ESMTP id 8446F20ED9 for ; Tue, 22 Aug 2017 09:31:26 +0100 (BST) Received: from mta.aluminati.local ([127.0.0.1]) by localhost (mta01.prd.rdg.aluminati.org [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id Pr0YPVxOZCb4 for ; Tue, 22 Aug 2017 09:31:25 +0100 (BST) Received: from mail-oi0-f48.google.com (unknown [10.2.0.9]) by mta01.prd.rdg.aluminati.org (Postfix) with ESMTPSA id F2B4F621CF for ; Tue, 22 Aug 2017 09:31:24 +0100 (BST) Received: by mail-oi0-f48.google.com with SMTP id f11so178769216oic.0 for ; Tue, 22 Aug 2017 01:31:24 -0700 (PDT) In-Reply-To: <4070576.EzaRnAn6cA@bl4ckspoons> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Jacopo De Simoi Cc: Org Mode List --001a113cecc2adee470557536b7a Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable [copy to list] A few years ago I wrote org-wc.el, which is on MELPA. It uses overlays to display a word count against each heading. Just install the package, and run org-wc-display. https://github.com/tesujimath/org-wc Hope that helps. cheers, Simon On 22 August 2017 at 09:34, Jacopo De Simoi wrote: > On Monday, August 21, 2017 2:09:25 PM EDT Eric S Fraga wrote: > > On Monday, 21 Aug 2017 at 13:21, Jacopo De Simoi wrote: > > > tl;dr > > > > > > Is there a way to create a token on a subtree header that would count > > > words in the subtree and [optionally] mark a maximum allowed number o= f > > > words? > > I cannot help you directly but what I do is: narrow the region to the > > sub-tree while writing and then simply execute M-x count-words RET ever= y > > now and again. > > this has the drawback that it also counts words in the header line; excep= t > this, could work as a temporary solution, but I'd still like to cook up > some > tag integrated with org > > > > > There is a wc-mode which displays the number of words/chars in the > > modeline but my modeline is already too busy for this... > > Indeed modelines are crowded these days=E2=80=A6 > > > --001a113cecc2adee470557536b7a Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
[copy to list]

A few years ago I wrote org-wc.el, which is on MELPA.= =C2=A0 It uses overlays to display a word count against each heading.
<= br>
Just install the package, and run org-wc-display.
<= br>

Hope that helps.

cheers,
Simon

On 22 August 201= 7 at 09:34, Jacopo De Simoi <wilderkde@gmail.com> wrote:
On Monday, August 21, 201= 7 2:09:25 PM EDT Eric S Fraga wrote:
> On Monday, 21 Aug 2017 at 13:21, Jacopo De Simoi wrote:
> > tl;dr
> >
> > Is there a way to create a token on a subtree header that would c= ount
> > words in the subtree and [optionally] mark a maximum allowed numb= er of
> > words?
> I cannot help you directly but what I do is: narrow the region to the<= br> > sub-tree while writing and then simply execute M-x count-words RET eve= ry
> now and again.

this has the drawback that it also counts words in the header line; = except
this, could work as a temporary solution, but I'd still like to cook up= some
tag integrated with org

>
> There is a wc-mode which displays the number of words/chars in the
> modeline but my modeline is already too busy for this...

Indeed modelines are crowded these days=E2=80=A6



--001a113cecc2adee470557536b7a--