src/hbcore/utils/hbfontspec.cpp
changeset 5 627c4a0fd0e7
parent 1 f7ac710697a9
child 7 923ff622b8b9
--- a/src/hbcore/utils/hbfontspec.cpp	Thu May 27 13:10:59 2010 +0300
+++ b/src/hbcore/utils/hbfontspec.cpp	Fri Jun 11 13:58:22 2010 +0300
@@ -33,7 +33,7 @@
 #include <QFont>
 
 /*!
-	@stable
+    @stable
     @hbcore
     \class HbFontSpec
     \brief HbFontSpec is used to request a system font.
@@ -142,31 +142,31 @@
 #ifdef HB_BOOTSTRAPPED
     return 0;
 #else
-    if ( (mRole != HbFontSpec::Undefined) && (mTextHeight < 0) ) {
+    if ((mRole != HbFontSpec::Undefined) && (mTextHeight < 0)) {
         qreal parameterValue;
         QString parameterName;
-        switch (mRole){
-            case HbFontSpec::Primary:
-                parameterName = "hb-param-text-height-primary";
-                break;
-            case HbFontSpec::Secondary:
-                parameterName = "hb-param-text-height-secondary";
-                break;
-            case HbFontSpec::Title:    
-                parameterName = "hb-param-text-height-title";
-                break;
-            case HbFontSpec::PrimarySmall:
-                parameterName = "hb-param-text-height-tiny";
-                break;
-            case HbFontSpec::Digital:
-            default: // Usage of Secondary as the default system typeface
-                parameterName = "hb-param-text-height-secondary";
-                break;
+        switch (mRole) {
+        case HbFontSpec::Primary:
+            parameterName = "hb-param-text-height-primary";
+            break;
+        case HbFontSpec::Secondary:
+            parameterName = "hb-param-text-height-secondary";
+            break;
+        case HbFontSpec::Title:
+            parameterName = "hb-param-text-height-title";
+            break;
+        case HbFontSpec::PrimarySmall:
+            parameterName = "hb-param-text-height-tiny";
+            break;
+        case HbFontSpec::Digital:
+        default: // Usage of Secondary as the default system typeface
+            parameterName = "hb-param-text-height-secondary";
+            break;
         }
-        HbInstance::instance()->style()->parameter( parameterName, parameterValue );
+        HbInstance::instance()->style()->parameter(parameterName, parameterValue);
         mTextHeight = parameterValue;
     }
-	return mTextHeight;
+    return mTextHeight;
 #endif
 }
 
@@ -178,7 +178,7 @@
 #ifdef HB_BOOTSTRAPPED
     return QFont();
 #else
-    if ( mRole == HbFontSpec::Undefined ) {
+    if (mRole == HbFontSpec::Undefined) {
         return QFont();
     }
     QString typefaceFamily;
@@ -193,7 +193,7 @@
 
     // Sets default size if text height is not set explicitly.
     qreal height = textHeight();
-	int downSizedSize = tInfo->textHeightToSizeInPixels(typefaceFamily, weight, height);
+    int downSizedSize = tInfo->textHeightToSizeInPixels(typefaceFamily, weight, height);
     font.setPixelSize(downSizedSize);
 
     return font;
@@ -212,7 +212,7 @@
 /*!
     Constructs a new font spec with the given font \a role.
 */
-HbFontSpec::HbFontSpec(HbFontSpec::Role role) 
+HbFontSpec::HbFontSpec(HbFontSpec::Role role)
     : d(new HbFontSpecPrivate())
 {
     d->mRole = role;
@@ -307,9 +307,9 @@
     Returns true if this fontSpec is equal to \a other fontSpec; otherwise returns false.
 */
 bool HbFontSpec::operator==(const HbFontSpec &other) const
-{    
+{
     return ((d->mRole == other.d->mRole)
-        && qFuzzyCompare(d->textHeight(), other.d->textHeight()));
+            && qFuzzyCompare(d->textHeight(), other.d->textHeight()));
 }
 
 /*!
@@ -329,7 +329,7 @@
 */
 qreal HbFontSpec::textHeight() const
 {
-	return d->textHeight();
+    return d->textHeight();
 }
 
 /*!