all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Rasmus Pank Roulund <rasmus.pank@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Beginner's Lisp Question
Date: Thu, 17 Jan 2008 19:18:53 +0100	[thread overview]
Message-ID: <fmo66c$gjq$1@ger.gmane.org> (raw)

Hey,
This is probably a rather stupid question.
Either way, I use the texcount.pl script to count words in LaTeX document.
The output is something like this:

      FILE: hist_pol_oko.tex
      Words in text: 3811
      Words in headers: 43
      Words in float captions: 0
      Number of headers: 7
      Number of floats: 0
      Number of math inlines: 0
      Number of math displayed: 0

I have added the following to my .emacs file

      (add-to-list 'TeX-command-list
       (list "Count Words" "texcount.pl %s.tex"
       'TeX-run-command nil t)
      )

First, when I have Count Words from within AUCTeX the status line displays
"Count Words: Done". Instead, I would like it to display the number of 
words. In the example above it would be "3811 words".

Second, would also be nice, if Emacs would be able to do a calculation. 
I.e. "3811 words and 10.88 normal page(s)". The second figure would be 
calculated by dividing 3811 with 350.

Third, I would be nice if I could define a alias for the "Count Words" 
command. I.e. "Wordcount" and "Count Words" would run the same script. I 
was only able to find

    (defalias 'perl-mode 'cperl-mode)

in the "Learning GNU Emacs", and as far as I can tell it would not work 
with this kind of command.

I am sorry for asking so many questions, but I am really unfamiliar with 
Lisp.

Thanks a bunch,
Rasmus

             reply	other threads:[~2008-01-17 18:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-17 18:18 Rasmus Pank Roulund [this message]
     [not found] <mailman.6235.1200593955.18990.help-gnu-emacs@gnu.org>
2008-01-18  1:24 ` Beginner's Lisp Question Xah Lee

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='fmo66c$gjq$1@ger.gmane.org' \
    --to=rasmus.pank@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.