[2] | 1 | ;------------------------------------------------------------ |
---|
| 2 | ;------------------------------------------------------------ |
---|
| 3 | ;------------------------------------------------------------ |
---|
| 4 | ;+ |
---|
| 5 | ; |
---|
[142] | 6 | ; @file_comments |
---|
| 7 | ; This procedure will reinitialise all or a selection |
---|
| 8 | ; ofthe system plot variables |
---|
[2] | 9 | ; |
---|
[142] | 10 | ; @categories |
---|
| 11 | ; plot Utility |
---|
[2] | 12 | ; |
---|
[142] | 13 | ; |
---|
| 14 | ; @keyword X |
---|
| 15 | ; clear the appropriate variable |
---|
[2] | 16 | ; |
---|
[142] | 17 | ; @keyword Y |
---|
| 18 | ; clear the appropriate variable |
---|
| 19 | ; |
---|
| 20 | ; @keyword Z |
---|
| 21 | ; clear the appropriate variable |
---|
| 22 | ; |
---|
| 23 | ; @keyword P |
---|
| 24 | ; clear the appropriate variable |
---|
| 25 | ; |
---|
| 26 | ; @keyword ALL |
---|
| 27 | ; Clear all, this is equivalent to /x,/y,/z,/p |
---|
| 28 | ; |
---|
| 29 | ; @keyword INVERT |
---|
| 30 | ; Invert the logic. Clear all unselected variables. |
---|
| 31 | ; Therefore "clearplt,/all,/invert" does nothing. |
---|
[2] | 32 | ; |
---|
[142] | 33 | ; @uses |
---|
| 34 | ; common.pro |
---|
| 35 | ; |
---|
| 36 | ; @restrictions |
---|
| 37 | ; The sytem plot variables are changed. |
---|
[2] | 38 | ; |
---|
[142] | 39 | ; @history |
---|
| 40 | ; Written by: Trevor Harris, Physics Dept., University of Adelaide, |
---|
[2] | 41 | ; July, 1990. |
---|
| 42 | ; |
---|
[142] | 43 | ; Sebastien Masson 7/5/98 |
---|
[2] | 44 | ; |
---|
[142] | 45 | ; @version |
---|
| 46 | ; $Id$ |
---|
| 47 | ; |
---|
[2] | 48 | ;- |
---|
| 49 | ;------------------------------------------------------------ |
---|
| 50 | ;------------------------------------------------------------ |
---|
| 51 | ;------------------------------------------------------------ |
---|
| 52 | pro reinitplt, all=all,x=x,y=y,z=z,p=p, invert=invert |
---|
| 53 | ;------------------------------------------------------------ |
---|
[114] | 54 | ; |
---|
| 55 | compile_opt idl2, strictarrsubs |
---|
| 56 | ; |
---|
[2] | 57 | clearx = 0 |
---|
| 58 | cleary = 0 |
---|
| 59 | clearz = 0 |
---|
| 60 | clearp = 0 |
---|
| 61 | if (keyword_set(x)) then clearx = 1 |
---|
| 62 | if (keyword_set(y)) then cleary = 1 |
---|
| 63 | if (keyword_set(z)) then clearz = 1 |
---|
| 64 | if (keyword_set(p)) then clearp = 1 |
---|
| 65 | if (keyword_set(all)) $ |
---|
| 66 | or (not keyword_set(x) and not keyword_set(y) and $ |
---|
| 67 | not keyword_set(z) and not keyword_set(p)) then begin |
---|
| 68 | clearx = 1 |
---|
| 69 | cleary = 1 |
---|
| 70 | clearz = 1 |
---|
| 71 | clearp = 1 |
---|
| 72 | endif |
---|
| 73 | |
---|
| 74 | if (keyword_set(invert)) then begin |
---|
| 75 | clearx = not clearx |
---|
| 76 | cleary = not cleary |
---|
| 77 | clearz = not clearz |
---|
| 78 | clearp = not clearp |
---|
| 79 | endif |
---|
| 80 | |
---|
| 81 | if (clearx) then begin |
---|
| 82 | !x.charsize=0 |
---|
| 83 | !x.GRIDSTYLE=0 |
---|
| 84 | !X.MARGIN=[10,3] |
---|
| 85 | !X.MINOR=0 |
---|
| 86 | !X.OMARGIN=[0,0] |
---|
| 87 | !x.region=0 |
---|
| 88 | !X.RANGE=0 |
---|
| 89 | !x.STYLE=5 |
---|
| 90 | ; !x.tick=1 |
---|
| 91 | !x.TICKFORMAT='' |
---|
| 92 | !x.TICKLEN=0 |
---|
| 93 | !x.tickname='' |
---|
| 94 | !x.ticks=0 |
---|
| 95 | !X.TICKV[0]=!X.TICKV[1] |
---|
| 96 | !x.title='' |
---|
| 97 | !x.TYPE=0 |
---|
| 98 | endif |
---|
| 99 | if (cleary) then begin |
---|
| 100 | !y.charsize=0 |
---|
| 101 | !y.GRIDSTYLE=0 |
---|
| 102 | !Y.MARGIN=[10,3] |
---|
| 103 | !Y.MINOR=0 |
---|
| 104 | !Y.OMARGIN=[0,0] |
---|
| 105 | !y.region=0 |
---|
| 106 | !Y.RANGE=0 |
---|
| 107 | !y.STYLE=5 |
---|
| 108 | ; !y.tick=1 |
---|
| 109 | !y.TICKFORMAT='' |
---|
| 110 | !y.TICKLEN=0 |
---|
| 111 | !y.tickname='' |
---|
| 112 | !y.ticks=0 |
---|
| 113 | !Y.TICKV[0]=!Y.TICKV[1] |
---|
| 114 | !y.title='' |
---|
| 115 | !y.TYPE=0 |
---|
| 116 | endif |
---|
| 117 | if (clearz) then begin |
---|
| 118 | !z.charsize=0 |
---|
| 119 | !z.GRIDSTYLE=0 |
---|
| 120 | !Z.MARGIN=[10,3] |
---|
| 121 | !Z.MINOR=0 |
---|
| 122 | !Z.OMARGIN=[0,0] |
---|
| 123 | !z.region=0 |
---|
| 124 | !Z.RANGE=0 |
---|
| 125 | !z.STYLE=1 |
---|
| 126 | ; !z.tick=1 |
---|
| 127 | !z.TICKFORMAT='' |
---|
| 128 | !z.TICKLEN=0 |
---|
| 129 | !z.tickname='' |
---|
| 130 | !z.ticks=0 |
---|
| 131 | !Z.TICKV[0]=!Z.TICKV[1] |
---|
| 132 | !z.title='' |
---|
| 133 | !z.TYPE=0 |
---|
| 134 | endif |
---|
| 135 | if (clearp) then begin |
---|
| 136 | !p.BACKGROUND=(!d.n_colors-1) < 255 |
---|
| 137 | !p.CHARSIZE=1. |
---|
| 138 | !p.CHARTHICK=0 |
---|
| 139 | !p.LINESTYLE=0 |
---|
| 140 | !p.MULTI=replicate(0,5) |
---|
| 141 | !p.NOERASE=0 |
---|
| 142 | !p.POSITION=0 |
---|
| 143 | !p.region=0 |
---|
| 144 | !p.title='' |
---|
| 145 | !p.subtitle='' |
---|
| 146 | !p.ticklen=0.02 |
---|
| 147 | !p.thick=0.1 |
---|
| 148 | !p.color=0 |
---|
| 149 | endif |
---|
| 150 | return |
---|
| 151 | end |
---|
| 152 | |
---|
| 153 | |
---|
| 154 | |
---|
| 155 | |
---|
| 156 | |
---|
| 157 | |
---|