|
KiCad PCB EDA Suite
|
Simple class to construct and store cursors against unique ID keys. More...
#include <cursors.h>
Classes | |
| struct | CURSOR_DEF |
| Definition of a cursor. More... | |
Static Public Member Functions | |
| static const WX_CURSOR_TYPE | GetCursor (KICURSOR aCursorType, bool aHiDPI=false) |
| Get a cursor bundle (wx 3.3+) or appropriate cursor (older versions) | |
| static wxStockCursor | GetStockCursor (KICURSOR aCursorType) |
| Get stock cursor type for the given cursor. | |
Private Member Functions | |
| CURSOR_STORE () | |
| Construct a store with cursors for all defined types. | |
| const wxCursor & | storeGetCursor (KICURSOR aIdKey, bool aHiDPI=false) const |
| Get a cursor by its ID, automatically selecting the appropriate resolution. | |
Private Attributes | |
| std::map< KICURSOR, wxCursor > | m_standardCursorMap |
| std::map< KICURSOR, wxCursor > | m_hidpiCursorMap |
Simple class to construct and store cursors against unique ID keys.
This can be used to lazily construct cursors as needed for specific applications.
|
private |
Construct a store with cursors for all defined types.
The store will automatically contain both standard and HiDPI cursors.
Definition at line 315 of file cursors.cpp.
References cursors_defs, m_hidpiCursorMap, and m_standardCursorMap.
Referenced by GetCursor().
|
static |
Get a cursor bundle (wx 3.3+) or appropriate cursor (older versions)
| aCursorType | the cursor type to get |
| aHiDPI | whether to prefer HiDPI version for older wx versions |
Definition at line 390 of file cursors.cpp.
References CURSOR_STORE(), GetStockCursor(), Pgm(), and storeGetCursor().
Referenced by KIGFX::CAIRO_GAL::SetNativeCursorStyle(), and KIGFX::OPENGL_GAL::SetNativeCursorStyle().
|
static |
Get stock cursor type for the given cursor.
| aCursorType | the cursor type |
Definition at line 424 of file cursors.cpp.
References ARROW, BULLSEYE, HAND, KIPLATFORM::UI::IsStockCursorOk(), and MOVING.
Referenced by GetCursor().
|
private |
Get a cursor by its ID, automatically selecting the appropriate resolution.
| aIdKey | the ID key to look up |
| aHiDPI | whether to prefer HiDPI version if available |
Definition at line 375 of file cursors.cpp.
References m_hidpiCursorMap, and m_standardCursorMap.
Referenced by GetCursor().
|
private |
Definition at line 166 of file cursors.h.
Referenced by CURSOR_STORE(), and storeGetCursor().
|
private |
Definition at line 165 of file cursors.h.
Referenced by CURSOR_STORE(), and storeGetCursor().