5 |
5 |
6 """ |
6 """ |
7 Module implementing the icon editor grid. |
7 Module implementing the icon editor grid. |
8 """ |
8 """ |
9 |
9 |
10 from PyQt4.QtCore import pyqtSignal, Qt, QPoint, QRect, QSize |
10 from PyQt4.QtCore import pyqtSignal, pyqtSlot, Qt, QPoint, QRect, QSize |
11 from PyQt4.QtGui import QUndoCommand, QImage, QWidget, QColor, QPixmap, \ |
11 from PyQt4.QtGui import QUndoCommand, QImage, QWidget, QColor, QPixmap, \ |
12 QSizePolicy, QUndoStack, qRgba, QPainter, QApplication, QCursor, \ |
12 QSizePolicy, QUndoStack, qRgba, QPainter, QApplication, QCursor, \ |
13 QBrush, QDialog, qGray, qAlpha |
13 QBrush, QDialog, qGray, qAlpha |
14 |
14 |
15 from E5Gui import E5MessageBox |
15 from E5Gui import E5MessageBox |
877 """ |
877 """ |
878 if self.__selRect.isValid(): |
878 if self.__selRect.isValid(): |
879 img = self.__getSelectionImage(True) |
879 img = self.__getSelectionImage(True) |
880 QApplication.clipboard().setImage(img) |
880 QApplication.clipboard().setImage(img) |
881 |
881 |
|
882 @pyqtSlot() |
882 def editPaste(self, pasting=False): |
883 def editPaste(self, pasting=False): |
883 """ |
884 """ |
884 Public slot to paste an image from the clipboard. |
885 Public slot to paste an image from the clipboard. |
885 |
886 |
886 @param pasting flag indicating part two of the paste operation |
887 @param pasting flag indicating part two of the paste operation |