{"thread":{"id":"6748","subject":"[PATCH 4/7] git-blame.el: improve color handling","startedAt":"2007-02-09T08:21:03Z","lastAt":"2007-02-09T08:21:03Z","messageCount":1,"participants":["David Kågedal"],"isPatch":true,"patchVersion":1,"patchTotal":7},"messages":[{"id":"34043","messageId":"87r6szpwr4.fsf@morpheus.local","threadId":"6748","inReplyTo":null,"subject":"[PATCH 4/7] git-blame.el: improve color handling","fromName":"David Kågedal","fromEmail":"davidk@lysator.liu.se","sentAt":"2007-02-09T08:21:03Z","receivedAt":"2007-02-09T08:21:03Z","isPatch":true,"sender":{"key":"davidk@lysator.liu.se","avatar":"https://avatars.githubusercontent.com/u/60530?v=4"},"body":"\nSigned-off-by: David Kågedal <davidk@lysator.liu.se>\n---\n contrib/emacs/git-blame.el |   24 ++++++++++--------------\n 1 files changed, 10 insertions(+), 14 deletions(-)\n\ndiff --git a/contrib/emacs/git-blame.el b/contrib/emacs/git-blame.el\nindex c99437e..7ffc153 100644\n--- a/contrib/emacs/git-blame.el\n+++ b/contrib/emacs/git-blame.el\n@@ -95,16 +95,10 @@\n     colors))\n \n (defvar git-blame-dark-colors\n-  (color-scale '(\"00\" \"04\" \"08\" \"0c\"\n-                 \"10\" \"14\" \"18\" \"1c\"\n-                 \"20\" \"24\" \"28\" \"2c\"\n-                 \"30\" \"34\" \"38\" \"3c\")))\n+  (color-scale '(\"0c\" \"04\" \"24\" \"1c\" \"2c\" \"34\" \"14\" \"3c\")))\n \n (defvar git-blame-light-colors\n-  (color-scale '(\"c0\" \"c4\" \"c8\" \"cc\"\n-                 \"d0\" \"d4\" \"d8\" \"dc\"\n-                 \"e0\" \"e4\" \"e8\" \"ec\"\n-                 \"f0\" \"f4\" \"f8\" \"fc\")))\n+  (color-scale '(\"c4\" \"d4\" \"cc\" \"dc\" \"f4\" \"e4\" \"fc\" \"ec\")))\n \n (defvar git-blame-ancient-color \"dark green\")\n \n@@ -127,13 +121,15 @@\n   (make-local-variable 'git-blame-overlays)\n   (make-local-variable 'git-blame-colors)\n   (make-local-variable 'git-blame-cache)\n-  (let ((bgmode (cdr (assoc 'background-mode (frame-parameters)))))\n-    (if (eq bgmode 'dark)\n-        (setq git-blame-colors git-blame-dark-colors)\n-      (setq git-blame-colors git-blame-light-colors)))\n+  (git-blame-cleanup)\n   (if git-blame-mode\n-      (git-blame-run)\n-    (git-blame-cleanup)))\n+      (progn\n+        (let ((bgmode (cdr (assoc 'background-mode (frame-parameters)))))\n+          (if (eq bgmode 'dark)\n+              (setq git-blame-colors git-blame-dark-colors)\n+            (setq git-blame-colors git-blame-light-colors)))\n+        (setq git-blame-cache (make-hash-table :test 'equal))\n+        (git-blame-run))))\n \n (defun git-blame-run ()\n   (let* ((display-buf (current-buffer))\n-- \n1.5.0.rc3.204.g93c76\n\n\n-- \nDavid Kågedal\n"}]}