source: trunk/SRC/Documentation/idldoc_html_output/ToBeReviewed/COULEURS/getcolor.html @ 157

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

header improvements + xxx doc

File size: 25.4 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>getcolor.pro (SAXO Documentation)</title>
10
11   
12    <style type="text/css" media="all">
13     
14/* CSS for all files which appear in the "main" viewing area: overview,
15   directory overviews, warnings, index, search, pro files, source
16   code, help, and etc files. */
17
18/* Link styles --------------------------------------------------------------- */
19
20a { text-decoration: none; }
21
22a:link, a:visited { 
23  color: #660000; 
24  border-bottom: 1px dotted #C0C0F0;   
25}
26
27a:hover, a:focus { 
28  color: #993333; 
29  background: #FFFFCC; 
30  border-bottom: 1px dotted #303099; 
31}
32
33
34/* Main styles --------------------------------------------------------------- */
35p.preformat {
36  font-family: Courier;
37}
38p.preformat {
39  font-family: Courier;
40}
41p.preformat {
42  font-family: Courier;
43}
44p.preformat {
45  font-family: Courier;
46}
47p.preformat {
48  font-family: Courier;
49}
50p.preformat {
51  font-family: Courier;
52}
53p.preformat {
54  font-family: Courier;
55}
56p.preformat {
57  font-family: Courier;
58}
59p.preformat {
60  font-family: Courier;
61}
62p.preformat {
63  font-family: Courier;
64}
65p.preformat {
66  font-family: Courier;
67}
68p.preformat {
69  font-family: Courier;
70}
71p.preformat {
72  font-family: Courier;
73}
74p.preformat {
75  font-family: Courier;
76}
77p.preformat {
78  font-family: Courier;
79}
80p.preformat {
81  font-family: Courier;
82}
83p.preformat {
84  font-family: Courier;
85}
86p.preformat {
87  font-family: Courier;
88}
89p.preformat {
90  font-family: Courier;
91}
92p.preformat {
93  font-family: Courier;
94}
95p.preformat {
96  font-family: Courier;
97}
98p.preformat {
99  font-family: Courier;
100}
101
102body {
103  margin: 0;
104  padding: 0;
105  font-size: 10pt;
106  font-family: Verdana, Helvetica, Arial, sans-serif;
107  background-color: #FFFFFF;
108}
109
110p {
111  margin-top: 0.5em;
112  margin-bottom: 0;
113}
114
115#container { margin: 1em; }
116
117code.section { white-space: pre; }
118
119pre.snippet {
120  margin-left: 5%;
121  background: #F0F0F0;
122  border: 1px dashed #999999;
123  width: 43em;
124  padding: 0.5em 0.5em 0.5em 0.5em;
125  white-space: pre;
126}
127
128/* Navbar styles ------------------------------------------------------------- */
129
130#navbar_title {
131  color: #000033;
132  background-color: #F0F0FF;
133  font-family: Arial, Helvetica, sans-serif;
134  padding: 20px 30px;
135  border-bottom: 1px solid #000033;
136}
137
138#navbar_title * {
139  margin: 0;
140  padding: 0;
141}
142
143#navbar_title h1 {
144  letter-spacing: 0.1em;
145  font-variant: small-caps;
146  font-size: 250%;
147  text-indent: -1em;
148  padding-left: 1em; 
149}
150
151#navbar_title h2 {
152  font-size: 110%;
153  font-weight: normal;
154  color: #333399;
155}
156
157#main_navbar table {
158  width: 100%;
159  border-bottom: 1px solid #666699;
160}
161
162#main_navbar td {
163  background: #CCCCFF;
164  font-size: 80%;
165  font-weight: bold;
166  font-family: Arial, Helvetica, sans-serif;
167  border-top: 3px solid #CCCCFF;
168  border-bottom: 3px solid #CCCCFF;
169  padding-left: 6px;
170  padding-right: 6px;
171  margin: 0;
172}
173
174#main_navbar td#selected {
175  background: #CCCCFF;
176  font-size: 80%;
177  font-weight: bold;
178  font-family: Arial, Helvetica, sans-serif;
179  border-top: 3px solid #333399;
180  border-bottom: 3px solid #CCCCFF;
181  padding-left: 6px;
182  padding-right: 6px;
183  margin: 0;
184}
185
186#main_navbar td#flexible {
187  width: 100%;
188  text-align: right;
189  padding-right: 1em;
190  background: #CCCCFF;
191  font-size: 70%;
192  font-weight: normal;
193  font-family: Arial, Helvetica, sans-serif;
194  text-transform: uppercase;
195  border-top: 3px solid #CCCCFF;
196  border-bottom: 3px solid #CCCCFF;
197}
198
199#main_navbar a:link, #main_navbar a:visited { color: #660000; border: 0; }
200
201#main_navbar a:hover, #main_navbar a:focus {
202  color: #FFFF66;
203  background: #CCCCFF;
204  border-bottom: 1px none #606099; 
205  border: 0;
206}
207
208#secondary_navbar {
209  font-size: 80%;
210  font-weight: normal;
211  font-family: Arial, Helvetica, sans-serif;
212  margin-top: 4px;
213  margin-left: 20px;
214  white-space: nowrap;
215}
216
217
218/* Tagline and footer styles ------------------------------------------------- */
219
220div#tagline {
221  margin-top: 6px;
222  border-top: 1px dotted lightsteelblue;
223  padding-top: 6px;
224  font-size: 66%;
225  font-style: italic;
226}
227
228div#footer {
229  margin-top: 6px;
230  border-top: 1px dotted lightsteelblue;
231  padding-top: 6px;
232  font-size: 66%;
233  font-style: italic;
234}
235
236/* Basic data presenation styles -------------------------------------------- */
237
238.index_letter { 
239  font-size: 300%;
240  font-weight: bold;
241  color: #000066; 
242  margin: 0.5em 0 0 -0.1em;
243}
244
245h1, h2, h3, h4 {
246  font-weight: normal;
247  color: #3333CC;
248}
249
250h1 {
251  padding-top: 0.75em;
252  font-size: 160%;
253}
254
255h2 {
256  padding-top: 1em;
257  font-size: 120%;
258  }
259
260h3 {
261  padding-top: 0.75em;
262  margin-bottom: 0.25em;
263  font-size: 100%;
264}
265
266h4 {
267  padding: 0;
268  margin: 0.5em 0 0 0;
269  font-size: 80%;
270}
271
272table.basic {
273  empty-cells: show;
274  margin: 1.5em 1em 0 1em;
275  border: 1px dotted #CFCFFF;
276  font-size: 80%;
277}
278
279table.basic th {
280  background-color: #F0F0FF;
281  font-weight: bold;
282  text-align: left;
283  padding: 4px 1em 4px 4px;
284  border-bottom: 1px dotted #666699;
285}
286
287table.basic td {
288  vertical-align: top;
289  padding: 4px 1em 4px 4px;
290}
291
292dd {
293  margin-bottom: 0.25em;
294  font-size: 80%;
295}
296
297
298/* Warnings styles ----------------------------------------------------------- */
299
300
301#todo dl, #bugs dl { 
302  margin: 0 0 0 1.5em;
303  font-size: 80%;
304}
305
306#todo dd, #bugs dd { 
307  margin-left: 3em; 
308  font-size: 100%;
309}
310
311#undoc table, #obsolete table, #statistics table {
312  width: 80%;
313  margin-left: 2em;
314}
315
316#undoc td, #obsolete td, #statistics td { 
317  padding: 0 0 0 0;
318  font-size: 80%;
319  white-space: nowrap;
320}
321
322#undoc td.docroutine, #obsolete td.obsroutine, #statistics td.statroutine { width: 50%; }
323
324#undoc td.docstat, #statistics td.stat { 
325  width: 50%;
326  text-align: right;
327}
328
329#undoc td.partialdoc, #statistics td.caution { color: #CC6600; }
330
331#undoc td.notdoc, #statistics td.warning { color: #993333; }
332
333/* File + routine styles ----------------------------------------------------- */
334
335h1.directory { 
336  padding: 1em 0 0 0;
337  margin: 0;
338  font-size: 66%;
339}
340
341h1.directory a { border-bottom: 0; }
342
343h2.pro_file { 
344  padding: 0;
345  margin: 0;
346  font-size: 140%;
347}
348
349div#file_attr {
350  padding: 0 1em 0 1em;
351  margin: 1em;
352  background: #F6F6F6;
353  border: 1px dotted #999999;
354}
355
356div#file_attr dt {
357  font-size: 80%;
358  font-weight: bold;
359}
360
361div#file_attr dd {
362  font-size: 80%;
363}
364
365div#class_diagram { 
366  padding: 1em 0 1em 0; 
367  white-space: pre;
368  font-family: 'Courier New';
369}
370
371table#sav_attr { 
372  font-size: 90%; 
373  margin: 1em; 
374  padding: 1em 1em 1em 1em;
375  background: #F6F6F6;
376  border: 1px dotted #999999;
377}
378
379table#sav_attr th { text-align: left; }
380
381table#sav_attr td { vertical-align: top; padding-right: 2em; }
382
383table#sav_attr td.value { width: 20em; padding-right: 0em; font-style: italic; }
384
385p.sav_warning { margin-left: 4em; font-family: 80%; }
386
387table.variables { 
388  font-family: 'Courier New', monospace; 
389  font-size: 80%; 
390  text-indent: -2em; 
391  padding-left: 2em; 
392}
393
394table.variables td.image { width: 64px; }
395
396div#file_comments { white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; white-space: pre; 
397  margin: 2em;
398  font-size: 80%;
399}
400
401
402div.field_summary {
403  padding: 0 1em 0 1em;
404  margin: 1em;
405  background: #FFFFF0;
406  border: 1px dotted #C0C000;
407}
408
409div#routine_summary { 
410  padding: 0 1em 0 1em;
411  margin: 1em;
412  background: #F0F0FF;
413  border: 1px dotted #9999FF;
414}
415
416div.field_summary h2, div#routine_summary h2 { 
417  padding: 0.5em 0 0 0;
418  margin: 0;
419}
420
421div.field_summary table, div.field_summary p { 
422  margin: 1em 1em;
423}
424
425div.field_summary td.name { 
426  vertical-align: top;
427  padding-bottom: 0.25em;
428  color: #3333CC;
429}
430
431div.field_summary span.field_type { 
432  font-weight: normal;
433  font-size: 80%;
434  color: black;
435}
436
437div.field_summary td.comments { 
438  vertical-align: top;
439  padding-left: 2em;
440  font-size: 80%;
441}
442
443p.commaList { 
444  margin: 1em 1em 1em 1em;
445}
446
447span.warning { 
448  color: #CC6633;
449  font-weight: bold;
450  font-size: 66%;
451  text-transform: uppercase;
452}
453
454span.categories { 
455  color: #006633;
456  font-weight: bold;
457  font-size: 66%;
458  text-transform: uppercase;
459}
460
461span.undoc { 
462  color: #FF6633;
463  font-weight: bold;
464  font-size: 80%;
465  text-transform: uppercase;
466}
467
468span.attr { 
469  color: #006633;
470  font-weight: bold;
471  font-size: 80%;
472  text-transform: uppercase;
473}
474
475span.value { 
476  color: #006633;
477  font-weight: normal;
478  text-transform: none;
479}
480
481a.top { 
482  font-weight: bold;
483  font-size: 66%;
484  text-transform: uppercase;
485  float: right;
486}
487
488span.result { 
489  font-family: Verdana, Arial, Helvetica, sans-serif;
490  font-style: italic;
491  font-size: 80%;
492}
493
494div#routine_summary p, div.routine_details p.header { 
495  padding-top: 0.5em;
496  margin-left: 1.5em;
497  text-indent: -1.5em;
498  font-family: 'Courier New', monospace;
499}
500
501div.routine_details { 
502  padding: 0.5em 1em 0.5em 1em;
503  margin: 1em;
504  border: 1px dotted #CCCCCC;
505}
506
507div.routine_details h2 { 
508  padding-top: 0;
509  margin-top: 0;
510}
511
512div.routine_details div.value { 
513  margin: 0 1em 0 1em;
514  font-size: 80%;
515}
516
517div.routine_details div.comments { 
518  font-size: 80%;
519  margin: 0.75em 1em 1em 1em;
520}
521
522div.routine_details div.preformat { 
523  white-space: pre;
524}
525
526table.statistics { 
527  font-size: 80%;
528  margin-left: 1em;
529}
530
531table.statistics td { 
532  padding: 0 2em 0 0;
533}
534
535/* Overview styles ----------------------------------------------------------- */
536
537div.overview { 
538  width: 100%;
539  margin-top: 1em;
540  clear: both;
541}
542
543div.overview table {
544  empty-cells: show;
545  font-size: 90%;
546  margin: 1em 1em 1em 1em;
547  padding: 1em 0.5em 1em 0.5em;
548  background: #F6F6F6;
549  border: 1px dotted #999999;
550}
551
552div.overview td {
553  padding: 3px 1em 3px 1em;
554}
555
556div.overview td.dir {
557  width: 1%;
558  vertical-align: top;
559  text-align: right;
560  padding-right: 1em;
561}
562
563
564/* Navigation list styles for tree structures -------------------------------- */
565
566#tree {
567  text-align: left;
568  font-size: 90%;
569  margin: 0.75em 0 0.75em 0;
570  padding: 0;
571}
572
573#tree ul {
574  text-align: left;
575  margin: 0;
576  padding: 0;
577}
578
579#tree li {
580  margin: 0 0 0 15px;
581  padding: 0;
582  list-style-type: none;
583}
584
585#tree .symbols {
586  float: left;
587  width: 12px;
588  height: 1em;
589  padding-left: 4px;
590  background-position: 0 100%;
591  background-repeat: no-repeat;
592}
593
594/* Search styles ------------------------------------------------------------- */
595
596input.writein { 
597  padding-left: 0.5em;
598  border: 1px solid #CCCCCC;
599  font-family: 'Courier New';
600  background: #FFFFF3;
601}
602
603#search form { 
604  margin-left: 2em;
605}
606
607#search table { 
608  margin: 1em 1em 0 2em;
609  padding: 1em 2em 1em 2em;
610  background: #F6F6F6;
611  border: 1px dotted #999999;
612}
613
614#search tr { 
615  text-align: center;
616}
617
618#search td { 
619  font-size: 80%; 
620  text-align: left;
621}
622
623#search td * { 
624  vertical-align: middle;
625}
626
627#search p { 
628  font-size: 66%;
629  margin: 0 3em 2em 3em;
630}
631
632/* Help styles --------------------------------------------------------------- */
633
634div.toc { 
635  padding: 0 1em 0 1em;
636  margin: 1em;
637  background: #F0F0FF;
638  border: 1px dotted #9999FF; 
639  width: 19em;
640}
641
642div.right { 
643  float: right;
644  width: 22em;
645}
646
647ol.toc { 
648  list-style-type: upper-roman;
649}
650
651ol.toc ol { 
652  padding-left: 3em;
653  margin-left: 0;
654  list-style-type: lower-alpha;
655}
656
657dl.variables dt { font-size: 80%; }
658dl.variables dd { margin-bottom: 0.5em; }
659
660    </style>
661    <style type="text/css" media="print">
662      #navbar_title { 
663  background-color: #FFFFFF; 
664}
665
666#main_navbar td {
667  background: #FFFFFF;
668  border-top: 0.25em solid #FFFFFF;
669  border-bottom: 0.25em solid #FFFFFF;
670}
671
672#main_navbar td#selected {
673  background: #FFFFFF;
674  border-top: 0.25em solid #333399;
675  border-bottom: 0.25em solid #FFFFFF;
676}
677
678#main_navbar td#flexible {
679  background: #FFFFFF;
680  border-top: 0.25em solid #FFFFFF;
681  border-bottom: 0.25em solid #FFFFFF;
682}
683
684#secondary_navbar {
685  display: none;
686}
687
688    </style>
689   
690
691    <script type="text/javascript">
692      function setTitle() {
693        parent.document.title="getcolor.pro (SAXO Documentation)";
694      }
695    </script>
696  </head>
697
698  <body onload="setTitle();">
699
700    <div id="navbar_title">
701  <h1>SAXO Documentation</h1>
702</div>
703
704
705<div id="main_navbar">
706
707  <table cellspacing="0">
708    <tr>
709     
710      <td><a href="./../../overview.html?format=raw" title="Overview of library">Overview</a></td>
711     
712
713     
714      <td >Directory</td>
715     
716
717     
718      <td><a href="./../../idldoc-categories.html?format=raw" title="Browse library by category">Categories</a></td>
719     
720
721     
722      <td><a href="./../../idldoc-index.html?format=raw" title="Index of files, routines, and parameters">Index</a></td>
723     
724
725     
726      <td><a href="./../../search-page.html?format=raw" title="Search library">Search</a></td>
727     
728
729      <td id="selected">File</td>
730
731     
732      <td >Source</td>
733     
734
735     
736      <td><a href="./../../idldoc-help.html?format=raw" title="Help on IDLdoc">Help</a></td>
737     
738
739      <td >Etc</td>
740
741      <td id="flexible">Developer&nbsp;documentation</td>
742    </tr>
743  </table>
744
745</div>
746
747<div id="secondary_navbar">
748
749<a href="colorbar.html?format=raw">&lt;&lt;prev file</a> | <a href="lct.html?format=raw">next file &gt;&gt;</a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="getcolor.html?format=raw" target="_TOP">view single page</a> | <a href="./../../index.html?format=raw" 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>
750
751</div>
752
753
754    <div id="container">
755
756      <h1 class="directory"><a href="directory-overview.html?format=raw">ToBeReviewed/COULEURS/</a></h1>
757      <h2 class="pro_file">getcolor.pro</h2>
758
759      <div id="file_attr">
760        <dl>
761        </dl>
762      </div>
763
764      <div id="file_comments"></div>
765
766     
767
768     
769
770     
771
772     
773      <div id="routine_summary">               
774        <h2>Routine summary</h2>
775       
776        <dl>
777         
778          <dt><p><a href="#_COLOR24"><span class="result">result = </span>COLOR24(<span class="result">number</span>)</a></p><dt>
779          <dd>  NAME:        GETCOLOR   PURPOSE:        The original purpose of this function was to enable the        user to specify one of the 16 colors supported by the        McIDAS color map by name.</dd>     
780         
781          <dt><p><a href="#_GETCOLOR"><span class="result">result = </span>GETCOLOR(<span class="result">thisColor, index</span>, TRUE=<span class="result">TRUE</span>, NAMES=<span class="result">NAMES</span>, LOAD=<span class="result">LOAD</span>, START=<span class="result">START</span>)</a></p><dt>
782          <dd></dd>     
783               
784        </dl>
785      </div>
786     
787
788      <div id="routine_details">
789       
790
791        <div class="routine_details" id="_COLOR24">
792
793          <h2><a class="top" href="#container">top</a>COLOR24 </h2>
794       
795          <p class="header">
796            <span class="result">result = </span>COLOR24(<span class="result"><a href="#_COLOR24_param_number">number</a></span>)</p>
797       
798          <div class="comments">
799 NAME:
800       GETCOLOR
801
802 PURPOSE:
803       The original purpose of this function was to enable the
804       user to specify one of the 16 colors supported by the
805       McIDAS color map by name. Over time, however, the function
806       has become a general purpose function for handling and
807       supporting drawing colors in a device-independent way.
808       In particular, I have been looking for ways to write color
809       handling code that will work transparently on both 8-bit and
810       24-bit machines. On 24-bit machines, the code should work the
811       same where color decomposition is turned on or off.
812
813       (The 16 supported colors in GETCOLOR come from the McIDAS color
814       table offered on the IDL newsgroup by Liam Gumley.)
815
816 CATEGORY:
817       Graphics, Color Specification.
818
819 CALLING SEQUENCE:
820       result = GETCOLOR(color)
821
822 OPTIONAL INPUT PARAMETERS:
823       COLOR: A string with the "name" of the color. Valid names are:
824           black
825           magenta
826           cyan
827           yellow
828           green
829           red
830           blue
831           navy
832           gold
833           pink
834           aqua
835           orchid
836           gray
837           sky
838           beige
839           white
840
841           The color YELLOW is returned if the color name can't be resolved.
842           Case is unimportant.
843
844           If the function is called with just this single input parameter,
845           the return value is either a 1-by-3 array containing the RGB values of
846           that particular color, or a 24-bit integer that can be "decomposed" into
847           that particular color, depending upon the state of the TRUE keyword and
848           upon whether color decomposition is turned on or off. The state of color
849           decomposition can ONLY be determined if the program is being run in
850           IDL 5.2 or higher.
851
852       INDEX: The color table index where the specified color should be loaded.
853           If this parameter is passed, then the return value of the function is the
854           index number and not the color triple. (If color decomposition is turned
855           on AND the user specifies an index parameter, the color is loaded in the
856           color table at the proper index, but a 24-bit value is returned to the
857           user in IDL 5.2 and higher.)
858
859       If no positional parameter is present, then the return value is either a 16-by-3
860       byte array containing the RGB values of all 16 colors or it is a 16-element
861       long integer array containing color values that can be decomposed into colors.
862       The 16-by-3 array is appropriate for loading color tables with the TVLCT command:
863
864           Device, Decomposed=0
865           colors = GetColor()
866           TVLCT, colors, 100
867
868
869 INPUT KEYWORD PARAMETERS:
870
871       NAMES: If this keyword is set, the return value of the function is
872              a 16-element string array containing the names of the colors.
873              These names would be appropriate, for example, in building
874              a list widget with the names of the colors. If the NAMES
875              keyword is set, the COLOR and INDEX parameters are ignored.
876
877                 listID = Widget_List(baseID, Value=GetColor(/Names), YSize=16)
878
879       LOAD:  If this keyword is set, all 16 colors are automatically loaded
880              starting at the color index specified by the START keyword.
881              Note that setting this keyword means that the return value of the
882              function will be a structure, with each field of the structure
883              corresponding to a color name. The value of each field will be
884              an index number (set by the START keyword) corresponding to the
885              associated color, or a 24-bit long integer value that creates the
886              color on a true-color device. What you have as the field values is
887              determined by the TRUE keyword or whether color decomposition is on
888              or off in the absense of the TRUE keyword. It will either be a 1-by-3
889              byte array or a long integer value.
890
891       START: The starting color index number if the LOAD keyword is set. This keyword
892              value is ignored unless the LOAD keyword is also set. The keyword is also
893              ignored if the TRUE keyword is set or if color decomposition in on in
894              IDL 5.2 and higher. The default value for the START keyword is
895              !D.TABLE_SIZE - 17.
896
897       TRUE:  If this keyword is set, the specified color triple is returned
898              as a 24-bit integer equivalent. The lowest 8 bits correspond to
899              the red value; the middle 8 bits to the green value; and the
900              highest 8 bits correspond to the blue value. In IDL 5.2 and higher,
901              if color decomposition is turned on, it is as though this keyword
902              were set.
903
904 COMMON BLOCKS:
905       None.
906
907 SIDE EFFECTS:
908       None.
909
910 RESTRICTIONS:
911       The TRUE keyword causes the START keyword to be ignored.
912       The NAMES keyword causes the COLOR, INDEX, START, and TRUE parameters to be ignored.
913       The COLOR parameter is ignored if the LOAD keyword is used.
914       On systems where it is possible to tell the state of color decomposition
915       (i.e., IDL 5.2 and higher), a 24-bit value (or values) is automatically
916       returned if color decomposition is ON.
917
918 EXAMPLE:
919       To load a yellow color in color index 100 and plot in yellow, type:
920
921          yellow = GETCOLOR('yellow', 100)
922          PLOT, data, COLOR=yellow
923
924       or,
925
926          PLOT, data, COLOR=GETCOLOR('yellow', 100)
927
928       To do the same thing on a 24-bit color system with decomposed color on, type:
929
930          PLOT, data, COLOR=GETCOLOR('yellow', /TRUE)
931
932       or in IDL 5.2 and higher,
933
934          DEVICE, Decomposed=1
935          PLOT, data, COLOR=GETCOLOR('yellow')
936
937       To load all 16 colors into the current color table, starting at
938       color index 200, type:
939
940          TVLCT, GETCOLOR(), 200
941
942       To add the color names to a list widget:
943
944           listID = Widget_List(baseID, Value=GetColor(/Names), YSize=16)
945
946       To load all 16 colors and have the color indices returned in a structure:
947
948           DEVICE, Decomposed=0
949           colors = GetColor(/Load, Start=1)
950           HELP, colors, /Structure
951           PLOT, data, COLOR=colors.yellow
952
953       To get the direct color values as 24-bit integers in color structure fields:
954
955           DEVICE, Decomposed=1
956           colors = GetColor(/Load)
957           PLOT, data, COLOR=colors.yellow
958
959       Note that the START keyword value is ignored if on a 24-bit device,
960       so it is possible to write completely device-independent code by
961       writing code like this:
962
963           colors = GetColor(/Load)
964           PLOT, data, Color=colors.yellow
965
966 MODIFICATION HISTORY:
967       Written by: David Fanning, 10 February 96.
968       Fixed a bug in which N_ELEMENTS was spelled wrong. 7 Dec 96. DWF
969       Added the McIDAS colors to the program. 24 Feb 99. DWF
970       Added the INDEX parameter to the program 8 Mar 99. DWF
971       Added the NAMES keyword at insistence of Martin Schultz. 10 Mar 99. DWF
972       Reorderd the colors so black is first and white is last. 7 June 99. DWF
973       Added automatic recognition of DECOMPOSED=1 state. 7 June 99. DWF
974       Added LOAD AND START keywords. 7 June 99. DWF.</div>
975
976         
977
978         
979            <h3>Parameters</h3>
980       
981           
982            <h4 id="_COLOR24_param_number">number&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
983             
984             
985             
986             
987             
988             
989             
990             
991            </h4>
992       
993          <div class="comments"></div>
994           
995
996         
997
998         
999
1000         
1001         
1002         
1003         
1004         
1005         
1006         
1007         
1008         
1009         
1010         
1011         
1012       
1013         
1014         
1015         
1016         
1017         
1018         
1019         
1020       
1021         
1022       
1023        </div>
1024       
1025
1026        <div class="routine_details" id="_GETCOLOR">
1027
1028          <h2><a class="top" href="#container">top</a>GETCOLOR </h2>
1029       
1030          <p class="header">
1031            <span class="result">result = </span>GETCOLOR(<span class="result"><a href="#_GETCOLOR_param_thisColor">thisColor</a>, <a href="#_GETCOLOR_param_index">index</a></span>, <a href="#_GETCOLOR_keyword_TRUE">TRUE</a>=<span class="result">TRUE</span>, <a href="#_GETCOLOR_keyword_NAMES">NAMES</a>=<span class="result">NAMES</span>, <a href="#_GETCOLOR_keyword_LOAD">LOAD</a>=<span class="result">LOAD</span>, <a href="#_GETCOLOR_keyword_START">START</a>=<span class="result">START</span>)</p>
1032       
1033          <div class="comments"></div>
1034
1035         
1036
1037         
1038            <h3>Parameters</h3>
1039       
1040           
1041            <h4 id="_GETCOLOR_param_thisColor">thisColor&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1042             
1043             
1044             
1045             
1046             
1047             
1048             
1049             
1050            </h4>
1051       
1052          <div class="comments"></div>
1053           
1054            <h4 id="_GETCOLOR_param_index">index&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1055             
1056             
1057             
1058             
1059             
1060             
1061             
1062             
1063            </h4>
1064       
1065          <div class="comments"></div>
1066           
1067
1068         
1069
1070         
1071
1072            <h3>Keywords</h3>
1073           
1074            <h4 id="_GETCOLOR_keyword_TRUE">TRUE&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1075             
1076             
1077             
1078             
1079             
1080             
1081             
1082             
1083            </h4>
1084       
1085            <div class="comments"></div>
1086           
1087            <h4 id="_GETCOLOR_keyword_NAMES">NAMES&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1088             
1089             
1090             
1091             
1092             
1093             
1094             
1095             
1096            </h4>
1097       
1098            <div class="comments"></div>
1099           
1100            <h4 id="_GETCOLOR_keyword_LOAD">LOAD&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1101             
1102             
1103             
1104             
1105             
1106             
1107             
1108             
1109            </h4>
1110       
1111            <div class="comments"></div>
1112           
1113            <h4 id="_GETCOLOR_keyword_START">START&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1114             
1115             
1116             
1117             
1118             
1119             
1120             
1121             
1122            </h4>
1123       
1124            <div class="comments"></div>
1125           
1126         
1127
1128         
1129         
1130         
1131         
1132         
1133         
1134         
1135         
1136         
1137         
1138         
1139         
1140       
1141         
1142         
1143         
1144         
1145         
1146         
1147         
1148       
1149         
1150       
1151        </div>
1152       
1153      </div>
1154
1155     
1156
1157      <div id="tagline">Produced by IDLdoc 2.0.</div>
1158
1159    </div>
1160
1161  </body>
1162</html>
Note: See TracBrowser for help on using the repository browser.