source: trunk/SRC/Documentation/idldoc_html_output/ToBeReviewed/STRING/string2struct.html @ 338

Last change on this file since 338 was 338, checked in by smasson, 16 years ago

update documentation

File size: 6.7 KB
Line 
1
2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
3 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
4
5<!-- Generated by IDLdoc 2.0 -->
6
7<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
8  <head>
9    <title>string2struct.pro (SAXO Documentation)</title>
10
11   
12    <link rel="stylesheet" type="text/css" media="all" href="./../../main_files.css" />
13    <link rel="stylesheet" type="text/css" media="print" href="./../../main_files_print.css" />
14   
15
16    <script type="text/javascript">
17      function setTitle() {
18        parent.document.title="string2struct.pro (SAXO Documentation)";
19      }
20    </script>
21  </head>
22
23  <body onload="setTitle();">
24
25    <div id="navbar_title">
26  <h1>SAXO Documentation</h1>
27</div>
28
29
30<div id="main_navbar">
31
32  <table cellspacing="0">
33    <tr>
34     
35      <td><a href="./../../overview.html" title="Overview of library">Overview</a></td>
36     
37
38     
39      <td >Directory</td>
40     
41
42     
43      <td><a href="./../../idldoc-categories.html" title="Browse library by category">Categories</a></td>
44     
45
46     
47      <td><a href="./../../idldoc-index.html" title="Index of files, routines, and parameters">Index</a></td>
48     
49
50     
51      <td><a href="./../../search-page.html" title="Search library">Search</a></td>
52     
53
54      <td id="selected">File</td>
55
56     
57      <td><a href="../../../../ToBeReviewed/STRING//string2struct.pro" title="Source code of a file">Source</a></td>
58     
59
60     
61      <td><a href="./../../idldoc-help.html" title="Help on IDLdoc">Help</a></td>
62     
63
64      <td >Etc</td>
65
66      <td id="flexible">Developer&nbsp;documentation</td>
67    </tr>
68  </table>
69
70</div>
71
72<div id="secondary_navbar">
73
74<a href="str_size.html">&lt;&lt;prev file</a> | <a href="strkeywd.html">next file &gt;&gt;</a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="string2struct.html" target="_TOP">view single page</a> | <a href="./../../index.html" target="_TOP">view frames</a>&nbsp;&nbsp;&nbsp;&nbsp;summary: fields | <a href="#routine_summary">routine</a>&nbsp;&nbsp;&nbsp;&nbsp;details: <a href="#routine_details">routine</a>
75
76</div>
77
78
79    <div id="container">
80
81      <h1 class="directory"><a href="directory-overview.html">ToBeReviewed/STRING/</a></h1>
82      <h2 class="pro_file">string2struct.pro</h2>
83
84      <div id="file_attr">
85        <dl>
86        </dl>
87      </div>
88
89      <div id="file_comments">
90 This is a really, really cool way to turn keywords into a structure.
91
92
93 Takes an input string set up as keywords and returns an anonymous structure.
94 This is particularly useful for taking keywords entered by a user in a text
95 field and passing then to other routines.
96</div>
97
98     
99
100     
101
102     
103
104     
105      <div id="routine_summary">               
106        <h2>Routine summary</h2>
107       
108        <dl>
109         
110          <dt><p><a href="#_too_cool"><span class="result">result = </span>too_cool(_EXTRA=<span class="result">_EXTRA</span>)</a></p><dt>
111          <dd> </dd>   
112         
113          <dt><p><a href="#_string2struct"><span class="result">result = </span>string2struct(<span class="result">strVal</span>)</a></p><dt>
114          <dd> </dd>   
115               
116        </dl>
117      </div>
118     
119
120      <div id="routine_details">
121       
122
123        <div class="routine_details" id="_too_cool">
124
125          <h2><a class="top" href="#container">top</a>too_cool <span class="categories">
126
127</span></h2>
128       
129          <p class="header">
130            <span class="result">result = </span>too_cool(<a href="#_too_cool_keyword__EXTRA">_EXTRA</a>=<span class="result">_EXTRA</span>)</p>
131       
132          <div class="comments">
133</div>
134
135          <h3>Return value</h3><div class="preformat">
136</div>
137
138         
139
140         
141
142            <h3>Keywords</h3>
143           
144            <h4 id="_too_cool_keyword__EXTRA">_EXTRA&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
145             
146             
147             
148             
149             
150             
151             
152             
153            </h4>
154       
155            <div class="comments">
156 Used to pass keywords
157</div>
158           
159         
160
161          <h3>Examples</h3><div class="preformat">
162</div>
163          <h3>Version history</h3>
164         
165          <h4>Version</h4><div class="preformat">
166 $Id: string2struct.pro 325 2007-12-06 10:04:53Z pinsard $
167</div>
168          <h4>History</h4><div class="preformat">
169</div>
170         
171         
172          <h3>Known issues</h3>
173         
174         
175         
176          <h4>Restrictions</h4><div class="preformat">
177</div>
178       
179         
180         
181         
182         
183         
184         
185         
186       
187          <h3>Statistics</h3>
188          <table class="statistics">
189            <tr><td>McCabe cyclic</td><td>           1</td></tr>
190            <tr><td>McCabe essential</td><td>           1</td></tr>
191            <tr><td>McCabe modular design</td><td>           1</td></tr>
192          </table>
193         
194       
195        </div>
196       
197
198        <div class="routine_details" id="_string2struct">
199
200          <h2><a class="top" href="#container">top</a>string2struct <span class="categories">
201 Utilities
202</span></h2>
203       
204          <p class="header">
205            <span class="result">result = </span>string2struct(<span class="result"><a href="#_string2struct_param_strVal">strVal</a></span>)</p>
206       
207          <div class="comments">
208</div>
209
210          <h3>Return value</h3><div class="preformat">
211 This function returns the string as an anonymous structure. If an
212 error was found then this function returns a structure with a null field.
213</div>
214
215         
216            <h3>Parameters</h3>
217       
218           
219            <h4 id="_string2struct_param_strVal">strVal&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
220              <span class="attr">in</span>
221             
222             
223              <span class="attr">required</span>
224             
225             
226             
227             
228            </h4>
229       
230          <div class="comments">
231 String set up as keywords. Keywords require a little special treatment. Such as
232 plot,findgen(100),_extra=stringToStructure('title="testing"')
233</div>
234           
235
236         
237
238         
239
240          <h3>Examples</h3><div class="preformat">
241       The code below creates a widget that uses this routine.
242       pro tPlot,event
243       widget_control,event.top,get_uvalue=field
244       widget_control,field,get_value=strVal
245       extra = stringToStructure(strVal)
246       plot,findgen(100),_extra=extra
247       wshow
248       return
249       end
250
251       pro testWid
252       ;enter any keyword to plot and see how it works
253       base = widget_base(/col)
254       field = cw_field(base,title='test',value='ax=0',/string)
255       void = widget_button(base,value='plot',event_pro='tPlot')
256       widget_control,base,/realize,set_uvalue=field
257       xmanager,'testWid',base,/no_block
258       return
259       end
260</div>
261          <h3>Version history</h3>
262         
263          <h4>Version</h4><div class="preformat">
264 $Id: string2struct.pro 325 2007-12-06 10:04:53Z pinsard $
265</div>
266          <h4>History</h4><div class="preformat">
267       Written by:
268       RLK, Ronn Kling Consulting.
269       ronn@rlkling.com
270       www.rlkling.com
271               May, 1999
272</div>
273         
274         
275         
276         
277         
278         
279         
280       
281         
282         
283         
284         
285         
286         
287         
288       
289          <h3>Statistics</h3>
290          <table class="statistics">
291            <tr><td>McCabe cyclic</td><td>           2</td></tr>
292            <tr><td>McCabe essential</td><td>           1</td></tr>
293            <tr><td>McCabe modular design</td><td>           1</td></tr>
294          </table>
295         
296       
297        </div>
298       
299      </div>
300
301     
302
303      <div id="tagline">Produced by IDLdoc 2.0.</div>
304
305    </div>
306
307  </body>
308</html>
Note: See TracBrowser for help on using the repository browser.