diff options
author | Stijn Buys <ingar@osirion.org> | 2012-02-21 22:30:21 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2012-02-21 22:30:21 +0000 |
commit | 0392694560d530c14aced7ac21f85b18b676a685 (patch) | |
tree | 2410f58516767913b6fdd5f2efcdca9fb1155fc2 /src/properties.h | |
parent | ba14d604adfee8b7596e0bfca81ad2720bbc0cf5 (diff) |
Initial support to preserve ini file comments
Diffstat (limited to 'src/properties.h')
-rw-r--r-- | src/properties.h | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/src/properties.h b/src/properties.h index 6faf885..c6147e4 100644 --- a/src/properties.h +++ b/src/properties.h @@ -56,7 +56,13 @@ public: return properties_color; } - + /** + * @brief returns the comment string of this object + * */ + inline const QString &comment() const { + return properties_comment; + } + /** * @brief returns the info string of this object * */ @@ -74,6 +80,13 @@ public: /* ---- mutators ---- */ /** + * @brief set the comments string of this object + * */ + inline void set_comment(const QString &text) { + properties_comment = text; + } + + /** * @brief set the info string of this object * */ inline void set_info(const QString &text) { @@ -95,7 +108,7 @@ public: /** * @brief add a value key pair to the values string * */ - void add_value(const QString &key, const QString &value); + void add_value(const QString &key, const QString &value, const QString &comment); /** * @brief set the object label @@ -151,6 +164,7 @@ public: } private: + QString properties_comment; QString properties_label; QString properties_name; |