diff options
author | Caolán McNamara <caolanm@redhat.com> | 2013-12-09 15:35:32 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-12-09 16:20:35 +0000 |
commit | 98e135931a64025c728b2949eaaa8c5c70c97a2f (patch) | |
tree | 6854c26363f35c34005f6135d6ac472b3269438a /chart2 | |
parent | cf38ab5d8929d99d70dcf517e1c795a3f6f90e9d (diff) |
convert chart elements page to .ui
Change-Id: I7b6dba29622dc1eaa7e12c58084c6ffed19fe886
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/AllLangResTarget_chartcontroller.mk | 1 | ||||
-rw-r--r-- | chart2/UIConfig_chart2.mk | 1 | ||||
-rw-r--r-- | chart2/source/controller/dialogs/ResourceIds.hrc | 1 | ||||
-rw-r--r-- | chart2/source/controller/dialogs/dlg_InsertTitle.cxx | 14 | ||||
-rw-r--r-- | chart2/source/controller/dialogs/res_Titles.cxx | 37 | ||||
-rw-r--r-- | chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx | 76 | ||||
-rw-r--r-- | chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx | 17 | ||||
-rw-r--r-- | chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.src | 82 | ||||
-rw-r--r-- | chart2/source/controller/inc/HelpIds.hrc | 1 | ||||
-rw-r--r-- | chart2/source/controller/inc/dlg_InsertTitle.hxx | 9 | ||||
-rw-r--r-- | chart2/source/controller/inc/res_Titles.hxx (renamed from chart2/source/controller/dialogs/res_Titles.hxx) | 5 | ||||
-rw-r--r-- | chart2/uiconfig/ui/wizelementspage.ui | 493 |
12 files changed, 557 insertions, 180 deletions
diff --git a/chart2/AllLangResTarget_chartcontroller.mk b/chart2/AllLangResTarget_chartcontroller.mk index 7376f1df8414..5a64ac812801 100644 --- a/chart2/AllLangResTarget_chartcontroller.mk +++ b/chart2/AllLangResTarget_chartcontroller.mk @@ -54,7 +54,6 @@ $(eval $(call gb_SrsTarget_add_files,chart2/res,\ chart2/source/controller/dialogs/tp_PointGeometry.src \ chart2/source/controller/dialogs/tp_PolarOptions.src \ chart2/source/controller/dialogs/tp_RangeChooser.src \ - chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.src \ )) $(eval $(call gb_SrsTarget_add_nonlocalized_files,chart2/res,\ diff --git a/chart2/UIConfig_chart2.mk b/chart2/UIConfig_chart2.mk index e3d08d49db01..7bf377e2f9ea 100644 --- a/chart2/UIConfig_chart2.mk +++ b/chart2/UIConfig_chart2.mk @@ -45,6 +45,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/schart,\ chart2/uiconfig/ui/tp_SeriesToAxis \ chart2/uiconfig/ui/tp_Scale \ chart2/uiconfig/ui/tp_Trendline \ + chart2/uiconfig/ui/wizelementspage \ )) # vim: set noet sw=4 ts=4: diff --git a/chart2/source/controller/dialogs/ResourceIds.hrc b/chart2/source/controller/dialogs/ResourceIds.hrc index b1cd82770e12..fa61cce5a16b 100644 --- a/chart2/source/controller/dialogs/ResourceIds.hrc +++ b/chart2/source/controller/dialogs/ResourceIds.hrc @@ -49,7 +49,6 @@ #define TP_AXIS_POSITIONS 904 #define TP_CHARTTYPE 910 #define TP_RANGECHOOSER 911 -#define TP_WIZARD_TITLEANDOBJECTS 912 #define TP_DATA_SOURCE 914 #define TP_3D_SCENEGEOMETRY 915 diff --git a/chart2/source/controller/dialogs/dlg_InsertTitle.cxx b/chart2/source/controller/dialogs/dlg_InsertTitle.cxx index d2ec1674a24d..5e5c83ded6ca 100644 --- a/chart2/source/controller/dialogs/dlg_InsertTitle.cxx +++ b/chart2/source/controller/dialogs/dlg_InsertTitle.cxx @@ -26,20 +26,16 @@ namespace chart { SchTitleDlg::SchTitleDlg(Window* pWindow, const TitleDialogData& rInput ) - : ModalDialog( pWindow, "InsertTitleDialog", "modules/schart/ui/inserttitledlg.ui" ) - , m_apTitleResources( new TitleResources(this,true) ) -{ - this->SetText( ObjectNameProvider::getName(OBJECTTYPE_TITLE,true) ); - m_apTitleResources->writeToResources( rInput ); -} - -SchTitleDlg::~SchTitleDlg() + : ModalDialog(pWindow, "InsertTitleDialog", "modules/schart/ui/inserttitledlg.ui") + , m_xTitleResources(new TitleResources(*this, true)) { + SetText( ObjectNameProvider::getName(OBJECTTYPE_TITLE, true)); + m_xTitleResources->writeToResources( rInput ); } void SchTitleDlg::getResult( TitleDialogData& rOutput ) { - m_apTitleResources->readFromResources( rOutput ); + m_xTitleResources->readFromResources( rOutput ); } } //namespace chart diff --git a/chart2/source/controller/dialogs/res_Titles.cxx b/chart2/source/controller/dialogs/res_Titles.cxx index 98a7f7cc1e8e..3f13b9b5b0e4 100644 --- a/chart2/source/controller/dialogs/res_Titles.cxx +++ b/chart2/source/controller/dialogs/res_Titles.cxx @@ -21,31 +21,28 @@ #include "ResId.hxx" #include "TitleDialogData.hxx" #include <svtools/controldims.hrc> -// for ModalDialog -#include <vcl/dialog.hxx> namespace chart { -TitleResources::TitleResources( Window* pWindow, bool bShowSecondaryAxesTitle ) +TitleResources::TitleResources( VclBuilderContainer& rBuilder, bool bShowSecondaryAxesTitle ) { - ModalDialog* pDialog = reinterpret_cast<ModalDialog*>(pWindow); - pDialog->get( m_pFT_Main, "labelMainTitle" ); - pDialog->get( m_pFT_Sub, "labelSubTitle" ); - pDialog->get( m_pEd_Main, "maintitle" ); - pDialog->get( m_pEd_Sub, "subtitle" ); - - pDialog->get( m_pFT_XAxis, "labelPrimaryXaxis" ); - pDialog->get( m_pFT_YAxis, "labelPrimaryYaxis" ); - pDialog->get( m_pFT_ZAxis, "labelPrimaryZaxis" ); - pDialog->get( m_pEd_XAxis, "primaryXaxis" ); - pDialog->get( m_pEd_YAxis, "primaryYaxis" ); - pDialog->get( m_pEd_ZAxis, "primaryZaxis" ); - - pDialog->get( m_pFT_SecondaryXAxis, "labelSecondaryXAxis" ); - pDialog->get( m_pFT_SecondaryYAxis, "labelSecondaryYAxis" ); - pDialog->get( m_pEd_SecondaryXAxis, "secondaryXaxis" ); - pDialog->get( m_pEd_SecondaryYAxis, "secondaryYaxis" ); + rBuilder.get( m_pFT_Main, "labelMainTitle" ); + rBuilder.get( m_pFT_Sub, "labelSubTitle" ); + rBuilder.get( m_pEd_Main, "maintitle" ); + rBuilder.get( m_pEd_Sub, "subtitle" ); + + rBuilder.get( m_pFT_XAxis, "labelPrimaryXaxis" ); + rBuilder.get( m_pFT_YAxis, "labelPrimaryYaxis" ); + rBuilder.get( m_pFT_ZAxis, "labelPrimaryZaxis" ); + rBuilder.get( m_pEd_XAxis, "primaryXaxis" ); + rBuilder.get( m_pEd_YAxis, "primaryYaxis" ); + rBuilder.get( m_pEd_ZAxis, "primaryZaxis" ); + + rBuilder.get( m_pFT_SecondaryXAxis, "labelSecondaryXAxis" ); + rBuilder.get( m_pFT_SecondaryYAxis, "labelSecondaryYAxis" ); + rBuilder.get( m_pEd_SecondaryXAxis, "secondaryXaxis" ); + rBuilder.get( m_pEd_SecondaryYAxis, "secondaryYaxis" ); m_pFT_SecondaryXAxis->Show( bShowSecondaryAxesTitle ); m_pFT_SecondaryYAxis->Show( bShowSecondaryAxesTitle ); diff --git a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx index 727ab0eb2ae8..ba62a0750969 100644 --- a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx +++ b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx @@ -38,42 +38,24 @@ using namespace ::com::sun::star::chart2; TitlesAndObjectsTabPage::TitlesAndObjectsTabPage( svt::OWizardMachine* pParent , const uno::Reference< XChartDocument >& xChartModel , const uno::Reference< uno::XComponentContext >& xContext ) - : OWizardPage( pParent, SchResId(TP_WIZARD_TITLEANDOBJECTS) ) - , m_aFT_TitleDescription( this, SchResId( FT_TITLEDESCRIPTION ) ) - , m_aFL_Vertical( this, SchResId( FL_VERTICAL ) ) - , m_apTitleResources( new TitleResources(this,false) ) - , m_apLegendPositionResources( new oldLegendPositionResources(this,xContext) ) - , m_aFL_Grids( this, SchResId( FL_GRIDS ) ) - , m_aCB_Grid_X( this, SchResId( CB_X_SECONDARY ) ) - , m_aCB_Grid_Y( this, SchResId( CB_Y_SECONDARY ) ) - , m_aCB_Grid_Z( this, SchResId( CB_Z_SECONDARY ) ) - , m_xChartModel( xChartModel ) - , m_xCC( xContext ) - , m_bCommitToModel( true ) + : OWizardPage(pParent, "WizElementsPage", "modules/schart/ui/wizelementspage.ui") + , m_xTitleResources(new TitleResources(*this, false)) + , m_xLegendPositionResources(new LegendPositionResources(*this, xContext)) + , m_xChartModel(xChartModel) + , m_xCC(xContext) + , m_bCommitToModel(true) , m_aTimerTriggeredControllerLock( uno::Reference< frame::XModel >( m_xChartModel, uno::UNO_QUERY ) ) { - FreeResource(); + get(m_pCB_Grid_X, "x"); + get(m_pCB_Grid_Y, "y"); + get(m_pCB_Grid_Z, "z"); - this->SetText( SCH_RESSTR( STR_PAGE_CHART_ELEMENTS ) ); + m_xTitleResources->SetUpdateDataHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); + m_xLegendPositionResources->SetChangeHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); - Font aFont( m_aFT_TitleDescription.GetControlFont() ); - aFont.SetWeight( WEIGHT_BOLD ); - m_aFT_TitleDescription.SetControlFont( aFont ); - - m_aCB_Grid_X.SetHelpId( HID_SCH_CB_XGRID ); - m_aCB_Grid_Y.SetHelpId( HID_SCH_CB_YGRID ); - m_aCB_Grid_Z.SetHelpId( HID_SCH_CB_ZGRID ); - - m_apTitleResources->SetUpdateDataHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); - m_apLegendPositionResources->SetChangeHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); - - m_aCB_Grid_X.SetToggleHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); - m_aCB_Grid_Y.SetToggleHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); - m_aCB_Grid_Z.SetToggleHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); -} - -TitlesAndObjectsTabPage::~TitlesAndObjectsTabPage() -{ + m_pCB_Grid_X->SetToggleHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); + m_pCB_Grid_Y->SetToggleHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); + m_pCB_Grid_Z->SetToggleHdl( LINK( this, TitlesAndObjectsTabPage, ChangeHdl )); } void TitlesAndObjectsTabPage::initializePage() @@ -84,12 +66,12 @@ void TitlesAndObjectsTabPage::initializePage() { TitleDialogData aTitleInput; aTitleInput.readFromModel( uno::Reference< frame::XModel >( m_xChartModel, uno::UNO_QUERY) ); - m_apTitleResources->writeToResources( aTitleInput ); + m_xTitleResources->writeToResources( aTitleInput ); } //init legend { - m_apLegendPositionResources->writeToResources( uno::Reference< frame::XModel >( m_xChartModel, uno::UNO_QUERY) ); + m_xLegendPositionResources->writeToResources( uno::Reference< frame::XModel >( m_xChartModel, uno::UNO_QUERY) ); } //init grid checkboxes @@ -99,12 +81,12 @@ void TitlesAndObjectsTabPage::initializePage() uno::Sequence< sal_Bool > aExistenceList; AxisHelper::getAxisOrGridPossibilities( aPossibilityList, xDiagram, sal_False ); AxisHelper::getAxisOrGridExcistence( aExistenceList, xDiagram, sal_False ); - m_aCB_Grid_X.Enable( aPossibilityList[0] ); - m_aCB_Grid_Y.Enable( aPossibilityList[1] ); - m_aCB_Grid_Z.Enable( aPossibilityList[2] ); - m_aCB_Grid_X.Check( aExistenceList[0] ); - m_aCB_Grid_Y.Check( aExistenceList[1] ); - m_aCB_Grid_Z.Check( aExistenceList[2] ); + m_pCB_Grid_X->Enable( aPossibilityList[0] ); + m_pCB_Grid_Y->Enable( aPossibilityList[1] ); + m_pCB_Grid_Z->Enable( aPossibilityList[2] ); + m_pCB_Grid_X->Check( aExistenceList[0] ); + m_pCB_Grid_Y->Check( aExistenceList[1] ); + m_pCB_Grid_Z->Check( aExistenceList[2] ); } m_bCommitToModel = true; @@ -112,7 +94,7 @@ void TitlesAndObjectsTabPage::initializePage() sal_Bool TitlesAndObjectsTabPage::commitPage( ::svt::WizardTypes::CommitPageReason /*eReason*/ ) { - if( m_apTitleResources->IsModified() ) //titles may have changed in the meanwhile + if( m_xTitleResources->IsModified() ) //titles may have changed in the meanwhile commitToModel(); return sal_True;//return false if this page should not be left } @@ -127,14 +109,14 @@ void TitlesAndObjectsTabPage::commitToModel() //commit title changes to model { TitleDialogData aTitleOutput; - m_apTitleResources->readFromResources( aTitleOutput ); + m_xTitleResources->readFromResources( aTitleOutput ); aTitleOutput.writeDifferenceToModel( xModel, m_xCC ); - m_apTitleResources->ClearModifyFlag(); + m_xTitleResources->ClearModifyFlag(); } //commit legend changes to model { - m_apLegendPositionResources->writeToModel( xModel ); + m_xLegendPositionResources->writeToModel( xModel ); } //commit grid changes to model @@ -143,9 +125,9 @@ void TitlesAndObjectsTabPage::commitToModel() uno::Sequence< sal_Bool > aOldExistenceList; AxisHelper::getAxisOrGridExcistence( aOldExistenceList, xDiagram, sal_False ); uno::Sequence< sal_Bool > aNewExistenceList(aOldExistenceList); - aNewExistenceList[0]=m_aCB_Grid_X.IsChecked(); - aNewExistenceList[1]=m_aCB_Grid_Y.IsChecked(); - aNewExistenceList[2]=m_aCB_Grid_Z.IsChecked(); + aNewExistenceList[0] = m_pCB_Grid_X->IsChecked(); + aNewExistenceList[1] = m_pCB_Grid_Y->IsChecked(); + aNewExistenceList[2] = m_pCB_Grid_Z->IsChecked(); AxisHelper::changeVisibilityOfGrids( xDiagram , aOldExistenceList, aNewExistenceList, m_xCC ); } diff --git a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx index e5e48bf8b83b..53e14639db31 100644 --- a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx +++ b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.hxx @@ -36,7 +36,7 @@ namespace chart /** */ class TitleResources; -class oldLegendPositionResources; +class LegendPositionResources; class TitlesAndObjectsTabPage : public svt::OWizardPage { public: @@ -45,7 +45,6 @@ public: ::com::sun::star::chart2::XChartDocument >& xChartModel , const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& xContext ); - virtual ~TitlesAndObjectsTabPage(); virtual void initializePage(); virtual sal_Bool commitPage( ::svt::WizardTypes::CommitPageReason eReason ); @@ -56,16 +55,12 @@ protected: DECL_LINK( ChangeHdl, void* ); protected: - FixedText m_aFT_TitleDescription; - FixedLine m_aFL_Vertical; + boost::scoped_ptr< TitleResources > m_xTitleResources; + boost::scoped_ptr< LegendPositionResources > m_xLegendPositionResources; - boost::scoped_ptr< TitleResources > m_apTitleResources; - boost::scoped_ptr< oldLegendPositionResources > m_apLegendPositionResources; - - FixedLine m_aFL_Grids; - CheckBox m_aCB_Grid_X; - CheckBox m_aCB_Grid_Y; - CheckBox m_aCB_Grid_Z; + CheckBox* m_pCB_Grid_X; + CheckBox* m_pCB_Grid_Y; + CheckBox* m_pCB_Grid_Z; ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XChartDocument > m_xChartModel; diff --git a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.src b/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.src deleted file mode 100644 index 28a6dcaa4a09..000000000000 --- a/chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.src +++ /dev/null @@ -1,82 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * This Source Code Form is subject to the terms of the Mozilla Public - * License, v. 2.0. If a copy of the MPL was not distributed with this - * file, You can obtain one at http://mozilla.org/MPL/2.0/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ -#include "HelpIds.hrc" -#include "tp_Wizard_TitlesAndObjects.hrc" -#include "res_Titlesx.hrc" -#include "res_SecondaryAxisCheckBoxes.hrc" -#include "dlg_CreationWizard.hrc" -#include "res_LegendPosition.hrc" -#include <svtools/controldims.hrc> - -#define MASKCOLOR MaskColor = Color { Red = 0xC000 ; Green = 0xC000 ; Blue = 0xC000 ; } -#define WIZ_TITLES_WIDTH 130 - -#define WIZ_POSX1 6 -#define WIZ_POSX1_A (WIZ_POSX1) -#define WIZ_POSX_VERTICAL (WIZ_POSX1+WIZ_TITLES_WIDTH+6) -#define WIZ_POSX2 (WIZ_POSX_VERTICAL+RSC_CD_FIXEDLINE_WIDTH+2) -#define WIZ_POSX2_A (WIZ_POSX2) -#define WIZ_POSX2_B (WIZ_POSX2_A+9) - -#define WIZ_COMPLETE_FIXEDLINE_WIDTH (CHART_WIZARD_PAGEWIDTH-10-(WIZ_POSX1)) -#define WIZ_VERTICAL_FIXEDLINE_HEIGHT ( 88 ) - -#define WIZ_POSY1 8 -#define WIZ_POSY1_A (WIZ_POSY1 + RSC_CD_FIXEDTEXT_HEIGHT +5) -#define WIZ_POSY1_B (WIZ_POSY1_A+ RSC_CD_FIXEDTEXT_HEIGHT +7) - -#define WIZ_POSY2 110 -#define WIZ_POSY_GRID (WIZ_POSY2+RSC_CD_FIXEDTEXT_HEIGHT+6) - -TabPage TP_WIZARD_TITLEANDOBJECTS -{ - HelpID = "chart2:TabPage:TP_WIZARD_TITLEANDOBJECTS"; - Hide = TRUE ; - SVLook = TRUE ; - Size = MAP_APPFONT ( CHART_WIZARD_PAGEWIDTH , CHART_WIZARD_PAGEHEIGHT ) ; - - FixedText FT_TITLEDESCRIPTION - { - Pos = MAP_APPFONT ( WIZ_POSX1 , WIZ_POSY1 ) ; - Size = MAP_APPFONT ( WIZ_COMPLETE_FIXEDLINE_WIDTH , RSC_CD_FIXEDTEXT_HEIGHT ) ; - Text [ en-US ] = "Choose titles, legend, and grid settings"; - }; - FixedLine FL_VERTICAL - { - Pos = MAP_APPFONT ( WIZ_POSX_VERTICAL , WIZ_POSY1+3+RSC_CD_FIXEDLINE_HEIGHT ) ; - Size = MAP_APPFONT ( RSC_CD_FIXEDLINE_WIDTH, WIZ_VERTICAL_FIXEDLINE_HEIGHT ) ; - Vert = TRUE ; - }; - - TITLES(WIZ_POSX1_A,WIZ_POSY1_A,WIZ_TITLES_WIDTH,0,0) - RESOURCE_LEGENDDISPLAY( WIZ_POSX2_A, WIZ_POSY1_A ) - RESOURCE_LEGENDPOSITION( WIZ_POSX2_B, WIZ_POSY1_B ) - - - FixedLine FL_GRIDS - { - Pos = MAP_APPFONT ( WIZ_POSX1 , WIZ_POSY2 ) ; - Size = MAP_APPFONT ( WIZ_COMPLETE_FIXEDLINE_WIDTH , RSC_CD_FIXEDLINE_HEIGHT ) ; - Text [ en-US ] = "Display grids"; - }; - - SECONDARYAXISCHECKBOXES( WIZ_POSX1_A, WIZ_POSY_GRID, 43, 0 ) -}; - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/chart2/source/controller/inc/HelpIds.hrc b/chart2/source/controller/inc/HelpIds.hrc index f2b7c1fd5ad7..75f3a1240d72 100644 --- a/chart2/source/controller/inc/HelpIds.hrc +++ b/chart2/source/controller/inc/HelpIds.hrc @@ -120,7 +120,6 @@ #define HID_3D_VIEW "CHART2_HID_3D_VIEW" #define HID_DIAGRAM_DATA "CHART2_HID_DIAGRAM_DATA" #define HID_INSERT_STATISTICS "CHART2_HID_INSERT_STATISTICS" -#define HID_INSERT_TITLE "CHART2_HID_INSERT_TITLE" #define HID_INSERT_CHART_LEGEND "CHART2_HID_INSERT_CHART_LEGEND" #define HID_INSERT_DESCRIPTION "CHART2_HID_INSERT_DESCRIPTION" diff --git a/chart2/source/controller/inc/dlg_InsertTitle.hxx b/chart2/source/controller/inc/dlg_InsertTitle.hxx index c0d05f14b64d..b992606512d6 100644 --- a/chart2/source/controller/inc/dlg_InsertTitle.hxx +++ b/chart2/source/controller/inc/dlg_InsertTitle.hxx @@ -19,23 +19,20 @@ #ifndef INCLUDED_CHART2_SOURCE_CONTROLLER_INC_DLG_INSERTTITLE_HXX #define INCLUDED_CHART2_SOURCE_CONTROLLER_INC_DLG_INSERTTITLE_HXX -#include "TitleDialogData.hxx" +#include "res_Titles.hxx" #include <vcl/dialog.hxx> #include <vcl/button.hxx> -//for auto_ptr -#include <memory> +#include <boost/scoped_ptr.hpp> namespace chart { -class TitleResources; class SchTitleDlg : public ModalDialog { private: - ::std::auto_ptr< TitleResources > m_apTitleResources; + boost::scoped_ptr< TitleResources > m_xTitleResources; public: SchTitleDlg( Window* pParent, const TitleDialogData& rInput ); - virtual ~SchTitleDlg(); void getResult( TitleDialogData& rOutput ); }; diff --git a/chart2/source/controller/dialogs/res_Titles.hxx b/chart2/source/controller/inc/res_Titles.hxx index b69deebf1198..dbfb065ee910 100644 --- a/chart2/source/controller/dialogs/res_Titles.hxx +++ b/chart2/source/controller/inc/res_Titles.hxx @@ -20,7 +20,8 @@ #define INCLUDED_CHART2_SOURCE_CONTROLLER_DIALOGS_RES_TITLES_HXX #include "TitleDialogData.hxx" -#include <vcl/edit.hxx> +#include <vcl/builder.hxx> +#include <vcl/fixed.hxx> #include <vcl/fixed.hxx> namespace chart @@ -29,7 +30,7 @@ namespace chart class TitleResources { public: - TitleResources( Window* pParent, bool bShowSecondaryAxesTitle ); + TitleResources(VclBuilderContainer& rParent, bool bShowSecondaryAxesTitle); virtual ~TitleResources(); void writeToResources( const TitleDialogData& rInput ); diff --git a/chart2/uiconfig/ui/wizelementspage.ui b/chart2/uiconfig/ui/wizelementspage.ui new file mode 100644 index 000000000000..6d6c0fb4604b --- /dev/null +++ b/chart2/uiconfig/ui/wizelementspage.ui @@ -0,0 +1,493 @@ +<?xml version="1.0" encoding="UTF-8"?> +<interface> + <!-- interface-requires gtk+ 3.6 --> + <object class="GtkBox" id="WizElementsPage"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="border_width">6</property> + <property name="orientation">vertical</property> + <property name="spacing">12</property> + <child> + <object class="GtkFrame" id="frameAxes"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="label_xalign">0</property> + <property name="shadow_type">none</property> + <child> + <object class="GtkAlignment" id="alignment1"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="top_padding">6</property> + <property name="left_padding">12</property> + <child> + <object class="GtkGrid" id="grid2"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="column_spacing">18</property> + <child> + <object class="GtkGrid" id="grid4"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="hexpand">True</property> + <property name="row_spacing">6</property> + <property name="column_spacing">12</property> + <child> + <object class="GtkLabel" id="labelPrimaryXaxis"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">_X axis</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">primaryXaxis</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">2</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkLabel" id="labelPrimaryYaxis"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">_Y axis</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">primaryYaxis</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">3</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkLabel" id="labelPrimaryZaxis"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">_Z axis</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">primaryZaxis</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">4</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkEntry" id="primaryXaxis"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="hexpand">True</property> + <property name="invisible_char">●</property> + <property name="invisible_char_set">True</property> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">2</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkEntry" id="primaryYaxis"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="hexpand">True</property> + <property name="invisible_char">●</property> + <property name="invisible_char_set">True</property> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">3</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkEntry" id="primaryZaxis"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="hexpand">True</property> + <property name="invisible_char">●</property> + <property name="invisible_char_set">True</property> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">4</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkLabel" id="labelMainTitle"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">_Title</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">maintitle</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkLabel" id="labelSubTitle"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">_Subtitle</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">subtitle</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">1</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkEntry" id="maintitle"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="hexpand">True</property> + <property name="invisible_char">●</property> + <property name="invisible_char_set">True</property> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkEntry" id="subtitle"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="hexpand">True</property> + <property name="invisible_char">●</property> + <property name="invisible_char_set">True</property> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">1</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkLabel" id="labelSecondaryXAxis"> + <property name="can_focus">False</property> + <property name="no_show_all">True</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">X _axis</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">secondaryXaxis</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">5</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkLabel" id="labelSecondaryYAxis"> + <property name="can_focus">False</property> + <property name="no_show_all">True</property> + <property name="xalign">0</property> + <property name="label" translatable="yes">Y ax_is</property> + <property name="use_underline">True</property> + <property name="mnemonic_widget">secondaryYaxis</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">6</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkEntry" id="secondaryXaxis"> + <property name="can_focus">True</property> + <property name="no_show_all">True</property> + <property name="hexpand">True</property> + <property name="invisible_char">●</property> + <property name="invisible_char_set">True</property> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">5</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkEntry" id="secondaryYaxis"> + <property name="can_focus">True</property> + <property name="no_show_all">True</property> + <property name="hexpand">True</property> + <property name="invisible_char">●</property> + <property name="invisible_char_set">True</property> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">6</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkGrid" id="grid5"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="row_spacing">6</property> + <child> + <object class="GtkCheckButton" id="show"> + <property name="label" translatable="yes">_Display legend</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">False</property> + <property name="use_underline">True</property> + <property name="xalign">0</property> + <property name="draw_indicator">True</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkAlignment" id="alignment3"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="left_padding">12</property> + <child> + <object class="GtkGrid" id="grid6"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="row_spacing">6</property> + <child> + <object class="GtkRadioButton" id="left"> + <property name="label" translatable="yes">_Left</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">False</property> + <property name="use_underline">True</property> + <property name="xalign">0</property> + <property name="draw_indicator">True</property> + <property name="group">right</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkRadioButton" id="right"> + <property name="label" translatable="yes">_Right</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">False</property> + <property name="use_underline">True</property> + <property name="xalign">0</property> + <property name="draw_indicator">True</property> + <property name="group">top</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">1</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkRadioButton" id="top"> + <property name="label" translatable="yes">_Top</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">False</property> + <property name="use_underline">True</property> + <property name="xalign">0</property> + <property name="draw_indicator">True</property> + <property name="group">bottom</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">2</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkRadioButton" id="bottom"> + <property name="label" translatable="yes">_Bottom</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">False</property> + <property name="use_underline">True</property> + <property name="xalign">0</property> + <property name="draw_indicator">True</property> + <property name="group">left</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">3</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + </object> + </child> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">1</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + </object> + </child> + </object> + </child> + <child type="label"> + <object class="GtkLabel" id="Axe"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="label" translatable="yes">Choose titles, legend, and grid settings</property> + <attributes> + <attribute name="weight" value="bold"/> + </attributes> + </object> + </child> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">1</property> + </packing> + </child> + <child> + <object class="GtkFrame" id="frameSecondaryAxes"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="label_xalign">0</property> + <property name="shadow_type">none</property> + <child> + <object class="GtkAlignment" id="alignment2"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="top_padding">6</property> + <property name="left_padding">12</property> + <child> + <object class="GtkGrid" id="grid3"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="row_spacing">6</property> + <property name="column_spacing">12</property> + <child> + <object class="GtkCheckButton" id="x"> + <property name="label" translatable="yes">X axis</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">False</property> + <property name="use_underline">True</property> + <property name="xalign">0</property> + <property name="draw_indicator">True</property> + </object> + <packing> + <property name="left_attach">0</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkCheckButton" id="y"> + <property name="label" translatable="yes">Y ax_is</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">False</property> + <property name="use_underline">True</property> + <property name="xalign">0</property> + <property name="draw_indicator">True</property> + </object> + <packing> + <property name="left_attach">1</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + <child> + <object class="GtkCheckButton" id="z"> + <property name="label" translatable="yes">Z axi_s</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="receives_default">False</property> + <property name="use_underline">True</property> + <property name="xalign">0</property> + <property name="draw_indicator">True</property> + </object> + <packing> + <property name="left_attach">2</property> + <property name="top_attach">0</property> + <property name="width">1</property> + <property name="height">1</property> + </packing> + </child> + </object> + </child> + </object> + </child> + <child type="label"> + <object class="GtkLabel" id="label2"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="label" translatable="yes">Display grids</property> + <attributes> + <attribute name="weight" value="bold"/> + </attributes> + </object> + </child> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">2</property> + </packing> + </child> + </object> +</interface> |