1 // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either
7 // version 2.1 of the License.
9 // This library is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // Lesser General Public License for more details.
14 // You should have received a copy of the GNU Lesser General Public
15 // License along with this library; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
20 // File : GEOM_DlgRef.cxx
21 // Author : Vadim SANDLER, Open CASCADE S.A.S. (vadim.sandler@opencascade.com)
24 #include "GEOM_DlgRef.h"
26 //////////////////////////////////////////
27 // DlgRef_1List1Spin1Btn
28 //////////////////////////////////////////
30 DlgRef_1List1Spin1Btn::DlgRef_1List1Spin1Btn( QWidget* parent, Qt::WindowFlags f )
31 : QWidget( parent, f )
36 DlgRef_1List1Spin1Btn::~DlgRef_1List1Spin1Btn()
40 //////////////////////////////////////////
41 // DlgRef_1Sel1Check1List
42 //////////////////////////////////////////
44 DlgRef_1Sel1Check1List::DlgRef_1Sel1Check1List( QWidget* parent, Qt::WindowFlags f )
45 : QWidget( parent, f )
50 DlgRef_1Sel1Check1List::~DlgRef_1Sel1Check1List()
54 //////////////////////////////////////////
55 // DlgRef_1Sel1Check1Sel
56 //////////////////////////////////////////
58 DlgRef_1Sel1Check1Sel::DlgRef_1Sel1Check1Sel( QWidget* parent, Qt::WindowFlags f )
59 : QWidget( parent, f )
64 DlgRef_1Sel1Check1Sel::~DlgRef_1Sel1Check1Sel()
68 //////////////////////////////////////////
70 //////////////////////////////////////////
72 DlgRef_1Sel1Check::DlgRef_1Sel1Check( QWidget* parent, Qt::WindowFlags f )
73 : QWidget( parent, f )
78 DlgRef_1Sel1Check::~DlgRef_1Sel1Check()
82 //////////////////////////////////////////
83 // DlgRef_1Sel1List4Btn
84 //////////////////////////////////////////
86 DlgRef_1Sel1List4Btn::DlgRef_1Sel1List4Btn( QWidget* parent, Qt::WindowFlags f )
87 : QWidget( parent, f )
92 DlgRef_1Sel1List4Btn::~DlgRef_1Sel1List4Btn()
96 //////////////////////////////////////////
97 // DlgRef_1Sel1Spin1Check
98 //////////////////////////////////////////
100 DlgRef_1Sel1Spin1Check::DlgRef_1Sel1Spin1Check( QWidget* parent, Qt::WindowFlags f )
101 : QWidget( parent, f )
106 DlgRef_1Sel1Spin1Check::~DlgRef_1Sel1Spin1Check()
110 //////////////////////////////////////////
112 //////////////////////////////////////////
114 DlgRef_1Sel1Spin::DlgRef_1Sel1Spin( QWidget* parent, Qt::WindowFlags f )
115 : QWidget( parent, f )
120 DlgRef_1Sel1Spin::~DlgRef_1Sel1Spin()
124 //////////////////////////////////////////
125 // DlgRef_1Sel2Spin1View1Check
126 //////////////////////////////////////////
128 DlgRef_1Sel2Spin1View1Check::DlgRef_1Sel2Spin1View1Check( QWidget* parent, Qt::WindowFlags f )
129 : QWidget( parent, f )
134 DlgRef_1Sel2Spin1View1Check::~DlgRef_1Sel2Spin1View1Check()
138 //////////////////////////////////////////
140 //////////////////////////////////////////
142 DlgRef_1Sel2Spin::DlgRef_1Sel2Spin( QWidget* parent, Qt::WindowFlags f )
143 : QWidget( parent, f )
148 DlgRef_1Sel2Spin::~DlgRef_1Sel2Spin()
152 //////////////////////////////////////////
154 //////////////////////////////////////////
156 DlgRef_1Sel3Check::DlgRef_1Sel3Check( QWidget* parent, Qt::WindowFlags f )
157 : QWidget( parent, f )
162 DlgRef_1Sel3Check::~DlgRef_1Sel3Check()
166 //////////////////////////////////////////
168 //////////////////////////////////////////
170 DlgRef_1Sel3Spin::DlgRef_1Sel3Spin( QWidget* parent, Qt::WindowFlags f )
171 : QWidget( parent, f )
176 DlgRef_1Sel3Spin::~DlgRef_1Sel3Spin()
180 //////////////////////////////////////////
182 //////////////////////////////////////////
184 DlgRef_1Sel4Spin::DlgRef_1Sel4Spin( QWidget* parent, Qt::WindowFlags f )
185 : QWidget( parent, f )
190 DlgRef_1Sel4Spin::~DlgRef_1Sel4Spin()
194 //////////////////////////////////////////
196 //////////////////////////////////////////
198 DlgRef_1Sel5Spin::DlgRef_1Sel5Spin( QWidget* parent, Qt::WindowFlags f )
199 : QWidget( parent, f )
204 DlgRef_1Sel5Spin::~DlgRef_1Sel5Spin()
208 //////////////////////////////////////////
210 //////////////////////////////////////////
212 DlgRef_1Spin::DlgRef_1Spin( QWidget* parent, Qt::WindowFlags f )
213 : QWidget( parent, f )
218 DlgRef_1Spin::~DlgRef_1Spin()
222 //////////////////////////////////////////
224 //////////////////////////////////////////
226 DlgRef_1Sel::DlgRef_1Sel( QWidget* parent, Qt::WindowFlags f )
227 : QWidget( parent, f )
232 DlgRef_1Sel::~DlgRef_1Sel()
236 //////////////////////////////////////////
238 //////////////////////////////////////////
240 DlgRef_1SelExt::DlgRef_1SelExt( QWidget* parent, Qt::WindowFlags f )
241 : QWidget( parent, f )
246 DlgRef_1SelExt::~DlgRef_1SelExt()
250 //////////////////////////////////////////
252 //////////////////////////////////////////
254 DlgRef_2Sel1List::DlgRef_2Sel1List( QWidget* parent, Qt::WindowFlags f )
255 : QWidget( parent, f )
260 DlgRef_2Sel1List::~DlgRef_2Sel1List()
264 //////////////////////////////////////////
265 // DlgRef_2Sel1Spin2Check
266 //////////////////////////////////////////
268 DlgRef_2Sel1Spin2Check::DlgRef_2Sel1Spin2Check( QWidget* parent, Qt::WindowFlags f )
269 : QWidget( parent, f )
274 DlgRef_2Sel1Spin2Check::~DlgRef_2Sel1Spin2Check()
278 //////////////////////////////////////////
280 //////////////////////////////////////////
282 DlgRef_2Sel1Spin::DlgRef_2Sel1Spin( QWidget* parent, Qt::WindowFlags f )
283 : QWidget( parent, f )
288 DlgRef_2Sel1Spin::~DlgRef_2Sel1Spin()
292 //////////////////////////////////////////
293 // DlgRef_2Sel2Spin1Check
294 //////////////////////////////////////////
296 DlgRef_2Sel2Spin1Check::DlgRef_2Sel2Spin1Check( QWidget* parent, Qt::WindowFlags f )
297 : QWidget( parent, f )
302 DlgRef_2Sel2Spin1Check::~DlgRef_2Sel2Spin1Check()
306 //////////////////////////////////////////
308 //////////////////////////////////////////
310 DlgRef_2Sel2Spin::DlgRef_2Sel2Spin( QWidget* parent, Qt::WindowFlags f )
311 : QWidget( parent, f )
316 DlgRef_2Sel2Spin::~DlgRef_2Sel2Spin()
320 //////////////////////////////////////////
322 //////////////////////////////////////////
324 DlgRef_2Sel3Spin::DlgRef_2Sel3Spin( QWidget* parent, Qt::WindowFlags f )
325 : QWidget( parent, f )
330 DlgRef_2Sel3Spin::~DlgRef_2Sel3Spin()
334 //////////////////////////////////////////
335 // DlgRef_2Sel4Spin1Check
336 //////////////////////////////////////////
338 DlgRef_2Sel4Spin1Check::DlgRef_2Sel4Spin1Check( QWidget* parent, Qt::WindowFlags f )
339 : QWidget( parent, f )
344 DlgRef_2Sel4Spin1Check::~DlgRef_2Sel4Spin1Check()
348 //////////////////////////////////////////
350 //////////////////////////////////////////
352 DlgRef_2Sel::DlgRef_2Sel( QWidget* parent, Qt::WindowFlags f )
353 : QWidget( parent, f )
358 DlgRef_2Sel::~DlgRef_2Sel()
362 //////////////////////////////////////////
364 //////////////////////////////////////////
366 DlgRef_2SelExt::DlgRef_2SelExt( QWidget* parent, Qt::WindowFlags f )
367 : QWidget( parent, f )
372 DlgRef_2SelExt::~DlgRef_2SelExt()
376 //////////////////////////////////////////
378 //////////////////////////////////////////
380 DlgRef_2Spin::DlgRef_2Spin( QWidget* parent, Qt::WindowFlags f )
381 : QWidget( parent, f )
386 DlgRef_2Spin::~DlgRef_2Spin()
390 //////////////////////////////////////////
392 //////////////////////////////////////////
394 DlgRef_3Check::DlgRef_3Check( QWidget* parent, Qt::WindowFlags f )
395 : QWidget( parent, f )
400 DlgRef_3Check::~DlgRef_3Check()
404 //////////////////////////////////////////
406 //////////////////////////////////////////
408 DlgRef_3Sel1Check::DlgRef_3Sel1Check( QWidget* parent, Qt::WindowFlags f )
409 : QWidget( parent, f )
414 DlgRef_3Sel1Check::~DlgRef_3Sel1Check()
418 //////////////////////////////////////////
420 //////////////////////////////////////////
422 DlgRef_3Sel1Spin::DlgRef_3Sel1Spin( QWidget* parent, Qt::WindowFlags f )
423 : QWidget( parent, f )
428 DlgRef_3Sel1Spin::~DlgRef_3Sel1Spin()
432 //////////////////////////////////////////
433 // DlgRef_3Sel3Spin1Check
434 //////////////////////////////////////////
436 DlgRef_3Sel3Spin1Check::DlgRef_3Sel3Spin1Check( QWidget* parent, Qt::WindowFlags f )
437 : QWidget( parent, f )
442 DlgRef_3Sel3Spin1Check::~DlgRef_3Sel3Spin1Check()
446 void DlgRef_3Sel3Spin1Check::ShowRows( int fromRow, int toRow, bool toShow )
448 const int maxRows = 6;
450 if ( toRow >= fromRow && fromRow >= 0 && toRow <= maxRows ) {
451 int c = gridLayout1->count();
452 for ( int i = 0; i < c; i++ ) {
453 QWidget* w = gridLayout1->itemAt( i )->widget();
454 int row, col, rowspan, colspan;
455 gridLayout1->getItemPosition( i, &row, &col, &rowspan, &colspan );
456 if ( w && row >= fromRow && row <= toRow )
457 w->setVisible( toShow );
462 //////////////////////////////////////////
463 // DlgRef_3Sel4Spin2Check
464 //////////////////////////////////////////
466 DlgRef_3Sel4Spin2Check::DlgRef_3Sel4Spin2Check( QWidget* parent, Qt::WindowFlags f )
467 : QWidget( parent, f )
472 DlgRef_3Sel4Spin2Check::~DlgRef_3Sel4Spin2Check()
476 //////////////////////////////////////////
478 //////////////////////////////////////////
480 DlgRef_3Sel::DlgRef_3Sel( QWidget* parent, Qt::WindowFlags f )
481 : QWidget( parent, f )
486 DlgRef_3Sel::~DlgRef_3Sel()
490 //////////////////////////////////////////
491 // DlgRef_3Spin1Check
492 //////////////////////////////////////////
494 DlgRef_3Spin1Check::DlgRef_3Spin1Check( QWidget* parent, Qt::WindowFlags f )
495 : QWidget( parent, f )
500 DlgRef_3Spin1Check::~DlgRef_3Spin1Check()
504 //////////////////////////////////////////
506 //////////////////////////////////////////
508 DlgRef_3Spin::DlgRef_3Spin( QWidget* parent, Qt::WindowFlags f )
509 : QWidget( parent, f )
514 DlgRef_3Spin::~DlgRef_3Spin()
518 //////////////////////////////////////////
519 // DlgRef_4Sel1List1Check
520 //////////////////////////////////////////
522 DlgRef_4Sel1List1Check::DlgRef_4Sel1List1Check( QWidget* parent, Qt::WindowFlags f )
523 : QWidget( parent, f )
528 DlgRef_4Sel1List1Check::~DlgRef_4Sel1List1Check()
532 //////////////////////////////////////////
534 //////////////////////////////////////////
536 DlgRef_4Sel1List::DlgRef_4Sel1List( QWidget* parent, Qt::WindowFlags f )
537 : QWidget( parent, f )
542 DlgRef_4Sel1List::~DlgRef_4Sel1List()
546 //////////////////////////////////////////
547 // DlgRef_4Sel1Spin2Check
548 //////////////////////////////////////////
550 DlgRef_4Sel1Spin2Check::DlgRef_4Sel1Spin2Check( QWidget* parent, Qt::WindowFlags f )
551 : QWidget( parent, f )
556 DlgRef_4Sel1Spin2Check::~DlgRef_4Sel1Spin2Check()
560 void DlgRef_4Sel1Spin2Check::ShowRows( int fromRow, int toRow, bool toShow )
562 const int maxRows = 6;
564 if ( toRow >= fromRow && fromRow >= 0 && toRow <= maxRows ) {
565 int c = gridLayout1->count();
566 for ( int i = 0; i < c; i++ ) {
567 QWidget* w = gridLayout1->itemAt( i )->widget();
568 int row, col, rowspan, colspan;
569 gridLayout1->getItemPosition( i, &row, &col, &rowspan, &colspan );
570 if ( w && row >= fromRow && row <= toRow )
571 w->setVisible( toShow );
576 //////////////////////////////////////////
578 //////////////////////////////////////////
580 DlgRef_6Sel::DlgRef_6Sel( QWidget* parent, Qt::WindowFlags f )
581 : QWidget( parent, f )
586 DlgRef_6Sel::~DlgRef_6Sel()
590 //////////////////////////////////////////
592 //////////////////////////////////////////
594 DlgRef_Skeleton::DlgRef_Skeleton( QWidget* parent, Qt::WindowFlags f )
595 : QWidget( parent, f )
600 DlgRef_Skeleton::~DlgRef_Skeleton()