support ratio for terminals

This commit is contained in:
David Levanon 2020-09-24 13:12:23 +03:00
parent 0151c68abe
commit 42b1915065

View File

@ -79,10 +79,12 @@ class ConfigJson(object):
if counter < (len(layoutjson) - 1):
containername = parent + "." + str(order) + "." + str(counter)
ratio = (100 / (len(layoutjson) - counter)) / 100
if 'ratio' in pane:
ratio = pane['ratio']
children[containername] = {
'type': 'VPaned' if vertical else 'HPaned',
'order': order + counter,
'ratio': round(ratio, 2),
'ratio': ratio,
'parent': actualparent
}
actualparent = containername