BioImager  3.9.1
A .NET microscopy imaging library. Supports various microscopes by using imported libraries & GUI automation. Supported libraries include PriorĀ® & ZeissĀ® & all devices supported by Micromanager 2.0 and python-microscope.
Loading...
Searching...
No Matches
BioImager.Scripting.State Class Reference

Public Member Functions

override string ToString ()
 

Static Public Member Functions

static State GetUp (PointD pf, MouseButtons mb)
 
static State GetDown (PointD pf, MouseButtons mb)
 
static State GetMove (PointD pf, MouseButtons mb)
 
static State GetNone ()
 

Public Attributes

Event type
 
PointD p
 
MouseButtons buts
 
bool processed = false
 

Detailed Description

Definition at line 161 of file Scripting.cs.

Member Function Documentation

◆ GetDown()

static State BioImager.Scripting.State.GetDown ( PointD  pf,
MouseButtons  mb 
)
static

‍This function returns a new State object with the type set to Event.Down, the point

set to the point passed in, and the buttons set to the buttons passed in

Parameters
PointDA point with double precision.
MouseButtonsThe mouse button that was pressed.
Returns
A new State object is being returned.

Definition at line 186 of file Scripting.cs.

187 {
188 State st = new State();
189 st.type = Event.Down;
190 st.p = pf;
191 st.buts = mb;
192 return st;
193 }

Referenced by BioImager.Tools.ToolDown().

◆ GetMove()

static State BioImager.Scripting.State.GetMove ( PointD  pf,
MouseButtons  mb 
)
static

‍This function returns a state object that represents a mouse move event

Parameters
PointDA point with double precision.
MouseButtonsThe mouse buttons that are pressed.
Returns
A new State object with the type, p, and buts fields set to the values passed in.

Definition at line 201 of file Scripting.cs.

202 {
203 State st = new State();
204 st.type = Event.Move;
205 st.p = pf;
206 st.buts = mb;
207 return st;
208 }

◆ GetNone()

static State BioImager.Scripting.State.GetNone ( )
static

It returns a new State object with the type set to None, the point set to a new PointD object, and the buttons set to None

Returns
A new State object with the type set to None, the point set to a new PointD object, and the buttons set to None.

Definition at line 214 of file Scripting.cs.

215 {
216 State st = new State();
217 st.type = Event.None;
218 st.p = new PointD();
219 st.buts = MouseButtons.None;
220 return st;
221 }

◆ GetUp()

static State BioImager.Scripting.State.GetUp ( PointD  pf,
MouseButtons  mb 
)
static

‍This function returns a new State object with the type set to Event.Up, the point set

to the point passed in, and the buttons set to the buttons passed in

Parameters
PointDA point with double precision.
MouseButtonsThe mouse button that was pressed.
Returns
A new State object is being returned.

Definition at line 171 of file Scripting.cs.

172 {
173 State st = new State();
174 st.type = Event.Up;
175 st.p = pf;
176 st.buts = mb;
177 return st;
178 }

Referenced by BioImager.Tools.ToolUp().

◆ ToString()

override string BioImager.Scripting.State.ToString ( )

Definition at line 226 of file Scripting.cs.

227 {
228 return type.ToString() + " ,(" + p.X.ToString() + ", " + p.Y.ToString() + "), " + buts.ToString();
229 }

Member Data Documentation

◆ buts

MouseButtons BioImager.Scripting.State.buts

Definition at line 224 of file Scripting.cs.

◆ p

◆ processed

bool BioImager.Scripting.State.processed = false

Definition at line 225 of file Scripting.cs.

◆ type

Event BioImager.Scripting.State.type

Definition at line 163 of file Scripting.cs.

Referenced by microscope.stages.linkam._CommsInfo.view_of_info().


The documentation for this class was generated from the following file: