![]() |
Louvre
v2.9.0-1
C++ library for Wayland compositors
|
An XCursor icon. More...
Public Member Functions | |
~LXCursor ()=default | |
Destructor. More... | |
const LTexture * | texture () const noexcept |
Gets the cursor's texture. More... | |
const LPoint & | hotspotB () const noexcept |
Gets the cursor's hotspot in buffer coordinates. More... | |
Static Public Member Functions | |
static LXCursor * | load (const char *cursor, const char *theme=NULL, Int32 suggestedSize=64) noexcept |
Load an XCursor pixmap. More... | |
An XCursor icon.
XCursor icons are widely used for cursor themes in Linux.
This class facilitates loading icons installed on the system and retrieving their hotspot and texture, which can then be applied to LCursor.
Example usage:
|
default |
Destructor.
Release the icon resources, including the texture.
|
staticnoexcept |
Load an XCursor pixmap.
Loads an XCursor that matches the specified name and theme.
cursor | Name of the XCursor to load. |
theme | Name of the cursor theme. Pass NULL if you don't want to specify a theme. |
suggestedSize | Suggested buffer size (width or height) of the pixmap. Returns the variant of the pixmap with closest dimensions to the specified one. |
nullptr
.
|
inlinenoexcept |
Gets the cursor's texture.
|
inlinenoexcept |
Gets the cursor's hotspot in buffer coordinates.