digiKam
Digikam::ImageGuideWidget Class Reference
+ Inheritance diagram for Digikam::ImageGuideWidget:

Public Types

enum  ColorPointSrc { OriginalImage = 0 , PreviewImage , TargetPreviewImage }
 
enum  GuideToolMode { HVGuideMode = 0 , PickColorMode }
 

Public Slots

void slotChangeGuideColor (const QColor &color)
 
void slotChangeGuideSize (int size)
 
void slotPreviewModeChanged (int mode)
 

Signals

void signalResized ()
 
void spotPositionChangedFromOriginal (const Digikam::DColor &color, const QPoint &position)
 
void spotPositionChangedFromTarget (const Digikam::DColor &color, const QPoint &position)
 

Public Member Functions

void exposureSettingsChanged ()
 
QImage getMask () const
 
DColor getSpotColor (int getColorFrom) const
 
QPoint getSpotPosition () const
 
void ICCSettingsChanged ()
 
 ImageGuideWidget (QWidget *const parent=nullptr, bool spotVisible=true, int guideMode=PickColorMode, const QColor &guideColor=Qt::red, int guideSize=1, bool blink=false, ImageIface::PreviewType type=ImageIface::FullImage)
 
ImageIfaceimageIface () const
 
int previewMode () const
 
void resetPoints ()
 
void resetSpotPosition ()
 
void setBackgroundColor (const QColor &)
 
void setEraseMode (bool erase)
 
void setMaskCursor ()
 
void setMaskEnabled (bool enabled)
 
void setMaskPenSize (int size)
 
void setPaintColor (const QColor &color)
 
void setPoints (const QPolygon &p, bool drawLine=false)
 
void setSpotVisible (bool spotVisible, bool blink=false)
 
void setSpotVisibleNoUpdate (bool spotVisible)
 
void updatePreview ()
 
 ~ImageGuideWidget () override
 

Protected Member Functions

void drawLineTo (const QPoint &endPoint)
 
void drawLineTo (int width, bool erase, const QColor &color, const QPoint &start, const QPoint &end)
 
void drawText (QPainter *const p, const QPoint &corner, const QString &text)
 
void enterEvent (QEvent *) override
 
void leaveEvent (QEvent *) override
 
void mouseMoveEvent (QMouseEvent *) override
 
void mousePressEvent (QMouseEvent *) override
 
void mouseReleaseEvent (QMouseEvent *) override
 
void paintEvent (QPaintEvent *) override
 
void resizeEvent (QResizeEvent *) override
 
void setSpotPosition (const QPoint &point)
 
void timerEvent (QTimerEvent *) override
 
QPoint translateItemPosition (const QPoint &point, bool src) const
 
QPoint translatePointPosition (const QPoint &point) const
 
void updateMaskCursor ()
 
void updatePixmap ()
 
void updateSpotPosition (int x, int y)
 

Member Enumeration Documentation

◆ ColorPointSrc

Enumerator
OriginalImage 
PreviewImage 
TargetPreviewImage 

◆ GuideToolMode

Enumerator
HVGuideMode 
PickColorMode 

Constructor & Destructor Documentation

◆ ImageGuideWidget()

Digikam::ImageGuideWidget::ImageGuideWidget ( QWidget *const  parent = nullptr,
bool  spotVisible = true,
int  guideMode = PickColorMode,
const QColor &  guideColor = Qt::red,
int  guideSize = 1,
bool  blink = false,
ImageIface::PreviewType  type = ImageIface::FullImage 
)
explicit

◆ ~ImageGuideWidget()

Digikam::ImageGuideWidget::~ImageGuideWidget ( )
override

Member Function Documentation

◆ drawLineTo() [1/2]

void Digikam::ImageGuideWidget::drawLineTo ( const QPoint &  endPoint)
protected

Referenced by mouseMoveEvent().

◆ drawLineTo() [2/2]

void Digikam::ImageGuideWidget::drawLineTo ( int  width,
bool  erase,
const QColor &  color,
const QPoint &  start,
const QPoint &  end 
)
protected

◆ drawText()

void Digikam::ImageGuideWidget::drawText ( QPainter *const  p,
const QPoint &  corner,
const QString &  text 
)
protected

Referenced by paintEvent(), and updatePixmap().

◆ enterEvent()

void Digikam::ImageGuideWidget::enterEvent ( QEvent *  event)
overrideprotected

◆ exposureSettingsChanged()

void Digikam::ImageGuideWidget::exposureSettingsChanged ( )

◆ getMask()

QImage Digikam::ImageGuideWidget::getMask ( ) const

◆ getSpotColor()

DColor Digikam::ImageGuideWidget::getSpotColor ( int  getColorFrom) const

◆ getSpotPosition()

QPoint Digikam::ImageGuideWidget::getSpotPosition ( ) const

Referenced by getSpotColor().

◆ ICCSettingsChanged()

void Digikam::ImageGuideWidget::ICCSettingsChanged ( )

◆ imageIface()

ImageIface * Digikam::ImageGuideWidget::imageIface ( ) const

◆ leaveEvent()

void Digikam::ImageGuideWidget::leaveEvent ( QEvent *  )
overrideprotected

◆ mouseMoveEvent()

void Digikam::ImageGuideWidget::mouseMoveEvent ( QMouseEvent *  e)
overrideprotected

References drawLineTo(), and updatePreview().

◆ mousePressEvent()

void Digikam::ImageGuideWidget::mousePressEvent ( QMouseEvent *  e)
overrideprotected

References updatePreview().

◆ mouseReleaseEvent()

◆ paintEvent()

◆ previewMode()

int Digikam::ImageGuideWidget::previewMode ( ) const

◆ resetPoints()

void Digikam::ImageGuideWidget::resetPoints ( )

◆ resetSpotPosition()

void Digikam::ImageGuideWidget::resetSpotPosition ( )

References updatePreview().

Referenced by ImageGuideWidget().

◆ resizeEvent()

void Digikam::ImageGuideWidget::resizeEvent ( QResizeEvent *  e)
overrideprotected

References signalResized(), and updatePixmap().

◆ setBackgroundColor()

void Digikam::ImageGuideWidget::setBackgroundColor ( const QColor &  bg)

References updatePreview().

◆ setEraseMode()

void Digikam::ImageGuideWidget::setEraseMode ( bool  erase)

◆ setMaskCursor()

void Digikam::ImageGuideWidget::setMaskCursor ( )

◆ setMaskEnabled()

void Digikam::ImageGuideWidget::setMaskEnabled ( bool  enabled)

References updatePreview().

◆ setMaskPenSize()

void Digikam::ImageGuideWidget::setMaskPenSize ( int  size)

References updateMaskCursor().

◆ setPaintColor()

void Digikam::ImageGuideWidget::setPaintColor ( const QColor &  color)

◆ setPoints()

void Digikam::ImageGuideWidget::setPoints ( const QPolygon &  p,
bool  drawLine = false 
)

References updatePreview().

◆ setSpotPosition()

void Digikam::ImageGuideWidget::setSpotPosition ( const QPoint &  point)
protected

References updatePreview().

◆ setSpotVisible()

void Digikam::ImageGuideWidget::setSpotVisible ( bool  spotVisible,
bool  blink = false 
)

References updatePreview().

Referenced by ImageGuideWidget().

◆ setSpotVisibleNoUpdate()

void Digikam::ImageGuideWidget::setSpotVisibleNoUpdate ( bool  spotVisible)

◆ signalResized

void Digikam::ImageGuideWidget::signalResized ( )
signal

Referenced by resizeEvent().

◆ slotChangeGuideColor

void Digikam::ImageGuideWidget::slotChangeGuideColor ( const QColor &  color)
slot

References updatePreview().

◆ slotChangeGuideSize

void Digikam::ImageGuideWidget::slotChangeGuideSize ( int  size)
slot

References updatePreview().

◆ slotPreviewModeChanged

void Digikam::ImageGuideWidget::slotPreviewModeChanged ( int  mode)
slot

◆ spotPositionChangedFromOriginal

void Digikam::ImageGuideWidget::spotPositionChangedFromOriginal ( const Digikam::DColor color,
const QPoint &  position 
)
signal

Referenced by mouseReleaseEvent().

◆ spotPositionChangedFromTarget

void Digikam::ImageGuideWidget::spotPositionChangedFromTarget ( const Digikam::DColor color,
const QPoint &  position 
)
signal

Referenced by mouseReleaseEvent().

◆ timerEvent()

void Digikam::ImageGuideWidget::timerEvent ( QTimerEvent *  e)
overrideprotected

References updatePreview().

◆ translateItemPosition()

QPoint Digikam::ImageGuideWidget::translateItemPosition ( const QPoint &  point,
bool  src 
) const
protected

◆ translatePointPosition()

QPoint Digikam::ImageGuideWidget::translatePointPosition ( const QPoint &  point) const
protected

Referenced by updatePixmap().

◆ updateMaskCursor()

void Digikam::ImageGuideWidget::updateMaskCursor ( )
protected

Referenced by setMaskCursor(), and setMaskPenSize().

◆ updatePixmap()

◆ updatePreview()

◆ updateSpotPosition()

void Digikam::ImageGuideWidget::updateSpotPosition ( int  x,
int  y 
)
protected

References updatePreview().


The documentation for this class was generated from the following files: