[138] | 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>colorbar.pro (SAXO Documentation)</title> |
---|
| 10 | |
---|
| 11 | |
---|
[191] | 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" /> |
---|
[138] | 14 | |
---|
| 15 | |
---|
| 16 | <script type="text/javascript"> |
---|
| 17 | function setTitle() { |
---|
| 18 | parent.document.title="colorbar.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 | |
---|
[189] | 35 | <td><a href="./../overview.html" title="Overview of library">Overview</a></td> |
---|
[138] | 36 | |
---|
| 37 | |
---|
| 38 | |
---|
| 39 | <td >Directory</td> |
---|
| 40 | |
---|
| 41 | |
---|
| 42 | |
---|
[189] | 43 | <td><a href="./../idldoc-categories.html" title="Browse library by category">Categories</a></td> |
---|
[138] | 44 | |
---|
| 45 | |
---|
| 46 | |
---|
[189] | 47 | <td><a href="./../idldoc-index.html" title="Index of files, routines, and parameters">Index</a></td> |
---|
[138] | 48 | |
---|
| 49 | |
---|
| 50 | |
---|
[189] | 51 | <td><a href="./../search-page.html" title="Search library">Search</a></td> |
---|
[138] | 52 | |
---|
| 53 | |
---|
| 54 | <td id="selected">File</td> |
---|
| 55 | |
---|
| 56 | |
---|
[189] | 57 | <td><a href="../../../Colors//colorbar.pro" title="Source code of a file">Source</a></td> |
---|
[138] | 58 | |
---|
| 59 | |
---|
| 60 | |
---|
[189] | 61 | <td><a href="./../idldoc-help.html" title="Help on IDLdoc">Help</a></td> |
---|
[138] | 62 | |
---|
| 63 | |
---|
| 64 | <td >Etc</td> |
---|
| 65 | |
---|
| 66 | <td id="flexible">Developer documentation</td> |
---|
| 67 | </tr> |
---|
| 68 | </table> |
---|
| 69 | |
---|
| 70 | </div> |
---|
| 71 | |
---|
| 72 | <div id="secondary_navbar"> |
---|
| 73 | |
---|
[189] | 74 | <a href="color24.html"><<prev file</a> | <a href="getcolor.html">next file >></a> <a href="colorbar.html" target="_TOP">view single page</a> | <a href="./../index.html" target="_TOP">view frames</a> summary: fields | routine details: <a href="#routine_details">routine</a> |
---|
[138] | 75 | |
---|
| 76 | </div> |
---|
| 77 | |
---|
| 78 | |
---|
| 79 | <div id="container"> |
---|
| 80 | |
---|
[189] | 81 | <h1 class="directory"><a href="directory-overview.html">Colors/</a></h1> |
---|
[138] | 82 | <h2 class="pro_file">colorbar.pro</h2> |
---|
| 83 | |
---|
| 84 | <div id="file_attr"> |
---|
| 85 | <dl> |
---|
| 86 | </dl> |
---|
| 87 | </div> |
---|
| 88 | |
---|
| 89 | <div id="file_comments"> |
---|
| 90 | The purpose of this routine is to add a color bar to the current |
---|
| 91 | graphics window. |
---|
| 92 | </div> |
---|
| 93 | |
---|
| 94 | |
---|
| 95 | |
---|
| 96 | |
---|
| 97 | |
---|
| 98 | |
---|
| 99 | |
---|
| 100 | |
---|
| 101 | |
---|
| 102 | <div id="routine_details"> |
---|
| 103 | |
---|
| 104 | |
---|
[163] | 105 | <div class="routine_details" id="_colorbar"> |
---|
[138] | 106 | |
---|
[234] | 107 | <h2><a class="top" href="#container">top</a>colorbar <span class="categories"> |
---|
[321] | 108 | Graphics |
---|
[138] | 109 | </span></h2> |
---|
| 110 | |
---|
| 111 | <p class="header"> |
---|
[163] | 112 | colorbar, <a href="#_colorbar_keyword_BOTTOM">BOTTOM</a>=<span class="result">BOTTOM</span>, <a href="#_colorbar_keyword_CB_CHARSIZE">CB_CHARSIZE</a>=<span class="result">CB_CHARSIZE</span>, <a href="#_colorbar_keyword_CB_CHARTHICK">CB_CHARTHICK</a>=<span class="result">CB_CHARTHICK</span>, <a href="#_colorbar_keyword_CB_COLOR">CB_COLOR</a>=<span class="result">CB_COLOR</span>, <a href="#_colorbar_keyword_DIVISIONS">DIVISIONS</a>=<span class="result">DIVISIONS</span>, <a href="#_colorbar_keyword_DISCRETE">DISCRETE</a>=<span class="result">DISCRETE</span>, <a href="#_colorbar_keyword_CB_LABEL">CB_LABEL</a>=<span class="result">vector</span>, <a href="#_colorbar_keyword_FORMAT">FORMAT</a>=<span class="result">FORMAT</span>, <a href="#_colorbar_keyword_POSITION">POSITION</a>=<span class="result">POSITION</span>, <a href="#_colorbar_keyword_MAX">MAX</a>=<span class="result">MAX</span>, <a href="#_colorbar_keyword_MIN">MIN</a>=<span class="result">MIN</span>, <a href="#_colorbar_keyword_NCOLORS">NCOLORS</a>=<span class="result">NCOLORS</span>, <a href="#_colorbar_keyword_PSCOLOR">PSCOLOR</a>=<span class="result">PSCOLOR</span>, <a href="#_colorbar_keyword_CB_TITLE">CB_TITLE</a>=<span class="result">CB_TITLE</span>, <a href="#_colorbar_keyword_VERTICAL">VERTICAL</a>=<span class="result">VERTICAL</span>, <a href="#_colorbar_keyword_TOP">TOP</a>=<span class="result">TOP</span>, <a href="#_colorbar_keyword_RIGHT">RIGHT</a>=<span class="result">RIGHT</span>, <a href="#_colorbar_keyword_CB_LOG">CB_LOG</a>=<span class="result">CB_LOG</span>, <a href="#_colorbar_keyword_NOTITLE">NOTITLE</a>=<span class="result">NOTITLE</span>, <a href="#_colorbar_keyword__EXTRA">_EXTRA</a>=<span class="result">_EXTRA</span></p> |
---|
[138] | 113 | |
---|
| 114 | <div class="comments"> |
---|
| 115 | </div> |
---|
| 116 | |
---|
| 117 | |
---|
| 118 | |
---|
| 119 | |
---|
| 120 | |
---|
| 121 | |
---|
| 122 | |
---|
| 123 | <h3>Keywords</h3> |
---|
| 124 | |
---|
[163] | 125 | <h4 id="_colorbar_keyword_BOTTOM">BOTTOM |
---|
[138] | 126 | |
---|
| 127 | |
---|
| 128 | |
---|
| 129 | |
---|
| 130 | |
---|
| 131 | |
---|
| 132 | <span class="attr">default:</span> <span class="value">0B</span> |
---|
| 133 | |
---|
| 134 | </h4> |
---|
| 135 | |
---|
| 136 | <div class="comments"> |
---|
| 137 | The lowest color index of the colors to be loaded in the bar. |
---|
| 138 | </div> |
---|
| 139 | |
---|
[163] | 140 | <h4 id="_colorbar_keyword_CB_CHARSIZE">CB_CHARSIZE |
---|
[138] | 141 | |
---|
| 142 | |
---|
| 143 | |
---|
| 144 | |
---|
| 145 | |
---|
| 146 | |
---|
| 147 | <span class="attr">default:</span> <span class="value">1.0</span> |
---|
| 148 | |
---|
| 149 | </h4> |
---|
| 150 | |
---|
| 151 | <div class="comments"> |
---|
| 152 | The character size of the color bar annotations. |
---|
| 153 | </div> |
---|
| 154 | |
---|
[163] | 155 | <h4 id="_colorbar_keyword_CB_CHARTHICK">CB_CHARTHICK |
---|
[138] | 156 | |
---|
| 157 | |
---|
| 158 | |
---|
| 159 | |
---|
| 160 | |
---|
| 161 | |
---|
| 162 | <span class="attr">default:</span> <span class="value">1.0</span> |
---|
| 163 | |
---|
| 164 | </h4> |
---|
| 165 | |
---|
| 166 | <div class="comments"> |
---|
| 167 | The character thick of the color bar annotations. |
---|
| 168 | </div> |
---|
| 169 | |
---|
[163] | 170 | <h4 id="_colorbar_keyword_CB_COLOR">CB_COLOR |
---|
[138] | 171 | |
---|
| 172 | |
---|
| 173 | |
---|
| 174 | |
---|
| 175 | |
---|
| 176 | |
---|
| 177 | <span class="attr">default:</span> <span class="value">ncolors - 1 + bottom</span> |
---|
| 178 | |
---|
| 179 | </h4> |
---|
| 180 | |
---|
| 181 | <div class="comments"> |
---|
| 182 | The color index of the bar outline and characters. |
---|
| 183 | </div> |
---|
| 184 | |
---|
[163] | 185 | <h4 id="_colorbar_keyword_DIVISIONS">DIVISIONS |
---|
[138] | 186 | |
---|
| 187 | |
---|
| 188 | |
---|
| 189 | |
---|
| 190 | |
---|
| 191 | |
---|
| 192 | <span class="attr">default:</span> <span class="value">2</span> |
---|
| 193 | |
---|
| 194 | </h4> |
---|
| 195 | |
---|
| 196 | <div class="comments"> |
---|
| 197 | The number of divisions to divide the bar into. |
---|
| 198 | There will be (divisions + 1) annotations. |
---|
| 199 | </div> |
---|
| 200 | |
---|
[163] | 201 | <h4 id="_colorbar_keyword_DISCRETE">DISCRETE |
---|
[138] | 202 | |
---|
| 203 | |
---|
| 204 | |
---|
| 205 | |
---|
| 206 | |
---|
| 207 | |
---|
| 208 | |
---|
| 209 | |
---|
| 210 | </h4> |
---|
| 211 | |
---|
[234] | 212 | <div class="comments"> |
---|
[138] | 213 | Vector which contain color's indexes to trace in a color bar. Therefore |
---|
[234] | 214 | we obtain a discrete colorbar which contains only the specified colors |
---|
[138] | 215 | in the order they appear in the vector |
---|
| 216 | </div> |
---|
| 217 | |
---|
[163] | 218 | <h4 id="_colorbar_keyword_CB_LABEL">CB_LABEL |
---|
[138] | 219 | |
---|
| 220 | |
---|
| 221 | |
---|
| 222 | |
---|
| 223 | |
---|
[163] | 224 | <span class="attr">type:</span> <span class="value">vector</span> |
---|
[138] | 225 | |
---|
| 226 | |
---|
| 227 | </h4> |
---|
| 228 | |
---|
[163] | 229 | <div class="comments"> |
---|
| 230 | A vector to specify sticks values of the color bar. It allows, |
---|
[138] | 231 | when we use DISCRETE, to have colors that don't increase by |
---|
| 232 | increments in a regular way. |
---|
| 233 | </div> |
---|
| 234 | |
---|
[163] | 235 | <h4 id="_colorbar_keyword_FORMAT">FORMAT |
---|
[138] | 236 | |
---|
| 237 | |
---|
| 238 | |
---|
| 239 | |
---|
| 240 | |
---|
| 241 | |
---|
| 242 | <span class="attr">default:</span> <span class="value">'(F6.2)'</span> |
---|
| 243 | |
---|
| 244 | </h4> |
---|
| 245 | |
---|
| 246 | <div class="comments"> |
---|
| 247 | The format of the bar annotations. |
---|
| 248 | </div> |
---|
| 249 | |
---|
[163] | 250 | <h4 id="_colorbar_keyword_POSITION">POSITION |
---|
[138] | 251 | |
---|
| 252 | |
---|
| 253 | |
---|
| 254 | |
---|
| 255 | |
---|
| 256 | |
---|
[363] | 257 | <span class="attr">default:</span> <span class="value">see below</span> |
---|
[138] | 258 | |
---|
| 259 | </h4> |
---|
| 260 | |
---|
| 261 | <div class="comments"> |
---|
| 262 | A four-element array of normalized coordinates in the same |
---|
| 263 | form as the POSITION keyword on a plot. Default is |
---|
| 264 | [0.88, 0.15, 0.95, 0.95] for a vertical bar and |
---|
| 265 | [0.15, 0.88, 0.95, 0.95] for a horizontal bar. |
---|
| 266 | </div> |
---|
| 267 | |
---|
[163] | 268 | <h4 id="_colorbar_keyword_MAX">MAX |
---|
[138] | 269 | |
---|
| 270 | |
---|
| 271 | |
---|
| 272 | |
---|
| 273 | |
---|
| 274 | |
---|
| 275 | <span class="attr">default:</span> <span class="value">NCOLORS - 1</span> |
---|
| 276 | |
---|
| 277 | </h4> |
---|
| 278 | |
---|
| 279 | <div class="comments"> |
---|
| 280 | The maximum data value for the bar annotation. |
---|
| 281 | </div> |
---|
| 282 | |
---|
[163] | 283 | <h4 id="_colorbar_keyword_MIN">MIN |
---|
[138] | 284 | |
---|
| 285 | |
---|
| 286 | |
---|
| 287 | |
---|
| 288 | |
---|
| 289 | |
---|
| 290 | <span class="attr">default:</span> <span class="value">0</span> |
---|
| 291 | |
---|
| 292 | </h4> |
---|
| 293 | |
---|
| 294 | <div class="comments"> |
---|
| 295 | The minimum data value for the bar annotation. |
---|
| 296 | </div> |
---|
| 297 | |
---|
[163] | 298 | <h4 id="_colorbar_keyword_NCOLORS">NCOLORS |
---|
[138] | 299 | |
---|
| 300 | |
---|
| 301 | |
---|
| 302 | |
---|
| 303 | |
---|
| 304 | |
---|
| 305 | <span class="attr">default:</span> <span class="value">!D.N_COLORS</span> |
---|
| 306 | |
---|
| 307 | </h4> |
---|
| 308 | |
---|
| 309 | <div class="comments"> |
---|
| 310 | This is the number of colors in the color bar. |
---|
| 311 | </div> |
---|
| 312 | |
---|
[163] | 313 | <h4 id="_colorbar_keyword_PSCOLOR">PSCOLOR |
---|
[138] | 314 | |
---|
| 315 | |
---|
| 316 | |
---|
| 317 | |
---|
| 318 | |
---|
| 319 | |
---|
| 320 | |
---|
| 321 | |
---|
| 322 | </h4> |
---|
| 323 | |
---|
| 324 | <div class="comments"> |
---|
| 325 | This keyword is only applied if the output is being sent to |
---|
| 326 | a Postscript file. It indicates that the Postscript device |
---|
| 327 | is configured for color output. If this keyword is set, then |
---|
| 328 | the annotation is drawn in the color specified by the COLOR |
---|
| 329 | keyword. If the keyword is not set, the annotation is drawn |
---|
| 330 | in the color specified by the !P.COLOR system variable |
---|
| 331 | (usually this will be the color black). In general, this |
---|
| 332 | gives better looking output on non-color or gray-scale |
---|
| 333 | printers. If you are not specifically setting the annotation |
---|
| 334 | color (with the COLOR keyword), it will probably |
---|
| 335 | be better NOT to set this keyword either, even if you |
---|
| 336 | are outputting to a color Postscript printer. |
---|
| 337 | </div> |
---|
| 338 | |
---|
[163] | 339 | <h4 id="_colorbar_keyword_CB_TITLE">CB_TITLE |
---|
[138] | 340 | |
---|
| 341 | |
---|
| 342 | |
---|
| 343 | |
---|
| 344 | |
---|
| 345 | |
---|
| 346 | <span class="attr">default:</span> <span class="value">''</span> |
---|
| 347 | |
---|
| 348 | </h4> |
---|
| 349 | |
---|
| 350 | <div class="comments"> |
---|
| 351 | This is title for the color bar. |
---|
| 352 | </div> |
---|
| 353 | |
---|
[163] | 354 | <h4 id="_colorbar_keyword_VERTICAL">VERTICAL |
---|
[138] | 355 | |
---|
| 356 | |
---|
| 357 | |
---|
| 358 | |
---|
| 359 | |
---|
| 360 | |
---|
| 361 | <span class="attr">default:</span> <span class="value">0 -> horizontal color bar</span> |
---|
| 362 | |
---|
| 363 | </h4> |
---|
| 364 | |
---|
| 365 | <div class="comments"> |
---|
| 366 | Setting this keyword give a vertical color bar. |
---|
| 367 | </div> |
---|
| 368 | |
---|
[163] | 369 | <h4 id="_colorbar_keyword_TOP">TOP |
---|
[138] | 370 | |
---|
| 371 | |
---|
| 372 | |
---|
| 373 | |
---|
| 374 | |
---|
| 375 | |
---|
| 376 | |
---|
| 377 | |
---|
| 378 | </h4> |
---|
| 379 | |
---|
| 380 | <div class="comments"> |
---|
| 381 | This puts the labels on top of the bar rather than under it. |
---|
| 382 | The keyword only applies if a horizontal color bar is rendered. |
---|
| 383 | </div> |
---|
| 384 | |
---|
[163] | 385 | <h4 id="_colorbar_keyword_RIGHT">RIGHT |
---|
[138] | 386 | |
---|
| 387 | |
---|
| 388 | |
---|
| 389 | |
---|
| 390 | |
---|
| 391 | |
---|
| 392 | |
---|
| 393 | |
---|
| 394 | </h4> |
---|
| 395 | |
---|
| 396 | <div class="comments"> |
---|
| 397 | This puts the labels on the right-hand side of a vertical |
---|
| 398 | color bar. It applies only to vertical color bars. |
---|
| 399 | </div> |
---|
| 400 | |
---|
[163] | 401 | <h4 id="_colorbar_keyword_CB_LOG">CB_LOG |
---|
[138] | 402 | |
---|
| 403 | |
---|
| 404 | |
---|
| 405 | |
---|
| 406 | |
---|
| 407 | |
---|
| 408 | |
---|
| 409 | |
---|
| 410 | </h4> |
---|
| 411 | |
---|
| 412 | <div class="comments"> |
---|
| 413 | to get logarithmic scale for the colorbar |
---|
| 414 | </div> |
---|
| 415 | |
---|
[163] | 416 | <h4 id="_colorbar_keyword_NOTITLE">NOTITLE |
---|
[138] | 417 | |
---|
| 418 | |
---|
| 419 | |
---|
| 420 | |
---|
| 421 | |
---|
| 422 | |
---|
| 423 | |
---|
| 424 | |
---|
| 425 | </h4> |
---|
| 426 | |
---|
| 427 | <div class="comments"> |
---|
| 428 | Force to don't write title even if CB_TITLE is declared. |
---|
| 429 | </div> |
---|
| 430 | |
---|
[163] | 431 | <h4 id="_colorbar_keyword__EXTRA">_EXTRA |
---|
[138] | 432 | |
---|
| 433 | |
---|
| 434 | |
---|
| 435 | |
---|
| 436 | |
---|
| 437 | |
---|
| 438 | |
---|
| 439 | |
---|
| 440 | </h4> |
---|
| 441 | |
---|
[157] | 442 | <div class="comments"> |
---|
| 443 | pass any keyword to colorbar |
---|
| 444 | </div> |
---|
[138] | 445 | |
---|
| 446 | |
---|
| 447 | |
---|
| 448 | <h3>Examples</h3><div class="preformat"> |
---|
| 449 | To display a horizontal color bar above a contour plot, type: |
---|
| 450 | |
---|
| 451 | IDL> LOADCT, 5, NCOLORS=100 |
---|
| 452 | IDL> CONTOUR, DIST(31,41), POSITION=[0.15, 0.15, 0.95, 0.75], $ |
---|
| 453 | IDL> C_COLORS=INDGEN(25)*4, NLEVELS=25 |
---|
| 454 | IDL> COLORBAR, NCOLORS=100 |
---|
| 455 | </div> |
---|
| 456 | <h3>Version history</h3> |
---|
| 457 | |
---|
[234] | 458 | <h4>Version</h4><div class="preformat"> |
---|
[363] | 459 | $Id: colorbar.pro 358 2008-04-28 09:41:14Z pinsard $ |
---|
[138] | 460 | </div> |
---|
[234] | 461 | <h4>History</h4><div class="preformat"> |
---|
[138] | 462 | Written by: David Fanning, 10 JUNE 96. |
---|
| 463 | 10/27/96: Added the ability to send output to PostScript. DWF |
---|
| 464 | 11/04/96: Substantially rewritten to go to screen or PostScript |
---|
| 465 | file without having to know much about the PostScript device |
---|
| 466 | or even what the current graphics device is. DWF |
---|
| 467 | 01/27/97: Added the RIGHT and TOP keywords. Also modified the |
---|
| 468 | way the TITLE keyword works. DWF |
---|
| 469 | 07/15/97: Fixed a problem some machines have with plots that have |
---|
| 470 | no valid data range in them. DWF |
---|
| 471 | 03/03/98: Add DISCRETE keyword, sebastien masson (smasson@lodyc.jussieu.fr) |
---|
| 472 | </div> |
---|
| 473 | |
---|
| 474 | |
---|
| 475 | <h3>Known issues</h3> |
---|
| 476 | |
---|
| 477 | |
---|
| 478 | |
---|
| 479 | <h4>Restrictions</h4><div class="preformat"> |
---|
| 480 | The number of colors available on the display device (not the |
---|
| 481 | Postscript device) is used unless the NCOLORS keyword is used. |
---|
| 482 | </div> |
---|
| 483 | |
---|
| 484 | |
---|
| 485 | |
---|
| 486 | |
---|
| 487 | |
---|
| 488 | |
---|
| 489 | |
---|
| 490 | |
---|
| 491 | |
---|
[163] | 492 | <h3>Statistics</h3> |
---|
| 493 | <table class="statistics"> |
---|
| 494 | <tr><td>McCabe cyclic</td><td> 34</td></tr> |
---|
| 495 | <tr><td>McCabe essential</td><td> 1</td></tr> |
---|
| 496 | <tr><td>McCabe modular design</td><td> 1</td></tr> |
---|
| 497 | </table> |
---|
[138] | 498 | |
---|
| 499 | |
---|
| 500 | </div> |
---|
| 501 | |
---|
| 502 | </div> |
---|
| 503 | |
---|
| 504 | |
---|
| 505 | |
---|
| 506 | <div id="tagline">Produced by IDLdoc 2.0.</div> |
---|
| 507 | |
---|
| 508 | </div> |
---|
| 509 | |
---|
| 510 | </body> |
---|
[249] | 511 | </html> |
---|