OpendTect-6_4  6.4
uiimpexpselgrp.h
Go to the documentation of this file.
1 #ifndef uiimpexpselgrp_h
2 #define uiimpexpselgrp_h
3 
4 /*+
5 ________________________________________________________________________
6 
7  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
8  Author: Satyaki Maitra
9  Date: Dec 2010
10  RCS: $Id$
11 ________________________________________________________________________
12 
13 -*/
14 
15 #include "uiiomod.h"
16 #include "uidialog.h"
18 #include "uigroup.h"
19 #include "filepath.h"
20 #include "strmdata.h"
21 
22 class BufferStringSet;
23 
24 class uiAxisHandler;
25 class uiCheckBox;
26 class uiComboBox;
27 class uiGenInput;
28 class uiListBox;
29 class uiGenInput;
30 class uiPushButton;
31 class uiToolButton;
33 
34 
35 mExpClass(uiIo) uiSGSel : public uiGroup
37 public:
38  uiSGSel(uiParent*,bool forread);
39 
40  bool isOK() const;
41  const char* selGrpFileNm();
42  const char* selGrpSetNm() const;
44  { return selgrpset_; }
45 
46  const OD::String& xName() { return xname_; }
47  const OD::String& yName() { return yname_; }
48  const OD::String& y2Name() { return y2name_; }
49 
51 
52 protected:
53 
56 
61 
63  bool forread_;
64  void selectSGCB(CallBacker*);
65 };
66 
67 
70 public:
71  uiSGSelGrp(uiParent*,bool forread);
72 
73  BufferString getCurFileNm() const;
74  const char* selGrpSetNm() const;
75  bool getCurSelGrpSet(ObjectSet<SelectionGrp>&);
76 
77  const OD::String& xName() { return xname_; }
78  const OD::String& yName() { return yname_; }
79  const OD::String& y2Name() { return y2name_; }
80 
82 
83 protected:
84 
90 
94  bool forread_;
95 
97 
98  bool createBaseDir();
99  bool hasIdxFile();
100  bool fillListBox();
101  bool getSelGrpSetNames(BufferStringSet&) const;
102  bool setSelGrpSetNames(const BufferStringSet&) const;
103 
104  void showInfo(CallBacker*);
105  void delSelGrps(CallBacker*);
106  void renameSelGrps(CallBacker*);
107  void selChangedCB(CallBacker*);
108  void selDoneCB(CallBacker*);
109 };
110 
111 
114 public:
115  SelGrpImporter(const char*);
116  ~SelGrpImporter();
117 
118  ObjectSet<SelectionGrp> getSelections();
119  const uiString& errMsg() { return errmsg_; }
120  const OD::String& xName() { return xname_; }
121  const OD::String& yName() { return yname_; }
122  const OD::String& y2Name() { return y2name_; }
123 
124 protected:
125 
130 
132 };
133 
134 
136 { mODTextTranslationClass(SelGrpExporter);
137 public:
138  SelGrpExporter(const char* fnm);
139  ~SelGrpExporter();
140  bool putSelections(const ObjectSet<SelectionGrp>&,
141  const char* xnm,
142  const char* ynm,
143  const char* y2nm);
144  const uiString& errMsg() const { return errmsg_; }
145 
146 protected:
147 
150 
151 };
152 
153 
156 public:
158 
159 protected:
160 
168 
173 
174  bool adjustSelectionGrps();
175  bool checkSelectionArea(SelectionArea&,
176  const BufferStringSet& selaxisnms,
177  const BufferStringSet& avlblaxnms,
178  bool);
179 
180  void fillRectangle(const SelectionArea& selarea,
181  SelectionArea& actselarea);
182  void fillPolygon(const SelectionArea& selarea,
183  SelectionArea& actselarea);
184 
185  BufferStringSet getAvailableAxisNames() const;
186  void getInfo(const ObjectSet<SelectionGrp>&,BufferString&);
187  void fldCheckedCB(CallBacker*);
188  void examineCB(CallBacker*);
189  void selectedCB(CallBacker*);
190  bool acceptOK(CallBacker*);
191 };
192 
193 
196 public:
197 
199  {
200  public:
201  Setup(const char* x,const char* y, const char* y2)
202  : y2name_(y2) , yname_(y) , xname_(x) {}
203 
204  mDefSetupMemb(const char*,y2name)
205  mDefSetupMemb(const char*,yname)
206  mDefSetupMemb(const char*,xname)
207  };
208 
212 
213 
214 protected:
215 
220 
221  bool acceptOK(CallBacker*);
222 
223 };
224 
225 #endif
Definition: uigroup.h:54
#define mExpClass(module)
Definition: commondefs.h:160
const uiString & errMsg()
Definition: uiimpexpselgrp.h:119
Definition: uiimpexpselgrp.h:135
BufferString xname_
Definition: uiimpexpselgrp.h:58
FilePath basefp_
Definition: uiimpexpselgrp.h:96
To be able to send and/or receive CallBacks, inherit from this class.
Definition: callback.h:272
BufferString yname_
Definition: uiimpexpselgrp.h:128
Setup setup_
Definition: uiimpexpselgrp.h:216
const OD::String & xName()
Definition: uiimpexpselgrp.h:77
StreamData sd_
Definition: uiimpexpselgrp.h:149
is the base class for all buttons.
Definition: uibutton.h:83
#define mODTextTranslationClass(clss)
Definition: uistring.h:38
const OD::String & xName()
Definition: uiimpexpselgrp.h:46
StreamData sd_
Definition: uiimpexpselgrp.h:131
Definition: uiimpexpselgrp.h:198
uiToolButton * infobut_
Definition: uiimpexpselgrp.h:87
BufferString y2name_
Definition: uiimpexpselgrp.h:129
const ObjectSet< SelectionGrp > & selGrpSet() const
Definition: uiimpexpselgrp.h:43
Handles an axis on a plot.
Definition: uiaxishandler.h:51
DataPointSet crossplotter.
Definition: uidatapointsetcrossplot.h:47
Combo box.
Definition: uicombobox.h:32
Definition: uistring.h:89
const OD::String & y2Name()
Definition: uiimpexpselgrp.h:79
Definition: uiparent.h:26
ObjectSet< SelectionGrp > selgrpset_
Definition: uiimpexpselgrp.h:62
Set of BufferString objects.
Definition: bufstringset.h:28
bool forread_
Definition: uiimpexpselgrp.h:63
Definition: uiimpexpselgrp.h:35
const ObjectSet< SelectionGrp > & selgrps_
Definition: uiimpexpselgrp.h:219
BufferString selgrpfilenm_
Definition: uiimpexpselgrp.h:57
Definition: uidialog.h:42
BufferString xname_
Definition: uiimpexpselgrp.h:170
uiComboBox * xselfld_
Definition: uiimpexpselgrp.h:162
Notifier< uiSGSelGrp > selectionDone
Definition: uiimpexpselgrp.h:81
List Box.
Definition: uilistbox.h:75
const OD::String & xName()
Definition: uiimpexpselgrp.h:120
uiListBox * listfld_
Definition: uiimpexpselgrp.h:85
uiGenInput * axisfld_
Definition: uiimpexpselgrp.h:217
uiComboBox * y2selfld_
Definition: uiimpexpselgrp.h:164
uiToolButton * renamebut_
Definition: uiimpexpselgrp.h:89
const OD::String & yName()
Definition: uiimpexpselgrp.h:47
encapsulates the read-access-only part of strings in OD.
Definition: odstring.h:31
BufferString xname_
Definition: uiimpexpselgrp.h:91
General Input Element.
Definition: uigeninput.h:58
Holds data to use and close an iostream.
Definition: strmdata.h:28
const OD::String & yName()
Definition: uiimpexpselgrp.h:121
#define mDefSetupMemb(typ, memb)
Definition: commondefs.h:137
uiPushButton * selbut_
Definition: uiimpexpselgrp.h:55
BufferString y2name_
Definition: uiimpexpselgrp.h:60
uiSGSel * inpfld_
Definition: uiimpexpselgrp.h:161
BufferString y2name_
Definition: uiimpexpselgrp.h:172
BufferString yname_
Definition: uiimpexpselgrp.h:171
uiToolButton * delbut_
Definition: uiimpexpselgrp.h:88
bool forread_
Definition: uiimpexpselgrp.h:94
const OD::String & yName()
Definition: uiimpexpselgrp.h:78
uiCheckBox * ychkfld_
Definition: uiimpexpselgrp.h:165
uiString errmsg_
Definition: uiimpexpselgrp.h:126
File pathname tools.
Definition: filepath.h:34
BufferString xname_
Definition: uiimpexpselgrp.h:127
uiComboBox * yselfld_
Definition: uiimpexpselgrp.h:163
uiCheckBox * y2chkfld_
Definition: uiimpexpselgrp.h:166
OD::String with its own variable length buffer. The buffer has a guaranteed minimum size...
Definition: bufstring.h:40
BufferString errmsg_
Definition: horizontracker.h:119
const OD::String & y2Name()
Definition: uiimpexpselgrp.h:48
Notifier< uiSGSel > selGrpSelected
Definition: uiimpexpselgrp.h:50
BufferString yname_
Definition: uiimpexpselgrp.h:92
uiGenInput * inpfld_
Definition: uiimpexpselgrp.h:54
ObjectSet< SelectionGrp > & selgrpset_
Definition: uiimpexpselgrp.h:169
Setup(const char *x, const char *y, const char *y2)
Definition: uiimpexpselgrp.h:201
Definition: uitoolbutton.h:22
uiSGSel * outfld_
Definition: uiimpexpselgrp.h:218
BufferString y2name_
Definition: uiimpexpselgrp.h:93
uiGenInput * nmfld_
Definition: uiimpexpselgrp.h:86
Definition: uiimpexpselgrp.h:112
Definition: uiimpexpselgrp.h:194
Definition: uiimpexpselgrp.h:154
Definition: uibutton.h:134
BufferString yname_
Definition: uiimpexpselgrp.h:59
ObjectSet< SelectionGrp > selgrpset_
Definition: uidatapointsetcrossplot.h:339
uiString errmsg_
Definition: uiimpexpselgrp.h:148
const OD::String & y2Name()
Definition: uiimpexpselgrp.h:122
uiDataPointSetCrossPlotter & plotter_
Definition: uiimpexpselgrp.h:167
Definition: uiimpexpselgrp.h:68
const uiString & errMsg() const
Definition: uiimpexpselgrp.h:144

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