summaryrefslogtreecommitdiffstats
path: root/part/kxetextviewsettings.h
diff options
context:
space:
mode:
authorSlávek Banko <[email protected]>2016-03-26 13:50:43 +0100
committerSlávek Banko <[email protected]>2016-03-26 13:50:43 +0100
commitd62c8c002c51fb7c36487839eeeb4ac89f044dee (patch)
treebb4d1f5c631ab1f22a3018ba39e6a806035f80fd /part/kxetextviewsettings.h
downloadkxmleditor-d62c8c002c51fb7c36487839eeeb4ac89f044dee.tar.gz
kxmleditor-d62c8c002c51fb7c36487839eeeb4ac89f044dee.zip
Initial import of kxmleditor 1.1.4
Diffstat (limited to 'part/kxetextviewsettings.h')
-rw-r--r--part/kxetextviewsettings.h105
1 files changed, 105 insertions, 0 deletions
diff --git a/part/kxetextviewsettings.h b/part/kxetextviewsettings.h
new file mode 100644
index 0000000..117282a
--- /dev/null
+++ b/part/kxetextviewsettings.h
@@ -0,0 +1,105 @@
+/***************************************************************************
+ kxetextviewsettings.h
+ --------------------
+ begin : Tue Dec 23 2003
+ copyright : (C) 2003 by The KXMLEditor Team
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+#ifndef KXETEXTVIEWSETTINGS_H
+#define KXETEXTVIEWSETTINGS_H
+
+#include "kxesettings.h"
+
+#include <qcolor.h>
+
+class KXETextViewSettingsPage;
+
+/**
+ * This class represents the group of configuration settings for
+ * the text view.
+ *
+ * @author Olaf Hartig
+ */
+class KXETextViewSettings : public KXESettings
+{
+ public:
+
+ KXETextViewSettings( QObject * pParent = 0, const char * pszName = 0 );
+
+ // The following functions can be used to access this object's settings.
+ const QColor & colorDfltText() const { return m_colorDfltText; }
+ const QColor & colorElemNames() const { return m_colorElemNames; }
+ const QColor & colorAttrNames() const { return m_colorAttrNames; }
+ const QColor & colorAttrValues() const { return m_colorAttrValues; }
+ const QColor & colorSyntaxChars() const { return m_colorSyntaxChars; }
+ const QColor & colorComments() const { return m_colorComments; }
+ const QColor & colorErrors() const { return m_colorErrors; }
+ int indentSteps() const { return m_iIndentSteps; }
+ bool isWrapOn() const { return m_bWrapOn; }
+
+ /**
+ * Derived from @ref KXESettings
+ */
+ virtual QString dialogPageName() const;
+ /**
+ * Derived from @ref KXESettings
+ */
+ virtual QString dialogPageHeader() const;
+ /**
+ * Derived from @ref KXESettings
+ */
+ virtual QString dialogPageIcon() const;
+ /**
+ * Derived from @ref KXESettings
+ */
+ virtual QWidget * dialogPage( QFrame * pParent );
+
+ protected:
+
+ /**
+ * Derived from @ref KXESettings
+ */
+ virtual void write( KConfig * ) const;
+ /**
+ * Derived from @ref KXESettings
+ */
+ virtual void read( const KConfig * );
+ /**
+ * Derived from @ref KXESettings
+ */
+ virtual void setFromPage();
+ /**
+ * Derived from @ref KXESettings
+ */
+ virtual void updatePage() const;
+
+ // the settings itself
+ QColor m_colorDfltText;
+ QColor m_colorElemNames;
+ QColor m_colorAttrNames;
+ QColor m_colorAttrValues;
+ QColor m_colorSyntaxChars;
+ QColor m_colorComments;
+ QColor m_colorErrors;
+ int m_iIndentSteps;
+ bool m_bWrapOn;
+
+ /**
+ * the corresponding configuration dialog page
+ * It is created on demand by @ref dialogPage.
+ */
+ KXETextViewSettingsPage * m_pDialogPage;
+
+};
+
+#endif