all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "B.T. Raven" <ejmn@cpinternet.com>
Subject: Re: Counting chars
Date: Tue, 22 Feb 2005 18:19:12 -0600	[thread overview]
Message-ID: <111nj01i0p915a3@corp.supernews.com> (raw)
In-Reply-To: mailman.1160.1109114820.32256.help-gnu-emacs@gnu.org


"Raimund Kohl-Fuechsle" <Raimund.Kohl@nabuli.de> wrote in message
news:mailman.1160.1109114820.32256.help-gnu-emacs@gnu.org...
> Hello,
>
> I am looking for a way to count the total sum of chars (whitespaces
> included) in a buffer.  I couldn't find an existing solution via
google
> ... anyone any idea?
>
> ray
>
>

C-x = will report the character position of point and the total number
of characters. For example, in my current buffer it reports 1417743
total characters in buffer, while Dos (via shell with command prompt)
shows a file size of 1572128. The difference is accounted for by the CR
LF pairs at the end of each line (or maybe LF if the file is in a Unix
like text file format).

If you have Cygwin or if you're running Linux you can use the wc program
(line, word, character count) but this probably includes the end of line
characters which you probably don't want.

Ed

       reply	other threads:[~2005-02-23  0:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <mailman.1160.1109114820.32256.help-gnu-emacs@gnu.org>
2005-02-23  0:19 ` B.T. Raven [this message]
2005-02-22 22:50 Counting chars Raimund Kohl-Fuechsle
2005-02-22 23:46 ` Peter Dyballa
2005-02-23  0:25 ` Drew Adams

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=111nj01i0p915a3@corp.supernews.com \
    --to=ejmn@cpinternet.com \
    /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.