Add a "definition" float.
[matthijs/master-project/report.git] / Utils / Lambda.tex
index 2172bbc38d0c1c42a1b01c255fe5b2a4c0d82146..1128c465044e3bd0c5769bea891acb935e0a7689 100644 (file)
@@ -27,7 +27,7 @@ path a, b;
 % Create a rectangle of the full size
 a := unitsquare xyscaled(\overlaywidth,\overlayheight);
 % Randomize it a bit
-b := a randomized (\overlaywidth / 25) ;
+b := a randomized (min(\overlayheight, \overlaywidth) / 25) ;
 % And draw it
 drawoptions (withpen pencircle scaled .75mm withcolor black) ;
 draw b; 
@@ -78,3 +78,9 @@ draw b;
   \stopboxed
 }
 
+% Define a "definition" float. We would like some more backgroundoffset, but
+% this offset doesn't move the caption, causing the border to cross the
+% caption... Also, centering the content didn't seem to work...
+% TODO: Make more pretty.
+\definefloat[definition][definitions]
+\setupfloat[definition][background=box,backgroundoffset=1mm]