[Libreoffice-commits] .: svx/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Thu Dec 6 01:36:41 PST 2012
svx/source/tbxctrls/tbcontrl.cxx | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
New commits:
commit b22881c8166708d6fd42fbadad47ff880ba19ed4
Author: Samuel Mehrbrodt <s.mehrbrodt at gmail.com>
Date: Wed Dec 5 20:48:43 2012 +0100
Modify the default Style list in Writer, give them a custom order.
Asking on UX-Advise, there were no negative voices for this change:
http://nabble.documentfoundation.org/Libreoffice-ux-advise-Default-Styles-in-Writer-td4020441.html
Change-Id: I780eaecc29c88493f09194399dfc00be1484c549
Reviewed-on: https://gerrit.libreoffice.org/1248
Reviewed-by: Bosdonnat Cedric <cedric.bosdonnat at free.fr>
Tested-by: Bosdonnat Cedric <cedric.bosdonnat at free.fr>
diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index fab0466..05f2b08 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -1681,11 +1681,13 @@ struct SvxStyleToolBoxControl::Impl
xParaStyles;
static const sal_Char* aWriterStyles[] =
{
- "Standard",
+ "Text body",
+ "Quotations",
+ "Title",
+ "Subtitle",
"Heading 1",
"Heading 2",
- "Heading 3",
- "Text body"
+ "Heading 3"
};
for( sal_uInt32 nStyle = 0; nStyle < sizeof( aWriterStyles ) / sizeof( sal_Char*); ++nStyle )
{
@@ -1946,6 +1948,11 @@ void SvxStyleToolBoxControl::FillStyleBox()
if( pImpl->bSpecModeWriter || pImpl->bSpecModeCalc )
{
+ // disable sort to preserve special order
+ WinBits nWinBits = pBox->GetStyle();
+ nWinBits &= ~WB_SORT;
+ pBox->SetStyle( nWinBits );
+
// insert default styles
sal_uInt16 _i;
sal_uInt32 nCnt = pImpl->aDefaultStyles.size();
@@ -1956,11 +1963,6 @@ void SvxStyleToolBoxControl::FillStyleBox()
++nPos;
}
- // disable sort to preserve special order
- WinBits nWinBits = pBox->GetStyle();
- nWinBits &= ~WB_SORT;
- pBox->SetStyle( nWinBits );
-
pBox->InsertEntry( pImpl->aClearForm, 0 );
pBox->SetSeparatorPos( 0 );
More information about the Libreoffice-commits
mailing list