all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* visible-whitespace-mode
@ 2022-06-09  1:30 goncholden via Users list for the GNU Emacs text editor
  2022-06-09  9:09 ` visible-whitespace-mode Michael Heerdegen
  2022-06-09 14:11 ` visible-whitespace-mode Michael Heerdegen
  0 siblings, 2 replies; 12+ messages in thread
From: goncholden via Users list for the GNU Emacs text editor @ 2022-06-09  1:30 UTC (permalink / raw)
  To: help-gnu-emacs@gnu.org

I want to use visible-whitespace-mode location here

https://www.emacswiki.org/emacs/visws.el

I have written the following function but getting the warning

Symbol's function definition is void: visible-whitespace-mode

(defun visws ()
"TODO"

(add-to-list
'load-path "~/contrib/visws")
;;(require "visible-whitespace-mode")
(visible-whitespace-mode))

(visws)

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09  1:30 visible-whitespace-mode goncholden via Users list for the GNU Emacs text editor
@ 2022-06-09  9:09 ` Michael Heerdegen
  2022-06-09 12:37   ` visible-whitespace-mode goncholden
  2022-06-09 14:11 ` visible-whitespace-mode Michael Heerdegen
  1 sibling, 1 reply; 12+ messages in thread
From: Michael Heerdegen @ 2022-06-09  9:09 UTC (permalink / raw)
  To: help-gnu-emacs

goncholden via Users list for the GNU Emacs text editor
<help-gnu-emacs@gnu.org> writes:

> I want to use visible-whitespace-mode location here
>
> https://www.emacswiki.org/emacs/visws.el
>
> I have written the following function but getting the warning
>
> Symbol's function definition is void: visible-whitespace-mode

When compiling?

Michael.




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09  9:09 ` visible-whitespace-mode Michael Heerdegen
@ 2022-06-09 12:37   ` goncholden
  2022-06-09 14:18     ` visible-whitespace-mode Michael Heerdegen
  0 siblings, 1 reply; 12+ messages in thread
From: goncholden @ 2022-06-09 12:37 UTC (permalink / raw)
  To: Michael Heerdegen; +Cc: help-gnu-emacs

------- Original Message -------
On Thursday, June 9th, 2022 at 9:09 PM, Michael Heerdegen <michael_heerdegen@web.de> wrote:


> goncholden via Users list for the GNU Emacs text editor
> help-gnu-emacs@gnu.org writes:
>
> > I want to use visible-whitespace-mode location here
> >
> > https://www.emacswiki.org/emacs/visws.el
> >
> > I have written the following function but getting the warning
> >
> > Symbol's function definition is void: visible-whitespace-mode
>
>
> When compiling?
>
> Michael.

I think so because I get

Warning (initialization): An error occurred while loading ‘/home/cholden/.emacs’:

I have put the code locally.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09  1:30 visible-whitespace-mode goncholden via Users list for the GNU Emacs text editor
  2022-06-09  9:09 ` visible-whitespace-mode Michael Heerdegen
@ 2022-06-09 14:11 ` Michael Heerdegen
  2022-06-09 15:33   ` visible-whitespace-mode goncholden
  1 sibling, 1 reply; 12+ messages in thread
From: Michael Heerdegen @ 2022-06-09 14:11 UTC (permalink / raw)
  To: help-gnu-emacs

goncholden via Users list for the GNU Emacs text editor
<help-gnu-emacs@gnu.org> writes:

Ehm - wait:

> Symbol's function definition is void: visible-whitespace-mode
>
> (defun visws ()
> "TODO"
>
> (add-to-list
> 'load-path "~/contrib/visws")
> ;;(require "visible-whitespace-mode")
> (visible-whitespace-mode))

An error is expect when you comment out the `require' call, no?  Why do
you expect this to work?

Michael.




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09 12:37   ` visible-whitespace-mode goncholden
@ 2022-06-09 14:18     ` Michael Heerdegen
  2022-06-09 14:24       ` visible-whitespace-mode goncholden
  0 siblings, 1 reply; 12+ messages in thread
From: Michael Heerdegen @ 2022-06-09 14:18 UTC (permalink / raw)
  To: goncholden; +Cc: help-gnu-emacs

goncholden <goncholden@protonmail.com> writes:

> > When compiling?
> >
> > Michael.
>
> I think so because I get
>
> Warning (initialization): An error occurred while loading
> ‘/home/cholden/.emacs’:

No, that's just a normal error while loading your .emacs.

Michael.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09 14:18     ` visible-whitespace-mode Michael Heerdegen
@ 2022-06-09 14:24       ` goncholden
  0 siblings, 0 replies; 12+ messages in thread
From: goncholden @ 2022-06-09 14:24 UTC (permalink / raw)
  To: Michael Heerdegen; +Cc: help-gnu-emacs


------- Original Message -------
On Friday, June 10th, 2022 at 2:18 AM, Michael Heerdegen <michael_heerdegen@web.de> wrote:


> goncholden goncholden@protonmail.com writes:
>
> > > When compiling?
> > >
> > > Michael.
> >
> > I think so because I get
> >
> > Warning (initialization): An error occurred while loading
> > ‘/home/cholden/.emacs’:
>
>
> No, that's just a normal error while loading your .emacs.
>
> Michael.

What could be the problem?  The path is ok.




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09 14:11 ` visible-whitespace-mode Michael Heerdegen
@ 2022-06-09 15:33   ` goncholden
  2022-06-09 18:17     ` visible-whitespace-mode Michael Heerdegen
  0 siblings, 1 reply; 12+ messages in thread
From: goncholden @ 2022-06-09 15:33 UTC (permalink / raw)
  To: Michael Heerdegen; +Cc: help-gnu-emacs

------- Original Message -------
On Friday, June 10th, 2022 at 2:11 AM, Michael Heerdegen <michael_heerdegen@web.de> wrote:


> goncholden via Users list for the GNU Emacs text editor
> help-gnu-emacs@gnu.org writes:
>
>
> Ehm - wait:
>
> > Symbol's function definition is void: visible-whitespace-mode
> >
> > (defun visws ()
> > "TODO"
> >
> > (add-to-list
> > 'load-path "~/contrib/visws")
> > ;;(require "visible-whitespace-mode")
> > (visible-whitespace-mode))
>
>
> An error is expect when you comment out the `require' call, no? Why do
> you expect this to work?
>
> Michael.

Because I used

(require 'visible-whitespace-mode)

and that failed as well.

Might be that calling (visible-whitespace-mode) is not the correct way for activating the minor mode.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09 15:33   ` visible-whitespace-mode goncholden
@ 2022-06-09 18:17     ` Michael Heerdegen
  2022-06-09 19:55       ` visible-whitespace-mode goncholden
  0 siblings, 1 reply; 12+ messages in thread
From: Michael Heerdegen @ 2022-06-09 18:17 UTC (permalink / raw)
  To: help-gnu-emacs

goncholden <goncholden@protonmail.com> writes:

> Because I used
>
> (require 'visible-whitespace-mode)
>
> and that failed as well.

Your file doesn't provide a feature, so you can't use `require' to load
it (you would not `require' the mode name anyway - please have a look in
the manual how `provide' and `require' work).

So you can either add a `provide' statement to your file, or load it
using `load': (load "visws").

Michael.




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09 18:17     ` visible-whitespace-mode Michael Heerdegen
@ 2022-06-09 19:55       ` goncholden
  2022-06-10  9:18         ` visible-whitespace-mode Michael Heerdegen
  0 siblings, 1 reply; 12+ messages in thread
From: goncholden @ 2022-06-09 19:55 UTC (permalink / raw)
  To: Michael Heerdegen; +Cc: help-gnu-emacs


------- Original Message -------
On Friday, June 10th, 2022 at 6:17 AM, Michael Heerdegen <michael_heerdegen@web.de> wrote:


> goncholden goncholden@protonmail.com writes:
>
> > Because I used
> >
> > (require 'visible-whitespace-mode)
> >
> > and that failed as well.
>
>
> Your file doesn't provide a feature, so you can't use `require' to load it (you would not` require' the mode name anyway - please have a look in
> the manual how `provide' and` require' work).
>
> So you can either add a `provide' statement to your file, or load it using` load': (load "visws").
>
> Michael.

I have added (provide 'visws) to the end of the file of the same name.  Then called (require 'visws), which works fine.

What can I do to activate the minor made because calling

(visible-whitespace-mode)

is giving me

Invalid read syntax: ?










^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-09 19:55       ` visible-whitespace-mode goncholden
@ 2022-06-10  9:18         ` Michael Heerdegen
  2022-06-10 13:20           ` visible-whitespace-mode Stefan Monnier via Users list for the GNU Emacs text editor
  0 siblings, 1 reply; 12+ messages in thread
From: Michael Heerdegen @ 2022-06-10  9:18 UTC (permalink / raw)
  To: help-gnu-emacs

goncholden <goncholden@protonmail.com> writes:

> Invalid read syntax: ?

|  (?\t [?» ?\t] [?\\ ?\t])
|  (?   [?·] [?.])
         ^^^

?» and ?· are syntactically invalid (two non-whitespace characters
follow the "?").  Which characters do you want to specify?

Michael.




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-10  9:18         ` visible-whitespace-mode Michael Heerdegen
@ 2022-06-10 13:20           ` Stefan Monnier via Users list for the GNU Emacs text editor
  2022-06-10 14:33             ` visible-whitespace-mode Michael Heerdegen
  0 siblings, 1 reply; 12+ messages in thread
From: Stefan Monnier via Users list for the GNU Emacs text editor @ 2022-06-10 13:20 UTC (permalink / raw)
  To: help-gnu-emacs

Michael Heerdegen [2022-06-10 11:18:08] wrote:
> goncholden <goncholden@protonmail.com> writes:
>> Invalid read syntax: ?
>
> |  (?\t [?» ?\t] [?\\ ?\t])
> |  (?   [?·] [?.])
>          ^^^
>
> ?» and ?· are syntactically invalid (two non-whitespace characters
> follow the "?").  Which characters do you want to specify?

This looks like utf-8 encoded text mis-decoded with the
latin-1 coding-system:

    (decode-coding-string (encode-coding-string "[?» ?\\t]" 'latin-1) 'utf-8)
    ==>
    "[?» ?\t]"

    (decode-coding-string (encode-coding-string "[?·]" 'latin-1) 'utf-8)"
    ==>
    "[?·]


-- Stefan




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: visible-whitespace-mode
  2022-06-10 13:20           ` visible-whitespace-mode Stefan Monnier via Users list for the GNU Emacs text editor
@ 2022-06-10 14:33             ` Michael Heerdegen
  0 siblings, 0 replies; 12+ messages in thread
From: Michael Heerdegen @ 2022-06-10 14:33 UTC (permalink / raw)
  To: help-gnu-emacs

Stefan Monnier via Users list for the GNU Emacs text editor
<help-gnu-emacs@gnu.org> writes:

> This looks like utf-8 encoded text mis-decoded with the
> latin-1 coding-system:
>
>     (decode-coding-string (encode-coding-string "[?» ?\\t]" 'latin-1)
> 'utf-8)
>     ==>
>     "[?» ?\t]"
>
>     (decode-coding-string (encode-coding-string "[?·]" 'latin-1) 'utf-8)"
>     ==>
>     "[?·]

Thanks for the hint.  So these are the characters the author wants to
use.

Michael.




^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2022-06-10 14:33 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-06-09  1:30 visible-whitespace-mode goncholden via Users list for the GNU Emacs text editor
2022-06-09  9:09 ` visible-whitespace-mode Michael Heerdegen
2022-06-09 12:37   ` visible-whitespace-mode goncholden
2022-06-09 14:18     ` visible-whitespace-mode Michael Heerdegen
2022-06-09 14:24       ` visible-whitespace-mode goncholden
2022-06-09 14:11 ` visible-whitespace-mode Michael Heerdegen
2022-06-09 15:33   ` visible-whitespace-mode goncholden
2022-06-09 18:17     ` visible-whitespace-mode Michael Heerdegen
2022-06-09 19:55       ` visible-whitespace-mode goncholden
2022-06-10  9:18         ` visible-whitespace-mode Michael Heerdegen
2022-06-10 13:20           ` visible-whitespace-mode Stefan Monnier via Users list for the GNU Emacs text editor
2022-06-10 14:33             ` visible-whitespace-mode Michael Heerdegen

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.