Changeset 223


Ignore:
Timestamp:
12/20/07 16:06:24 (4 years ago)
Author:
dcollins
Message:

made inquest plot opions, overplot work

Location:
trunk/Code
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Code/grab.pro

    r222 r223  
    9393                LocalDomainLeft  = [0.0,0.0,0.0] 
    9494                LocalDomainRight = [1.0,1.0,1.0] 
    95                 LocalFinestWidth = [0.1,0.1,0.1] 
     95                dimsA = size(LocalA,/dimension) 
     96                LocalFinestWidth = (LocalDomainRight-LocalDomainLeft)/dimsA 
    9697            endelse 
     98            ;stop 
    9799            break 
    98              
     100 
    99101        end 
    100102 
  • trunk/Code/gsh.pro

    r194 r223  
    305305 
    306306 
    307 ;print, "Grids shown:", GoodList[0:nGood-1] + 1 
     307print, "Grids shown:", GoodList[0:nGood-1] + 1 
    308308if ptr_valid(self.GridsInPlot) then ptr_free, self.GridsInPlot 
    309309self.GridsInPlot = ptr_new(GoodList, /no_copy) 
  • trunk/Code/gui.pro

    r222 r223  
    5555;get new geometry, resize draw window, resize pixmap, replot data. 
    5656case uname of 
    57     'inq_plot_opts': begin 
    58         print, "monkey" 
    59     end 
     57    'inq_plot_opts': (*top_uvalue).inq_plot_opts = event.value 
     58    'inquest_overplot': (*top_uvalue).inquest_overplot = event.value 
    6059    'inquest_persistent': (*top_uvalue).inquest_persistent = event.value 
    6160    'inquest_base': begin  
     
    195194if (*top_uvalue).ValidPlot EQ 1 then begin 
    196195    if (*top_uvalue).inquest_persistent EQ 1 then begin 
    197  
    198  
    199         ;get data, plot into inquest 
     196         
     197         
     198                                ;get data, plot into inquest 
    200199        indicies = (*(*top_uvalue).indexLine) 
    201200        Xaxis = (*(*top_uvalue).coordline) 
    202201        DataLine = (*(*top_uvalue).b)[indicies] 
    203202        wset, (*top_uvalue).inquest_pix_number ;use this next 
    204         plot, Xaxis, DataLine, psym = -5, xstyle=1 
     203        opts = "" 
     204        if (*top_uvalue).inq_plot_opts NE "" then opts = ","+(*top_uvalue).inq_plot_opts 
     205        if (*top_uvalue).inquest_overplot EQ 0 then begin 
     206            ret = execute('plot, Xaxis, DataLine, xstyle=1' + opts) 
     207        endif else begin 
     208            ret = execute('oplot, Xaxis,DataLine' + opts) 
     209        endelse 
    205210        wset, (*top_uvalue).inquest_window_number 
    206211        device,copy = [0,0,!d.x_size,!d.y_size,0,0,(*top_uvalue).inquest_pix_number]     
     
    755760                               event_pro="menu_buttons", uname = "inquest_button",$ 
    756761                               uvalue = ptr_new({base:inquest_base}) ) 
    757 inq_plot_opts  = cw_field(inq_tools,/row,title="plot opts",/string,value = 'this doesnt work yet', $ 
    758                     uname="inq_plot_opts", xsize = 40 ) 
     762inq_plot_opts  = cw_field(inq_tools,/row,title="plot opts",/string,value = 'psym = -5', $ 
     763                    uname="inq_plot_opts", xsize = 40,/all_events ) 
    759764 
    760765inq_pers = cw_bgroup(inq_tools,['no','yes'],/col,/exclusive ,set_value = 0, $ 
    761766                uname="inquest_persistent", /return_index, label_left='persistent', frame =1) 
     767 
     768inq_oplot = cw_bgroup(inq_tools,['no','yes'],/col,/exclusive ,set_value = 0, $ 
     769                uname="inquest_overplot", /return_index, label_left='oplot', frame =1) 
    762770 
    763771inquest_button = widget_button(button_column,value = 'Inquest', $; xsize = button_x,ysize = button_y,$ 
     
    938946                               'LineDrawn',0, 'HoldingEnd',0, 'DataLine',DataLine, $ 
    939947                               'CoordLine',CoordLine, 'IndexLine',IndexLine,$ 
    940                                'inq_plot_opts','', 'vis','hidden', 'inquest_persistent', 0) 
     948                               'inq_plot_opts','', 'vis','hidden', 'inquest_persistent',0,$ 
     949                               'inquest_overplot', 0,'inquest_plotted', 0) 
    941950;Things unique to the main window 
    942951main_uvalue = create_struct('object',self, $ 
  • trunk/Code/main_window_event.pro

    r222 r223  
    124124                DataLine = (*(*top_uvalue).b)[indicies] 
    125125                wset, (*top_uvalue).inquest_pix_number ;use this next 
    126                 plot, Xaxis, DataLine, psym = -5, xstyle=1 
     126 
     127                                ;Due to a design error, the first plot 
     128                                ;is done here. (as the line is drawn.) 
     129                                ;All persistent and oplots are done in 
     130                                ;the gui. 
     131                opts = "" 
     132                if (*top_uvalue).inq_plot_opts NE "" then opts = ","+(*top_uvalue).inq_plot_opts 
     133                ret = execute("plot, Xaxis, DataLine,/xstyle" + opts) 
    127134                wset, (*top_uvalue).inquest_window_number 
    128135                 
Note: See TracChangeset for help on using the changeset viewer.