Geometrize  1.0
An application for geometrizing images into geometric primitives
Public Member Functions | Static Public Attributes | Private Attributes | List of all members
geometrize::scene::CustomTabletEvent Class Reference

The CustomTabletEvent class represents a tablet event (specifically from a Wacom Pro pen) that can be passed down to items in a graphics scene. More...

#include <customtabletevent.h>

Inheritance diagram for geometrize::scene::CustomTabletEvent:
Inheritance graph
[legend]
Collaboration diagram for geometrize::scene::CustomTabletEvent:
Collaboration graph
[legend]

Public Member Functions

 CustomTabletEvent (const TabletEventData &data, QWidget *sourceWidget)
 CustomTabletEvent Creates a custom tablet event. More...
 
 ~CustomTabletEvent ()=default
 
const TabletEventDatagetData () const
 

Static Public Attributes

static const int customEventId = QEvent::registerEventType()
 CustomTabletEventTypeId is the id for the corresponding custom tablet event type. More...
 

Private Attributes

const TabletEventData m_data
 

Detailed Description

The CustomTabletEvent class represents a tablet event (specifically from a Wacom Pro pen) that can be passed down to items in a graphics scene.

Constructor & Destructor Documentation

◆ CustomTabletEvent()

geometrize::scene::CustomTabletEvent::CustomTabletEvent ( const TabletEventData data,
QWidget *  sourceWidget 
)

CustomTabletEvent Creates a custom tablet event.

Parameters
dataThe data that the tablet event holds
sourceWidgetThe widget that the event came from
59  : QGraphicsSceneEvent{static_cast<QEvent::Type>(customEventId)}, m_data{data}
60 {
61  setWidget(sourceWidget);
62 }

◆ ~CustomTabletEvent()

geometrize::scene::CustomTabletEvent::~CustomTabletEvent ( )
default

Member Function Documentation

◆ getData()

const TabletEventData & geometrize::scene::CustomTabletEvent::getData ( ) const
65 {
66  return m_data;
67 }

Member Data Documentation

◆ customEventId

const int geometrize::scene::CustomTabletEvent::customEventId = QEvent::registerEventType()
static

CustomTabletEventTypeId is the id for the corresponding custom tablet event type.

◆ m_data

const TabletEventData geometrize::scene::CustomTabletEvent::m_data
private

The documentation for this class was generated from the following files:
geometrize::scene::CustomTabletEvent::customEventId
static const int customEventId
CustomTabletEventTypeId is the id for the corresponding custom tablet event type.
Definition: customtabletevent.h:93
geometrize::scene::CustomTabletEvent::m_data
const TabletEventData m_data
Definition: customtabletevent.h:106