> 
> 
> Hi-
> 
> Someone was asking me a while ago about text menus, as are often found =
> in
> installation programs. I hope this person is on the list!  :-)
> 
> Here's a simple program I wrote that illustrates how to change colors o=
> n
> the console display. It doesn't use SVGAlib, but this sort of thing cou=
> ld
> be used as an SVGAlib program installer.
> 
[snip]

Hi All,

Speaking of using escape sequences to produce menus, here is something
that shows how to produce 3D fully functional dialogs on top of SVGALIB
using escape sequences. Of course you will need something that sits on
top of SVGALIB and knows about SVGALIB and the escape sequences ;)

I've attached two files one that contains the escape sequences to
produce a free running counter and the other that contains a picture
of the dialog that is produced by the escape sequence.

To try it yourself just download a copy of XEBOT for SVGALIB, open a
termial window and cat the escape sequences to it.

Regards
Sergio

PNG image data, 800 x 600, 8-bit colormap, non-interlaced

pe

? "*** point 0"

proc TASK_TEST::run(arg)

local val

while 1 do
        val = int(arg.result_textbox.get_value())
        arg.result_textbox.set_value(val + 1)
        result 0
done

endproc

proc TASK_TEST::build_task

define var x

x = generator TASK_TEST::run(this.frame)

add_idle_task(x)

endproc


? "*** point 1"

define var tmp
invalidate(tmp)

tmp = 
unpack("{type=frame}{control_name=frame_7}{background_colour=26}{border_type=96}{caption=}{font_name=}{foreground_colour=}{border_width=}{left_follows=left}{top_follows=top}{right_follows=right}{bottom_follows=bottom}{x=148}{y=215}{width=133}{height=133}{control_list=[{type=button}{pressed_func_name=TASK_TEST::build_task}{control_name=button_3547}{background_colour=26}{caption=start}{x=181}{y=303}{width=67}{height=23}{font_name=}{foreground_colour=}{border_type=}{border_width=}{left_follows=left}{top_follows=top}{right_follows=left}{bottom_follows=top}][{type=textbox}{control_name=result_textbox}{background_colour=26}{border_type=2}{border_width=2}{x=181}{y=248}{width=67}{height=23}{text=}{font_name=}{foreground_colour=}{left_follows=left}{top_follows=top}{right_follows=left}{bottom_follows=top}{completed_func_name=}{aborted_func_name=}]}")

? "*** point 2"

WINCTL::form(tmp)
xpe

Reply via email to