Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
6ffd516e
Kaydet (Commit)
6ffd516e
authored
Haz 21, 2012
tarafından
Wang Lei
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
#i119964 - Number displays different from MS with the same format code
Patch by: Zhang Lu Review by: Wang Lei
üst
4a89fce4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
2 deletions
+17
-2
zformat.hxx
svl/inc/svl/zformat.hxx
+12
-0
zformat.cxx
svl/source/numbers/zformat.cxx
+5
-2
No files found.
svl/inc/svl/zformat.hxx
Dosyayı görüntüle @
6ffd516e
...
@@ -313,6 +313,18 @@ public:
...
@@ -313,6 +313,18 @@ public:
(
eOp1
==
NUMBERFORMAT_OP_GT
&&
eOp2
==
NUMBERFORMAT_OP_LT
)
||
(
eOp1
==
NUMBERFORMAT_OP_GT
&&
eOp2
==
NUMBERFORMAT_OP_LT
)
||
(
eOp1
==
NUMBERFORMAT_OP_NO
&&
eOp2
==
NUMBERFORMAT_OP_NO
)
);
(
eOp1
==
NUMBERFORMAT_OP_NO
&&
eOp2
==
NUMBERFORMAT_OP_NO
)
);
}
}
// Whether the first subformat code is really for negative numbers
// or another limit set.
sal_Bool
IsNegativeRealNegative2
()
const
{
return
fLimit1
==
0.0
&&
fLimit2
==
0.0
&&
(
(
eOp2
==
NUMBERFORMAT_OP_GT
&&
eOp1
==
NUMBERFORMAT_OP_LT
)
||
(
eOp2
==
NUMBERFORMAT_OP_EQ
&&
eOp1
==
NUMBERFORMAT_OP_LT
)
||
(
eOp2
==
NUMBERFORMAT_OP_GE
&&
eOp1
==
NUMBERFORMAT_OP_LT
)
||
(
eOp2
==
NUMBERFORMAT_OP_NO
&&
eOp1
==
NUMBERFORMAT_OP_LT
)
||
(
eOp2
==
NUMBERFORMAT_OP_NO
&&
eOp1
==
NUMBERFORMAT_OP_LE
)
||
(
eOp2
==
NUMBERFORMAT_OP_GT
&&
eOp1
==
NUMBERFORMAT_OP_LE
));
}
// Whether the negative format is without a sign or not
// Whether the negative format is without a sign or not
sal_Bool
IsNegativeWithoutSign
()
const
;
sal_Bool
IsNegativeWithoutSign
()
const
;
...
...
svl/source/numbers/zformat.cxx
Dosyayı görüntüle @
6ffd516e
...
@@ -2129,9 +2129,12 @@ sal_Bool SvNumberformat::GetOutputString(double fNumber,
...
@@ -2129,9 +2129,12 @@ sal_Bool SvNumberformat::GetOutputString(double fNumber,
else
else
nIx
=
2
;
nIx
=
2
;
}
}
if
(
nIx
==
1
&&
fNumber
<
0.0
&&
// negatives Format
if
(
nIx
==
1
&&
// negatives Format
IsNegativeRealNegative
()
)
// ohne Vorzeichen
IsNegativeRealNegative
()
&&
fNumber
<
0.0
)
// ohne Vorzeichen
fNumber
=
-
fNumber
;
// Vorzeichen eliminieren
fNumber
=
-
fNumber
;
// Vorzeichen eliminieren
if
(
nIx
==
0
&&
IsNegativeRealNegative2
()
&&
fNumber
<
0.0
)
fNumber
=
-
fNumber
;
*
ppColor
=
NumFor
[
nIx
].
GetColor
();
*
ppColor
=
NumFor
[
nIx
].
GetColor
();
const
ImpSvNumberformatInfo
&
rInfo
=
NumFor
[
nIx
].
Info
();
const
ImpSvNumberformatInfo
&
rInfo
=
NumFor
[
nIx
].
Info
();
const
sal_uInt16
nAnz
=
NumFor
[
nIx
].
GetnAnz
();
const
sal_uInt16
nAnz
=
NumFor
[
nIx
].
GetnAnz
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment