From 2af635b0bb15400bc141a63760db594456717a0b Mon Sep 17 00:00:00 2001 From: asl Date: Fri, 19 Jun 2015 09:24:44 +0300 Subject: [PATCH] refs #585: gui for polyline operations --- src/HYDROGUI/HYDROGUI_SplitPolylinesDlg.cxx | 23 ++++++++++- src/HYDROGUI/resources/HYDROGUI_msg_en.ts | 44 +++++++++++++++++++++ 2 files changed, 66 insertions(+), 1 deletion(-) diff --git a/src/HYDROGUI/HYDROGUI_SplitPolylinesDlg.cxx b/src/HYDROGUI/HYDROGUI_SplitPolylinesDlg.cxx index 5a702d16..ddc0a44d 100644 --- a/src/HYDROGUI/HYDROGUI_SplitPolylinesDlg.cxx +++ b/src/HYDROGUI/HYDROGUI_SplitPolylinesDlg.cxx @@ -22,6 +22,7 @@ #include #include #include +#include #include #include #include @@ -40,14 +41,34 @@ HYDROGUI_SplitPolylinesDlg::HYDROGUI_SplitPolylinesDlg( HYDROGUI_Module* theModu aLayout->addWidget( myTab, 0, 0 ); QFrame* aPointPage = new QFrame(); + myMainPolyline1 = new HYDROGUI_ObjComboBox( theModule, tr( "POLYLINE" ), KIND_POLYLINEXY, aPointPage ); + myX = new QtxDoubleSpinBox( aPointPage ); + myY = new QtxDoubleSpinBox( aPointPage ); + QGridLayout* aPointPageLayout = new QGridLayout( aPointPage ); - + aPointPageLayout->addWidget( myMainPolyline1, 0, 0, 1, 3 ); + aPointPageLayout->addWidget( new QLabel( tr( "POINT" ) ), 1, 0 ); + aPointPageLayout->addWidget( myX, 1, 1 ); + aPointPageLayout->addWidget( myY, 1, 2 ); + aPointPageLayout->setColumnStretch( 1, 1 ); + aPointPageLayout->setColumnStretch( 2, 1 ); + aPointPageLayout->setRowStretch( 2, 1 ); myTab->addTab( aPointPage, tr( "BY_POINT" ) ); QFrame* aToolPage = new QFrame(); + myMainPolyline2 = new HYDROGUI_ObjComboBox( theModule, tr( "POLYLINE" ), KIND_POLYLINEXY, aToolPage ); + myToolPolyline = new HYDROGUI_ObjComboBox( theModule, tr( "TOOL_POLYLINE" ), KIND_POLYLINEXY, aToolPage ); + + QGridLayout* aToolPageLayout = new QGridLayout( aToolPage ); + aToolPageLayout->addWidget( myMainPolyline2, 0, 0 ); + aToolPageLayout->addWidget( myToolPolyline, 1, 0 ); + aToolPageLayout->setRowStretch( 2, 1 ); myTab->addTab( aToolPage, tr( "BY_TOOL" ) ); QFrame* aSplitPage = new QFrame(); + myPolylines = new HYDROGUI_ObjListBox( theModule, tr( "POLYLINES" ), KIND_POLYLINEXY, aSplitPage ); + QGridLayout* aSplitPageLayout = new QGridLayout( aSplitPage ); + aSplitPageLayout->addWidget( myPolylines, 0, 0 ); myTab->addTab( aSplitPage, tr( "COMPLETE_SPLIT" ) ); } diff --git a/src/HYDROGUI/resources/HYDROGUI_msg_en.ts b/src/HYDROGUI/resources/HYDROGUI_msg_en.ts index 88c56649..ad059868 100644 --- a/src/HYDROGUI/resources/HYDROGUI_msg_en.ts +++ b/src/HYDROGUI/resources/HYDROGUI_msg_en.ts @@ -2784,6 +2784,50 @@ Polyline should consist from one not closed curve. POLYLINES Polylines + + POINT + Point + + + POLYLINE + Polyline + + + TOOL_POLYLINE + Tool polyline + + + SPLIT_POLYLINES + Split polylines + + + BY_POINT + By point + + + BY_TOOL + By tool + + + COMPLETE_SPLIT + Complete split + + + + + HYDROGUI_MergePolylinesDlg + + POLYLINES + Polylines + + + MERGE_POLYLINES + Merge polylines + + + + + HYDROGUI_ObjListBox INCLUDE Include -- 2.30.2