add Canvas::Ruler::set_metric() to allow ruler metrics to be changed dynamically
This commit is contained in:
parent
1a6136e1e3
commit
94adde7ebb
@ -62,6 +62,7 @@ public:
|
||||
|
||||
void set_range (double lower, double upper);
|
||||
void set_font_description (Pango::FontDescription);
|
||||
void set_metric (const Metric&);
|
||||
|
||||
void render (Rect const & area, Cairo::RefPtr<Cairo::Context>) const;
|
||||
|
||||
|
@ -180,3 +180,11 @@ Ruler::render (Rect const & area, Cairo::RefPtr<Cairo::Context> cr) const
|
||||
|
||||
/* done! */
|
||||
}
|
||||
|
||||
void
|
||||
Ruler::set_metric (const Metric& m)
|
||||
{
|
||||
_metric = &m;
|
||||
_need_marks = true;
|
||||
redraw ();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user