Rev 6803 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 6803 | Rev 6806 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | char char_width[255]; |
1 | char char_width[255]; |
Line 2... | Line 2... | ||
2 | 2 | ||
3 | void get_label_symbols_size() |
3 | void get_label_symbols_size() |
4 | { |
4 | { |
5 | int i; |
5 | int i; |
6 | label.changeSIZE(); |
6 | kfont.changeSIZE(); |
7 | for (i=0; i<256; i++) char_width[i] = label.symbol_size(i); |
7 | for (i=0; i<256; i++) char_width[i] = kfont.symbol_size(i); |
Line 8... | Line 8... | ||
8 | } |
8 | } |
9 | 9 | ||
10 | int get_label_len(dword _text) |
10 | int get_label_len(dword _text) |
Line 21... | Line 21... | ||
21 | 21 | ||
22 | void WriteTextIntoBuf(int _x, _y; dword _text_col, _text_off) |
22 | void WriteTextIntoBuf(int _x, _y; dword _text_col, _text_off) |
23 | { |
23 | { |
24 | char error_message[128]; |
24 | char error_message[128]; |
25 | if (_x > list.w) { |
25 | if (_x > list.w) { |
26 | sprintf(#error_message, "'WriteTextIntoBuf _x overflow: H %d X %d' -A", label.size.height, _x); |
26 | sprintf(#error_message, "'WriteTextIntoBuf _x overflow: H %d X %d' -A", kfont.size.height, _x); |
27 | notify(#error_message); |
27 | notify(#error_message); |
28 | } |
28 | } |
29 | if (_y+label.size.pt > label.size.height) { |
29 | if (_y+kfont.size.pt > kfont.size.height) { |
30 | sprintf(#error_message, "'WriteTextIntoBuf _y overflow: H %d Y %d' -A", label.size.height, _y); |
30 | sprintf(#error_message, "'WriteTextIntoBuf _y overflow: H %d Y %d' -A", kfont.size.height, _y); |
31 | notify(#error_message); |
31 | notify(#error_message); |
32 | return; |
32 | return; |
33 | } |
33 | } |
34 | label.WriteIntoBuffer(_x, _y, list.w, label.size.height, 0xFFFFFF, _text_col, label.size.pt, _text_off); |
34 | kfont.WriteIntoBuffer(_x, _y, list.w, kfont.size.height, 0xFFFFFF, _text_col, kfont.size.pt, _text_off); |
35 | if (_y/list.item_h-list.first==list.visible) DrawPage(); |
35 | if (_y/list.item_h-list.first==list.visible) DrawPage(); |
Line 36... | Line 36... | ||
36 | } |
36 | } |
37 | 37 | ||
38 | 38 | ||
39 | void label_draw_bar(dword _x, _y, _w, _color) |
39 | void label_draw_bar(dword _x, _y, _w, _color) |
40 | { |
40 | { |
41 | int i; |
41 | int i; |