Function: doom-modeline-segment--word-count

doom-modeline-segment--word-count is a natively compiled function defined in doom-modeline-segments.el.

Signature

(doom-modeline-segment--word-count)

Documentation

The buffer word count.

Displayed when in a major mode in doom-modeline-continuous-word-count-modes. Respects doom-modeline-enable-word-count.

Source Code

;; Defined in /nix/store/1lcicrdd2r4b8rkc91nnn74ymk1jl6yd-emacs-packages-deps/share/emacs/site-lisp/elpa/doom-modeline-20260928.1632/doom-modeline-segments.el
;;
;; Word Count
;;

(doom-modeline-def-segment word-count
  "The buffer word count.
Displayed when in a major mode in `doom-modeline-continuous-word-count-modes'.
Respects `doom-modeline-enable-word-count'."
  (when (and doom-modeline-enable-word-count
             (member major-mode doom-modeline-continuous-word-count-modes))
    (propertize (format " %dW" (count-words (point-min) (point-max)))
                'face (doom-modeline-face))))