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

Last change on this file since 402 was 402, checked in by smasson, 15 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</span></h2>
127       
128          <p class="header">
129            <span class="result">result = </span>too_cool(<a href="#_too_cool_keyword__EXTRA">_EXTRA</a>=<span class="result">_EXTRA</span>)</p>
130       
131          <div class="comments">
132</div>
133
134          <h3>Return value</h3><div class="preformat">
135</div>
136
137         
138
139         
140
141            <h3>Keywords</h3>
142           
143            <h4 id="_too_cool_keyword__EXTRA">_EXTRA&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
144             
145             
146             
147             
148             
149             
150             
151             
152            </h4>
153       
154            <div class="comments">
155 Used to pass keywords
156</div>
157           
158         
159
160          <h3>Examples</h3><div class="preformat">
161</div>
162          <h3>Version history</h3>
163         
164          <h4>Version</h4><div class="preformat">
165 $Id: string2struct.pro 374 2008-08-08 15:12:27Z pinsard $
166</div>
167          <h4>History</h4><div class="preformat">
168</div>
169         
170         
171          <h3>Known issues</h3>
172         
173         
174         
175          <h4>Restrictions</h4><div class="preformat">
176</div>
177       
178         
179         
180         
181         
182         
183         
184         
185       
186          <h3>Statistics</h3>
187          <table class="statistics">
188            <tr><td>McCabe cyclic</td><td>           1</td></tr>
189            <tr><td>McCabe essential</td><td>           1</td></tr>
190            <tr><td>McCabe modular design</td><td>           1</td></tr>
191          </table>
192         
193       
194        </div>
195       
196
197        <div class="routine_details" id="_string2struct">
198
199          <h2><a class="top" href="#container">top</a>string2struct <span class="categories">
200 Utilities
201</span></h2>
202       
203          <p class="header">
204            <span class="result">result = </span>string2struct(<span class="result"><a href="#_string2struct_param_strval">strval</a></span>)</p>
205       
206          <div class="comments">
207</div>
208
209          <h3>Return value</h3><div class="preformat">
210 This function returns the string as an anonymous structure. If an
211 error was found then this function returns a structure with a null field.
212</div>
213
214         
215            <h3>Parameters</h3>
216       
217           
218            <h4 id="_string2struct_param_strval">strval&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
219              <span class="attr">in</span>
220             
221             
222              <span class="attr">required</span>
223             
224             
225             
226             
227            </h4>
228       
229          <div class="comments">
230 String set up as keywords. Keywords require a little special treatment.
231 Such as
232
233 plot,findgen(100),_extra=string2struct('title="testing"')
234</div>
235           
236
237         
238
239         
240
241          <h3>Examples</h3><div class="preformat">
242       The code below creates a widget that uses this routine.
243       pro tPlot,event
244       widget_control,event.top,get_uvalue=field
245       widget_control,field,get_value=strval
246       extra = string2struct(strval)
247       plot,findgen(100),_extra=extra
248       wshow
249       return
250       end
251
252       pro testWid
253       ;enter any keyword to plot and see how it works
254       base = widget_base(/col)
255       field = cw_field(base,title='test',value='ax=0',/string)
256       void = widget_button(base,value='plot',event_pro='tPlot')
257       widget_control,base,/realize,set_uvalue=field
258       xmanager,'testWid',base,/no_block
259       return
260       end
261</div>
262          <h3>Version history</h3>
263         
264          <h4>Version</h4><div class="preformat">
265 $Id: string2struct.pro 374 2008-08-08 15:12:27Z pinsard $
266</div>
267          <h4>History</h4><div class="preformat">
268       Written by:
269       RLK, Ronn Kling Consulting.
270       ronn@rlkling.com
271       www.rlkling.com
272               May, 1999
273</div>
274         
275         
276         
277         
278         
279         
280         
281       
282         
283         
284         
285         
286         
287         
288         
289       
290          <h3>Statistics</h3>
291          <table class="statistics">
292            <tr><td>McCabe cyclic</td><td>           2</td></tr>
293            <tr><td>McCabe essential</td><td>           1</td></tr>
294            <tr><td>McCabe modular design</td><td>           1</td></tr>
295          </table>
296         
297       
298        </div>
299       
300      </div>
301
302     
303
304      <div id="tagline">Produced by IDLdoc 2.0.</div>
305
306    </div>
307
308  </body>
309</html>
Note: See TracBrowser for help on using the repository browser.