MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / set_rotation

Method set_rotation

tests/test_pager_code.py:148–156  ·  view source on GitHub ↗

Set display rotation: 0, 90, 180, or 270.

(self, degrees)

Source from the content-addressed store, hash-verified

146
147 # ========== ROTATION/SIZE ==========
148 def set_rotation(self, degrees):
149 """Set display rotation: 0, 90, 180, or 270."""
150 self._rotation = degrees
151 if degrees in [90, 270]:
152 self._width, self._height = 480, 222
153 else:
154 self._width, self._height = 222, 480
155 if VERBOSE:
156 print(f"[MockPager] set_rotation({degrees}) -> {self._width}x{self._height}")
157
158 @property
159 def width(self):

Callers 1

run_testsFunction · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected