summaryrefslogtreecommitdiffstats
path: root/src/sp-text.cpp
diff options
context:
space:
mode:
authorMarkus Engel <markus.engel@tum.de>2013-10-26 22:00:51 +0000
committerMarkus Engel <markus.engel@tum.de>2013-10-26 22:00:51 +0000
commit73edade30f70b4c0ad94c9561b4e4ec0675465b0 (patch)
treede55f48e427afc5faf8fb97467a8f79b86820b0f /src/sp-text.cpp
parentfix crash (diff)
downloadinkscape-73edade30f70b4c0ad94c9561b4e4ec0675465b0.tar.gz
inkscape-73edade30f70b4c0ad94c9561b4e4ec0675465b0.zip
Added some consts.
(bzr r12729)
Diffstat (limited to 'src/sp-text.cpp')
-rw-r--r--src/sp-text.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/sp-text.cpp b/src/sp-text.cpp
index de5e63fe6..11d0e1a6c 100644
--- a/src/sp-text.cpp
+++ b/src/sp-text.cpp
@@ -293,7 +293,7 @@ Inkscape::XML::Node *SPText::write(Inkscape::XML::Document *xml_doc, Inkscape::X
return repr;
}
-Geom::OptRect SPText::bbox(Geom::Affine const &transform, SPItem::BBoxType type) {
+Geom::OptRect SPText::bbox(Geom::Affine const &transform, SPItem::BBoxType type) const {
Geom::OptRect bbox = SP_TEXT(this)->layout.bounds(transform);
// FIXME this code is incorrect
@@ -326,11 +326,11 @@ void SPText::hide(unsigned int key) {
}
}
-const char* SPText::displayName() {
+const char* SPText::displayName() const {
return _("Text");
}
-gchar* SPText::description() {
+gchar* SPText::description() const {
SPStyle *style = this->style;
font_instance *tf = font_factory::Default()->FaceFromStyle(style);
@@ -364,7 +364,7 @@ gchar* SPText::description() {
return ret;
}
-void SPText::snappoints(std::vector<Inkscape::SnapCandidatePoint> &p, Inkscape::SnapPreferences const *snapprefs) {
+void SPText::snappoints(std::vector<Inkscape::SnapCandidatePoint> &p, Inkscape::SnapPreferences const *snapprefs) const {
if (snapprefs->isTargetSnappable(Inkscape::SNAPTARGET_TEXT_BASELINE)) {
// Choose a point on the baseline for snapping from or to, with the horizontal position
// of this point depending on the text alignment (left vs. right)