void CATextField::setMarginLeft(int var) { m_iMarginLeft = var; DRect r = this->getBounds(); r.InflateRect(-m_iMarginLeft, 0, -m_iMarginRight, 0); ((CATextFieldWin32*)m_pTextField)->setFrame(r); delayShowImage(); }
void CATextField::setContentSize(const DSize& contentSize) { CAView::setContentSize(contentSize); if (m_pTextField) { DRect r = this->getBounds(); r.InflateRect(-m_iMarginLeft, 0, -m_iMarginRight, 0); ((CATextFieldWin32*)m_pTextField)->setFrame(r); } }
void CATextView::setContentSize(const DSize& contentSize) { CAView::setContentSize(contentSize); if (m_pBackgroundView) { m_pBackgroundView->setFrame(this->getBounds()); } if (m_pShowImageView) { m_pShowImageView->setFrame(this->getBounds()); } if (m_pTextView) { DRect r = this->getBounds(); r.InflateRect(-5); ((CATextViewWin32*)m_pTextView)->setFrame(r); } }