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
b776233c
Kaydet (Commit)
b776233c
authored
Haz 26, 2012
tarafından
Miklos Vajna
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
n#766487 testcases
Change-Id: I75c7913141461b354e85889faa6d43a1033680ef
üst
13b6a02e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
35 additions
and
0 deletions
+35
-0
n766487.docx
sw/qa/extras/ooxmltok/data/n766487.docx
+0
-0
ooxmltok.cxx
sw/qa/extras/ooxmltok/ooxmltok.cxx
+35
-0
No files found.
sw/qa/extras/ooxmltok/data/n766487.docx
0 → 100644
Dosyayı görüntüle @
b776233c
File added
sw/qa/extras/ooxmltok/ooxmltok.cxx
Dosyayı görüntüle @
b776233c
...
...
@@ -46,6 +46,8 @@
#include <vcl/svapp.hxx>
#define TWIP_TO_MM100(TWIP) ((TWIP) >= 0 ? (((TWIP)*127L+36L)/72L) : (((TWIP)*127L-36L)/72L))
using
rtl
::
OString
;
using
rtl
::
OUString
;
using
rtl
::
OUStringBuffer
;
...
...
@@ -72,6 +74,7 @@ public:
void
testN766477
();
void
testN758883
();
void
testN766481
();
void
testN766487
();
CPPUNIT_TEST_SUITE
(
Test
);
#if !defined(MACOSX) && !defined(WNT)
...
...
@@ -94,6 +97,7 @@ public:
CPPUNIT_TEST
(
testN766477
);
CPPUNIT_TEST
(
testN758883
);
CPPUNIT_TEST
(
testN766481
);
CPPUNIT_TEST
(
testN766487
);
#endif
CPPUNIT_TEST_SUITE_END
();
...
...
@@ -626,6 +630,37 @@ void Test::testN766481()
CPPUNIT_ASSERT_EQUAL
(
sal_False
,
xParaEnum
->
hasMoreElements
());
}
void
Test
::
testN766487
()
{
/*
* The problem was that 1) the font size of the first para was too large 2) numbering had no first-line-indent.
*
* oParas = ThisComponent.Text.createEnumeration
* oPara = oParas.nextElement
* oRuns = oPara.createEnumeration
* oRun = oRuns.nextElement
* xray oRun.CharHeight ' 12, was larger
* oPara = oParas.nextElement
* xray oPara.ParaFirstLineIndent ' -635, was 0
*/
load
(
"n766487.docx"
);
uno
::
Reference
<
text
::
XTextDocument
>
xTextDocument
(
mxComponent
,
uno
::
UNO_QUERY
);
uno
::
Reference
<
container
::
XEnumerationAccess
>
xParaEnumAccess
(
xTextDocument
->
getText
(),
uno
::
UNO_QUERY
);
uno
::
Reference
<
container
::
XEnumeration
>
xParaEnum
(
xParaEnumAccess
->
createEnumeration
());
uno
::
Reference
<
container
::
XEnumerationAccess
>
xRunEnumAccess
(
xParaEnum
->
nextElement
(),
uno
::
UNO_QUERY
);
uno
::
Reference
<
container
::
XEnumeration
>
xRunEnum
(
xRunEnumAccess
->
createEnumeration
());
uno
::
Reference
<
beans
::
XPropertySet
>
xPropertySet
(
xRunEnum
->
nextElement
(),
uno
::
UNO_QUERY
);
float
fValue
=
0
;
xPropertySet
->
getPropertyValue
(
"CharHeight"
)
>>=
fValue
;
CPPUNIT_ASSERT_EQUAL
(
12.
f
,
fValue
);
xPropertySet
.
set
(
xParaEnum
->
nextElement
(),
uno
::
UNO_QUERY
);
sal_Int32
nValue
=
0
;
xPropertySet
->
getPropertyValue
(
"ParaFirstLineIndent"
)
>>=
nValue
;
CPPUNIT_ASSERT_EQUAL
(
sal_Int32
(
TWIP_TO_MM100
(
-
360
)),
nValue
);
}
CPPUNIT_TEST_SUITE_REGISTRATION
(
Test
);
CPPUNIT_PLUGIN_IMPLEMENT
();
...
...
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