diff options
author | Andreas Baumann <abaumann@yahoo.com> | 2011-01-30 21:02:51 +0100 |
---|---|---|
committer | Andreas Baumann <abaumann@yahoo.com> | 2011-01-30 21:02:51 +0100 |
commit | 66de2ac642b5657e28842c5dbc8e7d83f3f28975 (patch) | |
tree | 18220a4dd0c76c82cb19d91c82908f0d3d899e9d | |
parent | 4d0bd3c4a539bc359c1ae05acba1c8716437d38a (diff) | |
download | tvisiontest-66de2ac642b5657e28842c5dbc8e7d83f3f28975.tar.gz tvisiontest-66de2ac642b5657e28842c5dbc8e7d83f3f28975.tar.bz2 |
some docu and the help line stack
-rw-r--r-- | src/newt/test1.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
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, "<Tab>/<Shift-Tab> between elements" ); + // context sensitive help text + newtPushHelpLine( "<Tab>/<Shift-Tab> 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( ); |