KDE PIM / Developers / API Docs / libkdepim

KPIM::KPixmapRegionSelectorDialog Class Reference

A dialog that uses a KPixmapRegionSelectorWidget to allow the user to select a region of an image. More...

#include <kpixmapregionselectordialog.h>

Inherits KDialogBase.

List of all members.

Public Member Functions

Static Public Member Functions

Protected Attributes


Detailed Description

A dialog that uses a KPixmapRegionSelectorWidget to allow the user to select a region of an image.

If you want to use special features like forcing the selected area to have a fixed aspect ratio, you can use

See also:
pixmapRegionSelectorWidget() to get the pointer to the pixmapRegionSelectorWidget object and set the desired options there.
There are some convenience methods that allow to easily show a dialog for the user to select a region of an image, and just care about the selected image.

Author:
Antonio Larrosa <larrosa@kde.org>
Since:
3.4


Constructor & Destructor Documentation

KPixmapRegionSelectorDialog::KPixmapRegionSelectorDialog QWidget *  parent = 0L,
const char *  name = 0L,
bool  modal = false
 

The constructor of an empty KPixmapRegionSelectorDialog, you have to call later the setPixmap method of the KPixmapRegionSelectorWidget widget of the new object.

KPixmapRegionSelectorDialog::~KPixmapRegionSelectorDialog  ) 
 

The destructor of the dialog.


Member Function Documentation

KPIM::KPixmapRegionSelectorWidget* KPIM::KPixmapRegionSelectorDialog::pixmapRegionSelectorWidget  )  const [inline]
 

Returns:
the KPixmapRegionSelectorWidget widget so that additional parameters can be set by using it.

QRect KPixmapRegionSelectorDialog::getSelectedRegion const QPixmap &  pixmap,
QWidget *  parent = 0L
[static]
 

Creates a modal dialog, lets the user to select a region of the pixmap and returns when the dialog is closed.

Returns:
the selected rectangle, or an invalid rectangle if the user pressed the Cancel button.

QRect KPixmapRegionSelectorDialog::getSelectedRegion const QPixmap &  pixmap,
int  aspectRatioWidth,
int  aspectRatioHeight,
QWidget *  parent = 0L
[static]
 

Creates a modal dialog, lets the user to select a region of the pixmap with the same aspect ratio than aspectRatioWidth x aspectRatioHeight and returns when the dialog is closed.

Returns:
the selected rectangle, or an invalid rectangle if the user pressed the Cancel button.

QImage KPixmapRegionSelectorDialog::getSelectedImage const QPixmap &  pixmap,
QWidget *  parent = 0L
[static]
 

Creates a modal dialog, lets the user to select a region of the pixmap and returns when the dialog is closed.

Returns:
the selected image, or an invalid image if the user pressed the Cancel button.

QImage KPixmapRegionSelectorDialog::getSelectedImage const QPixmap &  pixmap,
int  aspectRatioWidth,
int  aspectRatioHeight,
QWidget *  parent = 0L
[static]
 

Creates a modal dialog, lets the user to select a region of the pixmap with the same aspect ratio than aspectRatioWidth x aspectRatioHeight and returns when the dialog is closed.

Returns:
the selected image, or an invalid image if the user pressed the Cancel button.

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