#include <ImageView.h>

Public Slots

virtual void fitImage ()
 
virtual void oneToOneImage ()
 
- Public Slots inherited from Gui::MDIView
virtual void print (QPrinter *printer)
 
virtual void setOverrideCursor (const QCursor &)
 
virtual void restoreOverrideCursor ()
 

Signals

void closeEventIgnored ()
 
- Signals inherited from Gui::MDIView
void message (const QString &, int)
 

Public Member Functions

virtual void clearColorMap ()
 
virtual void clearImage ()
 
virtual int createColorMap (int numEntriesReq=0, bool Initialise=true)
 
virtual int createImageCopy (void *pSrcPixelData, unsigned long width, unsigned long height, int format, unsigned short numSigBitsPerSample, int displayMode=IV_DISPLAY_RESET)
 
virtual void enableFitImageAction (bool Enable)
 
virtual void enableMouseEvents (bool Enable)
 
virtual void enableOneToOneAction (bool Enable)
 
virtual void enableStatusBar (bool Enable)
 
virtual void enableToolBar (bool Enable)
 
const char * getName (void) const
 returns the name of the view (important for messages) More...
 
virtual int getNumColorMapEntries () const
 
virtual void ignoreCloseEvent (bool ignoreCloseEvent)
 
 ImageView (QWidget *parent)
 
bool onHasMsg (const char *) const
 Message handler test. More...
 
bool onMsg (const char *, const char **)
 Message handler. More...
 
void onUpdate (void)
 get called when the document is updated More...
 
virtual int pointImageTo (void *pSrcPixelData, unsigned long width, unsigned long height, int format, unsigned short numSigBitsPerSample, bool takeOwnership, int displayMode=IV_DISPLAY_RESET)
 
virtual int setColorMapAlphaValue (int index, float value)
 
virtual int setColorMapBlueValue (int index, float value)
 
virtual int setColorMapGreenValue (int index, float value)
 
virtual int setColorMapRedValue (int index, float value)
 
virtual int setColorMapRGBAValue (int index, float red, float green, float blue, float alpha=1.0)
 
virtual ~ImageView ()
 
- Public Member Functions inherited from Gui::MDIView
virtual bool canClose (void)
 overwrite when checking on close state More...
 
virtual void deleteSelf ()
 delete itself More...
 
virtual PyObjectgetPyObject ()
 This method returns the Python wrapper for a C++ object. More...
 
 MDIView (Gui::Document *pcDocument, QWidget *parent, Qt::WindowFlags wflags=Qt::WindowFlags())
 View constructor Attach the view to the given document. More...
 
virtual void onRelabel (Gui::Document *pDoc)
 get called when the document is updated More...
 
virtual void viewAll ()
 
 ~MDIView ()
 View destructor Detach the view from the document, if attached. More...
 
virtual void print ()
 Print content of view. More...
 
virtual void printPdf ()
 Print to PDF file. More...
 
virtual void printPreview ()
 Show a preview dialog. More...
 
QSize minimumSizeHint () const
 
virtual void setCurrentViewMode (ViewMode mode)
 If b is set to FullScreen the MDI view is displayed in full screen mode, if b is set to TopLevel then it is displayed as an own top-level window, otherwise (Normal) as tabbed window. More...
 
ViewMode currentViewMode () const
 
template<typename _T >
_T getActiveObject (const char *name, App::DocumentObject **parent=0, std::string *subname=0) const
 access getter for the active object list More...
 
void setActiveObject (App::DocumentObject *o, const char *n, const char *subname=0)
 
bool hasActiveObject (const char *n) const
 
bool isActiveObject (App::DocumentObject *o, const char *n, const char *subname=0) const
 
virtual bool containsViewProvider (const ViewProvider *) const
 containsViewProvider Checks if the given view provider is part of this view. The default implementation returns false. More...
 
- Public Member Functions inherited from Gui::BaseView
 BaseView (Gui::Document *pcDocument=0)
 View constructor Attach the view to the given document. More...
 
virtual ~BaseView ()
 View destructor Detach the view from the document, if attached! More...
 
void setDocument (Gui::Document *pcDocument)
 sets the view to another document (called by Application) More...
 
void onClose (void)
 is sent from the document in order to close the document More...
 
Gui::DocumentgetGuiDocument () const
 returns the document the view is attached to More...
 
App::DocumentgetAppDocument () const
 returns the document the view is attached to More...
 
bool isPassive (void) const
 indicates if the view is in passive mode More...
 
virtual void onRename (Gui::Document *)
 get called when the document is renamed (change of its internal name) More...
 
- Public Member Functions inherited from Base::BaseClass
 BaseClass ()
 Construction. More...
 
virtual Type getTypeId (void) const
 
bool isDerivedFrom (const Type type) const
 
virtual void setPyObject (PyObject *)
 
virtual ~BaseClass ()
 Destruction. More...
 

Protected Types

enum  {
  nothing = 0 , panning , zooming , selection ,
  addselection
}
 

Protected Slots

virtual void drawGraphics ()
 
- Protected Slots inherited from Gui::MDIView
virtual void windowStateChanged (MDIView *)
 This method gets called from the main window this view is attached to whenever the window state of the active view changes. More...
 

Protected Member Functions

virtual void addSelect (int currX, int currY)
 
virtual void closeEvent (QCloseEvent *e)
 
virtual void createActions ()
 
virtual QString createStatusBarText ()
 
virtual QSize minimumSizeHint () const
 
virtual void mouseDoubleClickEvent (QMouseEvent *cEvent)
 
virtual void mouseMoveEvent (QMouseEvent *cEvent)
 
virtual void mousePressEvent (QMouseEvent *cEvent)
 
virtual void mouseReleaseEvent (QMouseEvent *cEvent)
 
virtual void select (int currX, int currY)
 
virtual void showEvent (QShowEvent *e)
 
virtual void showOriginalColors ()
 
virtual void startDrag ()
 
virtual void updateStatusBar ()
 
virtual void wheelEvent (QWheelEvent *cEvent)
 
virtual void zoom (int prevX, int prevY, int currX, int currY)
 
- Protected Member Functions inherited from Gui::MDIView
void closeEvent (QCloseEvent *e)
 
void changeEvent (QEvent *e)
 

Protected Attributes

int dragStartWCx
 
int dragStartWCy
 
- Protected Attributes inherited from Gui::MDIView
PyObjectpythonObject
 
- Protected Attributes inherited from Gui::BaseView
bool bIsDetached
 
bool bIsPassive
 

Additional Inherited Members

- Public Types inherited from Gui::MDIView
enum  ViewMode { Child , TopLevel , FullScreen }
 MDI view mode enum. More...
 
- Static Public Member Functions inherited from Base::BaseClass
static void * create (void)
 
static Type getClassTypeId (void)
 
static void init (void)
 
- Static Protected Member Functions inherited from Base::BaseClass
static void initSubclass (Base::Type &toInit, const char *ClassName, const char *ParentName, Type::instantiationMethod method=nullptr)
 

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
protected
Enumerator
nothing 
panning 
zooming 
selection 
addselection 

Constructor & Destructor Documentation

◆ ImageView()

◆ ~ImageView()

ImageView::~ImageView ( )
virtual

Member Function Documentation

◆ addSelect()

void ImageView::addSelect ( int  currX,
int  currY 
)
protectedvirtual

Referenced by mouseReleaseEvent().

◆ clearColorMap()

void ImageView::clearColorMap ( )
virtual

◆ clearImage()

void ImageView::clearImage ( )
virtual

References updateStatusBar().

◆ closeEvent()

void ImageView::closeEvent ( QCloseEvent *  e)
protectedvirtual

◆ closeEventIgnored

void ImageGui::ImageView::closeEventIgnored ( )
signal

Referenced by closeEvent().

◆ createActions()

void ImageView::createActions ( )
protectedvirtual

◆ createColorMap()

int ImageView::createColorMap ( int  numEntriesReq = 0,
bool  Initialise = true 
)
virtual

◆ createImageCopy()

int ImageView::createImageCopy ( void *  pSrcPixelData,
unsigned long  width,
unsigned long  height,
int  format,
unsigned short  numSigBitsPerSample,
int  displayMode = IV_DISPLAY_RESET 
)
virtual

◆ createStatusBarText()

QString ImageView::createStatusBarText ( )
protectedvirtual

Referenced by updateStatusBar().

◆ drawGraphics

void ImageView::drawGraphics ( )
protectedvirtualslot

Referenced by ImageView().

◆ enableFitImageAction()

void ImageView::enableFitImageAction ( bool  Enable)
virtual

◆ enableMouseEvents()

void ImageView::enableMouseEvents ( bool  Enable)
virtual

◆ enableOneToOneAction()

void ImageView::enableOneToOneAction ( bool  Enable)
virtual

◆ enableStatusBar()

void ImageView::enableStatusBar ( bool  Enable)
virtual

Referenced by ImageView().

◆ enableToolBar()

void ImageView::enableToolBar ( bool  Enable)
virtual

◆ fitImage

void ImageView::fitImage ( )
virtualslot

Referenced by createActions().

◆ getName()

const char* ImageGui::ImageView::getName ( void  ) const
virtual

returns the name of the view (important for messages)

Reimplemented from Gui::BaseView.

◆ getNumColorMapEntries()

int ImageView::getNumColorMapEntries ( ) const
virtual

◆ ignoreCloseEvent()

virtual void ImageGui::ImageView::ignoreCloseEvent ( bool  ignoreCloseEvent)
virtual

References ignoreCloseEvent().

Referenced by ignoreCloseEvent().

◆ minimumSizeHint()

QSize ImageView::minimumSizeHint ( void  ) const
protectedvirtual

◆ mouseDoubleClickEvent()

void ImageView::mouseDoubleClickEvent ( QMouseEvent *  cEvent)
protectedvirtual

References updateStatusBar().

◆ mouseMoveEvent()

void ImageView::mouseMoveEvent ( QMouseEvent *  cEvent)
protectedvirtual

◆ mousePressEvent()

void ImageView::mousePressEvent ( QMouseEvent *  cEvent)
protectedvirtual

◆ mouseReleaseEvent()

void ImageView::mouseReleaseEvent ( QMouseEvent *  cEvent)
protectedvirtual

◆ oneToOneImage

void ImageView::oneToOneImage ( )
virtualslot

References updateStatusBar().

Referenced by createActions().

◆ onHasMsg()

bool ImageGui::ImageView::onHasMsg ( const char *  pMsg) const
virtual

Message handler test.

Reimplemented from Gui::MDIView.

◆ onMsg()

bool ImageGui::ImageView::onMsg ( const char *  pMsg,
const char **  ppReturn 
)
virtual

Message handler.

receive a message

Reimplemented from Gui::MDIView.

◆ onUpdate()

void ImageGui::ImageView::onUpdate ( void  )
virtual

get called when the document is updated

Reimplemented from Gui::BaseView.

Referenced by shipAreasCurve.TaskPanel.TaskPanel::initValues(), and shipAreasCurve.TaskPanel.TaskPanel::onData().

◆ pointImageTo()

int ImageView::pointImageTo ( void *  pSrcPixelData,
unsigned long  width,
unsigned long  height,
int  format,
unsigned short  numSigBitsPerSample,
bool  takeOwnership,
int  displayMode = IV_DISPLAY_RESET 
)
virtual

◆ select()

void ImageView::select ( int  currX,
int  currY 
)
protectedvirtual

Referenced by mouseReleaseEvent().

◆ setColorMapAlphaValue()

int ImageView::setColorMapAlphaValue ( int  index,
float  value 
)
virtual

◆ setColorMapBlueValue()

int ImageView::setColorMapBlueValue ( int  index,
float  value 
)
virtual

◆ setColorMapGreenValue()

int ImageView::setColorMapGreenValue ( int  index,
float  value 
)
virtual

◆ setColorMapRedValue()

int ImageView::setColorMapRedValue ( int  index,
float  value 
)
virtual

◆ setColorMapRGBAValue()

int ImageView::setColorMapRGBAValue ( int  index,
float  red,
float  green,
float  blue,
float  alpha = 1.0 
)
virtual

◆ showEvent()

void ImageView::showEvent ( QShowEvent *  e)
protectedvirtual

◆ showOriginalColors()

void ImageView::showOriginalColors ( )
protectedvirtual

Referenced by createImageCopy(), and pointImageTo().

◆ startDrag()

void ImageView::startDrag ( )
protectedvirtual

References dragStartWCx, and dragStartWCy.

Referenced by mousePressEvent().

◆ updateStatusBar()

void ImageView::updateStatusBar ( )
protectedvirtual

◆ wheelEvent()

void ImageView::wheelEvent ( QWheelEvent *  cEvent)
protectedvirtual

References updateStatusBar().

◆ zoom()

void ImageView::zoom ( int  prevX,
int  prevY,
int  currX,
int  currY 
)
protectedvirtual

Referenced by mouseMoveEvent().

Member Data Documentation

◆ dragStartWCx

int ImageGui::ImageView::dragStartWCx
protected

Referenced by mouseMoveEvent(), and startDrag().

◆ dragStartWCy

int ImageGui::ImageView::dragStartWCy
protected

Referenced by mouseMoveEvent(), and startDrag().


The documentation for this class was generated from the following files:
  • Sources/FreeCAD/src/Mod/Image/Gui/ImageView.h
  • Sources/FreeCAD/src/Mod/Image/Gui/ImageView.cpp