From 34158fee38374ff5bfea882785fed924b2a18e41 Mon Sep 17 00:00:00 2001 From: =?utf8?q?W=C5=82odzimierz=20Skiba?= Date: Fri, 5 Nov 2004 21:04:46 +0000 Subject: [PATCH] Simplify wxRect construction at the wxPoint(0,0) with given size. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30301 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/univ/textctrl.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/univ/textctrl.cpp b/src/univ/textctrl.cpp index 84f5c7d78b..167cf32f27 100644 --- a/src/univ/textctrl.cpp +++ b/src/univ/textctrl.cpp @@ -695,7 +695,7 @@ bool wxTextCtrl::Create(wxWindow *parent, // create data object for single line controls m_data.sdata = new wxTextSingleLineData; } - + #if wxUSE_TWO_WINDOWS if ((style & wxBORDER_MASK) == 0) style |= wxBORDER_SUNKEN; @@ -1650,7 +1650,7 @@ wxString wxTextCtrl::GetLineText(wxTextCoord line) const { //this is called during DoGetBestSize if (line == 0 && GetLineCount() == 0) return wxEmptyString ; - + wxCHECK_MSG( (size_t)line < GetLineCount(), _T(""), _T("line index out of range") ); @@ -2360,7 +2360,7 @@ wxSize wxTextCtrl::DoGetBestClientSize() const void wxTextCtrl::UpdateTextRect() { - wxRect rectTotal(wxPoint(0, 0), GetClientSize()); + wxRect rectTotal(GetClientSize()); wxCoord *extraSpace = WrapLines() ? &WData().m_widthMark : NULL; m_rectText = GetRenderer()->GetTextClientArea(this, rectTotal, extraSpace); @@ -4146,7 +4146,7 @@ void wxTextCtrl::DoDraw(wxControlRenderer *renderer) // the update region is in window coords and text area is in the client // ones, so it must be shifted before computing intersection wxRegion rgnUpdate = GetUpdateRegion(); - + wxRect rectTextArea = GetRealTextArea(); wxPoint pt = GetClientAreaOrigin(); wxRect rectTextAreaAdjusted = rectTextArea; -- 2.45.2