From: rkv Date: Tue, 22 Oct 2013 09:06:00 +0000 (+0000) Subject: New labels for coordinates are added into Import image dialog. Mode labels are updated. X-Git-Tag: BR_hydro_v_0_3~93 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=e3c215a2ca83866af33351a43e54b192e22848e1;p=modules%2Fhydro.git New labels for coordinates are added into Import image dialog. Mode labels are updated. --- diff --git a/src/HYDROData/CMakeLists.txt b/src/HYDROData/CMakeLists.txt index 566afc08..fed28edf 100644 --- a/src/HYDROData/CMakeLists.txt +++ b/src/HYDROData/CMakeLists.txt @@ -50,10 +50,11 @@ include_directories( ${CAS_INCLUDE_DIRS} ${QT_INCLUDES} ${CMAKE_CURRENT_SOURCE_DIR} + ${GUI_ROOT_DIR}/include/salome ) add_library(HYDROData SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS}) -target_link_libraries(HYDROData ${CAS_OCAF} ${CAS_OCAFVIS} ${CAS_TKG3d} ${CAS_TKGeomBase} ${CAS_TKGeomAlgo} ${QT_LIBRARIES} ${ImageComposer}) +target_link_libraries(HYDROData ${CAS_OCAF} ${CAS_OCAFVIS} ${CAS_TKG3d} ${CAS_TKGeomBase} ${CAS_TKGeomAlgo} ${CAS_TKBrep} ${CAS_TKTopAlgo} ${QT_LIBRARIES} ${ImageComposer}) set(PROJECT_LIBRARIES HYDROData) diff --git a/src/HYDROGUI/CMakeLists.txt b/src/HYDROGUI/CMakeLists.txt index a92c80f1..0a8e21c8 100644 --- a/src/HYDROGUI/CMakeLists.txt +++ b/src/HYDROGUI/CMakeLists.txt @@ -118,7 +118,7 @@ include_directories( add_library(HYDROGUI SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${PROJECT_HEADERS_MOC}) target_link_libraries(HYDROGUI HYDROData - ${CAS_TKV3d} ${CAS_TKTopAlgo} ${CAS_TKBRep} + ${CAS_TKV3d} ${CAS_TKTopAlgo} ${CAS_TKBrep} ${CAS_TKBO} ${LightApp} ${CAM} ${suit} ${qtx} ${ObjBrowser} ${GraphicsView} ${std} ${Event} ${OCCViewer} ${CurveCreator} ) diff --git a/src/HYDROGUI/HYDROGUI_ImportImageDlg.cxx b/src/HYDROGUI/HYDROGUI_ImportImageDlg.cxx index 795d099b..288e0a60 100644 --- a/src/HYDROGUI/HYDROGUI_ImportImageDlg.cxx +++ b/src/HYDROGUI/HYDROGUI_ImportImageDlg.cxx @@ -96,13 +96,13 @@ HYDROGUI_ImportImageDlg::HYDROGUI_ImportImageDlg( HYDROGUI_Module* theModule, co aPainter.drawPixmap( 0, 0, anArrowPixmap ); aPainter.end(); - QRadioButton* aManualLambertBtn = new QRadioButton( tr( "MANUALLY_LAMBERT93" ), myTransformGroup ); QRadioButton* aManualCartesianBtn = new QRadioButton( tr( "MANUALLY_CARTESIAN" ), myTransformGroup ); + QRadioButton* aManualLambertBtn = new QRadioButton( tr( "MANUALLY_LAMBERT93" ), myTransformGroup ); QRadioButton* aRefImageBtn = new QRadioButton( tr( "BY_REFERENCE_IMAGE" ), myTransformGroup ); myModeGroup = new QButtonGroup( myTransformGroup ); - myModeGroup->addButton( aManualLambertBtn, ManualLambert ); myModeGroup->addButton( aManualCartesianBtn, ManualCartesian ); + myModeGroup->addButton( aManualLambertBtn, ManualLambert ); myModeGroup->addButton( aRefImageBtn, RefImage ); myRefImage = new QComboBox( myTransformGroup ); @@ -110,8 +110,8 @@ HYDROGUI_ImportImageDlg::HYDROGUI_ImportImageDlg( HYDROGUI_Module* theModule, co QGridLayout* aModeLayout = new QGridLayout(); aModeLayout->setMargin( 0 ); aModeLayout->setSpacing( 5 ); - aModeLayout->addWidget( aManualLambertBtn, 0, 0 ); - aModeLayout->addWidget( aManualCartesianBtn, 1, 0 ); + aModeLayout->addWidget( aManualCartesianBtn, 0, 0 ); + aModeLayout->addWidget( aManualLambertBtn, 1, 0 ); aModeLayout->addWidget( aRefImageBtn, 2, 0 ); aModeLayout->addWidget( myRefImage, 2, 1 ); aModeLayout->setColumnStretch( 1, 1 ); @@ -121,6 +121,26 @@ HYDROGUI_ImportImageDlg::HYDROGUI_ImportImageDlg( HYDROGUI_Module* theModule, co aTransformLayout->setSpacing( 5 ); aTransformLayout->addLayout( aModeLayout, 0, 0, 1, 9 ); + QLabel* aImageCSLabel = new QLabel( tr( "IMAGE_CS" ), myTransformGroup ); + QLabel* aGeodesicLabel = new QLabel( "GEODESIC", myTransformGroup ); + QLabel* aLambertLabel = new QLabel( "LAMBERT93", myTransformGroup ); + QLabel* aRefImageLabel = new QLabel( "REFERENCE_IMAGE_CS", myTransformGroup ); + + aTransformLayout->addWidget( aImageCSLabel, 2, 1 ); + aTransformLayout->addWidget( aGeodesicLabel, 2, 3, 1, 6 ); + aTransformLayout->addWidget( aLambertLabel, 2, 3, 1, 6 ); + aTransformLayout->addWidget( aRefImageLabel, 2, 3, 1, 6 ); + + connect( aManualCartesianBtn, SIGNAL( toggled( bool ) ), aGeodesicLabel, SLOT( setVisible ( bool ) ) ); + connect( aManualCartesianBtn, SIGNAL( toggled( bool ) ), aLambertLabel, SLOT( setHidden ( bool ) ) ); + connect( aManualCartesianBtn, SIGNAL( toggled( bool ) ), aRefImageLabel, SLOT( setHidden ( bool ) ) ); + connect( aManualLambertBtn, SIGNAL( toggled( bool ) ), aLambertLabel, SLOT( setVisible ( bool ) ) ); + connect( aManualLambertBtn, SIGNAL( toggled( bool ) ), aGeodesicLabel, SLOT( setHidden ( bool ) ) ); + connect( aManualLambertBtn, SIGNAL( toggled( bool ) ), aRefImageLabel, SLOT( setHidden ( bool ) ) ); + connect( aRefImageBtn, SIGNAL( toggled( bool ) ), aRefImageLabel, SLOT( setVisible ( bool ) ) ); + connect( aRefImageBtn, SIGNAL( toggled( bool ) ), aGeodesicLabel, SLOT( setHidden ( bool ) ) ); + connect( aRefImageBtn, SIGNAL( toggled( bool ) ), aLambertLabel, SLOT( setHidden ( bool ) ) ); + for( int aPointType = HYDROGUI_PrsImage::PointA; aPointType <= HYDROGUI_PrsImage::PointC; aPointType++ ) { @@ -166,7 +186,7 @@ HYDROGUI_ImportImageDlg::HYDROGUI_ImportImageDlg( HYDROGUI_Module* theModule, co QtxIntSpinBox* aRefPointX = new QtxIntSpinBox( 0, 0, 1, myTransformGroup ); // max is updated later QtxIntSpinBox* aRefPointY = new QtxIntSpinBox( 0, 0, 1, myTransformGroup ); // max is updated later - int aRow = 4 * aPointType + 2; + int aRow = 4 * aPointType + 3; aTransformLayout->addWidget( aPointBtn, aRow, 0, 1, 9 ); aTransformLayout->addWidget( aPointXLabel, aRow + 1, 0 ); @@ -262,6 +282,9 @@ HYDROGUI_ImportImageDlg::HYDROGUI_ImportImageDlg( HYDROGUI_Module* theModule, co HYDROGUI_ImportImageDlg::~HYDROGUI_ImportImageDlg() { + delete myFileNameGroup; + delete myImageNameGroup; + delete myTransformGroup; } void HYDROGUI_ImportImageDlg::setIsEdit( const bool theIsEdit ) @@ -302,7 +325,7 @@ void HYDROGUI_ImportImageDlg::reset() myTransformGroup->setEnabled( false ); myRefImage->clear(); - setTransformationMode( ManualCartesian ); + setTransformationMode( ManualLambert ); myPrsPointDataList.clear(); diff --git a/src/HYDROGUI/resources/HYDROGUI_msg_en.ts b/src/HYDROGUI/resources/HYDROGUI_msg_en.ts index 356159ad..63f72ab8 100644 --- a/src/HYDROGUI/resources/HYDROGUI_msg_en.ts +++ b/src/HYDROGUI/resources/HYDROGUI_msg_en.ts @@ -245,12 +245,28 @@ file cannot be correctly imported for a Bathymetry definition. MANUALLY_CARTESIAN - Manually input Cartesian coordinates + Manually input Geodesic coordinates MANUALLY_LAMBERT93 Manually input Lambert93 coordinates + + IMAGE_CS + Image CS + + + GEODESIC + Geodesic + + + LAMBERT93 + Lambert93 + + + REFERENCE_IMAGE_CS + Reference Image CS + NAME Name diff --git a/src/HYDROGUI/resources/LightApp.xml b/src/HYDROGUI/resources/LightApp.xml index 1e8658d7..884de34c 100644 --- a/src/HYDROGUI/resources/LightApp.xml +++ b/src/HYDROGUI/resources/LightApp.xml @@ -36,8 +36,8 @@
- - + +