Medical Imaging Interaction Toolkit  2025.12.02
Medical Imaging Interaction Toolkit
mitkApplicationCursor.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef mitkApplicationCursor_h
14 #define mitkApplicationCursor_h
15 
16 #include "mitkNumericTypes.h"
17 #include <MitkCoreExports.h>
18 
19 namespace mitk
20 {
29  {
30  public:
32  virtual void PushCursor(const char *XPM[], int hotspotX, int hotspotY) = 0;
33 
35  virtual void PushCursor(std::istream &, int hotspotX, int hotspotY) = 0;
36 
38  virtual void PopCursor() = 0;
39 
41  virtual const Point2I GetCursorPosition() = 0;
42 
44  virtual void SetCursorPosition(const Point2I &) = 0;
45 
47  protected:
48  private:
49  };
50 
62  {
63  public:
66 
69 
71  void PushCursor(const char *XPM[], int hotspotX = -1, int hotspotY = -1);
72 
74  void PushCursor(std::istream &, int hotspotX = -1, int hotspotY = -1);
75 
77  void PopCursor();
78 
82 
84  void SetCursorPosition(const Point2I &);
85 
86  protected:
89 
90  private:
91  static ApplicationCursorImplementation *m_Implementation;
92  };
93 
94 } // namespace
95 
96 #endif
#define MITKCORE_EXPORT
Toolkit specific implementation of mitk::ApplicationCursor.
virtual void PopCursor()=0
Restore the previous cursor.
virtual const Point2I GetCursorPosition()=0
Get absolute mouse position on screen.
virtual void SetCursorPosition(const Point2I &)=0
Set absolute mouse position on screen.
virtual void PushCursor(std::istream &, int hotspotX, int hotspotY)=0
Change the current application cursor.
virtual void PushCursor(const char *XPM[], int hotspotX, int hotspotY)=0
Change the current application cursor.
Allows to override the application's cursor.
const Point2I GetCursorPosition()
void SetCursorPosition(const Point2I &)
Set absolute mouse position on screen.
static void RegisterImplementation(ApplicationCursorImplementation *implementation)
To be called by a toolkit specific ApplicationCursorImplementation.
void PopCursor()
Restore the previous cursor.
ApplicationCursor()
Purposely hidden - singleton.
void PushCursor(const char *XPM[], int hotspotX=-1, int hotspotY=-1)
Change the current application cursor.
void PushCursor(std::istream &, int hotspotX=-1, int hotspotY=-1)
Change the current application cursor.
static ApplicationCursor * GetInstance()
This class is a singleton.
Find image slices visible on a given plane.