2.0_beta sync to rsa
[framework/web/web-ui-fw.git] / libs / js / jquery-geo-1.0a4 / docs / geomap / drawStyle.html
1 <!doctype html>  
2
3 <html lang="en" class="no-js">
4 <head>
5   <meta charset="utf-8">
6
7   <title>drawStyle | geomap</title>
8   <meta name="description" content="geomap drawStyle option">
9   <meta name="author" content="Ryan Westphal">
10
11   <meta name="viewport" content="width=device-width, initial-scale=1.0">
12
13   <link rel="stylesheet" href="../css/style.css?v=2">
14   <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.css" />
15 </head>
16
17 <body>
18
19   <div id="drawStyle" data-role="page">
20     <div data-role="header" data-theme="f">
21       <h1>drawStyle</h1>
22     </div>
23     
24     <div data-role="content">
25       <table>
26         <tr>
27           <th>type</th>
28           <td>Object ( geomap style )</td>
29         </tr>
30         <tr>
31           <th>default</th>
32           <td><pre><code>{
33   borderRadius: &quot;8px&quot;,
34   color: &quot;#7f0000&quot;,
35   fillOpacity: .2,
36   height: &quot;8px&quot;,
37   opacity: 1,
38   strokeOpacity: 1,
39   strokeWidth: &quot;2px&quot;,
40   visibility: &quot;visible&quot;,
41   width: &quot;8px&quot;
42 }</code></pre>
43           </td>
44         </tr>
45         <tr>
46           <th>init</th>
47           <td><pre><code>$( <i>map selector</i> ).geomap( { drawStyle: { color: &quot;green&quot; } } );</code></pre></td>
48         </tr>
49         <tr>
50           <th>get</th>
51           <td><pre><code>var drawStyle = $( <i>map selector</i> ).geomap( &quot;option&quot;, &quot;drawStyle&quot; );</code></pre></td>
52         </tr>
53         <tr>
54           <th>set</th>
55           <td><pre><code>$( <i>map selector</i> ).geomap( &quot;option&quot;, &quot;drawStyle&quot;, { strokeWidth: &quot;4px&quot; } );</code></pre></td>
56         </tr>
57       </table>
58       <p>The drawStyle option retrieves or updates the style of incomplete lines and polygons <b>as they are being drawn</b>. This differs from the shapeStyle option which updates the style of shapes that you've appended to the map.</p>
59       <p>This option affects both the draw modes (drawPoint, drawLineString, and drawPolygon) and the measure modes (measureLength, and measureArea).</p>
60       <p>This option changes specific properties of the internal style object. If you init or set an incomplete style object, only the style properties you reference are updated.</p>
61       <p>Please see the style section at the bottom of the <a href="#" onclick="javascript:window.history.back();">geomap widget</a> page for more information about the style object.</p>
62     </div>
63   </div> <!-- end of #container -->
64
65   <script src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
66   <script src="http://code.jquerygeo.com/jquery.geo-1.0a4.min.js"></script>
67   <script src="../js/script.js"></script>
68   <script src="http://code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.js"></script>
69 </body>
70 </html>
71