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
7b3f5521
Kaydet (Commit)
7b3f5521
authored
Nis 08, 2013
tarafından
Armin Le Grand
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
i121965 Take draw:transform into account for draw:connector shapes
üst
4a1295be
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
0 deletions
+29
-0
ximpshap.cxx
xmloff/source/draw/ximpshap.cxx
+29
-0
No files found.
xmloff/source/draw/ximpshap.cxx
Dosyayı görüntüle @
7b3f5521
...
...
@@ -79,6 +79,7 @@
#include <com/sun/star/container/XChild.hpp>
#include <com/sun/star/text/XTextDocument.hpp>
#include <basegfx/vector/b2dvector.hxx>
#include <basegfx/point/b2dpoint.hxx>
using
::
rtl
::
OUString
;
using
::
rtl
::
OUStringBuffer
;
...
...
@@ -1805,6 +1806,11 @@ void SdXMLConnectorShapeContext::processAttribute( sal_uInt16 nPrefix, const ::r
SvXMLUnitConverter
::
convertEnum
(
mnType
,
rValue
,
aXML_ConnectionKind_EnumMap
);
return
;
}
// #121965# draw:transform may be used in ODF1.2, e.g. exports from MS seem to use these
else
if
(
IsXMLToken
(
rLocalName
,
XML_TRANSFORM
)
)
{
mnTransform
.
SetString
(
rValue
,
GetImport
().
GetMM100UnitConverter
());
}
}
case
XML_NAMESPACE_SVG
:
{
...
...
@@ -1892,6 +1898,29 @@ void SdXMLConnectorShapeContext::StartElement(const uno::Reference< xml::sax::XA
AddShape
(
"com.sun.star.drawing.ConnectorShape"
);
if
(
mxShape
.
is
())
{
// #121965# if draw:transform is used, apply directly to the start
// and end positions before using these
if
(
mnTransform
.
NeedsAction
())
{
// transformation is used, apply to object.
::
basegfx
::
B2DHomMatrix
aMat
;
mnTransform
.
GetFullTransform
(
aMat
);
if
(
!
aMat
.
isIdentity
())
{
basegfx
::
B2DPoint
aStart
(
maStart
.
X
,
maStart
.
Y
);
basegfx
::
B2DPoint
aEnd
(
maEnd
.
X
,
maEnd
.
Y
);
aStart
=
aMat
*
aStart
;
aEnd
=
aMat
*
aEnd
;
maStart
.
X
=
basegfx
::
fround
(
aStart
.
getX
());
maStart
.
Y
=
basegfx
::
fround
(
aStart
.
getY
());
maEnd
.
X
=
basegfx
::
fround
(
aEnd
.
getX
());
maEnd
.
Y
=
basegfx
::
fround
(
aEnd
.
getY
());
}
}
// add connection ids
if
(
maStartShapeId
.
getLength
()
)
GetImport
().
GetShapeImport
()
->
addShapeConnection
(
mxShape
,
sal_True
,
maStartShapeId
,
mnStartGlueId
);
...
...
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