Paints a translucent rectangle over another widget.
More...
|
| | DropOverlay (QWidget *parent) |
| | Constructs a DropOverlay with the given parent widget.
|
| DropArea | cursorLocation () const |
| | Returns the drop area currently under the mouse cursor.
|
|
void | hideDropOverlay () |
| | Hides the drop overlay.
|
| void | setAreaWidgets (const QHash< DropArea, QWidget * > &widgets) |
| | Sets the mapping of drop areas to their corresponding indicator widgets.
|
| void | showDropOverlay (QWidget *target, const QRect &targetAreaRect) |
| | Shows the drop overlay over the target widget constrained to a specific rectangle.
|
| DropArea | showDropOverlay (QWidget *target, QWidget *payload) |
| | Shows the drop overlay over the target widget for the given payload.
|
|
| virtual void | hideEvent (QHideEvent *e) override |
| | Handles the hide event to clean up overlay state.
|
| virtual void | moveEvent (QMoveEvent *e) override |
| | Handles move events to update overlay positioning.
|
| virtual void | paintEvent (QPaintEvent *e) override |
| | Paints the translucent drop indicator rectangle.
|
| virtual void | resizeEvent (QResizeEvent *e) override |
| | Handles resize events to update overlay geometry.
|
| virtual void | showEvent (QShowEvent *e) override |
| | Handles the show event to update overlay positioning.
|
Paints a translucent rectangle over another widget.
The geometry of the rectangle is based on the mouse location. Used with the NDEVR API Widget Docking system to show where a dock can be placed.
Definition at line 45 of file DropOverlay.h.
◆ DropOverlay()
| DropOverlay::DropOverlay |
( |
QWidget * | parent | ) |
|
◆ cursorLocation()
| DropArea DropOverlay::cursorLocation |
( |
| ) |
const |
Returns the drop area currently under the mouse cursor.
- Returns
- The DropArea beneath the cursor.
◆ hideEvent()
| virtual void DropOverlay::hideEvent |
( |
QHideEvent * | e | ) |
|
|
overrideprotectedvirtual |
Handles the hide event to clean up overlay state.
- Parameters
-
◆ moveEvent()
| virtual void DropOverlay::moveEvent |
( |
QMoveEvent * | e | ) |
|
|
overrideprotectedvirtual |
Handles move events to update overlay positioning.
- Parameters
-
◆ paintEvent()
| virtual void DropOverlay::paintEvent |
( |
QPaintEvent * | e | ) |
|
|
overrideprotectedvirtual |
Paints the translucent drop indicator rectangle.
- Parameters
-
◆ resizeEvent()
| virtual void DropOverlay::resizeEvent |
( |
QResizeEvent * | e | ) |
|
|
overrideprotectedvirtual |
Handles resize events to update overlay geometry.
- Parameters
-
◆ setAreaWidgets()
| void DropOverlay::setAreaWidgets |
( |
const QHash< DropArea, QWidget * > & | widgets | ) |
|
Sets the mapping of drop areas to their corresponding indicator widgets.
- Parameters
-
| [in] | widgets | A hash mapping DropArea values to their QWidget indicators. |
◆ showDropOverlay() [1/2]
| void DropOverlay::showDropOverlay |
( |
QWidget * | target, |
|
|
const QRect & | targetAreaRect ) |
Shows the drop overlay over the target widget constrained to a specific rectangle.
- Parameters
-
| [in] | target | The widget being dropped onto. |
| [in] | targetAreaRect | The rectangle within the target to constrain the overlay. |
◆ showDropOverlay() [2/2]
| DropArea DropOverlay::showDropOverlay |
( |
QWidget * | target, |
|
|
QWidget * | payload ) |
Shows the drop overlay over the target widget for the given payload.
- Parameters
-
| [in] | target | The widget being dropped onto. |
| [in] | payload | The widget being dragged. |
- Returns
- The DropArea currently indicated by the overlay.
◆ showEvent()
| virtual void DropOverlay::showEvent |
( |
QShowEvent * | e | ) |
|
|
overrideprotectedvirtual |
Handles the show event to update overlay positioning.
- Parameters
-
The documentation for this class was generated from the following file: