diff --git a/src/tests/apps/terminal_replicant/main.cpp b/src/tests/apps/terminal_replicant/main.cpp index e8b03d171a..f7a0017d5e 100644 --- a/src/tests/apps/terminal_replicant/main.cpp +++ b/src/tests/apps/terminal_replicant/main.cpp @@ -4,6 +4,7 @@ #include #include #include +#include #include #include @@ -62,14 +63,19 @@ Window::AttachTermView() message.AddString("class", "TermView"); message.AddString("add_on", TERM_SIGNATURE); message.AddBool("use_rect", true); - message.AddRect("_frame", Bounds().InsetByCopy(2, 2)); + + BRect viewFrame = Bounds(); + viewFrame.right -= 15; + message.AddRect("_frame", viewFrame); BView *termView = dynamic_cast(instantiate_object(&message)); - - if (termView != NULL) { - termView->SetResizingMode(B_FOLLOW_ALL); - AddChild(termView); + if (termView == NULL) + return; - termView->ResizeToPreferred(); - } + termView->SetResizingMode(B_FOLLOW_ALL); + + BScrollView *scrollView = new BScrollView("scrollview", termView, + B_FOLLOW_ALL, B_WILL_DRAW, false, true); + + AddChild(scrollView); }