A candidate line broken at an even word boundary from a string of text, and a |_LineSource| value containing the text that remains after the line is broken at this spot.
| 259 | |
| 260 | |
| 261 | class _Line(tuple): |
| 262 | """ |
| 263 | A candidate line broken at an even word boundary from a string of text, |
| 264 | and a |_LineSource| value containing the text that remains after the line |
| 265 | is broken at this spot. |
| 266 | """ |
| 267 | |
| 268 | def __new__(cls, text, remainder): |
| 269 | return tuple.__new__(cls, (text, remainder)) |
| 270 | |
| 271 | def __gt__(self, other): |
| 272 | return len(self.text) > len(other.text) |
| 273 | |
| 274 | def __lt__(self, other): |
| 275 | return not self.__gt__(other) |
| 276 | |
| 277 | def __len__(self): |
| 278 | return len(self.text) |
| 279 | |
| 280 | def __repr__(self): |
| 281 | return "'%s' => '%s'" % (self.text, self.remainder) |
| 282 | |
| 283 | @property |
| 284 | def remainder(self): |
| 285 | return self[1] |
| 286 | |
| 287 | @property |
| 288 | def text(self): |
| 289 | return self[0] |
| 290 | |
| 291 | |
| 292 | class _Fonts(object): |
no outgoing calls
searching dependent graphs…