Set text rotation mode. Parameters ---------- m : {None, 'default', 'anchor'} If ``None`` or ``"default"``, the text will be first rotated, then aligned according to their horizontal and vertical alignments. If ``"anchor"``, then
(self, m)
| 244 | return get_rotation(self._rotation) # string_or_number -> number |
| 245 | |
| 246 | def set_rotation_mode(self, m): |
| 247 | """ |
| 248 | Set text rotation mode. |
| 249 | |
| 250 | Parameters |
| 251 | ---------- |
| 252 | m : {None, 'default', 'anchor'} |
| 253 | If ``None`` or ``"default"``, the text will be first rotated, then |
| 254 | aligned according to their horizontal and vertical alignments. If |
| 255 | ``"anchor"``, then alignment occurs before rotation. |
| 256 | """ |
| 257 | if m is None or m in ["anchor", "default"]: |
| 258 | self._rotation_mode = m |
| 259 | else: |
| 260 | raise ValueError("Unknown rotation_mode : %s" % repr(m)) |
| 261 | self.stale = True |
| 262 | |
| 263 | def get_rotation_mode(self): |
| 264 | """Get the text rotation mode.""" |
no outgoing calls
no test coverage detected