@@ -71,7 +71,7 @@ impl LoadingUI {
7171 . direction ( Direction :: Vertical )
7272 . constraints ( [
7373 Constraint :: Fill ( 1 ) ,
74- Constraint :: Length ( 18 ) , // Height for loading box - increased for more content
74+ Constraint :: Length ( 19 ) , // Height for loading box - increased for wrap support
7575 Constraint :: Fill ( 1 ) ,
7676 ] )
7777 . split ( f. area ( ) ) ;
@@ -107,7 +107,7 @@ impl LoadingUI {
107107 let content_chunks = Layout :: default ( )
108108 . direction ( Direction :: Vertical )
109109 . constraints ( [
110- Constraint :: Length ( 1 ) , // Header line
110+ Constraint :: Length ( 2 ) , // Header line (2 lines for potential wrap)
111111 Constraint :: Length ( 1 ) , // Copyright line
112112 Constraint :: Length ( 1 ) , // License line
113113 Constraint :: Length ( 1 ) , // Empty line
@@ -121,17 +121,22 @@ impl LoadingUI {
121121 ] )
122122 . split ( inner_area) ;
123123
124- // Header
125- let header_line = Line :: from ( vec ! [
124+ // Header - with wrap support for narrow terminals
125+ use ratatui:: text:: Text ;
126+ use ratatui:: widgets:: Wrap ;
127+
128+ let header_text = Text :: from ( vec ! [ Line :: from( vec![
126129 Span :: styled( "🔍 " , Style :: default ( ) . fg( Color :: Yellow ) ) ,
127130 Span :: styled(
128- "Ghostscope v0.1.0 - A DWARF-friendly eBPF userspace probe with gdb -like TUI" ,
131+ "Ghostscope v0.1.0 - A DWARF-aware eBPF tracer with cgdb -like TUI - explore live processes at runtime " ,
129132 Style :: default ( )
130133 . fg( Color :: White )
131134 . add_modifier( Modifier :: BOLD ) ,
132135 ) ,
133- ] ) ;
134- let header_paragraph = Paragraph :: new ( header_line) . alignment ( Alignment :: Center ) ;
136+ ] ) ] ) ;
137+ let header_paragraph = Paragraph :: new ( header_text)
138+ . alignment ( Alignment :: Center )
139+ . wrap ( Wrap { trim : true } ) ;
135140 f. render_widget ( header_paragraph, content_chunks[ 0 ] ) ;
136141
137142 // Copyright
0 commit comments