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
6cc4118a
Kaydet (Commit)
6cc4118a
authored
Kas 11, 2015
tarafından
Noel Grandin
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
vcl: boost::ptr_vector->std::vector
Change-Id: I21f90c8d4b3d52b7119d664cb7af471b33f27649
üst
6e1c20b9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
26 deletions
+26
-26
textdat2.hxx
vcl/source/edit/textdat2.hxx
+13
-13
texteng.cxx
vcl/source/edit/texteng.cxx
+13
-13
No files found.
vcl/source/edit/textdat2.hxx
Dosyayı görüntüle @
6cc4118a
...
...
@@ -25,7 +25,7 @@
#include <vcl/cursor.hxx>
#include <vcl/idle.hxx>
#include <
boost/ptr_container/ptr_vector.hpp
>
#include <
vector
>
class
TextNode
;
class
TextView
;
...
...
@@ -105,9 +105,9 @@ private:
sal_uInt16
mnStartPortion
;
sal_uInt16
mnEndPortion
;
short
mnStartX
;
short
mnStartX
;
bool
mbInvalid
;
// fuer geschickte Formatierung/Ausgabe
bool
mbInvalid
;
// fuer geschickte Formatierung/Ausgabe
public
:
TextLine
()
...
...
@@ -131,12 +131,12 @@ public:
sal_Int32
&
GetEnd
()
{
return
mnEnd
;
}
void
SetStartPortion
(
sal_uInt16
n
)
{
mnStartPortion
=
n
;
}
sal_uInt16
GetStartPortion
()
const
{
return
mnStartPortion
;
}
sal_uInt16
&
GetStartPortion
()
{
return
mnStartPortion
;
}
sal_uInt16
GetStartPortion
()
const
{
return
mnStartPortion
;
}
sal_uInt16
&
GetStartPortion
()
{
return
mnStartPortion
;
}
void
SetEndPortion
(
sal_uInt16
n
)
{
mnEndPortion
=
n
;
}
sal_uInt16
GetEndPortion
()
const
{
return
mnEndPortion
;
}
sal_uInt16
&
GetEndPortion
()
{
return
mnEndPortion
;
}
sal_uInt16
GetEndPortion
()
const
{
return
mnEndPortion
;
}
sal_uInt16
&
GetEndPortion
()
{
return
mnEndPortion
;
}
sal_Int32
GetLen
()
const
{
return
mnEnd
-
mnStart
;
}
...
...
@@ -170,15 +170,15 @@ class TEParaPortion
private
:
TextNode
*
mpNode
;
boost
::
ptr_vector
<
TextLine
>
maLines
;
std
::
vector
<
TextLine
>
maLines
;
TETextPortionList
maTextPortions
;
std
::
vector
<
TEWritingDirectionInfo
>
maWritingDirectionInfos
;
sal_Int32
mnInvalidPosStart
;
sal_Int32
mnInvalidDiff
;
sal_Int32
mnInvalidPosStart
;
sal_Int32
mnInvalidDiff
;
bool
mbInvalid
;
bool
mbSimple
;
// only type linearly
bool
mbInvalid
;
bool
mbSimple
;
// only type linearly
TEParaPortion
(
const
TEParaPortion
&
)
{;}
...
...
@@ -198,7 +198,7 @@ public:
sal_Int32
GetInvalidDiff
()
const
{
return
mnInvalidDiff
;
}
TextNode
*
GetNode
()
const
{
return
mpNode
;
}
boost
::
ptr_vector
<
TextLine
>&
GetLines
()
{
return
maLines
;
}
std
::
vector
<
TextLine
>&
GetLines
()
{
return
maLines
;
}
TETextPortionList
&
GetTextPortions
()
{
return
maTextPortions
;
}
std
::
vector
<
TEWritingDirectionInfo
>&
GetWritingDirectionInfos
()
{
return
maWritingDirectionInfos
;
}
...
...
vcl/source/edit/texteng.cxx
Dosyayı görüntüle @
6cc4118a
...
...
@@ -1620,17 +1620,16 @@ void TextEngine::CreateAndInsertEmptyLine( sal_uInt32 nPara )
TextNode
*
pNode
=
mpDoc
->
GetNodes
()[
nPara
];
TEParaPortion
*
pTEParaPortion
=
mpTEParaPortions
->
GetObject
(
nPara
);
TextLine
*
pTmpLine
=
new
TextLine
;
pTmpLine
->
SetStart
(
pNode
->
GetText
().
getLength
()
);
pTmpLine
->
SetEnd
(
pTmpLine
->
GetStart
()
);
pTEParaPortion
->
GetLines
().
push_back
(
pTmpLine
);
TextLine
aTmpLine
;
aTmpLine
.
SetStart
(
pNode
->
GetText
().
getLength
()
);
aTmpLine
.
SetEnd
(
aTmpLine
.
GetStart
()
);
if
(
ImpGetAlign
()
==
TXTALIGN_CENTER
)
pTmpLine
->
SetStartX
(
(
short
)(
mnMaxTextWidth
/
2
)
);
aTmpLine
.
SetStartX
(
(
short
)(
mnMaxTextWidth
/
2
)
);
else
if
(
ImpGetAlign
()
==
TXTALIGN_RIGHT
)
pTmpLine
->
SetStartX
(
(
short
)
mnMaxTextWidth
);
aTmpLine
.
SetStartX
(
(
short
)
mnMaxTextWidth
);
else
pTmpLine
->
SetStartX
(
mpDoc
->
GetLeftMargin
()
);
aTmpLine
.
SetStartX
(
mpDoc
->
GetLeftMargin
()
);
bool
bLineBreak
=
!
pNode
->
GetText
().
isEmpty
();
...
...
@@ -1642,9 +1641,10 @@ void TextEngine::CreateAndInsertEmptyLine( sal_uInt32 nPara )
{
// -2: The new one is already inserted.
sal_uInt16
nPos
=
(
sal_uInt16
)
pTEParaPortion
->
GetTextPortions
().
size
()
-
1
;
pTmpLine
->
SetStartPortion
(
nPos
);
pTmpLine
->
SetEndPortion
(
nPos
);
aTmpLine
.
SetStartPortion
(
nPos
);
aTmpLine
.
SetEndPortion
(
nPos
);
}
pTEParaPortion
->
GetLines
().
push_back
(
aTmpLine
);
}
void
TextEngine
::
ImpBreakLine
(
sal_uInt32
nPara
,
TextLine
*
pLine
,
TETextPortion
*
,
sal_Int32
nPortionStart
,
long
nRemainingWidth
)
...
...
@@ -2142,8 +2142,7 @@ bool TextEngine::CreateLines( sal_uInt32 nPara )
// initialization
if
(
pTEParaPortion
->
GetLines
().
empty
()
)
{
TextLine
*
pL
=
new
TextLine
;
pTEParaPortion
->
GetLines
().
push_back
(
pL
);
pTEParaPortion
->
GetLines
().
push_back
(
TextLine
()
);
}
const
sal_Int32
nInvalidDiff
=
pTEParaPortion
->
GetInvalidDiff
();
...
...
@@ -2394,8 +2393,9 @@ bool TextEngine::CreateLines( sal_uInt32 nPara )
{
if
(
nIndex
<
pNode
->
GetText
().
getLength
()
)
{
pLine
=
new
TextLine
;
pTEParaPortion
->
GetLines
().
insert
(
pTEParaPortion
->
GetLines
().
begin
()
+
++
nLine
,
pLine
);
++
nLine
;
pTEParaPortion
->
GetLines
().
insert
(
pTEParaPortion
->
GetLines
().
begin
()
+
nLine
,
TextLine
()
);
pLine
=
&
pTEParaPortion
->
GetLines
()[
nLine
];
}
else
{
...
...
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