MapLink Pro 11.1.1.0.
Envitia MapLink Pro: The Ultimate Mapping Application Toolkit
Loading...
Searching...
No Matches
TSLWMSGetLegendGraphicResponse Class Reference

Detailed Description

This class represents a GetLegendGraphic response. This is an optionally supported request type that allows the server to produce legends for particular layer/style combinations. Plugins must implement the TSLWMSLegendSupport interface if they wish to support this capability.

To use this class, the createGraphic method must be called to create a drawable response of the required size.

Public Member Functions

TSLWMSGetMapRasterResponsecreateGraphic (const TSLWMSGetLegendGraphicRequest &request, unsigned int width, unsigned int height, unsigned int bgColor=0xFFFFFF)
 

Member Function Documentation

◆ createGraphic()

TSLWMSGetMapRasterResponse * TSLWMSGetLegendGraphicResponse::createGraphic ( const TSLWMSGetLegendGraphicRequest & request,
unsigned int width,
unsigned int height,
unsigned int bgColor = 0xFFFFFF )

This method is used to construct a TSLWMSGetMapRasterResponse that the plugin should use. The object is owned by the TSLWMSGetLegendGraphicResponse class and should a second call be made to this class, the original one will be deleted.

Parameters
requestThe original request
widthThe desired width of the raster response
heightThe desired height of the raster response
bgColorThe desired background colour of the raster response. This should be in the format XXBBGGRR, where the two most significant bytes are ignored and the remaining describe the red, blue and green components of the colour.