[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Window Background
- Subject: Window Background
- From: Eric Kihn <ekihn(at)ngdc.noaa.gov>
- Date: Sat, 04 Nov 2000 00:08:32 GMT
- Newsgroups: comp.lang.idl-pvwave
- Organization: National Oceanic and Atmospheric Administration, Boulder
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:22020
Hello all,
Since I got such a great response to my last post I thought I'd try one
more time. Thanks to JD I got the code running but now the
behaviour on Windows and Linux is different. On the Linux side my plot
window comes up with a white background, on the Windows side a black one.
Same code and version of IDL 5.3. Since I need the white BG I tried
!P.BACKGROUND = 255 on windows but no change.
;-----
; Define color table.
;-----
r = [ 255, 68, 87, 58, 0, 0, 0, 0, 0, 0, $
8, 93, 169, 255, 255, 255, 255, 0]
g = [ 255, 0, 0, 0, 8, 97, 182, 255, 255, 255, $
255, 255, 255, 255, 170, 80, 0, 0]
b = [ 255, 72, 145, 218, 255, 255, 255, 242, 165, 80, $
0, 0, 0, 0, 0, 0, 0, 0]
tvlct, r, g, b
;-----
; Store images in arrays.
;-----
elec_image = transpose( j4_data( min_data_rec: $
max_data_rec).diff_num_flux_electrons(*))
ion_image = transpose( j4_data( min_data_rec: $
max_data_rec).diff_num_flux_ions(*))
image_size = size( elec_image)
;-----
; Set window size and plot position info.
;-----
num_colors = 17
!order = 1
x_size = 1000
y_size = 600
x_data_start = 150
x_data_end = 900
x_data_extent = x_data_end - x_data_start
y_data_e_top = 540
y_data_e_bottom = 340
y_data_i_top = 320
y_data_i_bottom = 120
y_data_extent = y_data_e_top - y_data_e_bottom
if ( y_data_extent NE y_data_i_top - y_data_i_bottom) then $
begin
print, 'Error in J4_COLOR_SPECTROGRAM: ', $ image = 0
return
endif
x_color_bar_left = x_data_end + 55
x_color_bar_right = x_color_bar_left + 20
y_color_bar_bottom = y_data_i_bottom + 50
y_color_bar_top = y_color_bar_bottom + 20 * ( num_colors - 1)
min_data_value = 1.0E05
max_data_value = 1.0E09
min_channel_energy = 30.0 ; eV
max_channel_energy = 30000.0 ; eV
;;;; Shouldn't this be trick ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
!P.BACKGROUND = 255
window, /free, xsize = x_size, ysize = y_size
;-----
; Labels.
;-----
x_tick_labels = [' ', ' ', ' ', ' ', ' ']