[Libreoffice-commits] core.git: sw/source sw/uiconfig
Caolán McNamara
caolanm at redhat.com
Mon Apr 7 05:02:07 PDT 2014
sw/source/ui/dialog/docstdlg.cxx | 20 ++++++++++--------
sw/uiconfig/swriter/ui/statisticsinfopage.ui | 30 ++++++++++++++++++---------
2 files changed, 32 insertions(+), 18 deletions(-)
New commits:
commit 9526d1969da25189563a99476176842d38418b76
Author: Caolán McNamara <caolanm at redhat.com>
Date: Mon Apr 7 12:21:30 2014 +0100
Related: fdo#51818 format statistical numbers with locale rules
Change-Id: Ic21e93d55037a7971b2b6f7988f87c9b4eb01de5
diff --git a/sw/source/ui/dialog/docstdlg.cxx b/sw/source/ui/dialog/docstdlg.cxx
index 0cb27d6..7cf70ba 100644
--- a/sw/source/ui/dialog/docstdlg.cxx
+++ b/sw/source/ui/dialog/docstdlg.cxx
@@ -34,6 +34,9 @@
#include <fldmgr.hxx>
#include <fldbas.hxx>
+#include <unotools/localedatawrapper.hxx>
+#include <vcl/settings.hxx>
+
SfxTabPage * SwDocStatPage::Create(Window *pParent, const SfxItemSet &rSet)
{
return new SwDocStatPage(pParent, rSet);
@@ -88,14 +91,15 @@ void SwDocStatPage::Reset(const SfxItemSet &/*rSet*/)
// Description: update / set data
void SwDocStatPage::SetData(const SwDocStat &rStat)
{
- m_pTableNo->SetText(OUString::number( rStat.nTbl ));
- m_pGrfNo->SetText(OUString::number( rStat.nGrf ));
- m_pOLENo->SetText(OUString::number( rStat.nOLE ));
- m_pPageNo->SetText(OUString::number( rStat.nPage ));
- m_pParaNo->SetText(OUString::number( rStat.nPara ));
- m_pWordNo->SetText(OUString::number( rStat.nWord ));
- m_pCharNo->SetText(OUString::number( rStat.nChar ));
- m_pCharExclSpacesNo->SetText(OUString::number( rStat.nCharExcludingSpaces ));
+ const LocaleDataWrapper& rLocaleData = GetSettings().GetUILocaleDataWrapper();
+ m_pTableNo->SetText(rLocaleData.getNum(rStat.nTbl, 0));
+ m_pGrfNo->SetText(rLocaleData.getNum(rStat.nGrf, 0));
+ m_pOLENo->SetText(rLocaleData.getNum(rStat.nOLE, 0));
+ m_pPageNo->SetText(rLocaleData.getNum(rStat.nPage, 0));
+ m_pParaNo->SetText(rLocaleData.getNum(rStat.nPara, 0));
+ m_pWordNo->SetText(rLocaleData.getNum(rStat.nWord, 0));
+ m_pCharNo->SetText(rLocaleData.getNum(rStat.nChar, 0));
+ m_pCharExclSpacesNo->SetText(rLocaleData.getNum(rStat.nCharExcludingSpaces, 0));
}
// Description: update statistics
diff --git a/sw/uiconfig/swriter/ui/statisticsinfopage.ui b/sw/uiconfig/swriter/ui/statisticsinfopage.ui
index 462e599..e628534 100644
--- a/sw/uiconfig/swriter/ui/statisticsinfopage.ui
+++ b/sw/uiconfig/swriter/ui/statisticsinfopage.ui
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.16.1 -->
<interface>
- <!-- interface-requires gtk+ 3.0 -->
+ <requires lib="gtk+" version="3.0"/>
<object class="GtkGrid" id="StatisticsInfoPage">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -157,8 +158,9 @@
<object class="GtkLabel" id="nopages">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="width_chars">10</property>
</object>
<packing>
@@ -172,8 +174,9 @@
<object class="GtkLabel" id="notables">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="width_chars">10</property>
</object>
<packing>
@@ -187,8 +190,9 @@
<object class="GtkLabel" id="nogrfs">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="width_chars">10</property>
</object>
<packing>
@@ -202,8 +206,9 @@
<object class="GtkLabel" id="nooles">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="width_chars">10</property>
</object>
<packing>
@@ -217,8 +222,9 @@
<object class="GtkLabel" id="noparas">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="width_chars">10</property>
</object>
<packing>
@@ -232,8 +238,9 @@
<object class="GtkLabel" id="nowords">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="width_chars">10</property>
</object>
<packing>
@@ -247,8 +254,9 @@
<object class="GtkLabel" id="nochars">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="width_chars">10</property>
</object>
<packing>
@@ -262,8 +270,9 @@
<object class="GtkLabel" id="nocharsexspaces">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="width_chars">10</property>
</object>
<packing>
@@ -292,8 +301,9 @@
<object class="GtkLabel" id="nolines">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="halign">start</property>
<property name="hexpand">True</property>
- <property name="xalign">0</property>
+ <property name="xalign">1</property>
<property name="label">...</property>
<property name="width_chars">10</property>
</object>
More information about the Libreoffice-commits
mailing list