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
ad69a033
Kaydet (Commit)
ad69a033
authored
Nis 06, 2013
tarafından
Tor Lillqvist
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Use CGContextShowGlyphsWithAdvances()
Change-Id: I9373647e5d710acb26c9818e6d06d4bfb862a7df
üst
37805971
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
salcoretextlayout.cxx
vcl/coretext/salcoretextlayout.cxx
+7
-5
No files found.
vcl/coretext/salcoretextlayout.cxx
Dosyayı görüntüle @
ad69a033
...
@@ -69,7 +69,7 @@ private:
...
@@ -69,7 +69,7 @@ private:
mutable
int
*
mpCharWidths
;
// map relative charpos to charwidth
mutable
int
*
mpCharWidths
;
// map relative charpos to charwidth
mutable
int
*
mpGlyphs2Chars
;
// map absolute glyphpos to absolute charpos
mutable
int
*
mpGlyphs2Chars
;
// map absolute glyphpos to absolute charpos
mutable
int
*
mpGlyphAdvances
;
// glyph width
s for the justified layout
mutable
CGSize
*
mpGlyphAdvances
;
// glyph advance
s for the justified layout
mutable
CGPoint
*
mpGlyphPositions
;
mutable
CGPoint
*
mpGlyphPositions
;
mutable
CTTypesetterRef
mpTypesetter
;
mutable
CTTypesetterRef
mpTypesetter
;
...
@@ -186,7 +186,8 @@ void CoreTextLayout::DrawText( SalGraphics& rGraphics ) const
...
@@ -186,7 +186,8 @@ void CoreTextLayout::DrawText( SalGraphics& rGraphics ) const
CGContextSetTextMatrix
(
gr
.
mrContext
,
CGAffineTransformMakeScale
(
1.0
,
-
1.0
));
CGContextSetTextMatrix
(
gr
.
mrContext
,
CGAffineTransformMakeScale
(
1.0
,
-
1.0
));
CGContextSetShouldAntialias
(
gr
.
mrContext
,
!
gr
.
mbNonAntialiasedText
);
CGContextSetShouldAntialias
(
gr
.
mrContext
,
!
gr
.
mbNonAntialiasedText
);
CGContextTranslateCTM
(
gr
.
mrContext
,
pos
.
X
(),
pos
.
Y
());
CGContextTranslateCTM
(
gr
.
mrContext
,
pos
.
X
(),
pos
.
Y
());
CGContextShowGlyphs
(
gr
.
mrContext
,
mpGlyphs
,
mnGlyphCount
);
CGContextShowGlyphsWithAdvances
(
gr
.
mrContext
,
mpGlyphs
,
mpGlyphAdvances
,
mnGlyphCount
);
#ifndef IOS
#ifndef IOS
// Request an update of the changed window area. Like in the ATSUI
// Request an update of the changed window area. Like in the ATSUI
...
@@ -350,7 +351,7 @@ int CoreTextLayout::GetNextGlyphs( int nLen, sal_GlyphId* pGlyphIDs, Point& rPos
...
@@ -350,7 +351,7 @@ int CoreTextLayout::GetNextGlyphs( int nLen, sal_GlyphId* pGlyphIDs, Point& rPos
}
}
pGlyphIDs
[
i
]
=
mpGlyphs
[
mnCurrentGlyphIndex
];
pGlyphIDs
[
i
]
=
mpGlyphs
[
mnCurrentGlyphIndex
];
if
(
pGlyphAdvances
)
{
if
(
pGlyphAdvances
)
{
pGlyphAdvances
[
i
]
=
mpGlyphAdvances
[
mnCurrentGlyphIndex
];
pGlyphAdvances
[
i
]
=
mpGlyphAdvances
[
mnCurrentGlyphIndex
]
.
width
;
}
}
if
(
pCharIndexes
)
{
if
(
pCharIndexes
)
{
pCharIndexes
[
i
]
=
mpGlyphs2Chars
[
mnCurrentGlyphIndex
];
pCharIndexes
[
i
]
=
mpGlyphs2Chars
[
mnCurrentGlyphIndex
];
...
@@ -509,7 +510,7 @@ bool CoreTextLayout::InitGIA( ImplLayoutArgs& rArgs ) const
...
@@ -509,7 +510,7 @@ bool CoreTextLayout::InitGIA( ImplLayoutArgs& rArgs ) const
mpCharWidths
[
i
]
=
0.0
;
mpCharWidths
[
i
]
=
0.0
;
}
}
mpGlyphs2Chars
=
new
int
[
mnGlyphCount
];
mpGlyphs2Chars
=
new
int
[
mnGlyphCount
];
mpGlyphAdvances
=
new
int
[
mnGlyphCount
];
mpGlyphAdvances
=
new
CGSize
[
mnGlyphCount
];
mpGlyphPositions
=
new
CGPoint
[
mnGlyphCount
];
mpGlyphPositions
=
new
CGPoint
[
mnGlyphCount
];
CFArrayRef
runs
=
CTLineGetGlyphRuns
(
mpLine
);
CFArrayRef
runs
=
CTLineGetGlyphRuns
(
mpLine
);
...
@@ -555,7 +556,8 @@ bool CoreTextLayout::InitGIA( ImplLayoutArgs& rArgs ) const
...
@@ -555,7 +556,8 @@ bool CoreTextLayout::InitGIA( ImplLayoutArgs& rArgs ) const
}
}
if
(
p
>
0
)
if
(
p
>
0
)
{
{
mpGlyphAdvances
[
p
-
1
]
=
mpGlyphPositions
[
p
].
x
-
mpGlyphPositions
[
p
-
1
].
x
;
mpGlyphAdvances
[
p
-
1
].
width
=
mpGlyphPositions
[
p
].
x
-
mpGlyphPositions
[
p
-
1
].
x
;
mpGlyphAdvances
[
p
-
1
].
height
=
mpGlyphPositions
[
p
].
y
-
mpGlyphPositions
[
p
-
1
].
y
;
}
}
}
}
}
}
...
...
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