Font demo

Image obtained by using pbm driver and then converted to png.

 1 
 2 #include "plcdemos.h"
 3 
 4 
 5 int
 6 main(int argc, char *argv[])
 7 {
 8     char text[10];
 9     int i, j, k;
10     PLFLT x, y;
11 
12 
13     (void) plParseOpts(&argc, argv, PL_PARSE_FULL);
14 
15 
16     plinit();
17 
18     pladv(0);
19 
20 
21     plcol0(2);
22     plvpor(0.1, 1.0, 0.1, 0.9);
23     plwind(0.0, 1.0, 0.0, 1.3);
24 
25 
26     plbox("bcgt", 0.1, 0, "bcgt", 0.1, 0);
27 
28 
29     plcol0(15);
30     for (i = 0; i <= 9; i++) {
31 	sprintf(text, "%d", i);
32 	plmtex("b", 1.5, (0.1 * i + 0.05), 0.5, text);
33     }
34 
35     k = 0;
36     for (i = 0; i <= 12; i++) {
37 
38 
39 	sprintf(text, "%d", 10 * i);
40 	plmtex("lv", 1.0, (1.0 - (2 * i + 1) / 26.0), 1.0, text);
41 	for (j = 0; j <= 9; j++) {
42 	    x = 0.1 * j + 0.05;
43 	    y = 1.25 - 0.1 * i;
44 
45 		
46 	    if (k < 128)
47 		plpoin(1, &x, &y, k);
48 	    k = k + 1;
49 	}
50     }
51 
52     plmtex("t", 1.5, 0.5, 0.5, "PLplot Example 6 - plpoin symbols");
53     plend();
54     exit(0);
55 }

Copyright 2006 Roman Putanowicz

Email: putanowr at twins.pk.edu.pl

Last Modified: Thu, 13 Jul 2006 15:36:34 CEST

Made with PubTal 3.1.3