Changeset 2294
- Timestamp:
- 11/29/07 14:18:49 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/trunk-reorg/thirdparty/emacs/javascript.el
r2291 r2294 1 1 ;;; javascript.el --- Major mode for editing JavaScript source text 2 3 ;; This version contains a few font-lock fixes for quoted strings 4 ;; and regular expressions by Joost Diepenmaat <joost@zeekat.nl> 5 ;; Joost's version - 2007-11-29 6 7 ;; Currently known issues: 8 ;; 9 ;; /* .. */ style comments inside quoted strings are shown as comments 10 ;; instead of quoted strings. Fixing this may get complicated. 2 11 3 12 ;; Copyright (C) 2006 Karl Landström … … 8 17 ;; Date: 2006-12-26 9 18 ;; Keywords: languages, oop 10 11 ;; This version contains a few font-lock fixes for quoted strings12 ;; and regular expressions by Joost Diepenmaat <joost@zeekat.nl>13 19 14 20 ;; This file is free software; you can redistribute it and/or modify … … 118 124 (modify-syntax-entry ?\" "." table) 119 125 126 ;; partially disable comment detection. Our manual string detection 127 ;; won't work if there are automatically detected comments inside the 128 ;; string. 129 ;; 130 ;; note that we keep auto-detection of /* .. */ style comments since 131 ;; they are multi-line and can't easily be detected otherwise. 132 (modify-syntax-entry ?/ ". 14" table) 133 120 134 ;; The syntax class of underscore should really be `symbol' ("_") 121 135 ;; but that makes matching of tokens much more complex as e.g. … … 298 312 ;; detect "autoquoted" object properties... clases with "switch { ... default: }" 299 313 ;; may not be worth the trouble 300 (list "\\(^[ \t]*\\|[,{][ \t]*\\)\\(\\w+\\):" 2 font-lock-string-face)) 301 314 (list "\\(^[ \t]*\\|[,{][ \t]*\\)\\(\\w+\\):" 2 font-lock-string-face) 315 316 ;; find single-line comments 317 (list "\\(//.*\\)" 1 font-lock-comment-face)) 302 318 "Level one font lock.") 303 319
