1 macro start_draw_window x,y,xsize,ysize,areacolor,caption
\r
3 mov eax, 12 ; function 12:tell os about windowdraw
\r
4 mov ebx, 1 ; 1, start of draw
\r
7 mov eax, 0 ; function 0 : define and draw window
\r
8 mov ebx, x*65536+xsize ; [x start] *65536 + [x size]
\r
9 mov ecx, y*65536+ysize ; [y start] *65536 + [y size]
\r
10 mov edx,areacolor ; color of work area RRGGBB
\r
11 mov edi,caption ; window title
\r
15 macro end_draw_window
\r
17 mov eax, 12 ; end of redraw
\r
22 macro draw_button x,y,xsize,ysize,id,butcolor,text,textlen,textcolor
\r
24 mov eax, 8 ; function 8 : define and draw button
\r
25 mov ebx, (x)*65536+xsize ; [x start] *65536 + [x size]
\r
26 mov ecx, (y)*65536+ysize ; [y start] *65536 + [y size]
\r
27 mov edx, id ; button id
\r
28 mov esi, butcolor ; button color RRGGBB
\r
31 mov ebx, (x+5)*65536+y+(ysize-5)/2 ; Draw button text
\r
41 macro outtextxy x,y,prompt,prompt_len,color
\r
43 mov ebx, x*65536+y ; draw info text with function 4
\r
53 macro bar x,y,xsize,ysize,color
\r
56 mov ebx, x*65536+xsize
\r
57 mov ecx, y*65536+ysize
\r
62 macro line x1,y1,x2,y2,color
\r
65 mov ebx, x1*65536+x2
\r
66 mov ecx, y1*65536+y2
\r
71 macro rectangle x,y,xsize,ysize,color
\r
77 line x,y2,x2,y2,color
\r
78 line x2,y,x2,y2,color
\r
81 macro putpixel x,y,color
\r
96 bar 532, 53, 10, 11, 0x0000FF00
\r
102 bar 500, 53, 10, 11, 0x0000FF00
\r
107 bar 565, 53, 10, 11, 0x0000FF00
\r
112 ;mov ebx, x*65536+y ; draw info text with function 4
\r