|
Warning: this is an htmlized version!
The original is here, and the conversion rules are here. |
;; -*- lexical-binding: nil; -*-
;; This file:
;; http://anggtwu.net/MAXIMA/edrx-maxima.el.html
;; http://anggtwu.net/MAXIMA/edrx-maxima.el
;; (find-angg "MAXIMA/edrx-maxima.el")
;; Author: Eduardo Ochs <eduardoochs@gmail.com>
;; Version: 2025jun07
;; See: (find-windows-beginner-intro "12. Install qdraw")
;; «.m» (to "m")
;; «.maxima-mode» (to "maxima-mode")
;; «.find-maximanode» (to "find-maximanode")
;; «.myqdraw» (to "myqdraw")
;; «.ilq» (to "ilq")
;; «.lisptree» (to "lisptree")
;; «._s_» (to "_s_")
;; «.ils» (to "ils")
;; «.find-flipbookanim-links» (to "find-flipbookanim-links")
;;; __ __
;;; | \/ | __ __ _ __ ___
;;; | |\/| |____\ \/ / | '_ ` _ \
;;; | | | |_____> < | | | | | |
;;; |_| |_| /_/\_\ |_| |_| |_|
;;;
;; «m» (to ".m")
;; See: (find-eev "eev-aliases.el")
;; (find-eev-quick-intro "7.3. Defining eejump targets")
;; (find-eev-quick-intro "7.4. Commands with very short names")
;; (find-angg-es-links)
(defun m () (interactive) (find-es "maxima"))
;;; __ __ _ _
;;; | \/ | __ ___ _(_)_ __ ___ __ _ _ __ ___ ___ __| | ___
;;; | |\/| |/ _` \ \/ / | '_ ` _ \ / _` | | '_ ` _ \ / _ \ / _` |/ _ \
;;; | | | | (_| |> <| | | | | | | (_| | | | | | | | (_) | (_| | __/
;;; |_| |_|\__,_/_/\_\_|_| |_| |_|\__,_| |_| |_| |_|\___/ \__,_|\___|
;;;
;; «maxima-mode» (to ".maxima-mode")
;; For: (find-fline "~/MAXIMA/" " maxima.el")
;; (find-fline "~/MAXIMA/" "maxima-font-lock.el")
(setq load-path (delete "~/MAXIMA/" load-path))
(add-to-list 'load-path "~/MAXIMA/")
(add-to-list 'auto-mode-alist '(".mac$" . maxima-mode))
(autoload 'maxima-mode "maxima" nil t)
;;; __ __ _
;;; | \/ | __ _ _ __ _ _ __ _| |
;;; | |\/| |/ _` | '_ \| | | |/ _` | |
;;; | | | | (_| | | | | |_| | (_| | |
;;; |_| |_|\__,_|_| |_|\__,_|\__,_|_|
;;;
;; «find-maximanode» (to ".find-maximanode")
;; Tests: (find-maximanode "")
;; (find-maximafile "")
;; (find-maximafile "share/")
;; See: (find-fline "/usr/share/maxima/")
(code-c-d "maxima" "/usr/share/maxima/5.47.0/" "maxima")
;;; __ __ ___ _
;;; | \/ |_ _ / _ \ __| |_ __ __ ___ __
;;; | |\/| | | | | | | |/ _` | '__/ _` \ \ /\ / /
;;; | | | | |_| | |_| | (_| | | | (_| |\ V V /
;;; |_| |_|\__, |\__\_\\__,_|_| \__,_| \_/\_/
;;; |___/
;;
;; «myqdraw» (to ".myqdraw")
;; See: (find-myqdraw "")
;; (find-myqdraw "myqdraw3.mac")
;; http://anggtwu.net/eev-qdraw.html
(code-c-d "myqdraw" "~/myqdraw/" :anchor)
;;; _ _
;;; (_) | __ _
;;; | | |/ _` |
;;; | | | (_| |
;;; |_|_|\__, |
;;; |_|
;;
;; «ilq» (to ".ilq")
;; See: (find-windows-beginner-intro "12.1. `M-x ils' and friends")
(defalias 'ilq 'insert-load-qdraw)
(defun insert-load-qdraw ()
(interactive)
(insert "\
** (find-myqdraw \"myqdraw3.mac\")
load_myqdraw();
"))
'("An example of how to use `M-x ilq':
* (eepitch-maxima)
* (eepitch-kill)
* (eepitch-maxima)
** (find-myqdraw "myqdraw3.mac")
** (find-myqdraw "myqdraw3.mac" "zpts")
load_myqdraw();
[xmin,ymin, xmax,ymax] : [-3,-3, 3,3];
a : 1 + %i*1/2;
as : makelist(a^n, n,0,10);
myqdraw(xyrange(), zpts(as));
--")
;; See: (find-myqdraw "mydraw3d.mac")
(defun il3 () (interactive) (insert "\
** (find-myqdraw \"mydraw3d.mac\")
load (\"~/myqdraw/mydraw3d.mac\");
"))
;;; _ _ _____
;;; | | (_)___ _ _|_ _| __ ___ ___
;;; | | | / __| '_ \| || '__/ _ \/ _ \
;;; | |___| \__ \ |_) | || | | __/ __/
;;; |_____|_|___/ .__/|_||_| \___|\___|
;;; |_|
;;
;; «lisptree» (to ".lisptree")
;; See: (find-lisptree "")
;; (find-lisptree "lisptree.mac")
;; http://anggtwu.net/lisptree.html
(code-c-d "lisptree" "~/lisptree/" :anchor)
(defun ilt ()
(interactive)
(insert "\
** (find-lisptree \"lisptree.mac\")
load (\"~/lisptree/lisptree.mac\");
"))
'("An example of how to use `M-x ilq':
* (eepitch-maxima)
* (eepitch-kill)
* (eepitch-maxima)
** (find-lisptree "lisptree.mac")
load ("~/lisptree/lisptree.mac");
lisptree(integrate(f(x),x,2,4));
--")
;;; ___
;;; / __|
;;; \__ \
;;; ____|___/____
;;; |_____| |_____|
;;
;; «_s_» (to "._s_")
;; «ils» (to ".ils")
;; See: (find-windows-beginner-intro "12.1. `M-x ils' and friends")
;; (find-angg "MAXIMA/2025-1-s.mac")
(defun ils ()
(interactive)
(insert "\
** (find-fline \"~/MAXIMA/2025-1-s.mac\")
load (\"~/MAXIMA/2025-1-s.mac\");
"))
;;; __ _ _ _ _ _
;;; / _| (_)_ __ | |__ ___ ___ | | ____ _ _ __ (_)_ __ ___
;;; | |_| | | '_ \| '_ \ / _ \ / _ \| |/ / _` | '_ \| | '_ ` _ \
;;; | _| | | |_) | |_) | (_) | (_) | < (_| | | | | | | | | | |
;;; |_| |_|_| .__/|_.__/ \___/ \___/|_|\_\__,_|_| |_|_|_| |_| |_|
;;; |_|
;;
;; «find-flipbookanim-links» (to ".find-flipbookanim-links")
;; Skel: (find-find-links-links-new "flipbookanim" "jpgargs gifargs" "")
;; Test: (find-flipbookanim-links)
;; See: (find-myqdraw "mydraw3d.mac" "flipbook-anim")
;;
(defun find-flipbookanim-links (&optional jpgargs gifargs &rest pos-spec-list)
"Visit a temporary buffer containing hyperlinks for flipbookanim."
(interactive)
(setq jpgargs (or jpgargs "{jpgargs}"))
(setq gifargs (or gifargs "{gifargs}"))
(apply
'find-elinks
`((find-flipbookanim-links ,jpgargs ,gifargs ,@pos-spec-list)
(find-flipbookanim-links "quality=80 -r 150" "--delay 20")
;; Convention: the first sexp always regenerates the buffer.
(find-efunction 'find-flipbookanim-links)
""
,(ee-template0 "\
* (sh-mode)
* (eepitch-bash)
* (eepitch-kill)
* (eepitch-bash)
add_1zs () {<} for i in $*; do echo $i 1-z; done; {>}
cutext () {<} echo $1 | rev | cut -f2- -d. | rev; {>}
jpgtogif () {<} echo convert $1 $(cutext $1).gif;
convert $1 $(cutext $1).gif; {>}
jpgstogifs () {<} for i in $*; do jpgtogif $i; done; {>}
rm -fv /tmp/frame_*.jpg
rm -fv /tmp/frames*.pdf
rm -fv /tmp/frame*.gif
ls -lAF /tmp/frame*
add_1zs /tmp/frame_*.pdf
qpdf --empty --pages $(add_1zs /tmp/frame_*.pdf) -- /tmp/frames.pdf
pdftoppm -jpeg -jpegopt {jpgargs} -sep _ /tmp/frames.pdf /tmp/frame
jpgstogifs /tmp/frame*.jpg
gifsicle --colors 256 --loop {gifargs} /tmp/frame_*.gif > /tmp/frames.gif
file /tmp/frames.gif
rm -fv /tmp/frame_*.jpg
rm -fv /tmp/frame_*.gif
ls -lAF /tmp/frame*
# (find-pdf-page \"/tmp/frames.pdf\")
# (brg \"file:///tmp/frames.gif\")
")
)
pos-spec-list))
;; Local Variables:
;; coding: utf-8-unix
;; End: