forked from KolibriOS/kolibrios
some final adjustments
git-svn-id: svn://kolibrios.org@7798 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
f07f30b675
commit
e510a94760
Binary file not shown.
Before Width: | Height: | Size: 40 KiB After Width: | Height: | Size: 40 KiB |
@ -73,7 +73,6 @@ int kfont_char_width[255];
|
||||
if(font)free(font);
|
||||
label_io.read(font_path);
|
||||
if(!EAX) {
|
||||
//debugln(font_path);
|
||||
label_io.run("/sys/@notify", "'Error: KFONT is not loaded.' -E");
|
||||
return false;
|
||||
}
|
||||
@ -151,7 +150,7 @@ int kfont_char_width[255];
|
||||
dword tmp, _;
|
||||
byte X;
|
||||
byte chaw_width=0;
|
||||
if(s==32)return width/4;
|
||||
if(s==32)return width/4+1;
|
||||
if(s==9)return width;
|
||||
s = Cp866ToAnsi(s);
|
||||
tmp = block*s << 2 + font;
|
||||
|
@ -199,9 +199,12 @@ void draw_list()
|
||||
{
|
||||
if (streq(names.get(i), "-")) {
|
||||
DrawBar(menu1.x, item_y+0, menu1.w, 1, inactive_background_color);
|
||||
DrawBar(menu1.x, item_y+1, menu1.w, 1, system.color.work_dark);
|
||||
DrawBar(menu1.x-1, item_y+1, menu1.w+1, 1, system.color.work_dark);
|
||||
DrawBar(menu1.x, item_y+2, menu1.w, 1, system.color.work_light);
|
||||
DrawBar(menu1.x, item_y+3, menu1.w, 1, inactive_background_color);
|
||||
//DrawBar(menu1.x, item_y+0, menu1.w, 4, inactive_background_color);
|
||||
//DrawBar(13, item_y+1, menu1.w-24, 1, system.color.work_dark);
|
||||
//DrawBar(13, item_y+2, menu1.w-24, 1, system.color.work_light);
|
||||
item_y += SEP_H;
|
||||
} else {
|
||||
if (item_i==menu1.cur_y) {
|
||||
|
@ -34,8 +34,7 @@ dword line_start=io.buffer_data;
|
||||
list.count++;
|
||||
}
|
||||
if (mode==DRAW_BUF) {
|
||||
EBX = bufoff-line_start;
|
||||
strlcpy(#line, line_start, EBX);
|
||||
strlcpy(#line, line_start, bufoff-line_start);
|
||||
kfont.WriteIntoBuffer(DRAW_PADDING,stroka_y,list.w,kfont.size.height, bg_color, text_color, kfont.size.pt, #line);
|
||||
stroka_y += list.item_h;
|
||||
line_start = bufoff;
|
||||
@ -54,7 +53,7 @@ void PreparePage()
|
||||
Parse(COUNT_BUF_HEIGHT);
|
||||
|
||||
//draw text in buffer
|
||||
list.SetSizes(0, TOOLBAR_H, list.w, Form.cheight-TOOLBAR_H, kfont.size.pt+6);
|
||||
list.SetSizes(0, TOOLBAR_H, list.w, Form.cheight-TOOLBAR_H, kfont.size.pt+8);
|
||||
if (list.count < list.visible) list.count = list.visible;
|
||||
kfont.size.height = list.count+1*list.item_h;
|
||||
kfont.raw_size = 0;
|
||||
|
@ -222,10 +222,12 @@ void HandleKeyEvent()
|
||||
case SCAN_CODE_KEY_I:
|
||||
EventShowFileProperties();
|
||||
break;
|
||||
case SCAN_CODE_PLUS:
|
||||
case SCAN_CODE_UP:
|
||||
EventMagnifyPlus();
|
||||
break;
|
||||
case SCAN_CODE_DOWN:
|
||||
case SCAN_CODE_MINUS:
|
||||
EventMagnifyMinus();
|
||||
break;
|
||||
case SCAN_CODE_KEY_E:
|
||||
@ -439,8 +441,7 @@ void draw_window()
|
||||
if ((Form.cwidth-scroll.size_x-1 == list.w) &&
|
||||
(Form.cheight-TOOLBAR_H == list.h) &&
|
||||
(list.count)
|
||||
)
|
||||
{
|
||||
) {
|
||||
DrawPage();
|
||||
} else {
|
||||
PreparePage();
|
||||
|
Loading…
Reference in New Issue
Block a user