Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 3004 → Rev 3005

/programs/network/htmlv/browser/HTMLv.c
14,7 → 14,7
#include "..\lib\libimg_lib.h"
#include "..\lib\edit_box_lib.h"
#include "..\lib\scroll_lib.h"
#include "..\lib\ttf_fonts.h"
#include "..\lib\truetype.h"
//êàðòèíêè
#include "img\toolbar_icons.c"
#include "img\URLgoto.txt";
21,6 → 21,7
 
 
#define URL param
int use_truetype = 0;
 
char editURL[sizeof(URL)],
page_links[12000],
55,11 → 56,11
int scroll_used=0;
mem_Init();
load_dll2(libio, #libio_init,1);
load_dll2(libimg, #libimg_init,1);
load_dll2(boxlib, #edit_box_draw,0);
if (load_dll2(libio, #libio_init,1)!=0) debug("Íå óäàëîñü ïîäêëþ÷èòü áèáëèîòåêó libio."w);
if (load_dll2(libimg, #libimg_init,1)!=0) debug("Íå óäàëîñü ïîäêëþ÷èòü áèáëèîòåêó libimg."w);
if (load_dll2(boxlib, #edit_box_draw,0)!=0) debug("Íå óäàëîñü ïîäêëþ÷èòü áèáëèîòåêó boxlib."w);
load_dll2(#abox_lib, #boxlib_init,0);
//load_dll2(libtruetype, #truetype,0);
if (load_dll2(libtruetype, #truetype,0)!=0) debug("Íå óäàëîñü ïîäêëþ÷èòü áèáëèîòåêó TrueType."w);
if (!URL) strcpy(#URL, "/sys/home.htm");
strcpy(#editURL, #URL);
/programs/network/htmlv/browser/History.txt
1,3 → 1,6
05.11.12 - 0.97.5
Ïåðåêëþ÷àëêà íà øðèôòû TrueType èç ìåíþ ÏÊÌ.
 
16.07.12 - 0.97
- íåáîëüøèå óëó÷øåíèÿ â îáðàáîòêå ññûëîê è èçîáðàæåíèé;
- âêëþ÷åíèå îáðàáîòêè ðàçðûâîâ ñòðîê ÷åðåç ìåíþ;
/programs/network/htmlv/browser/TWB.h
8,7 → 8,7
 
char download_path[]="/rd/1/.download";
char search_path[]="http://nigma.ru/index.php?s=";
char version[]=" Text-based Browser 0.97";
char version[]=" Text-based Browser 0.97.5";
 
 
struct TWebBrowser {
119,6 → 119,9
if (!pre_text) pre_text=2;
else pre_text=0;
break;
case 005: //truetype
if (use_truetype == 1) use_truetype=0; else use_truetype=1;
break;
case BACK:
if (!BrowserHistory.GoBack()) return;
OpenPage();
130,9 → 133,6
case 052: //Íàæàòà F3
if (strcmp(get_URL_part(5),"http:")<>0) RunProgram("/rd/1/tinypad", #URL); else RunProgram("/rd/1/tinypad", #download_path);
return;
case 053: //Íàæàòà F4
if (strcmp(get_URL_part(5),"http:")<>0) RunProgram("/rd/1/develop/t_edit", #URL); else RunProgram("/rd/1/develop/t_edit", #download_path);
return;
case 054: //F5
IF(edit1.flags == 66) break;
case REFRESH:
180,22 → 180,22
IF(lines.first == lines.all - lines.visible) return;
lines.first += lines.visible + 2;
IF(lines.visible + lines.first > lines.all) lines.first = lines.all - lines.visible;
BREAK;
break;
case 184: //PgUp
IF(lines.first == 0) RETURN;
IF(lines.first == 0) return;
lines.first -= lines.visible - 2;
IF(lines.first < 0) lines.first = 0;
BREAK;
break;
case 180: //home
IF(lines.first == 0) RETURN;
IF(lines.first == 0) return;
lines.first = 0;
BREAK;
break;
case 181: //end
IF (lines.first == lines.all - lines.visible) RETURN;
IF (lines.first == lines.all - lines.visible) return;
lines.first = lines.all - lines.visible;
BREAK;
break;
default:
RETURN;
return;
}
ParseHTML(buf);
}
540,10 → 540,17
start_y=stroka * 10 + top + 5;
line_length=strlen(#line)*6;
if (use_truetype == 1)
{
//line_length = get_length stdcall (#line,-1,16,line_length);
text_out stdcall (#line, -1, 17, text_colors[text_color_index], start_x, start_y-3);
Pause(10);
}
else
{
WriteText(start_x, start_y, 0x80, text_colors[text_color_index], #line, 0);
//line_length = get_length stdcall (#line,-1,16,line_length);
//text_out stdcall (#line, -1, 17, text_colors[text_color_index], start_x, start_y-2);
IF (b_text) { $add ebx, 1<<16 $int 0x40 }
}
IF (i_text) Skew(start_x, start_y, line_length+6, 10);
IF (s_text) DrawBar(start_x, start_y + 4, line_length, 1, text_colors[text_color_index]);
IF (u_text) DrawBar(start_x, start_y + 8, line_length, 1, text_colors[text_color_index]);
/programs/network/htmlv/browser/compile.bat
2,5 → 2,5
del HTMLv
rename HTMLv.com HTMLv
rem ..\C--\kpack HTMLv
pause
del warning.txt
pause
/programs/network/htmlv/browser/include/menu_rmb.h
5,11 → 5,12
 
char *ITEMS_LIST[]={
"View in Tinypad F3",52,
"View in TextEdit F4",53,
"WIN F5",REFRESH,
"DOS Ctrl+D",04,
"KOI-8 Ctrl+K",11,
"UTF Ctrl+U",21,
"DOS Ctrl+D",04,
"Line breaks ON" ,01,
"TrueType fonts" ,05,
0};
 
 
88,6 → 89,7
DrawBar(1, i*ITEM_HEIGHT+1, ITEM_WIDTH-1, ITEM_HEIGHT, EDX);
WriteText(8,i*ITEM_HEIGHT+6,0x80,0x000000,ITEMS_LIST[i*2],0);
if (ITEMS_LIST[i*2+1]==1) && (pre_text==2) DrawBar(ITEM_WIDTH-18, i*ITEM_HEIGHT+8, 4, 4, 0x444444);
if (ITEMS_LIST[i*2+1]==5) && (use_truetype==1) DrawBar(ITEM_WIDTH-18, i*ITEM_HEIGHT+8, 4, 4, 0x444444);
}
}
}