From 9c31293f9d60626f38eb695d9581a3a49308d314 Mon Sep 17 00:00:00 2001 From: ndwarshuis Date: Sat, 24 Jul 2021 01:02:12 -0400 Subject: [PATCH] REF rename style to config --- core | 2 +- drawing/Common.lua | 16 ++++++++-------- drawing/Memory.lua | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/core b/core index 896bd28..dd025fd 160000 --- a/core +++ b/core @@ -1 +1 @@ -Subproject commit 896bd289485dec964b5edb43c8243e5e3a8d0f7d +Subproject commit dd025fd52a623a4cec0ed471c642dd5aa6b078ad diff --git a/drawing/Common.lua b/drawing/Common.lua index 4733fd8..0990b3e 100644 --- a/drawing/Common.lua +++ b/drawing/Common.lua @@ -123,32 +123,32 @@ end -------------------------------------------------------------------------------- -- label plot -M.default_grid_style = Timeseries.grid_style( +M.default_grid_config = Timeseries.grid_config( PLOT_GRID_X_N, PLOT_GRID_Y_N, Theme.PLOT_GRID_FG ) -M.default_plot_style = Timeseries.style( +M.default_plot_style = Timeseries.config( PLOT_NUM_POINTS, Theme.PLOT_OUTLINE_FG, Theme.PLOT_FILL_BORDER_PRIMARY, Theme.PLOT_FILL_BG_PRIMARY, - M.default_grid_style + M.default_grid_config ) -M.percent_label_style = Timeseries.label_style( +M.percent_label_config = Timeseries.label_config( Theme.INACTIVE_TEXT_FG, M.label_font_spec, function(_) return function(z) return Util.round_to_string(z * 100)..'%' end end ) -M.initThemedLabelPlot = function(x, y, w, h, label_style, update_freq) +M.initThemedLabelPlot = function(x, y, w, h, label_config, update_freq) return Timeseries.build( F.make_box(x, y, w, h), update_freq, M.default_plot_style, - label_style + label_config ) end @@ -170,7 +170,7 @@ M.initPercentPlot_formatted = function(x, y, w, h, spacing, label, update_freq, y + spacing, w, h, - M.percent_label_style, + M.percent_label_config, update_freq ), } @@ -243,7 +243,7 @@ M.initThemedScalePlot = function(x, y, w, h, f, min_domain, update_freq) F.make_box(x, y, w, h), update_freq, M.default_plot_style, - Timeseries.label_style( + Timeseries.label_config( Theme.INACTIVE_TEXT_FG, M.label_font_spec, f diff --git a/drawing/Memory.lua b/drawing/Memory.lua index 78ade53..66a81bb 100644 --- a/drawing/Memory.lua +++ b/drawing/Memory.lua @@ -104,7 +104,7 @@ return function(update_freq) PLOT_Y, Geometry.SECTION_WIDTH, PLOT_HEIGHT, - Common.percent_label_style, + Common.percent_label_config, update_freq )