Date: Tue, 2 Dec 1997 14:04:04 +1100 (EST) From: Peter Hawkins <peter@rhiannon.clari.net.au> To: jkh@time.cdrom.com, peter@rhiannon.clari.net.au Cc: danny@hilink.com.au, freebsd-hackers@FreeBSD.ORG, j@uriah.heep.sax.de Subject: Re: GUI wizard interface Message-ID: <199712020304.OAA17066@rhiannon.clari.net.au>
next in thread | raw e-mail | index | archive | help
>Hmmm. This sounds very promising, though without a bit more detail >it's hard for me comment any more significantly on it. Strangely >enough, I've also been working on a "wizard" tool these last couple of >days since I managed to hand Mike Smith my package & installer hat a >few weeks back and am now free to think about different problems in >that same general region of the system. Perhaps we can work together >on some aspect of this? Sure! How about you send me the code to your back end (the ppp thing which calls it) so I can get a feel for your contexts concept? In my case, the interface you'd write would be a finite state machine but it sounds sort of similar. The alpha will be out (I hope) within a week. I had envisaged that 1.1 would have an improved interface which I'd write using lex and define a syntax to be an alternative to direct calls. Perhaps I could encompass your contexts that way? The finite state machine doesn't push or pop states as it is; here is a crude example... exithandle() { cvend(); } display( char *result) { cvprintf("user added",result,"ok",mainmenu,"back",mainmenu,"cancel",exithandle); } adduser( char *result) { cvdialoglist( "Add an account", "type in up to 4 values", "enter username", "enter account name", "enter uid", "home directory", "back", mainmenu, "next", display ); } mainmenu() { cvbuttonlist( "Account manager", "press your button", "add new account", adduser, "delete account", deluser, "cancel", exithandle ); } main() { cvinit( stuff ); mainmenu(); } items are buttons or dialogs. buttons are followed by a handler routine name and the names "ok" "next" "back" and "cancel" are special - always buttons and are placed in the navigation bar at the bottom of the screen. cvprintf() is used to display messages and results. I am planning to add cvmatrix() which will combine all the above into a single call defining a state matrix. Peter Peter
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199712020304.OAA17066>