5#ifndef JPP_I_CURSOR_CONTROL_HPP_INCLUDED
6#define JPP_I_CURSOR_CONTROL_HPP_INCLUDED
8#include <jimcpp/core/engine/IReferenceCounted.hpp>
9#include <jimcpp/core/engine/position2d.hpp>
10#include <jimcpp/core/engine/rect.hpp>
68 : SpriteBank(0), SpriteId(-1)
73 : SpriteBank(spriteBank), SpriteId(spriteId), HotSpot(hotspot)
Base class of most objects of the Jimcpp Engine.
Definition IReferenceCounted.hpp:46
Axis aligned bounding box in 3d dimensional space.
Definition aabbox3d.hpp:22
Interface to manipulate the mouse cursor.
Definition ICursorControl.hpp:100
virtual bool isVisible() const =0
Returns if the cursor is currently visible.
virtual ECURSOR_PLATFORM_BEHAVIOR getPlatformBehavior() const
Return platform specific behavior.
Definition ICursorControl.hpp:193
virtual const core::position2d< s32 > & getPosition(bool updateCursor=true)=0
Returns the current position of the mouse cursor.
virtual void setPosition(f32 x, f32 y)=0
Sets the new position of the cursor.
virtual void setReferenceRect(core::rect< s32 > *rect=0)=0
Sets an absolute reference rect for setting and retrieving the cursor position.
virtual void setActiveIcon(ECURSOR_ICON iconId)
Sets the active cursor icon.
Definition ICursorControl.hpp:168
virtual void setPlatformBehavior(ECURSOR_PLATFORM_BEHAVIOR behavior)
Set platform specific behavior flags.
Definition ICursorControl.hpp:188
virtual void setVisible(bool visible)=0
Changes the visible state of the mouse cursor.
virtual void setPosition(const core::position2d< f32 > &pos)=0
Sets the new position of the cursor.
virtual core::dimension2di getSupportedIconSize() const
Return a system-specific size which is supported for cursors. Larger icons will fail,...
Definition ICursorControl.hpp:185
virtual ECURSOR_ICON getActiveIcon() const
Gets the currently active icon.
Definition ICursorControl.hpp:171
virtual ECURSOR_ICON addIcon(const gui::SCursorSprite &icon)
Add a custom sprite as cursor icon.
Definition ICursorControl.hpp:175
virtual void changeIcon(ECURSOR_ICON iconId, const gui::SCursorSprite &sprite)
replace a cursor icon.
Definition ICursorControl.hpp:182
virtual void setPosition(const core::position2d< s32 > &pos)=0
Sets the new position of the cursor.
virtual core::position2d< f32 > getRelativePosition(bool updateCursor=true)=0
Returns the current position of the mouse cursor.
virtual void setPosition(s32 x, s32 y)=0
Sets the new position of the cursor.
Sprite bank interface.
Definition IGUISpriteBank.hpp:71
class used to set sprites as cursors.
Definition ICursorControl.hpp:65
dimension2d< s32 > dimension2di
using type alias for an integer dimension.
Definition dimension2d.hpp:217
ECURSOR_PLATFORM_BEHAVIOR
platform specific behavior flags for the cursor
Definition ICursorControl.hpp:85
@ ECPB_NONE
default - no platform specific behavior
Definition ICursorControl.hpp:87
@ ECPB_X11_CACHE_UPDATES
On X11 try caching cursor updates as XQueryPointer calls can be expensive.
Definition ICursorControl.hpp:95
const c8 *const GUICursorIconNames[ECI_COUNT+1]
Names for ECURSOR_ICON.
Definition ICursorControl.hpp:45
ECURSOR_ICON
Default icons for cursors.
Definition ICursorControl.hpp:21
As of Jimcpp 1.6, position2d is a synonym for vector2d.
Definition vector3d.hpp:11
signed int s32
32 bit signed variable.
Definition irrTypes.hpp:72
float f32
32 bit floating point variable.
Definition irrTypes.hpp:110
char c8
8 bit character variable.
Definition irrTypes.hpp:37