[Libreoffice-commits] core.git: 2 commits - svx/source sw/AllLangResTarget_sw.mk sw/inc sw/source sw/uiconfig sw/UIConfig_swriter.mk
Caolán McNamara
caolanm at redhat.com
Thu Apr 25 03:33:38 PDT 2013
svx/source/dialog/txenctab.src | 2
sw/AllLangResTarget_sw.mk | 1
sw/UIConfig_swriter.mk | 1
sw/inc/dialog.hrc | 1
sw/inc/helpid.h | 1
sw/inc/swabstdlg.hxx | 2
sw/source/ui/dialog/ascfldlg.cxx | 129 ++++--------
sw/source/ui/dialog/ascfldlg.hrc | 36 ---
sw/source/ui/dialog/ascfldlg.src | 140 -------------
sw/source/ui/dialog/swdlgfact.cxx | 19 -
sw/source/ui/dialog/swdlgfact.hxx | 2
sw/source/ui/inc/ascfldlg.hxx | 23 --
sw/source/ui/uno/SwXFilterOptions.cxx | 3
sw/uiconfig/swriter/ui/asciifilterdialog.ui | 293 ++++++++++++++++++++++++++++
14 files changed, 362 insertions(+), 291 deletions(-)
New commits:
commit dc900869e5f530000a3036827328bc6fecebddd9
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Apr 25 10:50:40 2013 +0100
convert ascii filter dialog to .ui
Change-Id: I0e4f45d9e74fd2ae04defa75fce225d61295cdbc
diff --git a/sw/AllLangResTarget_sw.mk b/sw/AllLangResTarget_sw.mk
index 69a6aaa..6d63cea 100644
--- a/sw/AllLangResTarget_sw.mk
+++ b/sw/AllLangResTarget_sw.mk
@@ -94,7 +94,6 @@ $(eval $(call gb_SrsTarget_add_files,sw/res,\
sw/source/ui/dbui/mmpreparemergepage.src \
sw/source/ui/dbui/selectdbtabledialog.src \
sw/source/ui/dialog/abstract.src \
- sw/source/ui/dialog/ascfldlg.src \
sw/source/ui/dialog/dialog.src \
sw/source/ui/dialog/regionsw.src \
sw/source/ui/dochdl/dochdl.src \
diff --git a/sw/UIConfig_swriter.mk b/sw/UIConfig_swriter.mk
index 5b889c7..a4349e5 100644
--- a/sw/UIConfig_swriter.mk
+++ b/sw/UIConfig_swriter.mk
@@ -59,6 +59,7 @@ $(eval $(call gb_UIConfig_add_toolbarfiles,modules/swriter,\
))
$(eval $(call gb_UIConfig_add_uifiles,modules/swriter,\
+ sw/uiconfig/swriter/ui/asciifilterdialog \
sw/uiconfig/swriter/ui/autoformattable \
sw/uiconfig/swriter/ui/autotext \
sw/uiconfig/swriter/ui/bibliographyentry \
diff --git a/sw/inc/dialog.hrc b/sw/inc/dialog.hrc
index 806f1c7..802a66f 100644
--- a/sw/inc/dialog.hrc
+++ b/sw/inc/dialog.hrc
@@ -27,7 +27,6 @@
#define DLG_PASSWD (RC_DIALOG_BEGIN + 3)
#define DLG_INSERT_ABSTRACT (RC_DIALOG_BEGIN + 8)
-#define DLG_ASCII_FILTER (RC_DIALOG_BEGIN + 9)
#define RID_QB_SPELL_CONTINUE (RC_DIALOG_BEGIN + 11)
#define STR_SPELLING_COMPLETED (RC_DIALOG_BEGIN + 12)
diff --git a/sw/inc/helpid.h b/sw/inc/helpid.h
index ad22fb0..5b114f8 100644
--- a/sw/inc/helpid.h
+++ b/sw/inc/helpid.h
@@ -139,7 +139,6 @@
#define HID_FILEDLG_WIZDOKU "SW_HID_FILEDLG_WIZDOKU"
#define HID_MULTI_TOX_DLG "SW_HID_MULTI_TOX_DLG"
-#define HID_ASCII_FILTER "SW_HID_ASCII_FILTER"
#define HID_GLBLTREE_EDIT_LINK "SW_HID_GLBLTREE_EDIT_LINK"
#define HID_FORMAT_NAME_OBJECT_NAME "SW_HID_FORMAT_NAME_OBJECT_NAME"
#define HID_REFSELECTION_TOOLTIP "SW_HID_REFSELECTION_TOOLTIP" // #i83479#
diff --git a/sw/inc/swabstdlg.hxx b/sw/inc/swabstdlg.hxx
index 8992dce..c0ff6ed 100644
--- a/sw/inc/swabstdlg.hxx
+++ b/sw/inc/swabstdlg.hxx
@@ -334,7 +334,7 @@ public:
virtual AbstractSwInsertAbstractDlg * CreateSwInsertAbstractDlg(Window* pParent) = 0; // add for SwInsertAbstractDlg
virtual AbstractSwAsciiFilterDlg* CreateSwAsciiFilterDlg ( Window* pParent, SwDocShell& rDocSh,
- SvStream* pStream, int nResId ) = 0;// add for SwAsciiFilterDlg
+ SvStream* pStream ) = 0;// add for SwAsciiFilterDlg
virtual VclAbstractDialog * CreateSwInsertBookmarkDlg( Window *pParent, SwWrtShell &rSh, SfxRequest& rReq, int nResId ) = 0;// add for SwInsertBookmarkDlg
virtual AbstractSwBreakDlg * CreateSwBreakDlg(Window *pParent, SwWrtShell &rSh) = 0; // add for SwBreakDlg
diff --git a/sw/source/ui/dialog/ascfldlg.cxx b/sw/source/ui/dialog/ascfldlg.cxx
index 4dd1c66..b808142 100644
--- a/sw/source/ui/dialog/ascfldlg.cxx
+++ b/sw/source/ui/dialog/ascfldlg.cxx
@@ -38,7 +38,6 @@
#include <doc.hxx>
#include <dialog.hrc>
-#include <ascfldlg.hrc>
#include "vcl/metric.hxx"
@@ -52,25 +51,20 @@ const sal_uInt16 nDialogExtraDataLen = 11; // 12345678901
SwAsciiFilterDlg::SwAsciiFilterDlg( Window* pParent, SwDocShell& rDocSh,
SvStream* pStream )
- : SfxModalDialog( pParent, SW_RES( DLG_ASCII_FILTER )),
- aFL( this, SW_RES( FL_1 )),
- aCharSetFT( this, SW_RES( FT_CHARSET )),
- aCharSetLB( this, SW_RES( LB_CHARSET )),
- aFontFT( this, SW_RES( FT_FONT )),
- aFontLB( this, SW_RES( LB_FONT )),
- aLanguageFT( this, SW_RES( FT_LANGUAGE )),
- aLanguageLB( this, SW_RES( LB_LANGUAGE )),
- aCRLF_FT( this, SW_RES( FT_CRLF )),
- aCRLF_RB( this, SW_RES( RB_CRLF )),
- aCR_RB( this, SW_RES( RB_CR )),
- aLF_RB( this, SW_RES( RB_LF )),
- aOkPB( this, SW_RES( PB_OK )),
- aCancelPB( this, SW_RES( PB_CANCEL )),
- aHelpPB( this, SW_RES( PB_HELP )),
- sSystemCharSet( SW_RES( STR_SYS_CHARSET )),
- bSaveLineStatus( true )
+ : SfxModalDialog(pParent, "AsciiFilterDialog", "modules/swriter/ui/asciifilterdialog.ui")
+ , m_bSaveLineStatus(true)
{
- FreeResource();
+ get(m_pCharSetLB, "charset");
+ m_pCharSetLB->SetStyle(m_pCharSetLB->GetStyle() | WB_SORT);
+ get(m_pFontFT, "fontft");
+ get(m_pFontLB, "font");
+ m_pFontLB->SetStyle(m_pFontLB->GetStyle() | WB_SORT);
+ get(m_pLanguageFT, "languageft");
+ get(m_pLanguageLB, "language");
+ m_pLanguageLB->SetStyle(m_pLanguageLB->GetStyle() | WB_SORT);
+ get(m_pCRLF_RB, "crlf");
+ get(m_pCR_RB, "cr");
+ get(m_pLF_RB, "lf");
SwAsciiOptions aOpt;
{
@@ -169,8 +163,8 @@ SwAsciiFilterDlg::SwAsciiFilterDlg( Window* pParent, SwDocShell& rDocSh,
}
}
- aLanguageLB.SetLanguageList( LANG_LIST_ALL, sal_True, sal_False );
- aLanguageLB.SelectLanguage( aOpt.GetLanguage() );
+ m_pLanguageLB->SetLanguageList( LANG_LIST_ALL, sal_True, sal_False );
+ m_pLanguageLB->SelectLanguage( aOpt.GetLanguage() );
}
{
@@ -199,7 +193,7 @@ SwAsciiFilterDlg::SwAsciiFilterDlg( Window* pParent, SwDocShell& rDocSh,
for( std::set< String >::const_iterator it = aFontNames.begin();
it != aFontNames.end(); ++it )
{
- aFontLB.InsertEntry( *it );
+ m_pFontLB->InsertEntry( *it );
}
if( !aOpt.GetFontName().Len() )
@@ -209,7 +203,7 @@ SwAsciiFilterDlg::SwAsciiFilterDlg( Window* pParent, SwDocShell& rDocSh,
aOpt.SetFontName(aTmpFont.GetName());
}
- aFontLB.SelectEntry( aOpt.GetFontName() );
+ m_pFontLB->SelectEntry( aOpt.GetFontName() );
if( bDelPrinter )
delete pPrt;
@@ -219,48 +213,27 @@ SwAsciiFilterDlg::SwAsciiFilterDlg( Window* pParent, SwDocShell& rDocSh,
}
else
{
- // hide the used Control for the Export and move the
- // other behind the charset controls
- aFontFT.Hide();
- aFontLB.Hide();
- aLanguageFT.Hide();
- aLanguageLB.Hide();
-
- long nY = aFontFT.GetPosPixel().Y() + 1;
- Point aPos( aCRLF_FT.GetPosPixel() ); aPos.Y() = nY;
- aCRLF_FT.SetPosPixel( aPos );
-
- aPos = aCRLF_RB.GetPosPixel(); aPos.Y() = nY;
- aCRLF_RB.SetPosPixel( aPos );
-
- aPos = aCR_RB.GetPosPixel(); aPos.Y() = nY;
- aCR_RB.SetPosPixel( aPos );
-
- aPos = aLF_RB.GetPosPixel(); aPos.Y() = nY;
- aLF_RB.SetPosPixel( aPos );
-
- Size aSize = GetSizePixel();
- Size aTmpSz( 6, 6 );
- aTmpSz = LogicToPixel(aTmpSz, MAP_APPFONT);
- aSize.Height() = aHelpPB.GetPosPixel().Y() +
- aHelpPB.GetSizePixel().Height() + aTmpSz.Height();
- SetSizePixel( aSize );
+ // hide the unused Controls for Export
+ m_pFontFT->Hide();
+ m_pFontLB->Hide();
+ m_pLanguageFT->Hide();
+ m_pLanguageLB->Hide();
}
// initialise character set
- aCharSetLB.FillFromTextEncodingTable( pStream != NULL );
- aCharSetLB.SelectTextEncoding( aOpt.GetCharSet() );
+ m_pCharSetLB->FillFromTextEncodingTable( pStream != NULL );
+ m_pCharSetLB->SelectTextEncoding( aOpt.GetCharSet() );
- aCharSetLB.SetSelectHdl( LINK( this, SwAsciiFilterDlg, CharSetSelHdl ));
- aCRLF_RB.SetToggleHdl( LINK( this, SwAsciiFilterDlg, LineEndHdl ));
- aLF_RB.SetToggleHdl( LINK( this, SwAsciiFilterDlg, LineEndHdl ));
- aCR_RB.SetToggleHdl( LINK( this, SwAsciiFilterDlg, LineEndHdl ));
+ m_pCharSetLB->SetSelectHdl( LINK( this, SwAsciiFilterDlg, CharSetSelHdl ));
+ m_pCRLF_RB->SetToggleHdl( LINK( this, SwAsciiFilterDlg, LineEndHdl ));
+ m_pLF_RB->SetToggleHdl( LINK( this, SwAsciiFilterDlg, LineEndHdl ));
+ m_pCR_RB->SetToggleHdl( LINK( this, SwAsciiFilterDlg, LineEndHdl ));
SetCRLF( aOpt.GetParaFlags() );
- aCRLF_RB.SaveValue();
- aLF_RB.SaveValue();
- aCR_RB.SaveValue();
+ m_pCRLF_RB->SaveValue();
+ m_pLF_RB->SaveValue();
+ m_pCR_RB->SaveValue();
}
@@ -271,13 +244,13 @@ SwAsciiFilterDlg::~SwAsciiFilterDlg()
void SwAsciiFilterDlg::FillOptions( SwAsciiOptions& rOptions )
{
- sal_uLong nCCode = aCharSetLB.GetSelectTextEncoding();
+ sal_uLong nCCode = m_pCharSetLB->GetSelectTextEncoding();
String sFont;
sal_uLong nLng = 0;
- if( aFontLB.IsVisible() )
+ if( m_pFontLB->IsVisible() )
{
- sFont = aFontLB.GetSelectEntry();
- nLng = (sal_uLong)aLanguageLB.GetSelectLanguage();
+ sFont = m_pFontLB->GetSelectEntry();
+ nLng = (sal_uLong)m_pLanguageLB->GetSelectLanguage();
}
rOptions.SetFontName( sFont );
@@ -291,7 +264,7 @@ void SwAsciiFilterDlg::FillOptions( SwAsciiOptions& rOptions )
if( sData.Len() )
{
const OUString sFindNm = OUString::createFromAscii(
- aFontLB.IsVisible() ? sDialogImpExtraData
+ m_pFontLB->IsVisible() ? sDialogImpExtraData
: sDialogExpExtraData);
sal_uInt16 nEnd, nStt = GetExtraData().Search( sFindNm );
if( STRING_NOTFOUND != nStt )
@@ -314,18 +287,18 @@ void SwAsciiFilterDlg::SetCRLF( LineEnd eEnd )
{
switch( eEnd )
{
- case LINEEND_CR: aCR_RB.Check(); break;
- case LINEEND_CRLF: aCRLF_RB.Check(); break;
- case LINEEND_LF: aLF_RB.Check(); break;
+ case LINEEND_CR: m_pCR_RB->Check(); break;
+ case LINEEND_CRLF: m_pCRLF_RB->Check(); break;
+ case LINEEND_LF: m_pLF_RB->Check(); break;
}
}
LineEnd SwAsciiFilterDlg::GetCRLF() const
{
LineEnd eEnd;
- if( aCR_RB.IsChecked() )
+ if( m_pCR_RB->IsChecked() )
eEnd = LINEEND_CR;
- else if( aLF_RB.IsChecked() )
+ else if( m_pLF_RB->IsChecked() )
eEnd = LINEEND_LF;
else
eEnd = LINEEND_CRLF;
@@ -335,8 +308,8 @@ LineEnd SwAsciiFilterDlg::GetCRLF() const
IMPL_LINK( SwAsciiFilterDlg, CharSetSelHdl, SvxTextEncodingBox*, pBox )
{
LineEnd eOldEnd = GetCRLF(), eEnd = (LineEnd)-1;
- LanguageType nLng = aFontLB.IsVisible()
- ? aLanguageLB.GetSelectLanguage()
+ LanguageType nLng = m_pFontLB->IsVisible()
+ ? m_pLanguageLB->GetSelectLanguage()
: LANGUAGE_SYSTEM,
nOldLng = nLng;
@@ -387,7 +360,7 @@ IMPL_LINK( SwAsciiFilterDlg, CharSetSelHdl, SvxTextEncodingBox*, pBox )
}
}
- bSaveLineStatus = false;
+ m_bSaveLineStatus = false;
if( eEnd != (LineEnd)-1 ) // changed?
{
if( eOldEnd != eEnd )
@@ -396,21 +369,21 @@ IMPL_LINK( SwAsciiFilterDlg, CharSetSelHdl, SvxTextEncodingBox*, pBox )
else
{
// restore old user choise (not the automatic!)
- aCRLF_RB.Check( aCRLF_RB.GetSavedValue() );
- aCR_RB.Check( aCR_RB.GetSavedValue() );
- aLF_RB.Check( aLF_RB.GetSavedValue() );
+ m_pCRLF_RB->Check( m_pCRLF_RB->GetSavedValue() );
+ m_pCR_RB->Check( m_pCR_RB->GetSavedValue() );
+ m_pLF_RB->Check( m_pLF_RB->GetSavedValue() );
}
- bSaveLineStatus = true;
+ m_bSaveLineStatus = true;
- if( nOldLng != nLng && aFontLB.IsVisible() )
- aLanguageLB.SelectLanguage( nLng );
+ if( nOldLng != nLng && m_pFontLB->IsVisible() )
+ m_pLanguageLB->SelectLanguage( nLng );
return 0;
}
IMPL_LINK( SwAsciiFilterDlg, LineEndHdl, RadioButton*, pBtn )
{
- if( bSaveLineStatus )
+ if( m_bSaveLineStatus )
pBtn->SaveValue();
return 0;
}
diff --git a/sw/source/ui/dialog/ascfldlg.hrc b/sw/source/ui/dialog/ascfldlg.hrc
deleted file mode 100644
index 139353a..0000000
--- a/sw/source/ui/dialog/ascfldlg.hrc
+++ /dev/null
@@ -1,36 +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 .
- */
-
-#define FL_1 1
-#define FT_CHARSET 2
-#define LB_CHARSET 3
-#define FT_FONT 4
-#define LB_FONT 5
-#define FT_LANGUAGE 6
-#define LB_LANGUAGE 7
-#define FT_CRLF 8
-#define RB_CRLF 9
-#define RB_CR 10
-#define RB_LF 11
-#define PB_OK 12
-#define PB_CANCEL 13
-#define PB_HELP 14
-#define STR_SYS_CHARSET 15
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/ui/dialog/ascfldlg.src b/sw/source/ui/dialog/ascfldlg.src
deleted file mode 100644
index a70a8a8..0000000
--- a/sw/source/ui/dialog/ascfldlg.src
+++ /dev/null
@@ -1,140 +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 "dialog.hrc"
-#include "helpid.h"
-#include "ascfldlg.hrc"
-
-ModalDialog DLG_ASCII_FILTER
-{
- HelpID = HID_ASCII_FILTER ;
- OutputSize = TRUE ;
- SVLook = TRUE ;
- Size = MAP_APPFONT ( 239 , 80 ) ;
- Moveable = TRUE ;
- FixedLine FL_1
- {
- OutputSize = TRUE ;
- Pos = MAP_APPFONT ( 6 , 3 ) ;
- Size = MAP_APPFONT ( 170 , 8 ) ;
- Text [ en-US ] = "Properties";
- };
- FixedText FT_CHARSET
- {
- Pos = MAP_APPFONT ( 12 , 15 ) ;
- Size = MAP_APPFONT ( 66 , 10 ) ;
- Text [ en-US ] = "~Character set";
- };
- ListBox LB_CHARSET
- {
- HelpID = "sw:ListBox:DLG_ASCII_FILTER:LB_CHARSET";
- Pos = MAP_APPFONT ( 80 , 14 ) ;
- Size = MAP_APPFONT ( 90 , 61 ) ;
- TabStop = TRUE ;
- DropDown = TRUE ;
- Sort = TRUE ;
- };
- FixedText FT_FONT
- {
- Pos = MAP_APPFONT ( 12 , 31 ) ;
- Size = MAP_APPFONT ( 66 , 10 ) ;
- Text [ en-US ] = "Default fonts";
- };
- ListBox LB_FONT
- {
- HelpID = "sw:ListBox:DLG_ASCII_FILTER:LB_FONT";
- Pos = MAP_APPFONT ( 80 , 30 ) ;
- Size = MAP_APPFONT ( 90 , 61 ) ;
- TabStop = TRUE ;
- DropDown = TRUE ;
- Sort = TRUE ;
- };
- FixedText FT_LANGUAGE
- {
- Pos = MAP_APPFONT ( 12 , 47 ) ;
- Size = MAP_APPFONT ( 66 , 10 ) ;
- Text [ en-US ] = "Lan~guage";
- };
- ListBox LB_LANGUAGE
- {
- HelpID = "sw:ListBox:DLG_ASCII_FILTER:LB_LANGUAGE";
- Pos = MAP_APPFONT ( 80 , 46 ) ;
- Size = MAP_APPFONT ( 90 , 61 ) ;
- TabStop = TRUE ;
- DropDown = TRUE ;
- Sort = TRUE ;
- };
- FixedText FT_CRLF
- {
- Pos = MAP_APPFONT ( 12 , 64 ) ;
- Size = MAP_APPFONT ( 66 , 8 ) ;
- Text [ en-US ] = "~Paragraph break";
- };
- RadioButton RB_CRLF
- {
- HelpID = "sw:RadioButton:DLG_ASCII_FILTER:RB_CRLF";
- Pos = MAP_APPFONT ( 80 , 64 ) ;
- Size = MAP_APPFONT ( 40 , 10 ) ;
- TabStop = TRUE ;
- Check = TRUE;
- Text [ en-US ] = "~CR & LF";
- };
- RadioButton RB_CR
- {
- HelpID = "sw:RadioButton:DLG_ASCII_FILTER:RB_CR";
- Pos = MAP_APPFONT ( 121 , 64 ) ;
- Size = MAP_APPFONT ( 20 , 10 ) ;
-// TabStop = TRUE ;
- Text [ en-US ] = "C~R";
- };
- RadioButton RB_LF
- {
- HelpID = "sw:RadioButton:DLG_ASCII_FILTER:RB_LF";
- Pos = MAP_APPFONT ( 155 , 64 ) ;
- Size = MAP_APPFONT ( 20 , 10 ) ;
-// TabStop = TRUE ;
- Text [ en-US ] = "~LF";
- };
-
- OKButton PB_OK
- {
- Pos = MAP_APPFONT ( 183 , 6 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- TabStop = TRUE ;
- DefButton = TRUE ;
- };
- CancelButton PB_CANCEL
- {
- Pos = MAP_APPFONT ( 183 , 23 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- TabStop = TRUE ;
- };
- HelpButton PB_HELP
- {
- Pos = MAP_APPFONT ( 183 , 43 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- TabStop = TRUE ;
- };
- String STR_SYS_CHARSET
- {
- Text [ en-US ] = "System";
- };
- Text [ en-US ] = "ASCII Filter Options";
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/ui/dialog/swdlgfact.cxx b/sw/source/ui/dialog/swdlgfact.cxx
index 8f467bd..0cedad7 100644
--- a/sw/source/ui/dialog/swdlgfact.cxx
+++ b/sw/source/ui/dialog/swdlgfact.cxx
@@ -665,23 +665,10 @@ SfxAbstractDialog* SwAbstractDialogFactory_Impl::CreateSfxDialog( Window* pParen
AbstractSwAsciiFilterDlg* SwAbstractDialogFactory_Impl::CreateSwAsciiFilterDlg( Window* pParent,
SwDocShell& rDocSh,
- SvStream* pStream,
- int nResId )
+ SvStream* pStream )
{
- SwAsciiFilterDlg* pDlg=NULL;
- switch ( nResId )
- {
- case DLG_ASCII_FILTER :
- pDlg = new SwAsciiFilterDlg( pParent, rDocSh, pStream );
- break;
-
- default:
- break;
- }
-
- if ( pDlg )
- return new AbstractSwAsciiFilterDlg_Impl( pDlg );
- return 0;
+ SwAsciiFilterDlg* pDlg = new SwAsciiFilterDlg( pParent, rDocSh, pStream );
+ return new AbstractSwAsciiFilterDlg_Impl( pDlg );
}
VclAbstractDialog* SwAbstractDialogFactory_Impl::CreateSwInsertBookmarkDlg( Window *pParent,
diff --git a/sw/source/ui/dialog/swdlgfact.hxx b/sw/source/ui/dialog/swdlgfact.hxx
index 1776229..b9c75bd 100644
--- a/sw/source/ui/dialog/swdlgfact.hxx
+++ b/sw/source/ui/dialog/swdlgfact.hxx
@@ -439,7 +439,7 @@ public:
SfxChildWindow* pChild, Window *pParent, SfxChildWinInfo* pInfo);
virtual AbstractSwInsertAbstractDlg * CreateSwInsertAbstractDlg(Window* pParent);
virtual AbstractSwAsciiFilterDlg* CreateSwAsciiFilterDlg ( Window* pParent, SwDocShell& rDocSh,
- SvStream* pStream, int nResId ); //add for SwAsciiFilterDlg
+ SvStream* pStream ); //add for SwAsciiFilterDlg
virtual VclAbstractDialog * CreateSwInsertBookmarkDlg( Window *pParent, SwWrtShell &rSh, SfxRequest& rReq, int nResId );//add for SwInsertBookmarkDlg
virtual AbstractSwBreakDlg * CreateSwBreakDlg(Window *pParent, SwWrtShell &rSh); // add for SwBreakDlg
virtual VclAbstractDialog * CreateSwChangeDBDlg(SwView& rVw); //add for SwChangeDBDlg
diff --git a/sw/source/ui/inc/ascfldlg.hxx b/sw/source/ui/inc/ascfldlg.hxx
index 71cb7fb..2972bdf 100644
--- a/sw/source/ui/inc/ascfldlg.hxx
+++ b/sw/source/ui/inc/ascfldlg.hxx
@@ -32,20 +32,15 @@ class SwDocShell;
class SwAsciiFilterDlg : public SfxModalDialog
{
- FixedLine aFL;
- FixedText aCharSetFT;
- SvxTextEncodingBox aCharSetLB;
- FixedText aFontFT;
- ListBox aFontLB;
- FixedText aLanguageFT;
- SvxLanguageBox aLanguageLB;
- FixedText aCRLF_FT;
- RadioButton aCRLF_RB, aCR_RB, aLF_RB;
- OKButton aOkPB;
- CancelButton aCancelPB;
- HelpButton aHelpPB;
- String sSystemCharSet;
- bool bSaveLineStatus;
+ SvxTextEncodingBox* m_pCharSetLB;
+ FixedText* m_pFontFT;
+ ListBox* m_pFontLB;
+ FixedText* m_pLanguageFT;
+ SvxLanguageBox* m_pLanguageLB;
+ RadioButton* m_pCRLF_RB;
+ RadioButton* m_pCR_RB;
+ RadioButton* m_pLF_RB;
+ bool m_bSaveLineStatus;
DECL_LINK( CharSetSelHdl, SvxTextEncodingBox* );
DECL_LINK( LineEndHdl, RadioButton* );
diff --git a/sw/source/ui/uno/SwXFilterOptions.cxx b/sw/source/ui/uno/SwXFilterOptions.cxx
index 0f7019e..7ea106d 100644
--- a/sw/source/ui/uno/SwXFilterOptions.cxx
+++ b/sw/source/ui/uno/SwXFilterOptions.cxx
@@ -119,7 +119,8 @@ sal_Int16 SwXFilterOptions::execute() throw (uno::RuntimeException)
SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!");
- AbstractSwAsciiFilterDlg* pAsciiDlg = pFact->CreateSwAsciiFilterDlg( NULL, *pDocShell,pInStream, DLG_ASCII_FILTER );
+ AbstractSwAsciiFilterDlg* pAsciiDlg = pFact->CreateSwAsciiFilterDlg(NULL, *pDocShell,
+ pInStream);
OSL_ENSURE(pAsciiDlg, "Dialogdiet fail!");
if(RET_OK == pAsciiDlg->Execute())
{
diff --git a/sw/uiconfig/swriter/ui/asciifilterdialog.ui b/sw/uiconfig/swriter/ui/asciifilterdialog.ui
new file mode 100644
index 0000000..7230cae
--- /dev/null
+++ b/sw/uiconfig/swriter/ui/asciifilterdialog.ui
@@ -0,0 +1,293 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <!-- interface-requires gtk+ 3.0 -->
+ <!-- interface-requires LibreOffice 1.0 -->
+ <object class="GtkDialog" id="AsciiFilterDialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">6</property>
+ <property name="title" translatable="yes">ASCII Filter Options</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="dialog-vbox1">
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="ok">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="cancel">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="help">
+ <property name="label">gtk-help</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkFrame" id="frame1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="vexpand">True</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="grid1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="valign">start</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Character set</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">charset</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="fontft">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Default fonts</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">font</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="GtkLabel" id="languageft">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Lan_guage</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">language</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="label5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Paragraph break</property>
+ <property name="use_underline">True</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="svxlo-SvxTextEncodingBox" id="charset">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">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="GtkComboBoxText" id="font">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="entry_text_column">0</property>
+ <property name="id_column">1</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="svxcorelo-SvxLanguageBox" id="language">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">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="GtkBox" id="box1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="homogeneous">True</property>
+ <child>
+ <object class="GtkRadioButton" id="crlf">
+ <property name="label" translatable="yes">_CR & LF</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="active">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">cr</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="cr">
+ <property name="label" translatable="yes">C_R</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="halign">center</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">lf</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="lf">
+ <property name="label" translatable="yes">_LF</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="halign">end</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">crlf</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </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>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Properties</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>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="0">ok</action-widget>
+ <action-widget response="0">cancel</action-widget>
+ <action-widget response="0">help</action-widget>
+ </action-widgets>
+ </object>
+</interface>
commit ac36ecb2c939aef928c77ae3df99b0670488e298
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Apr 25 11:26:21 2013 +0100
Rumanian->Romanian, former now considered archaic
Change-Id: I9a47317bf7251dfef5f5d7f2cd6b817792114289
diff --git a/svx/source/dialog/txenctab.src b/svx/source/dialog/txenctab.src
index d8411cf..74ecaca 100644
--- a/svx/source/dialog/txenctab.src
+++ b/svx/source/dialog/txenctab.src
@@ -70,7 +70,7 @@ StringArray RID_SVXSTR_TEXTENCODING_TABLE
< "Cyrillic (Apple Macintosh)" ; RTL_TEXTENCODING_APPLE_CYRILLIC ; > ;
< "Greek (Apple Macintosh)" ; RTL_TEXTENCODING_APPLE_GREEK ; > ;
< "Western Europe (Apple Macintosh/Icelandic)" ; RTL_TEXTENCODING_APPLE_ICELAND ; > ;
- < "Eastern Europe (Apple Macintosh/Rumanian)" ; RTL_TEXTENCODING_APPLE_ROMANIAN ; > ;
+ < "Eastern Europe (Apple Macintosh/Romanian)" ; RTL_TEXTENCODING_APPLE_ROMANIAN ; > ;
< "Turkish (Apple Macintosh)" ; RTL_TEXTENCODING_APPLE_TURKISH ; > ;
< "Cyrillic (Apple Macintosh/Ukrainian)" ; RTL_TEXTENCODING_APPLE_UKRAINIAN ; > ;
< "Chinese simplified (Apple Macintosh)" ; RTL_TEXTENCODING_APPLE_CHINSIMP ; > ;
More information about the Libreoffice-commits
mailing list