]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/carbon/fontenum.cpp
fix off by one (or rather "off by border width") bug in ScrollWindow() (part of patch...
[wxWidgets.git] / src / mac / carbon / fontenum.cpp
index f99cc1fd028ca5ef11df4d269b83bd5fddf247a8..6db95ec8456ac00a14e31d06f36321ea8f7cbbbc 100644 (file)
@@ -12,7 +12,7 @@
 // For compilers that support precompilation, includes "wx.h".
 #include "wx/wxprec.h"
 
-#if wxUSE_FONTMAP
+#if wxUSE_FONTENUM
 
 #include "wx/fontenum.h"
 
@@ -37,26 +37,28 @@ bool wxFontEnumerator::EnumerateFacenames(wxFontEncoding encoding,
     //
     // From Apple's QA 1471 http://developer.apple.com/qa/qa2006/qa1471.html
     //
-    
+
     ATSFontFamilyIterator theFontFamilyIterator = NULL;
     ATSFontFamilyRef theATSFontFamilyRef = 0;
     OSStatus status = noErr;
-    
+
     wxArrayString fontFamilies ;
-    
+
     // Create the iterator
     status = ATSFontFamilyIteratorCreate(kATSFontContextLocal, nil,nil,
                                          kATSOptionFlagsUnRestrictedScope,
                                          &theFontFamilyIterator );
-    
+
     wxUint32 macEncoding = wxMacGetSystemEncFromFontEnc(encoding) ;
-    
+
     while (status == noErr)
     {
         // Get the next font in the iteration.
         status = ATSFontFamilyIteratorNext( theFontFamilyIterator, &theATSFontFamilyRef );
         if(status == noErr)
         {
+ #ifndef __LP64__
+            // TODO CS : Find replacement
             // added CS : avoid showing fonts that won't be displayable
             FMFontStyle intrinsicStyle = 0 ;
             FMFont fontInstance ;
@@ -67,14 +69,14 @@ bool wxFontEnumerator::EnumerateFacenames(wxFontEncoding encoding,
                 status = noErr;
                 continue ;
             }
-            
+#endif
             if ( encoding != wxFONTENCODING_SYSTEM )
             {
                 TextEncoding fontFamiliyEncoding = ATSFontFamilyGetEncoding(theATSFontFamilyRef) ;
                 if ( fontFamiliyEncoding != macEncoding )
                     continue ;
             }
-            
+
             // TODO: determine fixed widths ...
 
             CFStringRef theName = NULL;
@@ -92,13 +94,13 @@ bool wxFontEnumerator::EnumerateFacenames(wxFontEncoding encoding,
         }
     }
     ATSFontFamilyIteratorRelease(&theFontFamilyIterator);
-    
+
     for ( size_t i = 0 ; i < fontFamilies.Count() ; ++i )
     {
         if ( OnFacename( fontFamilies[i] ) == false )
             break ;
     }
-    
+
     return true;
 }
 
@@ -109,4 +111,4 @@ bool wxFontEnumerator::EnumerateEncodings(const wxString& family)
     return true;
 }
 
-#endif // wxUSE_FONTMAP
+#endif // wxUSE_FONTENUM