Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion screenconfig
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ def get_attr(sc, current, attr, default=None):
res = default
if attr in sc[current]:
res = sc[current][attr]
elif DEFAULT in sc:
elif DEFAULT in sc and attr in sc[DEFAULT]:
res = sc[DEFAULT].get(attr)
# print('get_attr', current, attr, res)
return res
Expand Down Expand Up @@ -107,6 +107,14 @@ def activate_crtc(sc, edid, output):
cmd.append('--auto')
else:
cmd.extend(('--mode', resolution))

scale = get_attr(sc, crtc, 'scale', '1x1')
cmd.extend(("--scale", scale))

panning = get_attr(sc, crtc, 'panning', False)
if(panning):
cmd.extend(("--panning", panning))

position = get_attr(sc, crtc, 'position')
if position:
p_crtc = position.get('crtc')
Expand Down