Question from a DK customer: "How can I use the DK to draw labels that are backed by a bitmap aligned with the label location following a line? I need to draw the highway markers behind the highway numbers, all aligned properly with the direction of the highway".
The DK (as of the v. 8.0) does not provide a specific function to do this, but this is very easy to implement. Just override the OnPaintShape handler and draw the symbol "manually", with:
mylayer.OnPaintShape := doPaintShape ; ...
procedure TForm1.doPaintShape( const _sender : TOBject; const _shape :
ptg : TGIS_Point ;
pt : TPoint ;
// calculate center point of the line;
ptg := shp.Centroid ;
pt := GIS.MapToScreen( ptg ) ;
// draw the shape itself
// draw the bitmap symbol on the top
GIS.Canvas.Draw( pt.x, pt,y, mybitmap ) ;