#NEWLINE# def preview( self ) : #NEWLINE# #INDENT# ' Display a preview of the data structure in the preview\n            window.\n        ' #NEWLINE# self . _preview_window . clear ( ) #NEWLINE# self . _preview_window . add_source ( data . data_source ) #NEWLINE# data = ( lambda name : self . data_sources [ name ] ) #NEWLINE# g = Glyph ( ) #NEWLINE# g . glyph . glyph_source . glyph_source = g . glyph . glyph_source . glyph_list [ 0 ] #NEWLINE# g . glyph . scale_mode = 'data_scaling_off' #NEWLINE# if ( not ( self . has_vector_data or ( self . data_type_ == 'vector' ) ) ) : #NEWLINE# #INDENT# g . glyph . glyph_source . glyph_source . glyph_type = 'cross' #NEWLINE# g . actor . property . representation = 'points' #NEWLINE# g . actor . property . point_size = 3.0 #NEWLINE# #UNINDENT# self . _preview_window . add_module ( g ) #NEWLINE# if ( ( not ( self . data_type_ in ( 'point' , 'vector' ) ) ) or self . lines ) : #NEWLINE# #INDENT# s = Surface ( ) #NEWLINE# s . actor . property . opacity = 0.3 #NEWLINE# self . _preview_window . add_module ( s ) #NEWLINE# #UNINDENT# if ( not ( self . data_type_ == 'point' ) ) : #NEWLINE# #INDENT# self . _preview_window . add_filter ( ExtractEdges ( ) ) #NEWLINE# s = Surface ( ) #NEWLINE# s . actor . property . opacity = 0.2 #NEWLINE# self . _preview_window . add_module ( s )