mirror of
https://codeberg.org/cage/tinmop/
synced 2025-01-03 01:09:20 +01:00
- added 'about' help window.
This commit is contained in:
parent
cd9b66d2be
commit
7640da7d60
@ -69,6 +69,8 @@ $(CONF_PATH_FILE):
|
||||
echo "(alexandria:define-constant +program-version+" >> $(CONF_PATH_FILE);
|
||||
echo -e "\""$(VERSION)"\" :test #'string=)\n" >> $(CONF_PATH_FILE);
|
||||
|
||||
echo "(alexandria:define-constant +issue-tracker+" >> $(CONF_PATH_FILE);
|
||||
echo -e "\""$(PACKAGE_BUGREPORT)"\" :test #'string=)\n" >> $(CONF_PATH_FILE);
|
||||
cat $(CONF_PATH_FILE).in | sed "\/^;;.*$\/d" >> $(CONF_PATH_FILE);
|
||||
|
||||
dist-hook:
|
||||
|
@ -125,6 +125,7 @@
|
||||
|
||||
(define-key "q" #'quit) ; here we are calling the custom
|
||||
; function defined above
|
||||
(define-key "C-a" #'show-about-window)
|
||||
|
||||
(define-key "?" #'print-quick-help)
|
||||
|
||||
|
@ -16,8 +16,9 @@
|
||||
|
||||
(in-package :constants)
|
||||
|
||||
(define-constant +help-about-message-template+
|
||||
"~a
|
||||
(define-constant +help-about-message+
|
||||
(format nil
|
||||
"~a
|
||||
Copyright (C) 2019 cage
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
@ -31,7 +32,13 @@
|
||||
General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. "
|
||||
along with this program.
|
||||
|
||||
For bug report please point your browser to:
|
||||
|
||||
~a"
|
||||
+program-name+
|
||||
+issue-tracker+)
|
||||
:test #'string=)
|
||||
|
||||
(define-constant +http-code-ok+ 200 :test #'=)
|
||||
|
@ -23,15 +23,17 @@
|
||||
:+text-domain+
|
||||
:+program-name+
|
||||
:+program-version+
|
||||
:+issue-tracker+
|
||||
:+home-data-dir+
|
||||
:_
|
||||
:n_))
|
||||
|
||||
(defpackage :constants
|
||||
(:use :cl
|
||||
:alexandria)
|
||||
:alexandria
|
||||
:config)
|
||||
(:export
|
||||
:+help-about-message-template+
|
||||
:+help-about-message+
|
||||
:+http-code-ok+
|
||||
:+mime-type-jpg+
|
||||
:+mime-type-png+
|
||||
@ -1882,7 +1884,8 @@
|
||||
:report-status
|
||||
:crypto-import-key
|
||||
:crypto-export-key
|
||||
:crypto-generate-key))
|
||||
:crypto-generate-key
|
||||
:show-about-window))
|
||||
|
||||
(defpackage :modules
|
||||
(:use
|
||||
|
@ -1131,3 +1131,14 @@ Starting from the oldest toot and going back."
|
||||
(ask-string-input #'on-add-username
|
||||
:prompt (_ "Username: ")
|
||||
:complete-fn #'complete:username-complete)))
|
||||
|
||||
(defun show-about-window ()
|
||||
(let ((lines (text-utils:split-lines +help-about-message+))
|
||||
(bg (swconf:win-bg swconf:+key-help-dialog+))
|
||||
(fg (swconf:win-fg swconf:+key-help-dialog+)))
|
||||
(windows:make-blocking-message-dialog specials:*main-window*
|
||||
nil
|
||||
(_ "About this software")
|
||||
lines
|
||||
bg
|
||||
fg)))
|
||||
|
Loading…
Reference in New Issue
Block a user