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
ba815705
Kaydet (Commit)
ba815705
authored
Agu 21, 2015
tarafından
Tor Lillqvist
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Error handling
Change-Id: I46e5463aaa5cab41cd69c13314ee98a0c73e7ba2
üst
dc0167c2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
2 deletions
+32
-2
winlayout.cxx
vcl/win/source/gdi/winlayout.cxx
+32
-2
No files found.
vcl/win/source/gdi/winlayout.cxx
Dosyayı görüntüle @
ba815705
...
@@ -271,6 +271,8 @@ bool ImplWinFontEntry::AddChunkOfGlyphs(int nGlyphIndex, const WinLayout& rLayou
...
@@ -271,6 +271,8 @@ bool ImplWinFontEntry::AddChunkOfGlyphs(int nGlyphIndex, const WinLayout& rLayou
if
(
!
GetCharABCWidthsI
(
hDC
,
0
,
nCount
,
aGlyphIndices
.
data
(),
aABC
.
data
()))
if
(
!
GetCharABCWidthsI
(
hDC
,
0
,
nCount
,
aGlyphIndices
.
data
(),
aABC
.
data
()))
{
{
SAL_WARN
(
"vcl.gdi"
,
"GetCharABCWidthsI failed: "
<<
WindowsErrorString
(
GetLastError
()));
SAL_WARN
(
"vcl.gdi"
,
"GetCharABCWidthsI failed: "
<<
WindowsErrorString
(
GetLastError
()));
SelectObject
(
hDC
,
hOrigFont
);
DeleteDC
(
hDC
);
return
false
;
return
false
;
}
}
...
@@ -296,10 +298,24 @@ bool ImplWinFontEntry::AddChunkOfGlyphs(int nGlyphIndex, const WinLayout& rLayou
...
@@ -296,10 +298,24 @@ bool ImplWinFontEntry::AddChunkOfGlyphs(int nGlyphIndex, const WinLayout& rLayou
}
}
TEXTMETRICW
aTextMetric
;
TEXTMETRICW
aTextMetric
;
GetTextMetricsW
(
hDC
,
&
aTextMetric
);
if
(
!
GetTextMetricsW
(
hDC
,
&
aTextMetric
))
{
SAL_WARN
(
"vcl.gdi"
,
"GetTextMetrics failed: "
<<
WindowsErrorString
(
GetLastError
()));
SelectObject
(
hDC
,
hOrigFont
);
DeleteDC
(
hDC
);
return
false
;
}
aChunk
.
mnAscentPlusIntLeading
=
aTextMetric
.
tmAscent
+
aTextMetric
.
tmInternalLeading
;
aChunk
.
mnAscentPlusIntLeading
=
aTextMetric
.
tmAscent
+
aTextMetric
.
tmInternalLeading
;
UINT
nAlign
=
GetTextAlign
(
hDC
);
UINT
nAlign
=
GetTextAlign
(
hDC
);
if
(
nAlign
==
GDI_ERROR
)
{
SAL_WARN
(
"vcl.gdi"
,
"GetTextAlign failed: "
<<
WindowsErrorString
(
GetLastError
()));
SelectObject
(
hDC
,
hOrigFont
);
DeleteDC
(
hDC
);
return
false
;
}
OUString
sAlign
;
OUString
sAlign
;
switch
((
TA_LEFT
|
TA_CENTER
|
TA_RIGHT
)
&
nAlign
)
switch
((
TA_LEFT
|
TA_CENTER
|
TA_RIGHT
)
&
nAlign
)
{
{
...
@@ -339,10 +355,24 @@ bool ImplWinFontEntry::AddChunkOfGlyphs(int nGlyphIndex, const WinLayout& rLayou
...
@@ -339,10 +355,24 @@ bool ImplWinFontEntry::AddChunkOfGlyphs(int nGlyphIndex, const WinLayout& rLayou
sAlign
+=
"NOUPDATECP"
;
sAlign
+=
"NOUPDATECP"
;
LOGFONTW
aLogfont
;
LOGFONTW
aLogfont
;
GetObjectW
(
rLayout
.
mhFont
,
sizeof
(
aLogfont
),
&
aLogfont
);
if
(
!
GetObjectW
(
rLayout
.
mhFont
,
sizeof
(
aLogfont
),
&
aLogfont
))
{
SAL_WARN
(
"vcl.gdi"
,
"GetObject failed: "
<<
WindowsErrorString
(
GetLastError
()));
SelectObject
(
hDC
,
hOrigFont
);
DeleteDC
(
hDC
);
return
false
;
}
wchar_t
sFaceName
[
200
];
wchar_t
sFaceName
[
200
];
int
nFaceNameLen
=
GetTextFaceW
(
hDC
,
SAL_N_ELEMENTS
(
sFaceName
),
sFaceName
);
int
nFaceNameLen
=
GetTextFaceW
(
hDC
,
SAL_N_ELEMENTS
(
sFaceName
),
sFaceName
);
if
(
!
nFaceNameLen
)
{
SAL_WARN
(
"vcl.gdi"
,
"GetTextFace failed: "
<<
WindowsErrorString
(
GetLastError
()));
SelectObject
(
hDC
,
hOrigFont
);
DeleteDC
(
hDC
);
return
false
;
}
SAL_INFO
(
"vcl.gdi.opengl"
,
OUString
(
sFaceName
,
nFaceNameLen
)
<<
SAL_INFO
(
"vcl.gdi.opengl"
,
OUString
(
sFaceName
,
nFaceNameLen
)
<<
": "
<<
sAlign
<<
": "
<<
sAlign
<<
" Escapement="
<<
aLogfont
.
lfEscapement
<<
" Escapement="
<<
aLogfont
.
lfEscapement
<<
...
...
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