[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/gnosis 6320d065e8 03/16: dashboard: Remove graph.
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/gnosis 6320d065e8 03/16: dashboard: Remove graph. |
Date: |
Sun, 6 Oct 2024 04:00:02 -0400 (EDT) |
branch: elpa/gnosis
commit 6320d065e82b9462824895f55b75d8ee9be468e7
Author: Thanos Apollo <public@thanosapollo.org>
Commit: Thanos Apollo <public@thanosapollo.org>
dashboard: Remove graph.
* Creating & maintaining a graph using text characters is unnecessary.
---
gnosis-dashboard.el | 57 -----------------------------------------------------
1 file changed, 57 deletions(-)
diff --git a/gnosis-dashboard.el b/gnosis-dashboard.el
index 23a04f71e1..3b96348899 100644
--- a/gnosis-dashboard.el
+++ b/gnosis-dashboard.el
@@ -143,63 +143,6 @@ Skips days where no note was reviewed."
do (setq total (+ total entry)))
(/ total (max (length (remove 0 entries)) 1))))
-;; TODO: Add more conds & faces
-(defun gnosis-dashboard--graph-propertize (string num)
- "Propertize STRING depending on the NUM of reviews."
- (cond ((= num 0)
- (propertize string 'face 'shadow))
- ((> num 0)
- (propertize string 'face 'font-lock-constant-face))))
-
-(defun gnosis-dashboard--add-padding (str-length)
- "Add padding for STR-LENGTH."
- (let ((padding (/ (- (window-width) str-length) 2)))
- (make-string padding ?\s)))
-
-(defun gnosis-dashboard-reviews-graph (dates &optional )
- "Insert graph for month DATES.
-
-Optionally, use when using multiple months."
- (let ((count 0)
- (row 0)
- (start-column (current-column))
- (end-column nil))
- (cl-loop for day in dates
- when (= count 0)
- do (let ((current-column (current-column)))
- (and (< (move-to-column start-column) start-column)
- ;; Add spaces to reach start-column.
- (insert (make-string (- start-column current-column)
?\s))))
- (insert " ")
- do (end-of-line)
- (insert (gnosis-dashboard--graph-propertize (format "[%s] " (if (=
day 0) "-" "x")) day))
- (cl-incf count)
- when (= count 7)
- do
- (setq end-column (current-column))
- (setq count 0)
- (insert " ")
- (cl-incf row)
- (end-of-line)
- (when (and (/= (forward-line 1) 0) (eobp))
- (insert "\n")
- (forward-line 0)))
- (insert (make-string (- end-column (current-column)) ?\s))
- (insert " ")))
-;; TODO: Refactor this!
-(defun gnosis-dashboard-month-overview (&optional num)
- "Insert review graph for MONTHS."
- (gnosis-insert-separator)
- (let* ((point (point))
- (month (car (calendar-current-date))))
- (insert (gnosis-dashboard--add-padding (min (* (max num 1) 50)
(window-width))))
- (while (<= month (+ (car (calendar-current-date)) num))
- ;; (insert (format "%d" month))
- (gnosis-dashboard-reviews-graph (gnosis-dashboard-month-reviews month))
- (goto-char point)
- (end-of-line)
- (cl-incf month))))
-
(defun gnosis-dashboard-output-note (id)
"Output contents for note with ID, formatted for gnosis dashboard."
(cl-loop for item in (append (gnosis-select '[main options answer tags type]
'notes `(= id ,id) t)
- [nongnu] elpa/gnosis updated (40f63788af -> 4f437a3b23), ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis f3d8505c34 01/16: [fix] cloze-remove-tags: Update regex for extra colons., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis ab33f0564f 02/16: [Packaging] Start working on 0.4.4-dev, ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis 5b3094c34b 05/16: New function: delete-activity-log., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis 6320d065e8 03/16: dashboard: Remove graph.,
ELPA Syncer <=
- [nongnu] elpa/gnosis bf7cf6ee59 12/16: Rename function delete-activity-log to history-clear., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis 4041ef532d 06/16: doc: Update manual & git repo sources, ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis 17418b16f6 08/16: New function: dashboard-enable-mode., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis fd1315830e 15/16: Update docs & version bump to 0.4.4., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis e40c287909 09/16: [fix] Update dashboard buffer names & issues with dashboard-mode., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis a542549906 04/16: Fix docstring typos, ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis 28b4067319 07/16: doc: New section: Interactions with other software., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis b83de5ab84 13/16: Clarify comments & Use polytonic Greek for Athens (Ἀθήνα)., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis c246c3abb1 10/16: Remove custom review keybindings., ELPA Syncer, 2024/10/06
- [nongnu] elpa/gnosis 3a9be993ad 11/16: Remove validate-actions-keys function., ELPA Syncer, 2024/10/06