diff --git a/tutorial/image.png b/tutorial/image.png new file mode 100644 index 0000000000000000000000000000000000000000..d39959fd79011a602ad7e99cfebf7ec3bb46d9e5 Binary files /dev/null and b/tutorial/image.png differ diff --git a/tutorial/t4.geo b/tutorial/t4.geo index a860690996a3442ca60ca6371e002bab6276ab2c..cc1e501eb7450f0fb7ec18a624669e6c9ab23736 100644 --- a/tutorial/t4.geo +++ b/tutorial/t4.geo @@ -90,8 +90,18 @@ View "comments" { // Add a text string in model coordinates at (X,Y,Z) = (0, 0.11, 0): T3(0, 0.11, 0, 0){ "Hole" }; + + // If a string starts with `file://', the rest is interpreted as an image + // file, whose size and orientation can be specified after a `@' symbol: + T3(-0.01, 0.09, 0, 0){ "file://image.png@0.02x0" }; + T2(195, -7, 0){ "file://image.png@20x0" }; }; +// Views and geometrical entities can be made to respond to double-click events: +View[0].DoubleClickedCommand = "Printf('View[0] has been double-clicked!');"; +Geometry.DoubleClickedLineCommand = "Printf('Line %g has been double-clicked!', + Geometry.DoubleClickedEntityTag);"; + Color Grey50{ Surface{ 22 }; } Color Purple{ Surface{ 24 }; } Color Red{ Line{ 1:14 }; }