[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master eb2e6b3 070/271: Formalize italic support.
From: |
Jackson Ray Hamilton |
Subject: |
[elpa] master eb2e6b3 070/271: Formalize italic support. |
Date: |
Thu, 05 Feb 2015 18:29:51 +0000 |
branch: master
commit eb2e6b3ec07dd8b6a7a79d6601632928cbadffcf
Author: Jackson Ray Hamilton <address@hidden>
Commit: Jackson Ray Hamilton <address@hidden>
Formalize italic support.
---
context-coloring.el | 9 +++++++--
scopifier.js | 5 +++--
2 files changed, 10 insertions(+), 4 deletions(-)
diff --git a/context-coloring.el b/context-coloring.el
index 18bf436..8623bc5 100644
--- a/context-coloring.el
+++ b/context-coloring.el
@@ -42,8 +42,7 @@
;;; Faces
(defface context-coloring-depth--1-face
- '((default (:slant italic))
- (((background light)) (:foreground "#7f7f7f"))
+ '((((background light)) (:foreground "#7f7f7f"))
(((background dark)) (:foreground "#7f7f7f")))
"Nested blocks face, depth -1; comments."
:group 'context-coloring-faces)
@@ -94,6 +93,11 @@
"Number of faces defined for highlighting delimiter levels.
Determines depth at which to cycle through faces again.")
+(defface context-coloring-depth--1-italic-face
+ '((default (:inherit context-coloring-depth--1-face :slant italic)))
+ "Nested blocks face, depth -1; italic; comments."
+ :group 'context-coloring-faces)
+
(defface context-coloring-depth-0-bold-face
'((default (:inherit context-coloring-depth-0-face :weight bold)))
"Nested blocks face, depth 0; bold; global scope."
@@ -148,6 +152,7 @@ For example: \"context-coloring-depth-1-face\"."
(mod (- depth 1)
(- context-coloring-face-count 1)))))
(cond ((= 1 style) "-bold")
+ ((= 2 style) "-italic")
(t ""))
"-face")))
diff --git a/scopifier.js b/scopifier.js
index 26501e4..4897ddc 100644
--- a/scopifier.js
+++ b/scopifier.js
@@ -15,7 +15,8 @@ var escope = require('escope'),
},
normal = 0,
- bold = 1;
+ bold = 1,
+ italic = 2;
// Given code, returns an array of `[level, start, end]' tokens for
// context-coloring.
@@ -103,7 +104,7 @@ module.exports = function (code) {
range[0],
range[1],
-1,
- normal
+ italic
];
});
- [elpa] master ff988f3 051/271: Fix duplicate tokens and tail-end bug., (continued)
- [elpa] master ff988f3 051/271: Fix duplicate tokens and tail-end bug., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 0143a29 058/271: Leverage .jslintrc files., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 38f0821 059/271: Perf with ugly for loops., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 148e55b 046/271: Readme updates., Jackson Ray Hamilton, 2015/02/05
- [elpa] master a02fe9f 064/271: Switch to microoptimized., Jackson Ray Hamilton, 2015/02/05
- [elpa] master f07ce20 061/271: Revert back to functions., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 0ab3ed5 060/271: And it still made no difference., Jackson Ray Hamilton, 2015/02/05
- [elpa] master c2114e9 040/271: Uglify tokenizer now working., Jackson Ray Hamilton, 2015/02/05
- [elpa] master b1e7a1d 076/271: Switch to 1-dimensional array., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 7c8e32c 062/271: Restore microooptimized, add more benchmarks, add tests., Jackson Ray Hamilton, 2015/02/05
- [elpa] master eb2e6b3 070/271: Formalize italic support.,
Jackson Ray Hamilton <=
- [elpa] master 67637bf 072/271: Update test fixture., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 65e4763 065/271: Just push to a single tokens array., Jackson Ray Hamilton, 2015/02/05
- [elpa] master cb8b1f2 066/271: Add light color scheme., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 7a49f9f 067/271: Make comments italic., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 07fe42c 078/271: Vconcat., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 28667b8 075/271: Move microoptimized scopifier into the limelight., Jackson Ray Hamilton, 2015/02/05
- [elpa] master c1f9f11 063/271: Switch to concat., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 183ac4e 081/271: Add emacs benchmark., Jackson Ray Hamilton, 2015/02/05
- [elpa] master 59b1c99 074/271: Documentation and cleanup., Jackson Ray Hamilton, 2015/02/05
- [elpa] master c81c3fd 068/271: Make declarations bold., Jackson Ray Hamilton, 2015/02/05