fix org babel gnuplot loading

This commit is contained in:
2026-04-08 20:14:30 +02:00
parent 2f249d0979
commit bd072b2c58
5 changed files with 339 additions and 2 deletions

View File

@@ -4,7 +4,7 @@
** syntax highlighting
*** graphviz dot
#+begin_src dot
#+begin_src dot :file img/src-dot.svg
digraph G {
main -> parse -> execute;
main -> init;
@@ -17,6 +17,10 @@ digraph G {
}
#+end_src
#+ATTR_ORG: :width 300
#+RESULTS:
[[file:img/src-dot.svg]]
*** gnuplot
#+begin_src gnuplot :results silent
reset
@@ -39,6 +43,20 @@ h(x) = 10*sqrt(abs(x))
plot f(x) w lp lw 1, g(x) w p lw 2, h(x) w l lw 3
#+end_src
#+NAME: tab-gnuplot
| 3.75 | 2.5 |
| 4.43 | 3 |
| 5.5 | 3 |
| 3.5 | 3.5 |
#+begin_src gnuplot :var data=tab-gnuplot :exports results :file img/gnuplot-tab.svg
set terminal svg size 400,320
plot data u 1 t "unsorted", \
'' u 2 lt 3 t "sorted"
#+end_src
#+RESULTS:
[[file:img/gnuplot-tab.svg]]
** custom header