(self, app_output, app_input)
| 511 | self._create_ui(app_output, app_input) |
| 512 | |
| 513 | def _create_ui(self, app_output, app_input): |
| 514 | prompt_buffer = Buffer() |
| 515 | self._prompt_buffer_control = BufferControl(prompt_buffer) |
| 516 | prompt_buffer_window = Window(self._prompt_buffer_control) |
| 517 | prompt_text_window = Window( |
| 518 | FormattedTextControl(">"), dont_extend_width=True, width=1 |
| 519 | ) |
| 520 | self._key_bindings = LiveTailKeyBindings( |
| 521 | self, prompt_buffer, self._output, self._keywords_to_highlight |
| 522 | ) |
| 523 | |
| 524 | output_buffer_control = BufferControl( |
| 525 | self._output, input_processors=[BufferControlColorProcessor()] |
| 526 | ) |
| 527 | log_output_container = Window(output_buffer_control, wrap_lines=True) |
| 528 | |
| 529 | dashed_line_container = Window(height=1, char="-") |
| 530 | metadata_container = self._create_metadata() |
| 531 | bottom_toolbar_container = self._create_bottom_toolbar() |
| 532 | |
| 533 | containers = HSplit( |
| 534 | [ |
| 535 | log_output_container, |
| 536 | dashed_line_container, |
| 537 | VSplit( |
| 538 | [ |
| 539 | prompt_text_window, |
| 540 | prompt_buffer_window, |
| 541 | ], |
| 542 | height=1, |
| 543 | ), |
| 544 | metadata_container, |
| 545 | bottom_toolbar_container, |
| 546 | ] |
| 547 | ) |
| 548 | layout = Layout(containers, prompt_buffer_window) |
| 549 | self._application = Application( |
| 550 | layout, |
| 551 | key_bindings=self._key_bindings, |
| 552 | refresh_interval=1, |
| 553 | output=app_output, |
| 554 | input=app_input, |
| 555 | ) |
| 556 | |
| 557 | @property |
| 558 | def prompt_buffer_control(self): |
no test coverage detected