Logo Search packages:      
Sourcecode: darkroom version File versions

KCurve Class Reference

#include <kcurve.h>

List of all members.

Detailed Description

KCurve is a widget that shows a single curve that can be edited by the user. The user can grab the curve and move it; this creates a new control point. Control points can be deleted by selecting a point and pressing the delete key.

(From: http://techbase.kde.org/Projects/Widgets_and_Classes#KCurve) KCurve allows editing of spline based y=f(x) curves. Handy for cases where you want the user to control such things as tablet pressure response, color transformations, acceleration by time, aeroplane lift by angle of attack.

Definition at line 45 of file kcurve.h.


void modified (void)

Public Member Functions

QList< QPointF > getCurve ()
double getCurveValue (double x)
 KCurve (QWidget *parent=0, Qt::WFlags f=0)
void reset (void)
void setCurve (QList< QPointF > inlist)
void setCurveGuide (const QColor &color)
void setPixmap (const QPixmap &pix)

Static Public Member Functions

static double getCurveValue (const QList< QPointF > &curve, double x)

Protected Member Functions

void keyPressEvent (QKeyEvent *)
void leaveEvent (QEvent *)
void mouseMoveEvent (QMouseEvent *e)
void mousePressEvent (QMouseEvent *e)
void mouseReleaseEvent (QMouseEvent *e)
void paintEvent (QPaintEvent *)

Private Member Functions

int nearestPointInRange (QPointF pt) const

Private Attributes

QColor m_colorGuide
QPointF m_draggedawaypoint
int m_draggedawaypointindex
bool m_dragging
int m_grab_point_index
double m_grabOffsetX
double m_grabOffsetY
double m_grabOriginalX
double m_grabOriginalY
bool m_guideVisible
QPixmap m_pix
QList< QPointF > m_points
bool m_readOnlyMode

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

Generated by  Doxygen 1.6.0   Back to index