OpendTect  6.6
uihistogramsel.h
Go to the documentation of this file.
1 #pragma once
2 
3 /*+
4 ________________________________________________________________________
5 
6  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
7  Author: Raman Singh
8  Date: May 2018
9 ________________________________________________________________________
10 
11 -*/
12 
13 #include "uitoolsmod.h"
14 #include "uigroup.h"
15 #include "uihistogramdisplay.h"
16 
17 
18 mExpClass(uiTools) uiHistogramSel : public uiGroup
19 {
20 public:
23  int an_id=0);
25 
26  int ID() const { return id_; }
27  void setID( int id ) { id_ = id; }
28 
29 
30  enum SliderTextPolicy { Always, OnMove, Never };
31 
34 
35  void setEmpty();
37  int version);
38  void setData(const Array2D<float>*);
39  void setData(const float*,int sz);
40  void setMarkValue(float,bool forx);
41 
42  const Interval<float>& getDataRange() const { return datarg_; }
44  const Interval<float>& getSelRange() const { return cliprg_; }
46 
47  uiHistogramDisplay& getDisplay() { return *histogramdisp_; }
48 
50 
51 protected:
52 
53  int id_;
57 
62 
65  int startpix_;
66  int stoppix_;
67 
68  bool mousedown_;
69 
70  virtual void drawAgain();
71  virtual void drawLines();
72  virtual void drawText();
73  virtual void drawPixmaps() {}
74  virtual void useClipRange() {}
75  virtual void makeSymmetricalIfNeeded(bool) {}
76 
77  void init();
78  bool changeLinePos(bool pressedonly=false);
79 
83 
86 };
87 
uiHistogramSel::minvaltext_
uiTextItem * minvaltext_
Definition: uihistogramsel.h:60
DataPack::id
ID id() const
Definition: datapack.h:45
uiLineItem
Definition: uigraphicsitemimpl.h:110
uiHistogramSel::maxvaltext_
uiTextItem * maxvaltext_
Definition: uihistogramsel.h:61
uiHistogramSel::uiHistogramSel
uiHistogramSel(uiParent *, const uiHistogramDisplay::Setup &, int an_id=0)
uiHistogramSel::setEmpty
void setEmpty()
uiHistogramSel::histogramResized
void histogramResized(CallBacker *)
mExpClass
#define mExpClass(module)
Definition: commondefs.h:177
uiHistogramSel::getDataRange
const Interval< float > & getDataRange() const
Definition: uihistogramsel.h:42
uiHistogramSel::getDisplay
uiHistogramDisplay & getDisplay()
Definition: uihistogramsel.h:47
uihistogramdisplay.h
DataPackMgr::ID
int ID
Each Mgr has its own ID.
Definition: datapack.h:139
uiAxisHandler
Handles an axis on a plot.
Definition: uiaxishandler.h:51
CallBacker
Inherit from this class to be able to send and/or receive CallBacks.
Definition: callback.h:185
uiHistogramSel::mousedown_
bool mousedown_
Definition: uihistogramsel.h:68
uiHistogramSel::stoppix_
int stoppix_
Definition: uihistogramsel.h:66
uiHistogramSel::SliderTextPolicy
SliderTextPolicy
Definition: uihistogramsel.h:30
sKey::Setup
FixedString Setup()
Definition: keystrs.h:139
uiHistogramSel::makeSymmetricalIfNeeded
virtual void makeSymmetricalIfNeeded(bool)
Definition: uihistogramsel.h:75
uiHistogramSel::mouseMoved
void mouseMoved(CallBacker *)
uiHistogramSel::useClipRange
virtual void useClipRange()
Definition: uihistogramsel.h:74
uigroup.h
uiHistogramSel::setDataPackID
bool setDataPackID(DataPack::ID, DataPackMgr::ID, int version)
uiHistogramSel::datarg_
Interval< float > datarg_
Definition: uihistogramsel.h:63
uiHistogramSel::setData
void setData(const Array2D< float > *)
uiHistogramSel::sliderTextPolicy
SliderTextPolicy sliderTextPolicy() const
uiHistogramSel::xax_
uiAxisHandler * xax_
Definition: uihistogramsel.h:56
uiHistogramSel::setID
void setID(int id)
Definition: uihistogramsel.h:27
uiGroup
Definition: uigroup.h:54
uiHistogramSel::setSelRange
void setSelRange(const Interval< float > &)
uiHistogramDisplay
Definition: uihistogramdisplay.h:26
uiHistogramSel::setSliderTextPolicy
void setSliderTextPolicy(SliderTextPolicy)
Notifier< uiHistogramSel >
uiHistogramSel::setMarkValue
void setMarkValue(float, bool forx)
uiHistogramSel::~uiHistogramSel
~uiHistogramSel()
uiHistogramSel::histogramdisp_
uiHistogramDisplay * histogramdisp_
Definition: uihistogramsel.h:55
uiHistogramSel::getSelRange
const Interval< float > & getSelRange() const
Definition: uihistogramsel.h:44
DataPack::ID
int ID
Definition: datapack.h:37
uiHistogramSel::minhandle_
uiLineItem * minhandle_
Definition: uihistogramsel.h:58
uiHistogramSel::changeLinePos
bool changeLinePos(bool pressedonly=false)
uiHistogramSel
Definition: uihistogramsel.h:19
uiHistogramSel::setDataRange
void setDataRange(const Interval< float > &)
uiHistogramSel::slidertextpol_
SliderTextPolicy slidertextpol_
Definition: uihistogramsel.h:54
uiHistogramSel::mousePressed
void mousePressed(CallBacker *)
uiHistogramSel::drawAgain
virtual void drawAgain()
uiHistogramSel::ID
int ID() const
Definition: uihistogramsel.h:26
uiHistogramSel::drawText
virtual void drawText()
uiHistogramSel::histDRChanged
void histDRChanged(CallBacker *)
uiHistogramSel::setData
void setData(const float *, int sz)
uiParent
Definition: uiparent.h:26
uiHistogramSel::mouseReleased
void mouseReleased(CallBacker *)
uiHistogramSel::maxhandle_
uiLineItem * maxhandle_
Definition: uihistogramsel.h:59
Interval< float >
uiHistogramSel::drawPixmaps
virtual void drawPixmaps()
Definition: uihistogramsel.h:73
uiHistogramSel::rangeChanged
Notifier< uiHistogramSel > rangeChanged
Definition: uihistogramsel.h:49
Array2D< float >
uiHistogramSel::cliprg_
Interval< float > cliprg_
Definition: uihistogramsel.h:64
uiHistogramSel::id_
int id_
Definition: uihistogramsel.h:53
uiTextItem
Definition: uigraphicsitemimpl.h:276
uiHistogramSel::init
void init()
uiHistogramSel::startpix_
int startpix_
Definition: uihistogramsel.h:65
uiHistogramSel::drawLines
virtual void drawLines()
DataPack::id_
const ID id_
Definition: datapack.h:68

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B.V. 1995-2021