aknfontspecification.h

Go to the documentation of this file.
00001 /*
00002 * ============================================================================
00003 *  Name     : AknFontSpecification.h
00004 *  Part of  : FontUtils
00005 *
00006 *  Copyright © 2002-2005 Nokia. All rights reserved.
00007 *  This material, including documentation and any related 
00008 *  computer programs, is protected by copyright controlled by 
00009 *  Nokia. All rights are reserved. Copying, including 
00010 *  reproducing, storing, adapting or translating, any 
00011 *  or all of this material requires the prior written consent of 
00012 *  Nokia. This material also contains confidential 
00013 *  information which may not be disclosed to others without the 
00014 *  prior written consent of Nokia.
00015 * ==============================================================================
00016 */
00017 
00018 #ifndef AKNFONTSPECIFICATION_H
00019 #define AKNFONTSPECIFICATION_H
00020 
00021 #include <gdi.h>
00022 #include <AknFontCategory.hrh>
00023 #include <babitflags.h>
00024 
00036 class TAknFontSpecification
00037     {
00038 public:
00039 
00040     enum TAknFontSpecificationUnits
00041         {
00042         EPixels = 0,
00043         ETwips
00044         };
00045 
00046 public:
00052     IMPORT_C TAknFontSpecification( TInt aFontId );
00053 
00068     IMPORT_C TAknFontSpecification(  
00069         TAknFontCategory aCategory, 
00070         const TFontSpec& aFontSpec, 
00071         const MGraphicsDeviceMap* aDeviceMap );
00072     
00078     IMPORT_C void SetFontCategory( TAknFontCategory aCategory );
00079     
00086     IMPORT_C TAknFontCategory FontCategory() const;
00087 
00104     IMPORT_C void SetTextPaneHeight( TInt aNewHeight );
00105 
00126     IMPORT_C TInt TextPaneHeight() const;
00127        
00133     IMPORT_C void SetWeight( TFontStrokeWeight aWeight );
00134     
00139     IMPORT_C void SetPosture( TFontPosture aPosture );
00140     
00157     IMPORT_C void SetTextPaneHeightIsDesignHeight( TBool aTextPaneHeightIsDesignHeight );
00158     
00165     IMPORT_C TBool TextPaneIsDesignHeight() const;
00166 
00177     IMPORT_C void SetExactMatchRequired ( TBool aRequiresExactMatch );
00178     
00184     IMPORT_C TBool ExactMatchRequired() const;
00185 
00195     IMPORT_C void SetUnits( TAknFontSpecification::TAknFontSpecificationUnits aUnits );
00196 
00202     IMPORT_C TAknFontSpecification::TAknFontSpecificationUnits Units() const;     
00203    
00209     IMPORT_C TFontStrokeWeight Weight() const ;
00210     
00216     IMPORT_C TFontPosture Posture() const;
00217 
00218 private:
00219     void LoadAnyCDLFontInstanceL();
00220 
00221 private:
00222     TAknFontCategory iBaseFontCategory;
00223     TInt iTextPaneHeight;
00224     // Symbian OS Font Style object convenient for holding style info
00225     TFontStyle iRequiredStyle;
00226     TBitFlags iFlags;
00227     TInt iSpare2; 
00228     };
00229 
00230 #endif
00231 // End of File

Copyright © Nokia Corporation 2001-2008
Back to top