From 258b3eff815842e0c26c075e1d9d5e03ae2ed1a9 Mon Sep 17 00:00:00 2001 From: Julian Storer Date: Thu, 15 Apr 2010 13:58:17 +0100 Subject: [PATCH] Removed some win32 warnings, made CustomTypeface automatically update its ascent. --- juce_amalgamated.cpp | 2 ++ juce_amalgamated.h | 2 ++ src/containers/juce_ScopedPointer.h | 2 ++ src/gui/graphics/fonts/juce_Typeface.cpp | 2 ++ 4 files changed, 8 insertions(+) diff --git a/juce_amalgamated.cpp b/juce_amalgamated.cpp index 9925dfc86b..3687087044 100644 --- a/juce_amalgamated.cpp +++ b/juce_amalgamated.cpp @@ -86511,6 +86511,8 @@ bool CustomTypeface::loadGlyphIfPossible (const juce_wchar /*characterNeeded*/) void CustomTypeface::addGlyphsFromOtherTypeface (Typeface& typefaceToCopy, juce_wchar characterStartIndex, int numCharacters) throw() { + setCharacteristics (name, typefaceToCopy.getAscent(), isBold, isItalic, defaultCharacter); + for (int i = 0; i < numCharacters; ++i) { const juce_wchar c = (juce_wchar) (characterStartIndex + i); diff --git a/juce_amalgamated.h b/juce_amalgamated.h index beb43993d5..86bb66a719 100644 --- a/juce_amalgamated.h +++ b/juce_amalgamated.h @@ -3485,9 +3485,11 @@ private: // (Required as an alternative to the overloaded & operator). const ScopedPointer* getAddress() const throw() { return this; } + #if ! JUCE_MSVC // (MSVC can't deal with multiple copy constructors) // This is private to stop people accidentally copying a const ScopedPointer (the compiler // will let you do so by implicitly casting the source to its raw object pointer). ScopedPointer (const ScopedPointer&); + #endif }; template diff --git a/src/containers/juce_ScopedPointer.h b/src/containers/juce_ScopedPointer.h index e3b7c071d9..f9f9eaf56b 100644 --- a/src/containers/juce_ScopedPointer.h +++ b/src/containers/juce_ScopedPointer.h @@ -167,9 +167,11 @@ private: // (Required as an alternative to the overloaded & operator). const ScopedPointer* getAddress() const throw() { return this; } + #if ! JUCE_MSVC // (MSVC can't deal with multiple copy constructors) // This is private to stop people accidentally copying a const ScopedPointer (the compiler // will let you do so by implicitly casting the source to its raw object pointer). ScopedPointer (const ScopedPointer&); + #endif }; //============================================================================== diff --git a/src/gui/graphics/fonts/juce_Typeface.cpp b/src/gui/graphics/fonts/juce_Typeface.cpp index a649986a54..d09d6754a0 100644 --- a/src/gui/graphics/fonts/juce_Typeface.cpp +++ b/src/gui/graphics/fonts/juce_Typeface.cpp @@ -238,6 +238,8 @@ bool CustomTypeface::loadGlyphIfPossible (const juce_wchar /*characterNeeded*/) void CustomTypeface::addGlyphsFromOtherTypeface (Typeface& typefaceToCopy, juce_wchar characterStartIndex, int numCharacters) throw() { + setCharacteristics (name, typefaceToCopy.getAscent(), isBold, isItalic, defaultCharacter); + for (int i = 0; i < numCharacters; ++i) { const juce_wchar c = (juce_wchar) (characterStartIndex + i);