Contents plugin provides a table of contents-like interface for all
the images viewed since the program was started. Unlike
Contents is sorted by channel. The contents also shows some configurable
metadata from the image.
Plugin Type: Global
Contents is a global plugin. Only one instance can be opened.
Click on a column heading to sort the table by that column; Click again to sort the other way.
The columns and their values are drawn from the FITS header, if applicable. This can be customized by setting the “columns” parameter in the “plugin_Contents.cfg” settings file.
The active image in the currently focused channel will normally be highlighted. Double-click on an image will force that image to be shown in the associated channel. Single-click on any image to activate the buttons at the bottom of the UI:
“Display”: Make the image the active image.
“Move”: Move the image to another channel.
“Copy”: Copy the image to another channel.
“Remove”: Remove the image from the channel.
If “Move” or “Copy” is done on an image that has been modified in Ginga
(which would have an entry under
ChangeHistory, if used), the
modification history will be retained as well. Removing an image from
a channel destroys any unsaved changes.
This plugin is not usually configured to be closeable, but the user can make it so by setting the “closeable” setting to True in the configuration file–then Close and Help buttons will be added to the bottom of the UI.
Excluding images from Contents
This also controls the behavior of
Although the default behavior is for every image that is loaded into the
reference viewer to show up in
Contents, there may be cases where this
is undesirable (e.g., when there are many images being loaded at a
periodic rate by some automated process). In such cases there are two
mechanisms for suppressing certain images from showing up in
Assigning the “genthumb” setting to False in a channel’s settings (for example from the
Preferencesplugin, under the “General” settings) will exclude the channel itself and any of its images.
Setting the “nothumb” keyword in the metadata of an image wrapper (not the FITS header, but by e.g.,
image.set(nothumb=True)) will exclude that particular image from
Contents, even if the “genthumb” setting is True for that channel.
It is customizable using
is your HOME directory:
# # Contents plugin preferences file # # Place this in file under ~/.ginga with the name "plugin_Contents.cfg" # columns to show from metadata -- NAME and MODIFIED recommended # format: [(col header, keyword1), ... ] columns = [ ('Name', 'NAME'), ('Object', 'OBJECT'), ('Filter', 'FILTER01'), ('Date', 'DATE-OBS'), ('Time UT', 'UT'), ('Modified', 'MODIFIED')] # If set to True, will always expand the tree in Contents when new entries are added always_expand = True # Option to highlight images that are displayed in channels. # If set to True this option will only highlight the image that is in the # channel with the keyboard focus highlight_tracks_keyboard_focus = False # If True, color every other row in alternating shades to improve # readability of long tables color_alternate_rows = True # Highlighted row colors (in addition to bold text) row_font_color = 'green' # Maximum number of rows that will turn off auto column resizing (for speed) max_rows_for_col_resize = 100 # Add a close button to this plugin, so that it can be stopped closeable = False