Reimplemented from OglGui::Window. Definition at line 110 of file TableOverviewWindow.h. References OglGui::Window::DisplayFunc(), Impala::Application::VideoExcel::TableDataSource::GetFilteredRows(), Impala::Application::VideoExcel::TableDataSource::GetMark(), Impala::Application::VideoExcel::TableDataSource::GetNumberOfRows(), Impala::Application::VideoExcel::TableDataSource::GetStartRow(), OglGui::OglWindow::H(), MarkToColor(), mDrawHeight, mDrawOffset, mPixelCacheSynced, mSelPixelCache, mSource, RowToPixel(), UpdatePixelCache(), and OglGui::OglWindow::W(). 00111 { 00112 if (mSource->GetFilteredRows() == 0) 00113 { 00114 Window::DisplayFunc(); 00115 return; 00116 } 00117 00118 OGC myOGC; 00119 OGCSave(&myOGC); 00120 SetStipple((short)oglDot); 00121 SetSolidLineColor(0xff777777); 00122 00123 mDrawHeight = H() - 32; 00124 mDrawOffset = 16; 00125 // mark marked areas: 00126 if (mDrawHeight < mSource->GetFilteredRows()) 00127 { 00128 // more rows than pixels: use cached version of sampled rows 00129 if (!mPixelCacheSynced) 00130 UpdatePixelCache(mDrawHeight); 00131 00132 for (int i=0; i<mDrawHeight; i++) 00133 { 00134 unsigned long avgcol = mSelPixelCache[i]; 00135 if (avgcol > 0) 00136 { 00137 SetSolidFillColor(avgcol); 00138 FillRectangle(0, mDrawOffset+mDrawHeight-i, W(), 1); 00139 } 00140 } 00141 } 00142 else 00143 { 00144 // less rows than pixels, draw blocks 00145 for (int y = 0; y < mSource->GetFilteredRows(); y++) 00146 { 00147 int mark = mSource->GetMark(y); 00148 if (mark) 00149 { 00150 SetSolidFillColor(MarkToColor(mark)); 00151 int l = RowToPixel(1); 00152 int s = RowToPixel(y) + l; 00153 FillRectangle(0, mDrawOffset+mDrawHeight-s, W(), l+1); 00154 } 00155 } 00156 } 00157 00158 // mark current visible area: 00159 SetSolidFillColor(0xffffffff); 00160 int l = RowToPixel(mSource->GetNumberOfRows()); 00161 int s = RowToPixel(mSource->GetStartRow()) + l; 00162 FillRectangle(0,mDrawOffset+mDrawHeight-s, 8,l); 00163 FillRectangle(W()-8,mDrawOffset+mDrawHeight-s, 8,l); 00164 00165 OGCRestore(&myOGC); 00166 Window::DisplayFunc(); 00167 }
Here is the call graph for this function:
|