Added comment support to inja templates in links and tooltips
This commit is contained in:
@@ -87,4 +87,11 @@ void decorated_element::append(const decorated_element &de)
|
||||
decorators_.push_back(d);
|
||||
}
|
||||
}
|
||||
|
||||
std::optional<std::string> decorated_element::comment() const
|
||||
{
|
||||
return comment_;
|
||||
}
|
||||
|
||||
void decorated_element::set_comment(const std::string &c) { comment_ = c; }
|
||||
}
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
#include "decorators/decorators.h"
|
||||
|
||||
#include <memory>
|
||||
#include <optional>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
@@ -45,8 +46,13 @@ public:
|
||||
|
||||
void append(const decorated_element &de);
|
||||
|
||||
std::optional<std::string> comment() const;
|
||||
|
||||
void set_comment(const std::string &c);
|
||||
|
||||
private:
|
||||
std::vector<std::shared_ptr<decorators::decorator>> decorators_;
|
||||
std::optional<std::string> comment_;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user