diff options
author | David Robillard <d@drobilla.net> | 2012-03-28 04:26:07 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-03-28 04:26:07 +0000 |
commit | 791587fe9408856a658e5780f0dc5b9231f6c021 (patch) | |
tree | 7a4c8d1fd0ef428ff8a7db245a1ee20a87cf53c4 /src/module.c | |
parent | 97ede5001777de4bb36491f4f2571b2037eb0cda (diff) | |
download | ganv-791587fe9408856a658e5780f0dc5b9231f6c021.tar.gz ganv-791587fe9408856a658e5780f0dc5b9231f6c021.tar.bz2 ganv-791587fe9408856a658e5780f0dc5b9231f6c021.zip |
Fix control rect colour and label stacking.
git-svn-id: http://svn.drobilla.net/lad/trunk/ganv@4124 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/module.c')
-rw-r--r-- | src/module.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/module.c b/src/module.c index ff85c6f..36d45a2 100644 --- a/src/module.c +++ b/src/module.c @@ -656,13 +656,20 @@ ganv_module_draw(GanvItem* item, int cx, int cy, int width, int height) { + GanvNode* node = GANV_NODE(item); GanvModule* module = GANV_MODULE(item); - // Draw box and label + // Draw box if (GANV_ITEM_CLASS(parent_class)->draw) { (*GANV_ITEM_CLASS(parent_class)->draw)(item, cr, cx, cy, width, height); } + // Draw label + if (node->impl->label) { + GanvItem* label_item = GANV_ITEM(node->impl->label); + GANV_ITEM_GET_CLASS(label_item)->draw(label_item, cr, cx, cy, width, height); + } + // Draw ports FOREACH_PORT(module->impl->ports, p) { GANV_ITEM_GET_CLASS(GANV_ITEM(*p))->draw( |