Gen modules integration (#54)
genevensis frames magic-modules integration
This commit is contained in:
@@ -90,6 +90,12 @@ clamp := {
|
||||
}
|
||||
round_up := {to_int(0.99999999999998+input)} #### 0.99999999999999 == 1, leave the 8
|
||||
round_near := {to_int(0.5+input)}
|
||||
to_number_lax :=
|
||||
{
|
||||
input := trim(input)
|
||||
if input == "" or input == "-" then input := 0
|
||||
to_number(input)
|
||||
}
|
||||
#### reads from a comma separated list like an array
|
||||
pull_comma_array := {
|
||||
array := split_text(input, match:divider)
|
||||
@@ -2801,6 +2807,7 @@ corners_possible_dimensions :=
|
||||
"1039x744": "1039x744"
|
||||
"750x1046": "750x1046"
|
||||
"1046x750": "1046x750"
|
||||
"1500x1046": "1500x1046"
|
||||
]
|
||||
|
||||
corners_disabled_1 := { false }
|
||||
@@ -4059,8 +4066,8 @@ swap_font_color := {
|
||||
nums := split_text(test, match:",")
|
||||
test_color := nil
|
||||
|
||||
if length(nums) >= 4 then test_color := rgba(nums.0, nums.1, nums.2, nums.3) or else nil
|
||||
if test_color == nil and length(nums) >= 3 then test_color := rgb(nums.0, nums.1, nums.2) or else nil
|
||||
if length(nums) >= 4 then test_color := rgba(to_number_lax(nums.0), to_number_lax(nums.1), to_number_lax(nums.2), to_number_lax(nums.3)) or else nil
|
||||
if test_color == nil and length(nums) >= 3 then test_color := rgb(to_number_lax(nums.0), to_number_lax(nums.1), to_number_lax(nums.2)) or else nil
|
||||
if test_color == nil and test != "" then test_color := to_color(test) or else nil
|
||||
if test_color != nil then font_color := test_color
|
||||
) else ""
|
||||
|
||||
Reference in New Issue
Block a user