#include <image-dialog.h>
Inheritance diagram for ImagePicker:
Public Slots | |
virtual void | pointSelected (int x, int y, bool right) |
Public Member Functions | |
ImagePicker (ImageValue *i) | |
virtual Value * | value ()=0 |
Protected Member Functions | |
virtual void | nextPoint (PointValue point, bool right)=0 |
Private Attributes | |
int | size_x |
int | size_y |
ImageValue * | image |
Definition at line 19 of file image-dialog.h.
|
Definition at line 17 of file image-dialog.cpp. References ImageValue::getQImage(), ImageValue::height_direct(), image, pointSelected(), size_x, size_y, and ImageValue::width_direct(). 00017 : QDialog(NULL,"image-picker",TRUE) 00018 { 00019 image = i; 00020 QGridLayout *tot = new QGridLayout( this, 1, 1, 11, 6, "layout"); 00021 // we want to scroll around if necessary 00022 QScrollView* sv = new QScrollView(this); 00023 tot->addWidget(sv,0,0); 00024 QVBox* big_box = new QVBox(sv->viewport()); 00025 sv->addChild(big_box); 00026 ImageLabel* child1 = new ImageLabel(big_box); 00027 const QPixmap pm(i->getQImage(false)); 00028 size_x = image->width_direct(); 00029 size_y = image->height_direct(); 00030 child1->setPixmap(pm); 00031 connect(child1,SIGNAL(pointSelected(int,int,bool)),this, SLOT(pointSelected(int,int,bool))); 00032 }
|
|
Implemented in BoxPicker, LinePicker, and PointPicker. Referenced by pointSelected(). |
|
Definition at line 34 of file image-dialog.cpp. References ImageValue::dcsToOcs(), image, nextPoint(), size_x, and size_y. Referenced by ImagePicker(). 00035 { 00036 if (x>=size_x || 00037 x<0 || 00038 y>=size_y || 00039 y <0) 00040 return; 00041 PointValue point = image->dcsToOcs(DirectPoint(x,y)); 00042 nextPoint(point,right); 00043 }
|
|
Implemented in BoxPicker, LinePicker, and PointPicker. |
|
Definition at line 25 of file image-dialog.h. Referenced by ImagePicker(), and pointSelected(). |
|
Definition at line 21 of file image-dialog.h. Referenced by ImagePicker(), and pointSelected(). |
|
Definition at line 24 of file image-dialog.h. Referenced by ImagePicker(), and pointSelected(). |