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
29cbbad6
Kaydet (Commit)
29cbbad6
authored
Kas 07, 2014
tarafından
Miklos Vajna
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
DOCX import: fix rounding error in table cell widths
Change-Id: I733fd4b998ba4d0bde2f91f2b3d76205f0dc8020
üst
8b8b0dfa
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
3 deletions
+9
-3
ooxmlexport4.cxx
sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
+1
-1
tcw-rounding.docx
sw/qa/extras/ooxmlimport/data/tcw-rounding.docx
+0
-0
ooxmlimport.cxx
sw/qa/extras/ooxmlimport/ooxmlimport.cxx
+6
-0
DomainMapperTableManager.cxx
writerfilter/source/dmapper/DomainMapperTableManager.cxx
+2
-2
No files found.
sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
Dosyayı görüntüle @
29cbbad6
...
...
@@ -295,7 +295,7 @@ DECLARE_OOXMLEXPORT_TEST(testSegFaultWhileSave, "test_segfault_while_save.docx")
xmlDocPtr
pXmlDoc
=
parseExport
(
"word/document.xml"
);
if
(
!
pXmlDoc
)
return
;
CPPUNIT_ASSERT
(
getXPath
(
pXmlDoc
,
"/w:document/w:body/w:tbl/w:tblGrid/w:gridCol[2]"
,
"w"
).
match
(
"6138"
));
CPPUNIT_ASSERT
_EQUAL
(
static_cast
<
sal_Int32
>
(
6137
),
getXPath
(
pXmlDoc
,
"/w:document/w:body/w:tbl/w:tblGrid/w:gridCol[2]"
,
"w"
).
toInt32
(
));
}
DECLARE_OOXMLEXPORT_TEST
(
fdo69656
,
"Table_cell_auto_width_fdo69656.docx"
)
...
...
sw/qa/extras/ooxmlimport/data/tcw-rounding.docx
0 → 100644
Dosyayı görüntüle @
29cbbad6
File added
sw/qa/extras/ooxmlimport/ooxmlimport.cxx
Dosyayı görüntüle @
29cbbad6
...
...
@@ -2391,6 +2391,12 @@ static OString dateTimeToString( const util::DateTime& dt )
return
DateTimeToOString
(
DateTime
(
Date
(
dt
.
Day
,
dt
.
Month
,
dt
.
Year
),
tools
::
Time
(
dt
.
Hours
,
dt
.
Minutes
,
dt
.
Seconds
)));
}
DECLARE_OOXMLIMPORT_TEST
(
testTcwRounding
,
"tcw-rounding.docx"
)
{
// Width of the A1 cell in twips was 3200, due to a rounding error.
CPPUNIT_ASSERT_EQUAL
(
static_cast
<
sal_Int32
>
(
3201
),
parseDump
(
"/root/page/body/tab/row/cell[1]/infos/bounds"
,
"width"
).
toInt32
());
}
DECLARE_OOXMLIMPORT_TEST
(
testBnc821804
,
"bnc821804.docx"
)
{
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"TITLE"
),
getRun
(
getParagraph
(
1
),
1
)
->
getString
());
...
...
writerfilter/source/dmapper/DomainMapperTableManager.cxx
Dosyayı görüntüle @
29cbbad6
...
...
@@ -34,6 +34,7 @@
#include <ooxml/resourceids.hxx>
#include <dmapperLoggers.hxx>
#include <dmapper/DomainMapper.hxx>
#include <rtl/math.hxx>
namespace
writerfilter
{
namespace
dmapper
{
...
...
@@ -745,8 +746,7 @@ void DomainMapperTableManager::endOfRowAction()
for
(
sal_Int32
nGridCount
=
*
aSpansIter
;
nGridCount
>
0
;
--
nGridCount
)
fGridWidth
+=
(
*
pTableGrid
.
get
())[
nBorderGridIndex
++
];
sal_Int16
nRelPos
=
sal
::
static_int_cast
<
sal_Int16
>
((
fGridWidth
*
10000
)
/
nFullWidthRelative
);
sal_Int16
nRelPos
=
rtl
::
math
::
round
((
fGridWidth
*
10000
)
/
nFullWidthRelative
);
pSeparators
[
nBorder
].
Position
=
nRelPos
+
nLastRelPos
;
pSeparators
[
nBorder
].
IsVisible
=
sal_True
;
...
...
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