emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: font-lock in machine mode of gdba


From: Nick Roberts
Subject: Re: font-lock in machine mode of gdba
Date: Mon, 18 Oct 2004 15:14:25 +1300

Stefan Monnier writes:
 > > +(defconst gdb-assembler-font-lock-keywords
 > > +  '(("\\$?0x*[0-9a-f]+" . font-lock-constant-face)
 > > +    ("<\\([^+>]+\\)\\+[0-9]+>:" 
 > > +     1 font-lock-function-name-face)
 > > +    ("%\\sw+" . font-lock-variable-name-face)
 > > +    ("^\\(Dump of assembler code for function\\) \\(.+\\):" 
 > > +     (1 font-lock-comment-face)
 > > +     (2 font-lock-function-name-face))
 > > +    ("^\\(End of assembler dump\\.\\)" . font-lock-comment-face))
 > > +    "Font lock keywords used in `gdb-assembler-mode'.")
 > 
 > Seems OK.
 >  
 > > +  (unless font-lock-mode (font-lock-mode 1))
 > 
 > This is WRONG.  The user should be able to choose whether he wants font-lock
 > or not.  He does that using either asm-mode-hook or global-font-lock-mode.

asm-mode, asm-mode-font-lock-keywords, etc doesn't work because the
disassembly view differs from that of assembler code (it adds the machine
address at the start of each line, for one thing). Since this buffer is not
editable would font-lock-face be the right thing to use here?

Nick




reply via email to

[Prev in Thread] Current Thread [Next in Thread]