| 4528 | } |
| 4529 | |
| 4530 | static void writeLegend(FILE *stream, int indent, legendObj *legend) |
| 4531 | { |
| 4532 | colorObj c; |
| 4533 | |
| 4534 | indent++; |
| 4535 | writeBlockBegin(stream, indent, "LEGEND"); |
| 4536 | MS_INIT_COLOR(c,255,255,255,255); |
| 4537 | writeColor(stream, indent, "IMAGECOLOR", &c, &(legend->imagecolor)); |
| 4538 | writeKeyword(stream, indent, "INTERLACE", legend->interlace, 2, MS_TRUE, "TRUE", MS_FALSE, "FALSE"); |
| 4539 | writeDimension(stream, indent, "KEYSIZE", legend->keysizex, legend->keysizey, NULL, NULL); |
| 4540 | writeDimension(stream, indent, "KEYSPACING", legend->keyspacingx, legend->keyspacingy, NULL, NULL); |
| 4541 | writeLabel(stream, indent, &(legend->label)); |
| 4542 | writeColor(stream, indent, "OUTLINECOLOR", NULL, &(legend->outlinecolor)); |
| 4543 | if(legend->status == MS_EMBED) writeKeyword(stream, indent, "POSITION", legend->position, 6, MS_LL, "LL", MS_UL, "UL", MS_UR, "UR", MS_LR, "LR", MS_UC, "UC", MS_LC, "LC"); |
| 4544 | writeKeyword(stream, indent, "POSTLABELCACHE", legend->postlabelcache, 1, MS_TRUE, "TRUE"); |
| 4545 | writeKeyword(stream, indent, "STATUS", legend->status, 3, MS_ON, "ON", MS_OFF, "OFF", MS_EMBED, "EMBED"); |
| 4546 | writeKeyword(stream, indent, "TRANSPARENT", legend->transparent, 2, MS_TRUE, "TRUE", MS_FALSE, "FALSE"); |
| 4547 | writeString(stream, indent, "TEMPLATE", NULL, legend->template); |
| 4548 | writeBlockEnd(stream, indent, "LEGEND"); |
| 4549 | writeLineFeed(stream); |
| 4550 | } |
| 4551 | |
| 4552 | /* |
| 4553 | ** Initialize, load and free a scalebarObj structure |
no test coverage detected