Пример #1
0
    def __init__(self, session):

        MouseMode.__init__(self, session)

        self._moving_marker = None  # Atom
        self._resizing_marker_or_link = None  # Atom or Bond
        self._set_initial_sizes = True  # First marker on volume sets marker radius
Пример #2
0
    def __init__(self,
                 session,
                 tug_mgr,
                 atoms,
                 spring_constant=None,
                 mode='atom'):
        MouseMode.__init__(self, session)
        self.tug_mode = mode
        self._tugging = False
        self._last_xy = None
        self.name = 'ISOLDE_mouse_tug'
        self._focal_atom = None
        self._picked_atoms = None
        self._picked_tuggables = None
        self._pull_vector = None
        self._xyz0 = None
        self._xy = None
        # Atomic array to pick from
        self._atoms = atoms
        # Tuggable atoms manager
        self._tug_mgr = tug_mgr
        if spring_constant is None:
            from .constants import defaults
            spring_constant = defaults.MOUSE_TUG_SPRING_CONSTANT
        self.spring_constant = spring_constant
        self.structure = atoms.unique_structures[0]

        # Variables to be set by the caller
        self.last_tugged_atom = None
        self.already_tugging = False
Пример #3
0
    def __init__(self, session):

        MouseMode.__init__(self, session)

        self._map = None
        self._matching_maps = []  # Adjust region for these maps too.
        self._xy_last = None
        self._center = None  # Center of rotation
Пример #4
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self._residue = None
     self._align_atom_names = ['N', 'C', 'CA']
     self._step_pixels = 20
     self._step_meters = 0.05
     self._last_y = None
     self._label_atom_name = 'CA'  # Which atom to show residue label on.
Пример #5
0
    def __init__(self, session):

        MouseMode.__init__(self, session)

        self._zone_range = 3		# Angstroms from chosen residue
        self._minimize_steps = 10	# Number of steps per coordinate update
        self._tugger = None
        self._minimize_handler = None
Пример #6
0
    def __init__(self, session):
        MouseMode.__init__(self, session)
        self._maps = []

        # Allow adjusting multiple windows (non-zero regions of brightness curve).
        self._multiwindow = True
        self._centers = []
        self._window_num = 0
        self._vr_window_switch_motion = 0.02	# meters
        self._dragged = False
Пример #7
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self._start_point = None
     self._marker_set = None
     self._markers = []
     self._color = (255, 255, 0, 255)
     self._radius = .1  # scene units (usually Angstroms)
     self._vr_radius = .002  # meters, for use in VR
     self._min_move = 5  # minimum pixels to draw tape
     self._start_time = 0
     self._clear_time = 0.3  # seconds. Fast click/release causes clear.
Пример #8
0
    def __init__(self, session):

        MouseMode.__init__(self, session)

        self._tugger = None
        self._tugging = False
        self._tug_handler = None
        self._last_frame_number = None
        self._puller = None
        self._arrow_model = None

        self._log = Logger('tug.log' if write_logs else None)
Пример #9
0
    def __init__(self, session):

        MouseMode.__init__(self, session)

        self.bound_button = None

        self._map = None
        self._matching_maps = []  # Adjust region for these maps too.
        self._axis = None  # Clicked face normal axis = 0, 1 or 2
        self._side = None  # 0 or 1 for min/max box face along axis
        self._xy_last = None
        self._frac_istep = 0
        self._pixel_size = 1  # Screen pixel size in scene units at click point
        self._slab_side = 0  # 0 for first slice of tilted slab, 1 for last slice
        self._slab_dir = (0, 1)
Пример #10
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self._zone_center_residue = None
     self._residue_distance = 5
     self._label_distance = 4
     self._label_size = 64		# Pixels
     self._label_height = 0.7	# Scene units (Angstroms)
     from chimerax.core.colors import BuiltinColors
     self._label_color = BuiltinColors['yellow']
     self._label_background = BuiltinColors['black']
     self._surface_distance = 8
     self._coil_width_scale = (0.2, 0.2)
     self._helix_width_scale = (0.6, 0.2)
     self._helix_arrow_scale = (1.2, 0.2, 0.2, 0.2)
     self._sheet_width_scale = (0.6, 0.2)
     self._sheet_arrow_scale = (1.2, 0.2, 0.2, 0.2)
     self._ribbon_transparency = 100		# 0 = completely transparent, 255 = opaque
     self._labeled_residues = None
     self._scale_accum = 1
     self._scale_step = 1.3			# Minimum scaling step factor
     self._original_atom_display = None	# Boolean mask of which atoms originally shown
     self._original_residue_display = None	# Boolean mask of which residues originally shown
Пример #11
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self._wrap = False
     self._vr_full_range = 0.5	# Meters.  Motion to play full coordset.
Пример #12
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self._maps = []
     self.speed = 1		# Sensitivity of mouse motions.
Пример #13
0
 def __init__(self, session):
   MouseMode.__init__(self, session)
 
   self._series = None
   self._player = None
   self.last_mouse_x = None
Пример #14
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self.speed = 1
Пример #15
0
    def __init__(self, session):
        MouseMode.__init__(self, session)

        self._step_pixels = 50
        self._last_xy = None
Пример #16
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self._label = None
Пример #17
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self._first_atom = None
Пример #18
0
 def __init__(self, session):
     MouseMode.__init__(self, session)
     self._bond_rot = None
     self._speed_factor = 2
     self._minimum_angle_step = 2  # Degrees.  Only applies to drag with 3d pointer.
Пример #19
0
 def __init__(self, session):
     MouseMode.__init__(self, session)