3.2. GRAPHICS PRIMITIVES (IN DETAIL) 17This command must appear before the first size command in the <strong>GLE</strong> file.rbezier x1 y1 x2 y2 x3 y3This command is identical to the BEZIER command except that the points are all relative to thecurrent point.amove 0.5 2.8rbezier 1 1 2 -1 3 1amove 0.2 0.2rbezier 1 1 2 1.2 1.8 0return expThe return command is used inside subroutines to return a value.reverseReverses the direction of the current path. This is used when filling multiple paths in order thatthe Non-Zero Winding Rule will know which part of the path is ‘inside’.With the Non-Zero Winding Rule an imaginary line is drawn through the object. Every time aline of the object crosses it from left to right, one is added to the counter; every time a line of theobject crosses it from right to left, one is subtracted from the counter. Everywhere the counter isnon-zero is considered to be the ‘inside’ of the drawing and is filled.0 1 0 1 0 0 1 2 1 0rline x y [arrow end] [arrow start] [arrow both] [curve α1 α2 d1 d2]Draws a line from the current point to the relative coordinates (x,y), which then become the newcurrent point. If the current point is (5,5) then rline 3 -2 is equivalent to aline 8 3. The optionalqualifiers on the end of the command will draw arrows at one or both ends of the line, the size ofthe arrow head is proportional to the current font size.The curve option is explained with the aline command.rmove x yChanges the current point to the relative coordinate (x,y). If the current point is (5,5) then rmove3 -2 is equivalent to amove 8 3.save objectnameThis command saves a point for later use with the join command.set alabeldist dThe spacing between the graph axis labels and the axis is set to d.set alabelscale sThe graph axis label font size is set to ‘alabelscale’ times ‘hei’.set arrowangle angleSets the opening angle of the arrow tips. (Actually, half of the opening angle.)set arrowsize sizeSets the length of the arrow tips in centimeter.
18 CHAPTER 3. PRIMITIVESFigure 3.4: Different arrow tip styles.set arrowstyle simple — filled — emptySets the style of the arrow tips. There are three pre-defined styles: simple, filled, and empty (SeeFig. 3.4).It is also possible to create user-defined arrow tip styles. To do so, create a subroutine ‘arrow xxxxlangle aangle asize’, with xxxx the name of the new style. The parameter langle is the angle of theline on which the arrow tip is to be drawn and the parameters aangle and asize are the currentvalues of the settings arrowangle and arrowsize. The user-defined style can be enabled, in the sameway as the built-in ones, with ‘set arrowstyle xxxx’. Fig. 3.4 shows the three predefined styles and auser-defined tip style that is defined by the following subroutine:sub arrow_circle langle aangle asizecircle 0.1 fill redend subMore complex examples of user-defined arrow styles can be found in the <strong>GLE</strong> example repository.set atitledist sThe spacing between the graph axis title and the axis labels is set to d.set atitlescale sThe graph axis title font size is set to ‘atitlescale’ times ‘hei’.set background it cSet the background color for a pattern fill to c. (See ‘set fill’.)set cap butt — round — squareDefines what happens at the end of a wide line.set cap buttset cap roundset cap squareset color colSets the current colour for all future drawing operations. <strong>GLE</strong> supports all SVG/X11 standardcolor names. These are listed in Appendix A.7, and include the following: black, white, red, green,blue, cyan, magenta, yellow, gray10, gray20, . . ., gray90. It is also possible to specify a gray scale asa real number with 0.0 = black and 1.0 = white. Colors can also be set using the HTML notation,e.g., #FF0000 = red. Finally, the functions rgb(red,green,blue) and rgb255(red,green,blue) may beused to create custom colors. Fig. 3.5 gives some examples.mm$ = "blue"amove 0.5 0.5for c = 0 to 1 step 0.05box 0.2 2 fill (c) noboxrmove 0.2 0next camove 2 1box 2 1 fill white noboxrmove -0.2 0.2box 2 1 fill mm$
- Page 1: Professional Graphics LanguageProfe
- Page 4 and 5: ivCONTENTS7.2.4 Import a GLE Figure
- Page 6 and 7: 1• Chapter 4, The Graph Module:De
- Page 8 and 9: Chapter 2Tutorial2.1 Installing GLE
- Page 10 and 11: 2.4. DRAWING A SIMPLE GRAPH 5gle -p
- Page 12 and 13: Chapter 3PrimitivesA GLE command is
- Page 14 and 15: 3.2. GRAPHICS PRIMITIVES (IN DETAIL
- Page 16 and 17: 3.2. GRAPHICS PRIMITIVES (IN DETAIL
- Page 18 and 19: 3.2. GRAPHICS PRIMITIVES (IN DETAIL
- Page 20 and 21: 3.2. GRAPHICS PRIMITIVES (IN DETAIL
- Page 24 and 25: 3.2. GRAPHICS PRIMITIVES (IN DETAIL
- Page 26 and 27: 3.2. GRAPHICS PRIMITIVES (IN DETAIL
- Page 28 and 29: Chapter 4The Graph ModuleA graph sh
- Page 30 and 31: 4.2. GRAPH COMMANDS (IN DETAIL) 25b
- Page 32 and 33: 4.2. GRAPH COMMANDS (IN DETAIL) 271
- Page 34 and 35: 4.2. GRAPH COMMANDS (IN DETAIL) 29M
- Page 36 and 37: 4.2. GRAPH COMMANDS (IN DETAIL) 31a
- Page 38 and 39: 4.2. GRAPH COMMANDS (IN DETAIL) 33x
- Page 40 and 41: 4.2. GRAPH COMMANDS (IN DETAIL) 351
- Page 42 and 43: 4.3. BAR GRAPHS 37Planet sizesNeptu
- Page 44 and 45: 4.6. NOTES ON DRAWING GRAPHS 394.6
- Page 46 and 47: Chapter 5The Key ModuleThe key modu
- Page 48 and 49: 5.2. ENTRY DEFINITION COMMANDS 43ju
- Page 50 and 51: 5.3. DEFINING THE KEY IN THE GRAPH
- Page 52 and 53: Chapter 6Programming Facilities6.1
- Page 54 and 55: 6.2. FUNCTIONS INSIDE EXPRESSIONS 4
- Page 56 and 57: 6.5. IF-THEN-ELSE 51Besides for-nex
- Page 58 and 59: 6.9. DEVICE DEPENDEND CONTROL 53fwr
- Page 60 and 61: Chapter 7Advanced FeaturesThis chap
- Page 62 and 63: 7.1. DIAGRAMS 57GRVCheeseCHVGoatsMa
- Page 64 and 65: 7.2. L A TEX INTERFACE 59house.wind
- Page 66 and 67: 7.4. COLOUR 61size 10 5begin clip !
- Page 68 and 69: Chapter 8Surface and Contour Plots8
- Page 70 and 71: 8.1. SURFACE PRIMITIVES 65ylines of
- Page 72 and 73:
8.2. LETZ 67zclip [min v1 ] [max v2
- Page 74 and 75:
8.5. COLOR MAPS 69• pixels-x, pix
- Page 76 and 77:
Chapter 9GLE Utilities9.1 FitlsThe
- Page 78 and 79:
9.2. MANIP 73c1 == c1c1r1r10 == 1,1
- Page 80 and 81:
9.2. MANIP 75BLANK"% BLANK C2C3" Cl
- Page 82 and 83:
9.2. MANIP 77PARSUM [range1] [range
- Page 84 and 85:
Appendix ATablesA.1 Markerstriangle
- Page 86 and 87:
A.2. FUNCTIONS AND VARIABLES 81widt
- Page 88 and 89:
A.4. INSTALLING GLE 83A.4 Installin
- Page 90 and 91:
A.6. FONT TABLES 85Typewriter (tt)0
- Page 92 and 93:
A.6. FONT TABLES 87TEXComputer Mode
- Page 94 and 95:
A.6. FONT TABLES 89PostScript Helve
- Page 96 and 97:
A.6. FONT TABLES 91(psbl)0246810121
- Page 98 and 99:
A.6. FONT TABLES 93PostScript ZapfC
- Page 100 and 101:
A.7. PREDEFINED COLORS 95GLE suppor
- Page 102 and 103:
Index!, 8, 25\expr(exp), 80.z file,
- Page 104 and 105:
INDEX 99histogram, 30horiz, 37horiz
- Page 106:
INDEX 101under, 32underneath, 66Uni