gsl-shell.git - gsl-shell

index : gsl-shell.git
gsl-shell
summary refs log tree commit diff
path: root/agg-plot/rect.h
diff options
context:
space:
mode:
Diffstat (limited to 'agg-plot/rect.h')
-rw-r--r--agg-plot/rect.h 16
1 files changed, 16 insertions, 0 deletions
diff --git a/agg-plot/rect.h b/agg-plot/rect.h
index 3205da6c..d768d0dd 100644
--- a/agg-plot/rect.h
+++ b/agg-plot/rect.h
@@ -20,10 +20,20 @@ public:
void clear() {
m_defined = false;
};
+
void set(const rect_type& r) {
m_defined = true;
m_rect = r;
};
+
+ void set(T x1, T y1, T x2, T y2) {
+ m_defined = true;
+ m_rect.x1 = x1;
+ m_rect.y1 = y1;
+ m_rect.x2 = x2;
+ m_rect.y2 = y2;
+ };
+
bool is_defined() const {
return m_defined;
};
@@ -41,6 +51,12 @@ public:
m_rect = src.m_rect;
}
+ void operator = (const rect_type& src)
+ {
+ m_defined = true;
+ m_rect = src;
+ }
+
template <set_oper_e op>
void add(const rect_type& r)
{
generated by cgit v1.2.3 (git 2.39.1) at 2025年09月19日 23:20:20 +0000

AltStyle によって変換されたページ (->オリジナル) /