17 #include "TGResourcePool.h"
41 m_widthOfTextInColumns(m_table->numberOfColumns(), static_cast<unsigned
int>(0)),
45 m_backgroundGC(ULONG_MAX),
59 gVirtualX->GrabButton(fId, kAnyButton, kAnyModifier, kButtonPressMask | kButtonReleaseMask,
kNone,
kNone);
60 m_table->Connect(
"visualPropertiesChanged()",
"FWTabularWidget",
this,
"needToRedraw()");
133 if (
event->fType == kButtonPress) {
134 Int_t row,
col, relX, relY;
137 if (row >= 0 && row < m_table->numberOfRows() &&
col >= 0 && col < m_table->numberOfColumns()) {
146 if (
event->fType == kButtonRelease) {
147 Int_t row,
col, relX, relY;
150 if (row >= 0 && row < m_table->numberOfRows() &&
col >= 0 && col < m_table->numberOfColumns()) {
163 Int_t iX, Int_t iY, Int_t& oRow, Int_t& oCol, Int_t& oRelX, Int_t& oRelY)
const {
193 if (oRow > numRows) {
203 args[0] = (Long_t)row;
204 args[1] = (Long_t)column;
206 args[3] = (Long_t)relX;
207 args[4] = (Long_t)relY;
208 Emit(
"buttonPressed(Int_t,Int_t,Event_t*,Int_t,Int_t)",
args);
213 args[0] = (Long_t)row;
214 args[1] = (Long_t)column;
216 args[3] = (Long_t)relX;
217 args[4] = (Long_t)relY;
218 Emit(
"buttonReleased(Int_t,Int_t,Event_t*,Int_t,Int_t)",
args);
233 gVirtualX->DrawLine(fId,
m_normGC, xOrigin,
y, visibleWidth,
y);
238 Int_t startRow, startColumn, relX, relY;
243 if (startColumn < 0) {
246 Int_t endRow, endColumn;
248 if (endRow >= numRows) {
249 endRow = numRows - 1;
261 itTextWidth != itEnd;
267 for (
int row = startRow; row <= endRow; ++row) {
270 int x = columnOffset;
272 for (
int col = startColumn;
col <= endColumn; ++
col, ++itTextWidth) {
278 gVirtualX->DrawLine(fId,
m_normGC, xOrigin,
y, visibleWidth,
y);
304 if (!(GetOptions() & kFixedWidth)) {
308 if (!(GetOptions() & kFixedHeight)) {
313 return TGDimension(
w,
h);
320 static const TGGC* s_default = gClient->GetResourcePool()->GetFrameGC();