@@ -297,13 +297,29 @@ function key_press(probe_atlas_gui,eventdata)
297297
298298 if ~any(strcmp(eventdata .Modifier ,' shift' ))
299299 % (no shift: list in native CCF order)
300+
300301 parsed_structures = unique(reshape(gui_data .av(1 : slice_spacing : end , ...
301- 1 : slice_spacing : end ,1 : slice_spacing : end ),[],1 ));
302- plot_structures_parsed = listdlg(' PromptString' ,' Select a structure to plot:' , ...
303- ' ListString' ,gui_data .st .safe_name(parsed_structures ),' ListSize' ,[520 ,500 ]);
304- plot_structures = parsed_structures(plot_structures_parsed );
305-
302+ 1 : slice_spacing : end ,1 : slice_spacing : end ),[],1 ));
306303
304+ if ~any(strcmp(eventdata .Modifier ,' alt' ))
305+ % (no alt: list all)
306+ plot_structures_parsed = listdlg(' PromptString' ,' Select a structure to plot:' , ...
307+ ' ListString' ,gui_data .st .safe_name(parsed_structures ),' ListSize' ,[520 ,500 ]);
308+ plot_structures = parsed_structures(plot_structures_parsed );
309+ else
310+ % (alt: search list)
311+ structure_search = lower(inputdlg(' Search structures' ));
312+ structure_match = find(contains(lower(gui_data .st .safe_name ),structure_search ));
313+ list_structures = intersect(parsed_structures ,structure_match );
314+ if isempty(list_structures )
315+ error(' No structure search results' )
316+ end
317+
318+ plot_structures_parsed = listdlg(' PromptString' ,' Select a structure to plot:' , ...
319+ ' ListString' ,gui_data .st .safe_name(list_structures ),' ListSize' ,[520 ,500 ]);
320+ plot_structures = list_structures(plot_structures_parsed );
321+ end
322+
307323 if ~isempty(plot_structures )
308324 for curr_plot_structure = reshape(plot_structures ,1 ,[])
309325 % If this label isn't used, don't plot
@@ -731,6 +747,7 @@ function probe_histology(probe_atlas_gui)
731747 ' m : set probe location manually' , ...
732748 ' \b f 3D brain areas: \r m' ...
733749 ' =/+ : add (list selector)' ...
750+ ' Alt/Option =/+ : add (search)' ...
734751 ' Shift =/+ : add (hierarchy selector)' ...
735752 ' - : remove' , ...
736753 ' \b f Visibility: \r m' ...
0 commit comments