mgear.core.widgets

mGear Qt custom widgets

class mgear.core.widgets.DragQListView(parent)

QListView with basic drop functionality

exp

int – Extend the mouse position to a rectable

theAction

func – function triggered when drop

doAction(sel)
mouseMoveEvent(event)
setAction(action)
staticMetaObject = <PySide2.QtCore.QMetaObject object>
class mgear.core.widgets.TableWidgetDragRows(*args, **kwargs)

qTableWidget with drag and drop functionality

dropEvent(event)
dropOn(event)
drop_on(event)
droppingOnItself(event, index)
getSelectedRowsFast()
is_below(pos, index)
position(pos, rect, index)
staticMetaObject = <PySide2.QtCore.QMetaObject object>
mgear.core.widgets.selectFromScreenApi(x, y, x_rect=None, y_rect=None)

Find the object under the cursor on Maya view

found here: http://nathanhorne.com/maya-python-selectfromscreen/ Thanks Nathan! :param x: rectable selection start x :type x: int :param y: rectagle selection start y :type y: int :param x_rect: rectable selection end x :type x_rect: int, optional :param y_rect: rectagle selection end y

Returns:Name of the objects under the cursor
Return type:list of str