[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    branches/work/koffice-essen/libs/odf
From:       Carlos Licea <carlos_licea () hotmail ! com>
Date:       2010-11-10 2:08:27
Message-ID: 20101110020827.A7F83AC8A5 () svn ! kde ! org
[Download RAW message or body]

SVN commit 1194896 by clicea:

Fix KoColumnStyle.

 A             KoColumnStyle.cpp   [License: LGPL (v2+)]
 M  +26 -9     KoColumnStyle.h  


--- branches/work/koffice-essen/libs/odf/KoColumnStyle.h #1194895:1194896
@@ -20,6 +20,7 @@
 #define KOCOLUMNSTYLE_H
 
 #include "KoStyle.h"
+#include "koodf_export.h"
 
 /**
  * A \class KoColumnStyle represents a style to be applied to one or more columns.
@@ -27,17 +28,25 @@
  * As all the styles it can be shared
  */
 
-class KoColumnStyle : public KoStyle
+class KOODF_EXPORT KoColumnStyle : public KoStyle
 {
+    KoColumnStyle();
 public:
-    KoColumnStyle();
+    KOSTYLE_DECLARE_SHARED_POINTER(KoColumnStyle)
+
     ~KoColumnStyle();
 
-    void setBreakBefore(bool breakBefore);
-    bool breakBefore() const;
+    enum BreakType {
+        NoBreak,
+        AutoBreak,
+        ColumnBreak,
+        PageBreak
+    };
+    void setBreakBefore(BreakType breakBefore);
+    BreakType breakBefore() const;
 
-    void setBreakAfter(bool breakAfter);
-    bool breakAfter() const;
+    void setBreakAfter(BreakType breakAfter);
+    BreakType breakAfter() const;
 
     enum WidthType{
         MinimumWidth,
@@ -45,12 +54,20 @@
         OptimalWidth
     };
     void setWidth(qreal width);
+    qreal width() const;
     void setWidthType(WidthType type);
-    qreal width() const;
+    WidthType widthType() const;
 
+protected:
+    virtual void prepareStyle(KoGenStyle& style) const;
+    virtual QString defaultPrefix() const;
+    virtual KoGenStyle::Type styleType() const;
+    virtual KoGenStyle::Type automaticstyleType() const;
+    virtual const char* styleFamilyName() const;
+
 private:
-    bool m_breakAfter;
-    bool m_breakBefore;
+    BreakType m_breakAfter;
+    BreakType m_breakBefore;
     qreal m_width;
     WidthType m_widthType;
 };
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic