0

I am very new to emacs and despite the great online documentation I can't figure out how to customize the face applied to the content between HTML header tags (e.g. <h1>Content here</h1>), so that the content is not displayed underlined nor bold in emacs. In other words, I would like such content to be displayed with no ornament at all, as pure default text.

In a general manner, how can syntactic-based (not keyword-based) highlighting be customized ?

Does anyone know how to proceed ?

Drew
  • 29,895
  • 7
  • 74
  • 104
Mathieu
  • 431
  • 1
  • 6
  • 15

1 Answers1

0

it depends on which mode is used to edit html files. But basically, you can put cursor to text, and execute M-x customize-face - Emacs will ask for name of face (font+color+...), and by default it substitutes the name of face for text under cursor, so you can simply press enter. After that, Emacs will open new buffer where you can edit parameters. After that you can press "Apply" (to set only for current session), or "Save" to save these parameters into file with settings.

Alex Ott
  • 80,552
  • 8
  • 87
  • 132
  • `M-x customize-face` indicates that the content is associated with two faces: 'underlined' and 'bold-italic'. It also lets me modify the properties of these faces (e.g. I can add a slant effect to the 'underlined' face). However, I don't want to redefine these faces. I just want **not** to associate these faces with the content of HTML headers h1, h2, etc. In other words, what I am looking for would make `M-x customize-face` return 'default' instead of 'underlined,bold-italic' the next time I run it with the cursor on such a header. – Mathieu Mar 30 '13 at 15:26
  • which mode are you using? You can find this by pressing `C-h m` – Alex Ott Mar 30 '13 at 18:36
  • Thanks for your help Alex. I am in HTML major mode, with all the associated default minor modes. I haven't customized anything so far. – Mathieu Mar 31 '13 at 01:56