source: trunk/SRC/Documentation/idldoc_assistant_output/ToBeReviewed/STRING/getwrd.html @ 163

Last change on this file since 163 was 163, checked in by navarro, 18 years ago

header improvements : type of parameters and keywords, default values, spell checking + idldoc assistant (IDL online_help)

File size: 6.4 KB
Line 
1
2
3<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4  <head>
5    <title>getwrd.pro (SAXO Documentation Assistant)</title>
6  </head>
7
8  <body text="#000000" bgcolor="#FFFFFF">
9
10   
11<!-- Navbar template takes a structure with the following fields:
12       overview_href :
13       overview_selected :
14       dir_overview_href :
15       dir_overview_selected :
16       categories_href :
17       categories_selected :
18       index_href :
19       index_selected :
20       search_href :
21       search_selected :
22       file_selected :
23       source_href :
24       source_selected :
25       help_href :
26       help_selected :
27       etc_selected :
28
29       prev_file_href :
30       next_file_href :
31
32       view_single_page_href :
33       view_frames_href :
34
35       summary_fields_href :
36       summary_routine_href :
37       details_routine_href :
38
39       title :
40       subtitle :
41       user :
42-->
43
44
45<table border="0" cellpadding="0" cellspacing="0" width="98%" bgcolor="#F0F0FF" valign="bottom">
46  <tr>
47    <td width="10%">
48<a href="getfile.html"><img src="./../../prev.gif" border="0" alt="Previous"></a></td>
49    <td width="80%" align="center" valign="center">
50<font size=-1><i>SAXO Documentation Assistant</i>: <a href="./../../home.html">Overview</a></font></td>
51    <td width="10%" align="right">
52<a href="isnumber.html"><img src="./../../next.gif" border="0" alt="Next"></a></td>
53  </tr>
54</table>
55
56
57    <h1><font size="-2">ToBeReviewed/STRING/</font></h1>
58    <h2>getwrd.pro</h2>
59
60    <dl>
61    </dl>
62
63   
64 Return the n'th word from a text string.
65 
66
67   
68
69     
70      <a name="#_getwrd"></a>
71
72      <h2>getwrd  <font size="-1" color="#006633">
73</font></h2>
74
75      <p><font face="Courier"><i>result = </i>getwrd(<i><a href="#_getwrd_keyword_TXTSTR">TXTSTR</a>, <a href="#_getwrd_keyword_NTH">NTH</a>, <a href="#_getwrd_keyword_MTH">MTH</a></i>, <a href="#_getwrd_keyword_help">help</a>=<i>help</i>, <a href="#_getwrd_keyword_location">location</a>=<i>location</i>, <a href="#_getwrd_keyword_delimiter">delimiter</a>=<i>delimiter</i>, <a href="#_getwrd_keyword_notrim">notrim</a>=<i>notrim</i>, <a href="#_getwrd_keyword_last">last</a>=<i>last</i>, <a href="#_getwrd_keyword_nwords">nwords</a>=<i>nwords</i>)</font></p>
76
77   
78
79
80    <h3>Return value</h3> wrd = returned word or words.
81
82
83   
84    <h3>Parameters</h3>
85   
86
87    <a name="#_getwrd_keyword_TXTSTR"></a>
88    <h4>TXTSTR&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
89      <font size="-1" color="#006633">in</font>
90     
91     
92      <font size="-1" color="#006633">required</font>
93     
94     
95     
96     
97    </h4>
98
99   
100 text string to extract from.
101 The first element is used if txt is an array.
102
103   
104
105    <a name="#_getwrd_keyword_NTH"></a>
106    <h4>NTH&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
107      <font size="-1" color="#006633">in</font>
108     
109     
110      <font size="-1" color="#006633">required</font>
111     
112     
113     
114     
115    </h4>
116
117   
118 word number to get (first = 0 = def)
119
120   
121
122    <a name="#_getwrd_keyword_MTH"></a>
123    <h4>MTH&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
124      <font size="-1" color="#006633">in</font>
125     
126     
127      <font size="-1" color="#006633">required</font>
128     
129     
130     
131     
132    </h4>
133
134   
135 optional last word number to get.
136
137   
138   
139
140   
141    <h3>Keywords</h3>
142
143   
144    <a name="#_getwrd_keyword_help"></a>
145    <h4>help&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
146     
147     
148     
149     
150     
151     
152     
153     
154    </h4>
155
156   
157   
158    <a name="#_getwrd_keyword_location"></a>
159    <h4>location&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
160     
161     
162     
163     
164     
165     
166     
167     
168    </h4>
169
170   
171 = l.  Return word n string location.
172         
173   
174    <a name="#_getwrd_keyword_delimiter"></a>
175    <h4>delimiter&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
176     
177     
178     
179     
180     
181     
182     
183     
184    </h4>
185
186   
187 = d. Set word delimiter (def = space & tab).
188         
189   
190    <a name="#_getwrd_keyword_notrim"></a>
191    <h4>notrim&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
192     
193     
194     
195     
196     
197     
198     
199     
200    </h4>
201
202   
203 suppresses whitespace trimming on ends.
204 
205   
206    <a name="#_getwrd_keyword_last"></a>
207    <h4>last&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
208     
209     
210     
211     
212     
213     
214     
215     
216    </h4>
217
218   
219 means n is offset from last word.  So n=0 gives
220 last word, n=-1 gives next to last, ...
221 If n=-2 and m=0 then last 3 words are returned.
222
223   
224    <a name="#_getwrd_keyword_nwords"></a>
225    <h4>nwords&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
226     
227     
228     
229     
230     
231     
232     
233     
234    </h4>
235
236   
237 = n. Returns number of words in string.
238 
239   
240   
241
242   
243    <h3>Version history</h3>
244   
245    <h4>Version</h4>
246 $Id: getwrd.pro 142 2006-07-21 12:47:49Z navarro $
247
248    <h4>History</h4>
249       Ray Sterner,  6 Jan, 1985.
250       R. Sterner, Fall 1989 --- converted to SUN.
251       R. Sterner, Jan 1990 --- added delimiter.
252       R. Sterner, 18 Mar, 1990 --- added /LAST.
253       R. Sterner, 31 Jan, 1991 --- added /NOTRIM.
254       R. Sterner, 20 May, 1991 --- Added common and NULL string.
255       R. Sterner, 13 Dec, 1992 --- Made tabs equivalent to spaces.
256       R. Sterner,  4 Jan, 1993 --- Added NWORDS keyword.
257       R. Sterner, 2001 Jan 15 --- Fixed to use first element if not a scalar.
258       Johns Hopkins University Applied Physics Laboratory.
259
260 Copyright (C) 1985, Johns Hopkins University/Applied Physics Laboratory
261 This software may be used, copied, or redistributed as long as it is not
262 sold and this copyright notice is reproduced on each copy made.  This
263 routine is provided as is without any express or implied warranties
264 whatsoever.  Other limitations apply as described in the file disclaimer.txt.
265
266   
267
268    <h3>Known issues</h3>
269   
270   
271   
272    <h4>Restrictions</h4>
273 If a NULL string is given (txt="") then the last string
274 given is used.  This saves finding the words again.
275 If m > n wrd will be a string of words from word n to
276 word m.  If no m is given wrd will be a single word.
277 n<0 returns text starting at word abs(n) to string end
278 If n is out of range then a null string is returned.
279 See also nwrds.
280
281
282    <h3>Other attributes</h3>
283   
284   
285    <h4>Uses routines</h4>
286 getwrd_com
287 
288   
289   
290    <h4>Common blocks used</h4>getwrd_com
291
292    <font size="-3"><p>&nbsp;</p></font>
293    <hr size="1" color="#CCCCCC"/>
294     
295
296   
297
298    <p><font color="gray" size="-3">&nbsp;&nbsp;Produced by IDLdoc 2.0 on Tue Aug 29 14:50:30 2006.</font></p>
299
300  </body>
301</html>
Note: See TracBrowser for help on using the repository browser.