microscope.gui module

Simple GUIs for individual devices.

This is meant as a simple GUIs for help during development. It does not aim to be pretty; it aims to be simple, complete, and work on any OS and Python without extra work. It is not meant as the basis for a full-fledged microscope GUI.

Tk was chosen for sake of simplicity. It is part of Python core so will be the easiest for users to test microscope and their hardware. It also prevents the version compatibility problems we have had with wxPython and PyQt.

class microscope.gui.DeformableMirror(dm, master=None, *args, **kwargs)[source]

Bases: tkinter.Frame

set_actuator(i, val)[source]
class microscope.gui.Device(device, master=None, *args, **kwargs)[source]

Bases: tkinter.Frame

microscope.gui.make_app(frame_cls, *args, **kwargs)[source]

Make a simple tkinter application from a single Frame.

A utility function that wraps a single tkinter Frame into its own application.

  • frame_cls (tkinter.Frame) – Frame class
  • *args – Argument list to initialize frame_cls
  • **kwargs – Keyword arguments to initialize frame_cls