- DrawTextRectangle( dc, GetCellValue( row, col ), rect2, hAlign, vAlign );
+
+ if ( useValueArg )
+ {
+ DrawTextRectangle( dc, value, rect2, hAlign, vAlign );
+ }
+ else
+ {
+ DrawTextRectangle( dc, GetCellValue( row, col ), rect2, hAlign, vAlign );
+ }
+}
+
+
+// this is used to echo text being entered into the top edit control when
+// in-place editing is turned off
+//
+void wxGrid::DrawCellValue( const wxGridCellCoords& coords, const wxString& value )
+{
+ if ( IsVisible( coords ) )
+ {
+ int row = coords.GetRow();
+ int col = coords.GetCol();
+ wxRect rect;
+ rect.x = m_colRights[ col ] - m_colWidths[ col ];
+ rect.y = m_rowBottoms[ row ] - m_rowHeights[ row ];
+ rect.width = m_colWidths[ col ];
+ rect.height = m_rowHeights[ row ];
+
+ wxClientDC dc( this );
+ DrawCellBackground( dc, rect, row, col );
+ DrawCellValue( dc, rect, row, col, value, TRUE );
+ }