From 66de2ac642b5657e28842c5dbc8e7d83f3f28975 Mon Sep 17 00:00:00 2001 From: Andreas Baumann Date: Sun, 30 Jan 2011 21:02:51 +0100 Subject: some docu and the help line stack --- src/newt/test1.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/newt/test1.cpp b/src/newt/test1.cpp index a59225e..61185d6 100644 --- a/src/newt/test1.cpp +++ b/src/newt/test1.cpp @@ -6,14 +6,21 @@ using namespace std; int main( void ) { + // init newtInit( ); newtCls( ); + + // impressum on root window newtDrawRootText( 0, 0, "SMERP newt client" ); newtDrawRootText( 75, 0, "(C)2011" ); - newtDrawRootText( 1, -1, "/ between elements" ); + // context sensitive help text + newtPushHelpLine( "/ between elements" ); + + // a window containing our form newtOpenWindow( 10, 3, 60, 18, "form1" ); + // construct the components of the form and the form itself newtComponent form, answer, label1, inputline1, label2, inputline2, ok, cancel; @@ -32,8 +39,10 @@ int main( void ) cancel = newtCompactButton( 20, 10, "Cancel" ); newtFormAddComponents( form, label1, inputline1, label2, inputline2, ok, cancel, NULL ); + // run the form answer = newtRunForm( form ); + // cleanup newtPopWindow( ); newtFinished( ); -- cgit v1.2.3-54-g00ecf