[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic

2015-04-02 Thread Caolán McNamara
 vcl/generic/glyphs/gcach_layout.cxx |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 6bbc6df677bfb85f7410a18e36eca4f62360f4a9
Author: Caolán McNamara caol...@redhat.com
Date:   Thu Apr 2 09:30:44 2015 +0100

fix hang with ooo71962-1.odt

script run ends after chunk we are rendering

(cherry picked from commit 00bf3a4259c1f960eff05b17649cc734c275950f)

Change-Id: Idbfe11c385db72a80d3d204f8638d67395580d1b
Reviewed-on: https://gerrit.libreoffice.org/15116
Reviewed-by: Björn Michaelsen bjoern.michael...@canonical.com
Tested-by: Björn Michaelsen bjoern.michael...@canonical.com

diff --git a/vcl/generic/glyphs/gcach_layout.cxx 
b/vcl/generic/glyphs/gcach_layout.cxx
index bf2eab2..1194e70 100644
--- a/vcl/generic/glyphs/gcach_layout.cxx
+++ b/vcl/generic/glyphs/gcach_layout.cxx
@@ -399,7 +399,9 @@ bool HbLayoutEngine::layout(ServerFontLayout rLayout, 
ImplLayoutArgs rArgs)
 aScriptSubRuns.push_back(aRun);
 
 nCurrentPos = nEndRunPos;
-aScriptRun.next();
+bool bHasMore = aScriptRun.next();
+if (!bHasMore)
+break;
 }
 
 // RTL subruns should be reversed to ensure that final glyph order is
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic

2015-02-27 Thread Michael Stahl
 vcl/generic/glyphs/gcach_layout.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 623f16d7a47020600e2b4ba03aa6a617545b0d93
Author: Michael Stahl mst...@redhat.com
Date:   Tue Feb 24 21:32:54 2015 +0100

tdf#89666: vcl: speed up HbLayoutEngine line layout for large paragraphs

When formatting a 180k char Writer paragraph, most of the time is spent
in vcl::ScriptRun::next(), which is called twice per line from
SwTxtGuess::Guess(), once via GetTxtBreak() and once via GetTxtSize().

In the second call, from GetTxtSize(), the end position of the line is
known, and passed to vcl, and iterating beyond that position seems
pointless.

This reduces vcl::ScriptRun::next() from 24 to 11 billion callgrind
cycles when built with GCC 4.9.2 -m32 -Os.

(cherry picked from commit 7fde44c85620f8079bc4863fe3f7ea1f69a0f88c)

Conflicts:
vcl/generic/glyphs/gcach_layout.cxx

Change-Id: Ia23fcccaf5ef9c9ecdcb54bfc8f0f8a043c8711e
Reviewed-on: https://gerrit.libreoffice.org/14645
Reviewed-by: Caolán McNamara caol...@redhat.com
Tested-by: Caolán McNamara caol...@redhat.com

diff --git a/vcl/generic/glyphs/gcach_layout.cxx 
b/vcl/generic/glyphs/gcach_layout.cxx
index 3f065bb..bf2eab2 100644
--- a/vcl/generic/glyphs/gcach_layout.cxx
+++ b/vcl/generic/glyphs/gcach_layout.cxx
@@ -372,7 +372,7 @@ bool HbLayoutEngine::layout(ServerFontLayout rLayout, 
ImplLayoutArgs rArgs)
 
 rLayout.Reserve(nGlyphCapacity);
 
-ScriptRun aScriptRun(reinterpret_castconst UChar *(rArgs.mpStr), 
rArgs.mnLength);
+ScriptRun aScriptRun(reinterpret_castconst UChar *(rArgs.mpStr), 
rArgs.mnEndCharPos);
 
 Point aCurrPos(0, 0);
 while (true)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic vcl/inc

2015-02-12 Thread Martin Hosken
 vcl/generic/glyphs/graphite_serverfont.cxx |4 ++--
 vcl/inc/graphite_layout.hxx|   18 +++---
 2 files changed, 13 insertions(+), 9 deletions(-)

New commits:
commit 0c2447648961bc8fa4776f996604fead893e3be4
Author: Martin Hosken martin_hos...@sil.org
Date:   Mon Feb 9 16:49:12 2015 +0700

Resolves: tdf#89252 Fix bold, regular font spacing bug for Graphite fonts

Change-Id: I31a09fa753ed15e302e5407ce8a0c46f3b13e099
Reviewed-on: https://gerrit.libreoffice.org/14380
Reviewed-by: Caolán McNamara caol...@redhat.com
Tested-by: Caolán McNamara caol...@redhat.com
(cherry picked from commit 0ed14401925d16932ed98bc418d395adac047b39)
Reviewed-on: https://gerrit.libreoffice.org/14439

diff --git a/vcl/generic/glyphs/graphite_serverfont.cxx 
b/vcl/generic/glyphs/graphite_serverfont.cxx
index 09159e4..3549c01 100644
--- a/vcl/generic/glyphs/graphite_serverfont.cxx
+++ b/vcl/generic/glyphs/graphite_serverfont.cxx
@@ -48,7 +48,7 @@ 
GraphiteServerFontLayout::GraphiteServerFontLayout(ServerFont rServerFont) thro
 , mpFeatures(NULL)
 , mpStr(NULL)
 {
-gr_font * pFont = 
rServerFont.GetGraphiteFace()-font(rServerFont.GetFontSelData().mnHeight);
+gr_font * pFont = 
rServerFont.GetGraphiteFace()-font(rServerFont.GetFontSelData().mnHeight, 
rServerFont.NeedsArtificialBold(), rServerFont.NeedsArtificialItalic());
 if (!pFont)
 {
 pFont = gr_make_font_with_advance_fn(
@@ -57,7 +57,7 @@ 
GraphiteServerFontLayout::GraphiteServerFontLayout(ServerFont rServerFont) thro
rServerFont,
freetypeServerFontAdvance,
rServerFont.GetGraphiteFace()-face());
-
rServerFont.GetGraphiteFace()-addFont(rServerFont.GetFontSelData().mnHeight, 
pFont);
+
rServerFont.GetGraphiteFace()-addFont(rServerFont.GetFontSelData().mnHeight, 
pFont, rServerFont.NeedsArtificialBold(), rServerFont.NeedsArtificialItalic());
 }
 maImpl.SetFont(pFont);
 OString aLang();
diff --git a/vcl/inc/graphite_layout.hxx b/vcl/inc/graphite_layout.hxx
index 6a84d54..c53b551 100644
--- a/vcl/inc/graphite_layout.hxx
+++ b/vcl/inc/graphite_layout.hxx
@@ -52,7 +52,8 @@ namespace grutils { class GrFeatureParser; }
 class GraphiteFaceWrapper
 {
 public:
-typedef std::mapint, gr_font* GrFontMap;
+typedef std::pairint, int GrFontMapKey;
+typedef std::mapGrFontMapKey, gr_font* GrFontMap;
 GraphiteFaceWrapper(gr_face * pFace) : m_pFace(pFace) {}
 ~GraphiteFaceWrapper()
 {
@@ -63,18 +64,21 @@ public:
 gr_face_destroy(m_pFace);
 }
 const gr_face * face() const { return m_pFace; }
-gr_font * font(int ppm) const
+gr_font * font(int ppm, bool isBold, bool isItalic) const
 {
-GrFontMap::const_iterator i = m_fonts.find(ppm);
+int styleKey = int(isBold) | (int(isItalic)  1);
+GrFontMap::const_iterator i = m_fonts.find(GrFontMapKey(ppm, 
styleKey));
 if (i != m_fonts.end())
 return i-second;
 return NULL;
 };
-void addFont(int ppm, gr_font * pFont)
+void addFont(int ppm, gr_font * pFont, bool isBold, bool isItalic)
 {
-if (m_fonts[ppm])
-gr_font_destroy(m_fonts[ppm]);
-m_fonts[ppm] = pFont;
+int styleKey = int(isBold) | (int(isItalic)  1);
+GrFontMapKey key(ppm, styleKey);
+if (m_fonts[key])
+gr_font_destroy(m_fonts[key]);
+m_fonts[key] = pFont;
 }
 private:
 gr_face * m_pFace;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic vcl/headless vcl/inc vcl/quartz vcl/source vcl/unx vcl/win

2015-01-30 Thread Michael Stahl
 vcl/generic/fontmanager/fontmanager.cxx |   25 +++-
 vcl/generic/print/genpspgraphics.cxx|8 +++
 vcl/headless/svptext.cxx|4 +--
 vcl/inc/fontmanager.hxx |7 +-
 vcl/inc/generic/genpspgraphics.h|6 +++--
 vcl/inc/headless/svpgdi.hxx |2 -
 vcl/inc/quartz/salgdi.h |2 -
 vcl/inc/salgdi.hxx  |3 +-
 vcl/inc/unx/salgdi.h|2 -
 vcl/inc/win/salgdi.h|2 -
 vcl/quartz/salgdi.cxx   |2 -
 vcl/source/gdi/pdfwriter_impl.cxx   |   33 
 vcl/unx/generic/gdi/salgdi3.cxx |4 +--
 vcl/win/source/gdi/salgdi3.cxx  |2 -
 14 files changed, 79 insertions(+), 23 deletions(-)

New commits:
commit 2f1f564bc3adf161ea0e9d6f81cb5f73a2097132
Author: Michael Stahl mst...@redhat.com
Date:   Tue Jan 27 00:20:58 2015 +0100

rhbz#1177022: vcl: fix PDF embedding of Type 1 fonts

Problem is that for the CM Typewriter font the Width for space (32)
is exported as 0 instead of 525, which is the correct value in the AFM.

The reason is that PDFWriterImpl::emitEmbeddedFont() has various arrays
to map from font code points to Unicode code points, and there are
duplicate mappings, so the 160-32 mapping overrides 32-32.

The PrintFontManager::PrintFont::readAfmMetrics() actually creates a
Unicode to font code mapping (which may legitimately be n:1) that is
then inverted; add an additional hack to store a set of preferred
Unicodes so that PDFWriterImpl can pick the right Unicode.

Presumably the code that is stored explicitly via C or CH in the
AFM should take priority over more generic mappings.

(cherry picked from commit 5183910a90e97cafc3cfaaad40acdaec0b792f6d)

Conflicts:
vcl/inc/cairotextrender.hxx
vcl/inc/salgdi.hxx
vcl/inc/textrender.hxx
vcl/inc/unx/salgdi.h
vcl/source/gdi/pdfwriter_impl.cxx
vcl/unx/generic/gdi/cairotextrender.cxx
vcl/unx/generic/gdi/salgdi3.cxx

Change-Id: Id4205a1cd45ba6a0a5facee1e39f70c3535e7dd4
Reviewed-on: https://gerrit.libreoffice.org/14207
Reviewed-by: Caolán McNamara caol...@redhat.com
Tested-by: Caolán McNamara caol...@redhat.com

diff --git a/vcl/generic/fontmanager/fontmanager.cxx 
b/vcl/generic/fontmanager/fontmanager.cxx
index 0677625..2bef8ad 100644
--- a/vcl/generic/fontmanager/fontmanager.cxx
+++ b/vcl/generic/fontmanager/fontmanager.cxx
@@ -290,6 +290,7 @@ bool PrintFontManager::PrintFont::readAfmMetrics( 
MultiAtomProvider* pProvider,
 }
 
 m_aEncodingVector.clear();
+m_aEncodingVectorPriority.clear();
 // fill in global info
 
 // PSName
@@ -503,7 +504,10 @@ bool PrintFontManager::PrintFont::readAfmMetrics( 
MultiAtomProvider* pProvider,
 {
 pUnicodes[i] = pChar-code + 0xf000;
 if( bFillEncodingvector )
+{
 m_aEncodingVector[ pUnicodes[i] ] = pChar-code;
+m_aEncodingVectorPriority.insert(pUnicodes[i]);
+}
 continue;
 }
 
@@ -564,7 +568,10 @@ bool PrintFontManager::PrintFont::readAfmMetrics( 
MultiAtomProvider* pProvider,
 {
 m_pMetrics-m_aMetrics[ pUnicodes[i] ] = aMetric;
 if( bFillEncodingvector )
+{
 m_aEncodingVector[ pUnicodes[i] ] = pChar-code;
+m_aEncodingVectorPriority.insert(pUnicodes[i]);
+}
 }
 else if( pChar-name )
 {
@@ -592,13 +599,21 @@ bool PrintFontManager::PrintFont::readAfmMetrics( 
MultiAtomProvider* pProvider,
 ::std::pair ::boost::unordered_multimap sal_uInt8, 
sal_Unicode ::const_iterator,
   ::boost::unordered_multimap sal_uInt8, sal_Unicode 
::const_iterator 
   aCodes = rManager.getUnicodeFromAdobeCode( 
pChar-code );
+bool bFirst = true;
 while( aCodes.first != aCodes.second )
 {
 if( (*aCodes.first).second != 0 )
 {
 m_pMetrics-m_aMetrics[ (*aCodes.first).second ] = 
aMetric;
 if( bFillEncodingvector )
+{
 m_aEncodingVector[ (*aCodes.first).second ] = 
pChar-code;
+if (bFirst) // arbitrarily prefer the first one
+{
+
m_aEncodingVectorPriority.insert((*aCodes.first).second);
+bFirst = false;
+}
+}
 

[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic

2014-12-02 Thread Caolán McNamara
 vcl/generic/glyphs/scrptrun.cxx |6 +-
 vcl/generic/glyphs/scrptrun.h   |4 +++-
 2 files changed, 8 insertions(+), 2 deletions(-)

New commits:
commit a4025724d5885c3f9032247d82930711ce56ccd0
Author: Caolán McNamara caol...@redhat.com
Date:   Sat Nov 29 16:44:12 2014 +

give us a parenStack which can grow to fit any input

Change-Id: Ic464184fe367da33bf8c4790b82656b140e3cbd0
(cherry picked from commit cced2f6b866877c39afe86f4af18622cb4022bef)
Reviewed-on: https://gerrit.libreoffice.org/13217
Reviewed-by: Michael Stahl mst...@redhat.com
Tested-by: Michael Stahl mst...@redhat.com

diff --git a/vcl/generic/glyphs/scrptrun.cxx b/vcl/generic/glyphs/scrptrun.cxx
index f72d296..6df7659 100644
--- a/vcl/generic/glyphs/scrptrun.cxx
+++ b/vcl/generic/glyphs/scrptrun.cxx
@@ -173,7 +173,11 @@ UBool ScriptRun::next()
 // characters above it on the stack will be poped.
 if (pairIndex = 0) {
 if ((pairIndex  1) == 0) {
-parenStack[++parenSP].pairIndex = pairIndex;
+++parenSP;
+int32_t nVecSize = parenStack.size();
+if (parenSP == nVecSize)
+parenStack.resize(nVecSize + 128);
+parenStack[parenSP].pairIndex = pairIndex;
 parenStack[parenSP].scriptCode  = scriptCode;
 } else if (parenSP = 0) {
 int32_t pi = pairIndex  ~1;
diff --git a/vcl/generic/glyphs/scrptrun.h b/vcl/generic/glyphs/scrptrun.h
index 6e9bbd6..1c4d0fa 100644
--- a/vcl/generic/glyphs/scrptrun.h
+++ b/vcl/generic/glyphs/scrptrun.h
@@ -43,6 +43,7 @@
 #include unicode/utypes.h
 #include unicode/uobject.h
 #include unicode/uscript.h
+#include vector
 
 struct ScriptRecord
 {
@@ -110,7 +111,7 @@ private:
 int32_t scriptEnd;
 UScriptCode scriptCode;
 
-ParenStackEntry parenStack[128];
+std::vectorParenStackEntry parenStack;
 int32_t parenSP;
 
 static int8_t highBit(int32_t value);
@@ -164,6 +165,7 @@ inline void ScriptRun::reset()
 scriptEnd   = charStart;
 scriptCode  = USCRIPT_INVALID_CODE;
 parenSP = -1;
+parenStack.resize(128);
 }
 
 inline void ScriptRun::reset(int32_t start, int32_t length)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic

2014-10-01 Thread Caolán McNamara
 vcl/generic/glyphs/gcach_ftyp.cxx |   11 +--
 1 file changed, 5 insertions(+), 6 deletions(-)

New commits:
commit 5aceca0f5bf25d535c33a726d698777322b378d7
Author: Caolán McNamara caol...@redhat.com
Date:   Thu Sep 11 14:16:05 2014 +0100

server font dtor always calls ReleaseFaceFT

therefore we must always call GetFaceFT in the ctor
and not return early *before* calling GetFaceFT which
could happen in case of inane font size requests, i.e.

if( (mnWidth  0) || (mfStretch  +64.0) || (mfStretch  -64.0) )

valgrind+bff

Change-Id: If22f8f7ff6aaed3ffa9eec68630da8601dfd5cae
(cherry picked from commit 884229ed3ee2f84eb052c866e22bdb242a385788)
Reviewed-on: https://gerrit.libreoffice.org/11400
Reviewed-by: Miklos Vajna vmik...@collabora.co.uk
Tested-by: Miklos Vajna vmik...@collabora.co.uk

diff --git a/vcl/generic/glyphs/gcach_ftyp.cxx 
b/vcl/generic/glyphs/gcach_ftyp.cxx
index 47adb09..3978f02 100644
--- a/vcl/generic/glyphs/gcach_ftyp.cxx
+++ b/vcl/generic/glyphs/gcach_ftyp.cxx
@@ -488,6 +488,10 @@ ServerFont::ServerFont( const FontSelectPattern rFSD, 
FtFontInfo* pFI )
 // it becomes reponsible for the ServerFont instantiation
 ((ImplServerFontEntry*)rFSD.mpFontEntry)-SetServerFont( this );
 
+maFaceFT = pFI-GetFaceFT();
+if( !maFaceFT )
+return;
+
 if( rFSD.mnOrientation != 0 )
 {
 const double dRad = rFSD.mnOrientation * ( F_2PI / 3600.0 );
@@ -504,10 +508,6 @@ ServerFont::ServerFont( const FontSelectPattern rFSD, 
FtFontInfo* pFI )
 if( (mnWidth  0) || (mfStretch  +64.0) || (mfStretch  -64.0) )
 return;
 
-maFaceFT = pFI-GetFaceFT();
-if( !maFaceFT )
-return;
-
 FT_New_Size( maFaceFT, maSizeFT );
 FT_Activate_Size( maSizeFT );
 FT_Error rc = FT_Set_Pixel_Sizes( maFaceFT, mnWidth, rFSD.mnHeight );
@@ -627,8 +627,7 @@ bool ServerFont::TestFont() const
 
 ServerFont::~ServerFont()
 {
-if( mpLayoutEngine )
-delete mpLayoutEngine;
+delete mpLayoutEngine;
 
 if( maSizeFT )
 FT_Done_Size( maSizeFT );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic vcl/source

2014-09-13 Thread Caolán McNamara
 vcl/generic/fontmanager/fontmanager.cxx |   72 
 vcl/source/fontsubset/sft.cxx   |   11 ++--
 2 files changed, 78 insertions(+), 5 deletions(-)

New commits:
commit 8618534a73e8c6b5cddb6a7cacedcc38b62bab33
Author: Caolán McNamara caol...@redhat.com
Date:   Thu Sep 11 17:11:33 2014 +0100

Support version 2 ttf fonts and mac font family name encodings

i.e. get loads more fonts working with LibreOffice

Related: fdo#82259 support version 2 ttc fonts on Linux

a lot of Mac OSX fonts are in this format, and we're not
seeing them under Linux

Change-Id: I8a6974ccb43afadec320331eb26bc4a2df9b13c9
(cherry picked from commit 02f8f895f2abc4ee090b4bd42963590aa018fb49)

Related: fdo#82259 implement mac ttf fontname encoding support

which is why these font's are not appearing under Linux

Change-Id: Ib72ddb465b2df729953ece416cfa0477cd565bcd
(cherry picked from commit 9436ae99438ccc24a86aff61aaa9174a9686814f)
Reviewed-on: https://gerrit.libreoffice.org/11419
Reviewed-by: David Tardon dtar...@redhat.com
Tested-by: David Tardon dtar...@redhat.com

diff --git a/vcl/generic/fontmanager/fontmanager.cxx 
b/vcl/generic/fontmanager/fontmanager.cxx
index 3936c88..0677625 100644
--- a/vcl/generic/fontmanager/fontmanager.cxx
+++ b/vcl/generic/fontmanager/fontmanager.cxx
@@ -1018,6 +1018,65 @@ OUString PrintFontManager::convertTrueTypeName( void* 
pRecord ) const
 }
 }
 }
+else if( pNameRecord-platformID == 1 )
+{
+OString aName((const sal_Char*)(pNameRecord-sptr), pNameRecord-slen);
+rtl_TextEncoding eEncoding = RTL_TEXTENCODING_DONTKNOW;
+switch (pNameRecord-encodingID)
+{
+case 0:
+eEncoding = RTL_TEXTENCODING_APPLE_ROMAN;
+break;
+case 1:
+eEncoding = RTL_TEXTENCODING_APPLE_JAPANESE;
+break;
+case 2:
+eEncoding = RTL_TEXTENCODING_APPLE_CHINTRAD;
+break;
+case 3:
+eEncoding = RTL_TEXTENCODING_APPLE_KOREAN;
+break;
+case 4:
+eEncoding = RTL_TEXTENCODING_APPLE_ARABIC;
+break;
+case 5:
+eEncoding = RTL_TEXTENCODING_APPLE_HEBREW;
+break;
+case 6:
+eEncoding = RTL_TEXTENCODING_APPLE_GREEK;
+break;
+case 7:
+eEncoding = RTL_TEXTENCODING_APPLE_CYRILLIC;
+break;
+case 9:
+eEncoding = RTL_TEXTENCODING_APPLE_DEVANAGARI;
+break;
+case 10:
+eEncoding = RTL_TEXTENCODING_APPLE_GURMUKHI;
+break;
+case 11:
+eEncoding = RTL_TEXTENCODING_APPLE_GUJARATI;
+break;
+case 21:
+eEncoding = RTL_TEXTENCODING_APPLE_THAI;
+break;
+case 25:
+eEncoding = RTL_TEXTENCODING_APPLE_CHINSIMP;
+break;
+case 29:
+eEncoding = RTL_TEXTENCODING_APPLE_CENTEURO;
+break;
+case 32://Uninterpreted
+eEncoding = RTL_TEXTENCODING_UTF8;
+break;
+default:
+SAL_WARN(vcl, Unimplmented mac encoding   
pNameRecord-encodingID   to unicode conversion);
+break;
+}
+if (eEncoding != RTL_TEXTENCODING_DONTKNOW)
+aValue = OStringToOUString(aName, eEncoding);
+}
+
 return aValue;
 }
 
@@ -1077,8 +1136,21 @@ void PrintFontManager::analyzeTrueTypeFamilyName( void* 
pTTFont, ::std::list OU
 else
 nMatch = 1000;
 }
+else if( pNameRecords[i].platformID == 1 )
+{
+/*
+// to-do, mac to LanguageType conversion
+if( pNameRecords[i].languageID == aLang )
+nMatch = 8000;
+else*/ if( pNameRecords[i].languageID == 0 ) //English
+nMatch = 2000;
+else
+nMatch = 1000;
+}
 OUString aName = convertTrueTypeName( pNameRecords + i );
 aSet.insert( aName );
+if (aName.isEmpty())
+continue;
 if( nMatch  nLastMatch || isBadTNR(aName, aSet) )
 {
 nLastMatch = nMatch;
diff --git a/vcl/source/fontsubset/sft.cxx b/vcl/source/fontsubset/sft.cxx
index c40d75c..a72627b 100644
--- a/vcl/source/fontsubset/sft.cxx
+++ b/vcl/source/fontsubset/sft.cxx
@@ -1476,14 +1476,15 @@ static int doOpenTTFont( sal_uInt32 facenum, 
TrueTypeFont* t )
 sal_uInt32 tdoffset = 0;/* offset to TableDirectory in a TTC file. 
For TTF files is 0 */
 int indexfmt;
 
-sal_uInt32 version = GetInt32(t-ptr, 0, 1);
+

[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic

2014-06-20 Thread Thorsten Behrens
 vcl/generic/glyphs/gcach_layout.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit a4090d9f9bfa7fbe9b25147f3c661c99714e83a6
Author: Thorsten Behrens t...@documentfoundation.org
Date:   Wed May 28 00:48:49 2014 +0200

Fix build to work with older harfbuzz versions.

Whee, seems hb has changed naming, with 0.9.11 it is spelled as
quoted. newer versions have a mapping in hb-deprecated.h ...

Change-Id: I425ded33e6b9928aadca9f6988437a021fcecbfb
(cherry picked from commit b3911e8adb34c6ee72577e58658b2cb72c6e79a3)

diff --git a/vcl/generic/glyphs/gcach_layout.cxx 
b/vcl/generic/glyphs/gcach_layout.cxx
index cbf3f9c..3f065bb 100644
--- a/vcl/generic/glyphs/gcach_layout.cxx
+++ b/vcl/generic/glyphs/gcach_layout.cxx
@@ -420,7 +420,7 @@ bool HbLayoutEngine::layout(ServerFontLayout rLayout, 
ImplLayoutArgs rArgs)
 
 static hb_unicode_funcs_t* pHbUnicodeFuncs = getUnicodeFuncs();
 
-int nHbFlags = HB_BUFFER_FLAG_DEFAULT;
+int nHbFlags = HB_BUFFER_FLAGS_DEFAULT;
 if (nMinRunPos == 0)
 nHbFlags |= HB_BUFFER_FLAG_BOT; /* Beginning-of-text */
 if (nEndRunPos == rArgs.mnLength)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - vcl/generic

2014-05-30 Thread Jan Holesovsky
 vcl/generic/print/common_gfx.cxx |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 6e6e03c9b7d591802c485acc5eb979c0e3ba5610
Author: Jan Holesovsky ke...@collabora.com
Date:   Wed May 28 12:57:44 2014 +0200

fdo#62719: Set more relaxed clipping region.

It actually is so that the line is in the output PostScript; and it is even
visible sometimes when you zoom the file (like, when you are zooming
continuously, the line is appearing and disappearing).

I guess it is a corner case of the clipping, highly dependent on the exact
settings, so let's be more relaxed and clip a bit less (as we already do for
right/bottom).

Hopefully some other functionality does not depend on this exact clip
setting ;-)

Change-Id: I7080ad3ff730408296f9e9dec7a0b74ac4afca7d

diff --git a/vcl/generic/print/common_gfx.cxx b/vcl/generic/print/common_gfx.cxx
index 7ff3a11..aa6e7c1 100644
--- a/vcl/generic/print/common_gfx.cxx
+++ b/vcl/generic/print/common_gfx.cxx
@@ -295,10 +295,10 @@ PrinterGfx::EndSetClipRegion()
 if( ! JoinVerticalClipRectangles( it, aOldPoint, nColumn ) )
 {
 // failed, so it is a single rectangle
-PSBinMoveTo (it-TopLeft(),  aOldPoint, 
nColumn );
-PSBinLineTo (Point( it-Left(), it-Bottom()+1 ),aOldPoint, 
nColumn );
+PSBinMoveTo (Point( it-Left()-1, it-Top()-1),  aOldPoint, 
nColumn );
+PSBinLineTo (Point( it-Left()-1, it-Bottom()+1 ),  aOldPoint, 
nColumn );
 PSBinLineTo (Point( it-Right()+1, it-Bottom()+1 ), aOldPoint, 
nColumn );
-PSBinLineTo (Point( it-Right()+1, it-Top() ),  aOldPoint, 
nColumn );
+PSBinLineTo (Point( it-Right()+1, it-Top()-1 ),aOldPoint, 
nColumn );
 ++it;
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits