summaryrefslogtreecommitdiffstats
path: root/krita/core/kis_image.h
diff options
context:
space:
mode:
Diffstat (limited to 'krita/core/kis_image.h')
-rw-r--r--krita/core/kis_image.h121
1 files changed, 61 insertions, 60 deletions
diff --git a/krita/core/kis_image.h b/krita/core/kis_image.h
index fccb2fd3..a3917953 100644
--- a/krita/core/kis_image.h
+++ b/krita/core/kis_image.h
@@ -19,10 +19,10 @@
#ifndef KIS_IMAGE_H_
#define KIS_IMAGE_H_
-#include <qobject.h>
-#include <qstring.h>
-#include <qvaluevector.h>
-#include <qmutex.h>
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqvaluevector.h>
+#include <tqmutex.h>
#include <config.h>
@@ -58,11 +58,12 @@ class KisProgressDisplayInterface;
class KisPaintLayer;
class KisPerspectiveGrid;
-class KRITACORE_EXPORT KisImage : public QObject, public KShared {
+class KRITACORE_EXPORT KisImage : public TQObject, public KShared {
Q_OBJECT
+ TQ_OBJECT
public:
- KisImage(KisUndoAdapter * adapter, Q_INT32 width, Q_INT32 height, KisColorSpace * colorSpace, const QString& name);
+ KisImage(KisUndoAdapter * adapter, TQ_INT32 width, TQ_INT32 height, KisColorSpace * colorSpace, const TQString& name);
KisImage(const KisImage& rhs);
virtual ~KisImage();
virtual DCOPObject *dcopObject();
@@ -78,26 +79,26 @@ public:
/// Paint the specified rect onto the painter, adjusting the colors using the
/// given profile. The exposure setting is used if the image has a high dynamic range.
- virtual void renderToPainter(Q_INT32 x1,
- Q_INT32 y1,
- Q_INT32 x2,
- Q_INT32 y2,
- QPainter &painter,
+ virtual void renderToPainter(TQ_INT32 x1,
+ TQ_INT32 y1,
+ TQ_INT32 x2,
+ TQ_INT32 y2,
+ TQPainter &painter,
KisProfile *profile,
PaintFlags paintFlags,
float exposure = 0.0f);
/**
- * Render the projection onto a QImage. In contrast with the above method, the
+ * Render the projection onto a TQImage. In contrast with the above method, the
* selection is not rendered.
*/
- virtual QImage convertToQImage(Q_INT32 x1,
- Q_INT32 y1,
- Q_INT32 x2,
- Q_INT32 y2,
+ virtual TQImage convertToTQImage(TQ_INT32 x1,
+ TQ_INT32 y1,
+ TQ_INT32 x2,
+ TQ_INT32 y2,
KisProfile * profile,
float exposure = 0.0f);
- virtual QImage convertToQImage(const QRect& r, const QSize& fullImageSize, KisProfile *profile, PaintFlags paintFlags, float exposure = 0.0f);
+ virtual TQImage convertToTQImage(const TQRect& r, const TQSize& fullImageSize, KisProfile *profile, PaintFlags paintFlags, float exposure = 0.0f);
KisBackgroundSP background() const;
KisSubstrateSP substrate() const;
@@ -126,17 +127,17 @@ public:
KisColor backgroundColor() const;
void setBackgroundColor(const KisColor & color);
- QString name() const;
- void setName(const QString& name);
+ TQString name() const;
+ void setName(const TQString& name);
- QString description() const;
- void setDescription(const QString& description);
+ TQString description() const;
+ void setDescription(const TQString& description);
- QString nextLayerName() const;
+ TQString nextLayerName() const;
void rollBackLayerName();
KisPerspectiveGrid* perspectiveGrid();
- void createPerspectiveGrid(QPoint topLeft, QPoint topRight, QPoint bottomRight, QPoint bottomLeft);
+ void createPerspectiveGrid(TQPoint topLeft, TQPoint topRight, TQPoint bottomRight, TQPoint bottomLeft);
/**
* Resize the image to the specified width and height. The resize
* method handles the creating on an undo step itself.
@@ -147,7 +148,7 @@ public:
* @param y the y position of the crop on all layer if cropLayers is true
* @param cropLayers if true, all layers are cropped to the new size.
*/
- void resize(Q_INT32 w, Q_INT32 h, Q_INT32 x = 0, Q_INT32 y = 0, bool cropLayers = false);
+ void resize(TQ_INT32 w, TQ_INT32 h, TQ_INT32 x = 0, TQ_INT32 y = 0, bool cropLayers = false);
/**
* Resize the image to the specified width and height. The resize
@@ -156,7 +157,7 @@ public:
* @param rc the rect describing the new width and height of the image
* @param cropLayers if true, all layers are cropped to the new rect
*/
- void resize(const QRect& rc, bool cropLayers = false);
+ void resize(const TQRect& rc, bool cropLayers = false);
void scale(double sx, double sy, KisProgressDisplayInterface *m_progress, KisFilterStrategy *filterStrategy);
void rotate(double radians, KisProgressDisplayInterface *m_progress);
@@ -165,7 +166,7 @@ public:
/**
* Convert the image and all its layers to the dstColorSpace
*/
- void convertTo(KisColorSpace * dstColorSpace, Q_INT32 renderingIntent = INTENT_PERCEPTUAL);
+ void convertTo(KisColorSpace * dstColorSpace, TQ_INT32 renderingIntent = INTENT_PERCEPTUAL);
// Get the profile associated with this image
KisProfile * getProfile() const;
@@ -210,8 +211,8 @@ public:
double yRes();
void setResolution(double xres, double yres);
- Q_INT32 width() const;
- Q_INT32 height() const;
+ TQ_INT32 width() const;
+ TQ_INT32 height() const;
bool empty() const;
@@ -224,16 +225,16 @@ public:
/*
* Returns the colour of the merged image at pixel (x, y).
*/
- KisColor mergedPixel(Q_INT32 x, Q_INT32 y);
+ KisColor mergedPixel(TQ_INT32 x, TQ_INT32 y);
/// Creates a new paint layer with the specified properties, adds it to the image, and returns it.
- KisLayerSP newLayer(const QString& name, Q_UINT8 opacity,
+ KisLayerSP newLayer(const TQString& name, TQ_UINT8 opacity,
const KisCompositeOp& compositeOp = KisCompositeOp(), KisColorSpace * colorstrategy = 0);
/// Get the active painting device. Returns 0 if the active layer does not have a paint device.
KisPaintDeviceSP activeDevice();
- void setLayerProperties(KisLayerSP layer, Q_UINT8 opacity, const KisCompositeOp& compositeOp, const QString& name);
+ void setLayerProperties(KisLayerSP layer, TQ_UINT8 opacity, const KisCompositeOp& compositeOp, const TQString& name);
KisGroupLayerSP rootLayer() const;
KisLayerSP activeLayer() const;
@@ -243,27 +244,27 @@ public:
KisPaintDeviceSP projection();
KisLayerSP activate(KisLayerSP layer);
- KisLayerSP findLayer(const QString& name) const;
+ KisLayerSP findLayer(const TQString& name) const;
KisLayerSP findLayer(int id) const;
/// Move layer to specified position
- bool moveLayer(KisLayerSP layer, KisGroupLayerSP parent, KisLayerSP aboveThis);
+ bool moveLayer(KisLayerSP layer, KisGroupLayerSP tqparent, KisLayerSP aboveThis);
/**
* Add an already existing layer to the image. The layer is put on top
* of the layers in the specified layergroup
* @param layer the layer to be added
- * @param parent the parent layer
+ * @param tqparent the tqparent layer
*/
- bool addLayer(KisLayerSP layer, KisGroupLayerSP parent);
+ bool addLayer(KisLayerSP layer, KisGroupLayerSP tqparent);
/**
* Add already existing layer to image.
*
* @param layer the layer to be added
- * @param parent the parent layer
+ * @param tqparent the tqparent layer
* @param aboveThis in the list with child layers of the specified
- * parent, add this layer above the specified sibling.
+ * tqparent, add this layer above the specified sibling.
* if 0, the layer is put in the lowermost position in
* its group.
* @param notify If true, the image is immediately recomposited, if false,
@@ -271,7 +272,7 @@ public:
*
* returns false if adding the layer didn't work, true if the layer got added
*/
- bool addLayer(KisLayerSP layer, KisGroupLayerSP parent, KisLayerSP aboveThis);
+ bool addLayer(KisLayerSP layer, KisGroupLayerSP tqparent, KisLayerSP aboveThis);
/// Remove layer
bool removeLayer(KisLayerSP layer);
@@ -288,8 +289,8 @@ public:
/// Move layer to bottom slot
bool toBottom(KisLayerSP layer);
- Q_INT32 nlayers() const;
- Q_INT32 nHiddenLayers() const;
+ TQ_INT32 nlayers() const;
+ TQ_INT32 nHiddenLayers() const;
KCommand *raiseLayerCommand(KisLayerSP layer);
KCommand *lowerLayerCommand(KisLayerSP layer);
@@ -308,7 +309,7 @@ public:
*/
void mergeLayer(KisLayerSP l);
- QRect bounds() const;
+ TQRect bounds() const;
/// use if the layers have changed _completely_ (eg. when flattening)
void notifyLayersChanged();
@@ -317,7 +318,7 @@ public:
void notifyImageLoaded();
- void notifyLayerUpdated(KisLayerSP layer, QRect rc);
+ void notifyLayerUpdated(KisLayerSP layer, TQRect rc);
void setColorSpace(KisColorSpace * colorSpace);
void setRootLayer(KisGroupLayerSP rootLayer);
@@ -332,10 +333,10 @@ public:
void addAnnotation(KisAnnotationSP annotation);
/** get the annotation with the given type, can return 0 */
- KisAnnotationSP annotation(QString type);
+ KisAnnotationSP annotation(TQString type);
/** delete the annotation, if the image contains it */
- void removeAnnotation(QString type);
+ void removeAnnotation(TQString type);
/**
* Start of an iteration over the annotations of this image (including the ICC Profile)
@@ -349,26 +350,26 @@ signals:
void sigActiveSelectionChanged(KisImageSP image);
void sigSelectionChanged(KisImageSP image);
- void sigSelectionChanged(KisImageSP image, const QRect& rect);
+ void sigSelectionChanged(KisImageSP image, const TQRect& rect);
/// Emitted after a different layer is made active.
void sigLayerActivated(KisLayerSP layer);
- /// Emitted after a layer is added: you can find out where by asking it for its parent(), et al.
+ /// Emitted after a layer is added: you can find out where by asking it for its tqparent(), et al.
void sigLayerAdded(KisLayerSP layer);
/** Emitted after a layer is removed.
It's no longer in the image, but still exists, so @p layer is valid.
@param layer the removed layer
- @param parent the parent of the layer, before it was removed
+ @param tqparent the tqparent of the layer, before it was removed
@param wasAboveThis the layer it was above, before it was removed.
*/
void sigLayerRemoved(KisLayerSP layer, KisGroupLayerSP wasParent, KisLayerSP wasAboveThis);
- /** Emitted after a layer is moved to a different position under its parent layer, or its parent changes.
+ /** Emitted after a layer is moved to a different position under its tqparent layer, or its tqparent changes.
- @param previousParent the parent of the layer, before it was moved
+ @param previousParent the tqparent of the layer, before it was moved
@param wasAboveThis the layer it was above, before it was moved.
*/
void sigLayerMoved(KisLayerSP layer, KisGroupLayerSP previousParent, KisLayerSP wasAboveThis);
@@ -388,7 +389,7 @@ signals:
*
* @param rc The rect that has been recomposited.
*/
- void sigImageUpdated(QRect rc);
+ void sigImageUpdated(TQRect rc);
/**
* Emitted whenever a layer is modified.
@@ -396,38 +397,38 @@ signals:
* @param layer The layer that has been modified.
* @param rc The rectangle that has been modified.
*/
- void sigLayerUpdated(KisLayerSP layer, QRect rc);
+ void sigLayerUpdated(KisLayerSP layer, TQRect rc);
/**
* Emitted whenever the image has been modified, so that it doesn't match with the version saved on disk.
*/
void sigImageModified();
- void sigSizeChanged(Q_INT32 w, Q_INT32 h);
+ void sigSizeChanged(TQ_INT32 w, TQ_INT32 h);
void sigProfileChanged(KisProfile * profile);
void sigColorSpaceChanged(KisColorSpace* cs);
- /// Emitted when any layer's mask info got updated (or when the current layer changes)
+ /// Emitted when any layer's tqmask info got updated (or when the current layer changes)
void sigMaskInfoChanged();
public slots:
void slotSelectionChanged();
- void slotSelectionChanged(const QRect& r);
+ void slotSelectionChanged(const TQRect& r);
private:
KisImage& operator=(const KisImage& rhs);
- void init(KisUndoAdapter * adapter, Q_INT32 width, Q_INT32 height, KisColorSpace * colorSpace, const QString& name);
+ void init(KisUndoAdapter * adapter, TQ_INT32 width, TQ_INT32 height, KisColorSpace * colorSpace, const TQString& name);
void emitSizeChanged();
private:
KURL m_uri;
- QString m_name;
- QString m_description;
+ TQString m_name;
+ TQString m_description;
- Q_INT32 m_width;
- Q_INT32 m_height;
+ TQ_INT32 m_width;
+ TQ_INT32 m_height;
double m_xres;
double m_yres;
@@ -437,7 +438,7 @@ private:
KisColorSpace * m_colorSpace;
bool m_dirty;
- QRect m_dirtyRect;
+ TQRect m_dirtyRect;
KisBackgroundSP m_bkg;