From 4a8e8d737ce2cc09de1cd5eaff00badba3879f2f Mon Sep 17 00:00:00 2001 From: Camil Staps Date: Thu, 7 Apr 2016 23:47:35 +0200 Subject: TeXample background --- bin/setbg2 | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100755 bin/setbg2 (limited to 'bin/setbg2') diff --git a/bin/setbg2 b/bin/setbg2 new file mode 100755 index 0000000..3721944 --- /dev/null +++ b/bin/setbg2 @@ -0,0 +1,29 @@ +#!/bin/bash + +SCR_WIDTH=1980 +SCR_HEIGHT=1080 +PADDING=50 +FONT_SIZE=20 + +let "SCR_WIDTH -= 2 * $PADDING" +let "SCR_WIDTH /= 2" +let "SCR_HEIGHT -= 2 * $PADDING" + +PAGE=$RANDOM; let "PAGE %= 22"; let "PAGE += 1" + +cd /tmp +wget -qO texample.html "http://texample.net/tikz/examples/all/?page=$PAGE" +EXAMPLES="$(grep '^