Rev 6197 | Rev 6209 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 6197 | Rev 6198 | ||
---|---|---|---|
Line 41... | Line 41... | ||
41 | DrawBar(x,y+h,w,1,color2); |
41 | DrawBar(x,y+h,w,1,color2); |
42 | } |
42 | } |
Line 43... | Line 43... | ||
43 | 43 | ||
44 | :void DrawCaptButton(dword x,y,w,h,id,color_b, color_t,text) |
44 | :void DrawCaptButton(dword x,y,w,h,id,color_b, color_t,text) |
45 | { |
45 | { |
46 | word tx = -strlen(text)*6+w/2+x+1; |
46 | word tx = -strlen(text)*9+w/2+x+1; |
47 | word ty = h/2-3+y; |
47 | word ty = h/2-7+y; |
48 | if (id>0) DefineButton(x,y,w,h,id,color_b); |
48 | if (id>0) DefineButton(x,y,w,h,id,color_b); |
49 | WriteText(tx+1,ty+1,0x80,MixColors(color_b,0,200),text); |
49 | WriteText(tx+1,ty+1,0x90,MixColors(color_b,0,230),text); |
50 | WriteText(tx,ty,0x80,color_t,text); |
50 | WriteText(tx,ty,0x90,color_t,text); |
Line 51... | Line 51... | ||
51 | } |
51 | } |
52 | 52 | ||
53 | :void WriteTextCenter(dword x,y,w,color_t,text) |
53 | :void WriteTextCenter(dword x,y,w,color_t,text) |
Line 126... | Line 126... | ||
126 | DrawRectangle3D(x-1,y-1,w+2,h+2,system.color.work_dark,system.color.work_light); |
126 | DrawRectangle3D(x-1,y-1,w+2,h+2,system.color.work_dark,system.color.work_light); |
127 | } |
127 | } |
Line 128... | Line 128... | ||
128 | 128 | ||
129 | :void MoreLessBox(dword x,y, bt_id_more, bt_id_less, value, text) |
129 | :void MoreLessBox(dword x,y, bt_id_more, bt_id_less, value, text) |
130 | { |
130 | { |
131 | #define VALUE_FIELD_W 26 |
131 | #define VALUE_FIELD_W 34 |
- | 132 | #define SIZE 18 |
|
Line 132... | Line 133... | ||
132 | #define SIZE 18 |
133 | dword value_text = itoa(value); |
133 | 134 | ||
134 | DrawRectangle(x, y, VALUE_FIELD_W, SIZE, system.color.work_graph); |
135 | DrawRectangle(x, y, VALUE_FIELD_W, SIZE, system.color.work_graph); |
135 | DrawRectangle3D(x+1, y+1, VALUE_FIELD_W-2, SIZE-2, 0xDDDddd, 0xffffff); |
136 | DrawRectangle3D(x+1, y+1, VALUE_FIELD_W-2, SIZE-2, 0xDDDddd, 0xffffff); |
Line 136... | Line 137... | ||
136 | DrawBar(x+2, y+2, VALUE_FIELD_W-3, SIZE-3, 0xffffff); |
137 | DrawBar(x+2, y+2, VALUE_FIELD_W-3, SIZE-3, 0xffffff); |
137 | WriteText(x+6, SIZE / 2 + y -3, 0x80, 0x000000, itoa(value)); |
138 | WriteText( -strlen(value_text)+3*8 + x+6, SIZE / 2 + y -6, 0x90, 0x000000, value_text); |
138 | 139 | ||
139 | DrawCaptButton(VALUE_FIELD_W + x, y, SIZE, SIZE, bt_id_more, system.color.work_button, system.color.work_button_text, "+"); |
140 | DrawCaptButton(VALUE_FIELD_W + x, y, SIZE, SIZE, bt_id_more, system.color.work_button, system.color.work_button_text, "+"); |