all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* How debug font lock mode settings and/or view existing font lock mode settings?
@ 2009-04-20 20:17 Chris Seberino
  2009-04-21 12:39 ` Anselm Helbig
  0 siblings, 1 reply; 4+ messages in thread
From: Chris Seberino @ 2009-04-20 20:17 UTC (permalink / raw)
  To: help-gnu-emacs

I created my own minor mode that highlights characters beyond column
78.
It works most of the time but sometimes fails like in java mode.

Is it possible to dump the font lock mode settings in a separate
buffer when it doesn't work to see what is going on?

(If you have another idea to fix font lock mode settings I'd love to
hear that too.)

cs


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

* Re: How debug font lock mode settings and/or view existing font lock mode settings?
  2009-04-20 20:17 How debug font lock mode settings and/or view existing font lock mode settings? Chris Seberino
@ 2009-04-21 12:39 ` Anselm Helbig
  2009-04-27 18:38   ` Chris Seberino
  0 siblings, 1 reply; 4+ messages in thread
From: Anselm Helbig @ 2009-04-21 12:39 UTC (permalink / raw)
  To: help-gnu-emacs

Hi!

> I created my own minor mode that highlights characters beyond column
> 78.
> It works most of the time but sometimes fails like in java mode.
> 
> Is it possible to dump the font lock mode settings in a separate
> buffer when it doesn't work to see what is going on?

Well, that should be easy, you either do 

  M-: font-lock-defaults<RET>

or just put the string "font-lock-defaults" in your java code (most
probably in a comment) and evaluate it there - C-x C-e to see the
result in the echo area and in the *Messages* buffer, C-u C-x C-e to
dump it right into the current buffer. 

You could also write a function that writes the settings into some
other buffer, 

  (defun debug-font-lock () 
    (let ((copy-of-font-lock-defaults font-lock-defaults))
      (save-excursion
        (set-buffer (get-buffer-create "*debug-font-lock*"))
        (goto-char (point-max))
        (insert (format "%s" copy-of-font-lock-defaults)))))

and then call 

  M-: (debug-font-lock)

when you're in your java buffer. There might be more elegant ways to
do this. 8-)

HTH, kind regards, 

Anselm


-- 
Anselm Helbig 
mailto:anselm.helbig+news2009@googlemail.com


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

* Re: How debug font lock mode settings and/or view existing font lock mode  settings?
  2009-04-21 12:39 ` Anselm Helbig
@ 2009-04-27 18:38   ` Chris Seberino
  2009-05-03  2:14     ` David Combs
  0 siblings, 1 reply; 4+ messages in thread
From: Chris Seberino @ 2009-04-27 18:38 UTC (permalink / raw)
  To: help-gnu-emacs

On Apr 21, 5:39 am, Anselm Helbig <anselm.helbig
+news2...@googlemail.com> wrote:

> Well, that should be easy, you either do
>
>   M-: font-lock-defaults<RET>

Thanks for you help.  I'm running Emacs 22.2.1 and it doesn't
recognize font-lock-defaults!?!?

cs


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

* Re: How debug font lock mode settings and/or view existing font lock mode  settings?
  2009-04-27 18:38   ` Chris Seberino
@ 2009-05-03  2:14     ` David Combs
  0 siblings, 0 replies; 4+ messages in thread
From: David Combs @ 2009-05-03  2:14 UTC (permalink / raw)
  To: help-gnu-emacs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 642 bytes --]

In article <2d1988f8-ccb8-4b0f-8efd-825dc9f4e219@v23g2000pro.googlegroups.com>,
Chris Seberino  <cseberino@gmail.com> wrote:
>On Apr 21, 5:39 am, Anselm Helbig <anselm.helbig
>+news2...@googlemail.com> wrote:
>
>> Well, that should be easy, you either do
>>
>>   M-: font-lock-defaults<RET>
>
>Thanks for you help.  I'm running Emacs 22.2.1 and it doesn't
>recognize font-lock-defaults!?!?
>
>cs

Ditto.

So what is/was/will-be the task of font-lock-defaults?

Is it supposed to output something?

Since we don't have that function/variable/whatever, do you
have anything to substitute for it?


Seems like a useful thing!


Thanks

David




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

end of thread, other threads:[~2009-05-03  2:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-04-20 20:17 How debug font lock mode settings and/or view existing font lock mode settings? Chris Seberino
2009-04-21 12:39 ` Anselm Helbig
2009-04-27 18:38   ` Chris Seberino
2009-05-03  2:14     ` David Combs

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.