~hp/midi_matrix.lv2

be7e0b2b59b2b89ba31f5bb97e4d3b44e354199d — Hanspeter Portner 2 years ago 31c2497
nk: use new scale API.
2 files changed, 6 insertions(+), 4 deletions(-)

M VERSION
M midi_matrix_channel_filter_nk.c
M VERSION => VERSION +1 -1
@@ 1,1 1,1 @@
0.29.3
0.29.9

M midi_matrix_channel_filter_nk.c => midi_matrix_channel_filter_nk.c +5 -3
@@ 194,9 194,11 @@ instantiate(const LV2UI_Descriptor *descriptor,
	handle->controller = controller;
	handle->writer = write_function;

	const float scale = nk_pugl_get_scale();

	nk_pugl_config_t *cfg = &handle->win.cfg;
	cfg->width = 640;
	cfg->height = 640;
	cfg->width = 640 * scale;
	cfg->height = 640 * scale;
	cfg->resizable = true;
	cfg->fixed_aspect = true;
	cfg->ignore = false;


@@ 209,7 211,7 @@ instantiate(const LV2UI_Descriptor *descriptor,

	if(asprintf(&cfg->font.face, "%sCousine-Regular.ttf", bundle_path) == -1)
		cfg->font.face= NULL;
	cfg->font.size = 13;
	cfg->font.size = 13 * scale;

	*(intptr_t *)widget = nk_pugl_init(&handle->win);