Files
Upsilon/apps/statistics/calculation_cell.cpp
2018-06-11 13:58:23 +02:00

21 lines
714 B
C++

#include "calculation_cell.h"
#include "../shared/hideable_even_odd_editable_text_cell.h"
#include "escher/metric.h"
namespace Statistics {
void CalculationCell::drawRect(KDContext * ctx, KDRect rect) const {
EvenOddBufferTextCell::drawRect(ctx, rect);
// Draw the separator
KDRect separatorRect(0, 0, Metric::TableSeparatorThickness, bounds().height());
ctx->fillRect(separatorRect, Shared::HideableEvenOddEditableTextCell::hideColor());
}
void CalculationCell::layoutSubviews() {
KDRect boundsThis = bounds();
m_bufferTextView.setFrame(KDRect(boundsThis.left() + Metric::TableSeparatorThickness, boundsThis.top(), boundsThis.width() - Metric::TableSeparatorThickness, boundsThis.height()));
}
}