all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Haines Brown <haines@engels.histomat.net>
To: help-gnu-emacs@gnu.org
Subject: Re: Automatic flyspell
Date: Sun, 22 Feb 2015 04:46:52 -0500	[thread overview]
Message-ID: <87ioeuwa5v.fsf@engels.histomat.net> (raw)
In-Reply-To: 87zj86n53i.fsf@debian.uxu

Emanuel Berg <embe8573@student.uu.se> writes:

> Haines Brown <haines@engels.histomat.net> writes:
>
>> In exploring how to get flyspell enabled for all
>> text files, I get impression these should work, but
>> despite them I remain in the Fundamental mode with
>> the only minor mode being Fill.
>
> Aha, now I think I understand. Do you want to use
> text-mode for files like README but you end up in
> fundamental-mode?
>
> If so, try this:
>
>     (set-default 'major-mode 'text-mode)

Emanuel, thanks. I actually have Flyspell working in Fundamental mode
with these lines:

  (defun turn-on-flyspell () (flyspell-mode 1))
  (add-hook 'find-file-hooks 'turn-on-flyspell)

For example it is on now as I write, and my present modes are Message
Fly MML Abbrev Fill Narrow. This probably because I started gnus in
emacs with the two lines above in its init file. When I start emacs its
modes are Lisp Interaction Fill. When I then open a text file with it,
the modes change to Fundamental Fly Fill. So it seems that flyspell is
working in Fundamental mode. If I give a test text file an .txt
extension, emacs opens in the Text Fly Fill modes.

I see no difference off hand from when I open that file without the
extension in the Fundamental Fly Fill modes or with it in the Text
mode. This raises a question, why should I set default to Text mode?

All my work is done in LaTeX mode rather than use a word processor (I
used to use WordPerfect under DOS, but have little idea how to use these
GUI things---too complicated for my antiquated brain). However, for
LaTeX emacs uses a different init file with the lines:

  (defun turn-on-flyspell () (flyspell-mode 1))
  (add-hook 'find-file-hooks 'turn-on-flyspell)

When the emacs session I initially mentioned opens a .tex file, it opens
in the LaTeX Fly Fill modes and knows not to mark commands or
environments such as \subsection{} as misspellings.

When I open a .java file I'm in the Java/1 Fly Abbrev Fill modes. When I
open a .c file, I'm in the C/1 Fly Abbrev Fill modes. In these cases
commands are marked as misspellings. If I did any serious programming
I'd have to tailor Flyspell for those modes.

Haines


 


  reply	other threads:[~2015-02-22  9:46 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-20 16:46 Automatic flyspell Haines Brown
2015-02-21 23:38 ` Emanuel Berg
2015-02-22  0:48 ` Emanuel Berg
2015-02-22  9:46   ` Haines Brown [this message]
2015-02-22 23:24     ` Emanuel Berg
2015-02-23  3:46     ` Robert Thorpe
     [not found] <mailman.664.1424663182.31049.help-gnu-emacs@gnu.org>
2015-02-23 19:19 ` Emanuel Berg
2015-02-23 21:05   ` Robert Thorpe
     [not found] <mailman.708.1424725551.31049.help-gnu-emacs@gnu.org>
2015-02-25 17:01 ` Emanuel Berg

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=87ioeuwa5v.fsf@engels.histomat.net \
    --to=haines@engels.histomat.net \
    --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.