+;;; sixel.el --- minor mode for processing sixel graphics
+
+;; Copyright (C) 2019 Tim Vaughan
+
+;; Author: Tim Vaughan <tgvaughan@gmail.com>
+;; Created: 19 May 2019
+;; Version: 1.0.0
+;; Keywords:
+;; Homepage: https://github.com/tgvaughan/sixel
+;; Package-Requires: ((emacs "25"))
+
+;;; Commentary:
+
+;;; Code:
+
(defvar test-string
(concat "q"
"#0;2;0;0;0#1;2;100;100;0#2;2;0;100;0"
"#2??GG????-"
"#1!14@"))
-
(defun sixel-get-params (string)
"Retrieve the sixel parameters."
(car (split-string string "q")))
"Retrieve data string."
(substring string (1+ (string-match "q" string))))
-(defun sixel-compute-row-length (string)
- (apply 'max
- (mapcar
- (lambda (substr)
- (apply 'max (mapcar
- (lambda (subsubstr)
- (length (subsubstr)))
- (split-string substr "$"))))
- (split-string string -))))
-
(defun sixel-tag-bits (sixel n tag)
"Set bits of SIXEL corresponding to N with to the value TAG."
(dotimes (i 6)
(goto-char (match-end 0)))
(push (reverse this-row) rows)
- (reverse rows))))
+ (list color-map
+ (reverse rows)))))
+
+;; sixel.el ends here