<!doctype html public "-//W3C//DTD W3 HTML//EN">
<html><head><style type="text/css"><!--
blockquote, dl, ul, ol, li { padding-top: 0 ; padding-bottom: 0 }
 --></style><title>Re: [UMN_MAPSERVER-USERS] how to use pictures as
labels</title></head><body>
<div>I don't have an example, but let me try explaining another
way.</div>
<div><br></div>
<div>For option one, I was suggesting that you figure out, in advance,
all possible combinations of all possible symbols, and generate all
possible icons that correspond to those states.&nbsp; In retrospect I
don't like that idea as much.</div>
<div><br></div>
<div>For option two, think of it in two steps.&nbsp; Consider only the
image that will be drawn to the upper-right of the mapped location.&nbsp;
Say you're mapping towns:&nbsp; if the town's economy is industrial
draw a red circle, and if it's agricultural draw a green square.&nbsp;
Now hopefully you understand how to map just that much of it, drawing
the red circle or green square at the exact location of the town:&nbsp;
define two classes in your layer for &quot;economy type&quot;, with
SYMBOL definitions for the red circle and green square.</div>
<div><br></div>
<div>At that point you have a map which draws one of the components of
your compound symbol, but it draws it dead center on the city
location, and you need it offset. Let's say your symbol fits in a box
8 pixels by 8 pixels.&nbsp; Now redefine your symbol.&nbsp; Put it in
a box that's 24 pixels by 24 pixels.&nbsp; But don't put it in the
center of that box--put it in the upper right corner instead, and
leave the other 8 cells blank.&nbsp; You can draw that 24x24 symbol at
the center point of the city, and your red circle/green square will be
offset.</div>
<div><br></div>
<div>Now repeat that for each of your other &quot;image labels&quot;,
with one LAYER per &quot;label&quot;, and one CLASS for each different
symbol that could appear in that corner of the icon.</div>
<div><br></div>
<div>Hal</div>
<div><br></div>
<div>At 8:04 AM -0800 11/7/06, william paul wrote:</div>
<blockquote type="cite" cite>Hi Hal:<br>
<br>
Do you have an example with a MAP file? I don't understand the first
option. In the second one how can I use OFF- Centered?<br>
<br>
The icons depends on the attribute data, which means that some points
will have less symbols and other points will have more symbols<br>
<br>
William<br>
<br>
<i><b>Hal Mueller &lt;hal@MOBILEGEOGRAPHICS.COM&gt;</b></i> wrote:<br>
<blockquote>Are the surrounding labels data-dependent? Or is there a
small<br>
number of states?<br>
<br>
One way to approach this is to pre-render the point icon plus<br>
&quot;labels&quot;, and use that image as the icon for your plot.<br>
<br>
Another way to do it would be to have 5 different layers, one for<br>
each of the different images. The trick is that for the 4 layers<br>
representing the layers, you use a large icon, but with the image<br>
off-centered. That is, make 4 copies of your &quot;image 2&quot;. In
each<br>
copy, delete the red circle. In copy one, delete all but the green<br>
rectangle. In copy two, delete all but the purple diamond.<br>
<br>
Hal<br>
</blockquote>
</blockquote>
<blockquote type="cite" cite><br></blockquote>
<blockquote type="cite" cite>&nbsp;</blockquote>
<blockquote type="cite" cite>
<hr size="1"></blockquote>
<blockquote type="cite" cite>Everyone is raving about <a
href=
"http://us.rd.yahoo.com/evt=45083/*http://advision.webevents.yahoo.com/mailbeta"><span
></span>the all-new Yahoo! Mail.</a></blockquote>
<div><br></div>
<div><br></div>
</body>
</html>