Numworks Epsilon  1.4.1
Graphing Calculator Operating System
pointer_text_view.cpp
Go to the documentation of this file.
2 #include <assert.h>
3 
4 PointerTextView::PointerTextView(KDText::FontSize size, const char * text, float horizontalAlignment, float verticalAlignment,
5  KDColor textColor, KDColor backgroundColor) :
6  TextView(size, horizontalAlignment, verticalAlignment, textColor, backgroundColor),
7  m_text(text)
8 {
9 }
10 
11 void PointerTextView::setText(const char * text) {
12  if (text != m_text) {
13  m_text = text;
15  }
16 }
17 
20 }
KDText::FontSize m_fontSize
Definition: text_view.h:26
void setText(const char *text) override
static KDSize stringSize(const char *text, FontSize size=FontSize::Large)
Definition: text.cpp:6
void markRectAsDirty(KDRect rect)
Definition: view.cpp:39
Definition: size.h:6
KDSize minimalSizeForOptimalDisplay() const override
PointerTextView(KDText::FontSize size=KDText::FontSize::Large, const char *text=nullptr, float horizontalAlignment=0.0f, float verticalAlignment=0.0f, KDColor textColor=KDColorBlack, KDColor backgroundColor=KDColorWhite)
Definition: color.h:6
FontSize
Definition: text.h:10
KDRect bounds() const
Definition: view.cpp:157
const char * text() const override