Allow ValueViewers to have a bounding box different from the Style's. This closes #64.

This commit is contained in:
Twan van Laarhoven
2020-06-01 01:18:13 +02:00
parent e9305c7554
commit 4ff603d413
24 changed files with 79 additions and 87 deletions
+1 -1
View File
@@ -24,7 +24,7 @@ bool MultipleChoiceValueViewer::prepare(RotatedDC& dc) {
void MultipleChoiceValueViewer::draw(RotatedDC& dc) {
drawFieldBorder(dc);
if (style().render_style & RENDER_HIDDEN) return;
RealPoint pos = align_in_rect(style().alignment, RealSize(0,0), style().getInternalRect());
RealPoint pos = align_in_rect(style().alignment, RealSize(0,0), dc.getInternalRect());
// selected choices
vector<String> selected;
value().get(selected);