REF don't use kwargs for arc functions
This commit is contained in:
parent
04955e1106
commit
853badd05e
2
core
2
core
|
@ -1 +1 @@
|
||||||
Subproject commit 9714d033f440af3b3748f33839455b5ec376be67
|
Subproject commit 937998112de5de54726925532ac20f7aa8e24226
|
|
@ -190,14 +190,23 @@ end
|
||||||
-- ring
|
-- ring
|
||||||
|
|
||||||
M.initRing = function(x, y, r)
|
M.initRing = function(x, y, r)
|
||||||
return _G_Widget_.Arc{
|
-- return _G_Widget_.Arc{
|
||||||
x = x,
|
-- x = x,
|
||||||
y = y,
|
-- y = y,
|
||||||
radius = r,
|
-- radius = r,
|
||||||
theta0 = 0,
|
-- theta0 = 0,
|
||||||
theta1 = 360,
|
-- theta1 = 360,
|
||||||
arc_pattern = _G_Patterns_.BORDER_FG
|
-- arc_pattern = _G_Patterns_.BORDER_FG
|
||||||
}
|
-- }
|
||||||
|
return _G_Widget_.Arc(
|
||||||
|
x,
|
||||||
|
y,
|
||||||
|
r,
|
||||||
|
0,
|
||||||
|
360,
|
||||||
|
2,
|
||||||
|
_G_Patterns_.BORDER_FG
|
||||||
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
|
|
|
@ -54,23 +54,44 @@ local DIAL_THETA_1 = math.rad(360)
|
||||||
local DIAL_X = _G_INIT_DATA_.RIGHT_X + DIAL_RADIUS + _DIAL_THICKNESS_ / 2
|
local DIAL_X = _G_INIT_DATA_.RIGHT_X + DIAL_RADIUS + _DIAL_THICKNESS_ / 2
|
||||||
local DIAL_Y = header.bottom_y + DIAL_RADIUS + _DIAL_THICKNESS_ / 2
|
local DIAL_Y = header.bottom_y + DIAL_RADIUS + _DIAL_THICKNESS_ / 2
|
||||||
|
|
||||||
local dial = _G_Widget_.Dial{
|
-- local dial = _G_Widget_.Dial{
|
||||||
x = DIAL_X,
|
-- x = DIAL_X,
|
||||||
y = DIAL_Y,
|
-- y = DIAL_Y,
|
||||||
radius = DIAL_RADIUS,
|
-- radius = DIAL_RADIUS,
|
||||||
thickness = _DIAL_THICKNESS_,
|
-- thickness = _DIAL_THICKNESS_,
|
||||||
critical_limit = 0.8,
|
-- critical_limit = 0.8,
|
||||||
dial_pattern = _G_Patterns_.INDICATOR_FG_PRIMARY,
|
-- dial_pattern = _G_Patterns_.INDICATOR_FG_PRIMARY,
|
||||||
critical_pattern = _G_Patterns_.INDICATOR_FG_CRITICAL,
|
-- critical_pattern = _G_Patterns_.INDICATOR_FG_CRITICAL,
|
||||||
arc_pattern = _G_Patterns_.INDICATOR_BG
|
-- arc_pattern = _G_Patterns_.INDICATOR_BG
|
||||||
}
|
-- }
|
||||||
local cache_arc = _G_Widget_.Arc{
|
local dial = _G_Widget_.Dial(
|
||||||
x = DIAL_X,
|
DIAL_X,
|
||||||
y = DIAL_Y,
|
DIAL_Y,
|
||||||
radius = DIAL_RADIUS,
|
DIAL_RADIUS,
|
||||||
thickness = _DIAL_THICKNESS_,
|
90,
|
||||||
arc_pattern = _G_Patterns_.INDICATOR_FG_SECONDARY
|
360,
|
||||||
}
|
_DIAL_THICKNESS_,
|
||||||
|
_G_Patterns_.INDICATOR_BG,
|
||||||
|
_G_Patterns_.INDICATOR_FG_PRIMARY,
|
||||||
|
_G_Patterns_.INDICATOR_FG_CRITICAL,
|
||||||
|
0.8
|
||||||
|
)
|
||||||
|
-- local cache_arc = _G_Widget_.Arc{
|
||||||
|
-- x = DIAL_X,
|
||||||
|
-- y = DIAL_Y,
|
||||||
|
-- radius = DIAL_RADIUS,
|
||||||
|
-- thickness = _DIAL_THICKNESS_,
|
||||||
|
-- arc_pattern = _G_Patterns_.INDICATOR_FG_SECONDARY
|
||||||
|
-- }
|
||||||
|
local cache_arc = _G_Widget_.Arc(
|
||||||
|
DIAL_X,
|
||||||
|
DIAL_Y,
|
||||||
|
DIAL_RADIUS,
|
||||||
|
90,
|
||||||
|
360,
|
||||||
|
_DIAL_THICKNESS_,
|
||||||
|
_G_Patterns_.INDICATOR_FG_SECONDARY
|
||||||
|
)
|
||||||
|
|
||||||
local text_ring = Common.initTextRing(
|
local text_ring = Common.initTextRing(
|
||||||
DIAL_X,
|
DIAL_X,
|
||||||
|
|
|
@ -56,18 +56,32 @@ local _create_core_ = function(cores, id, x, y)
|
||||||
end
|
end
|
||||||
|
|
||||||
cores[id +1] = {
|
cores[id +1] = {
|
||||||
dials = _G_Widget_.CompoundDial{
|
-- dials = _G_Widget_.CompoundDial{
|
||||||
x = x,
|
-- x = x,
|
||||||
y = y,
|
-- y = y,
|
||||||
inner_radius = _DIAL_INNER_RADIUS_,
|
-- inner_radius = _DIAL_INNER_RADIUS_,
|
||||||
outer_radius = _DIAL_OUTER_RADIUS_,
|
-- outer_radius = _DIAL_OUTER_RADIUS_,
|
||||||
spacing = _DIAL_SPACING_,
|
-- spacing = _DIAL_SPACING_,
|
||||||
num_dials = NUM_THREADS_PER_CORE,
|
-- num_dials = NUM_THREADS_PER_CORE,
|
||||||
critical_limit = 0.8,
|
-- critical_limit = 0.8,
|
||||||
critical_pattern = _G_Patterns_.INDICATOR_FG_CRITICAL,
|
-- critical_pattern = _G_Patterns_.INDICATOR_FG_CRITICAL,
|
||||||
dial_pattern = _G_Patterns_.INDICATOR_FG_PRIMARY,
|
-- dial_pattern = _G_Patterns_.INDICATOR_FG_PRIMARY,
|
||||||
arc_pattern = _G_Patterns_.INDICATOR_BG
|
-- arc_pattern = _G_Patterns_.INDICATOR_BG
|
||||||
},
|
-- },
|
||||||
|
dials = _G_Widget_.CompoundDial(
|
||||||
|
x,
|
||||||
|
y,
|
||||||
|
90,
|
||||||
|
360,
|
||||||
|
_G_Patterns_.INDICATOR_BG,
|
||||||
|
_G_Patterns_.INDICATOR_FG_PRIMARY,
|
||||||
|
_G_Patterns_.INDICATOR_FG_CRITICAL,
|
||||||
|
0.8,
|
||||||
|
_DIAL_INNER_RADIUS_,
|
||||||
|
_DIAL_OUTER_RADIUS_,
|
||||||
|
_DIAL_SPACING_,
|
||||||
|
NUM_THREADS_PER_CORE
|
||||||
|
),
|
||||||
text_ring = Common.initTextRing(
|
text_ring = Common.initTextRing(
|
||||||
x,
|
x,
|
||||||
y,
|
y,
|
||||||
|
|
Loading…
Reference in New Issue