Rev 7056 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
4411 | leency | 1 | |
4677 | leency | 2 | |
4416 | leency | 3 | |
5746 | leency | 4 | |
4416 | leency | 5 | |
5746 | leency | 6 | byte |
7 | b, u, s, h, |
||
6794 | leency | 8 | pre, |
5746 | leency | 9 | blq, |
10 | li, |
||
11 | li_tab, |
||
12 | align; |
||
13 | }; |
||
14 | |||
15 | |||
4411 | leency | 16 | llist list; |
4540 | leency | 17 | _style style; |
5746 | leency | 18 | DrawBufer DrawBuf; |
4475 | leency | 19 | int zoom; |
6803 | leency | 20 | void Prepare(); |
5766 | leency | 21 | void SetStyle(); |
22 | void DrawStyle(); |
||
23 | void DrawPage(); |
||
4411 | leency | 24 | void DrawScroller(); |
25 | void LoadInternalPage(); |
||
5747 | leency | 26 | void NewLine(); |
4650 | leency | 27 | void Perenos(); |
4718 | leency | 28 | void BufEncode(); |
5749 | leency | 29 | } WB1; |
4686 | leency | 30 | |
4486 | leency | 31 | |
5746 | leency | 32 | |
33 | link, |
||
34 | ignor_text, |
||
35 | cur_encoding, |
||
36 | t_html, |
||
37 | t_body; |
||
38 | |||
39 | |||
5781 | leency | 40 | dword o_bufpointer=0; |
41 | dword bufsize=0; |
||
42 | |||
4411 | leency | 43 | |
4417 | leency | 44 | dword text_color_index; |
45 | dword link_color_inactive; |
||
4491 | leency | 46 | dword link_color_active; |
47 | dword bg_color; |
||
4417 | leency | 48 | |
4411 | leency | 49 | |
6794 | leency | 50 | int stolbec; |
4417 | leency | 51 | int tab_len; |
52 | int anchor_y; |
||
6794 | leency | 53 | |
4636 | leency | 54 | |
6794 | leency | 55 | int basic_line_h=22; |
56 | |||
57 | |||
5746 | leency | 58 | char header[2048]; |
59 | char line[500]; |
||
4417 | leency | 60 | char tagparam[10000]; |
5746 | leency | 61 | char tag[100]; |
4417 | leency | 62 | char oldtag[100]; |
5768 | leency | 63 | char attr[1200]; |
5746 | leency | 64 | char val[4096]; |
65 | |||
4411 | leency | 66 | |
5990 | leency | 67 | #include "..\TWB\links.h" |
4686 | leency | 68 | #include "..\TWB\colors.h" |
4411 | leency | 69 | #include "..\TWB\unicode_tags.h" |
70 | #include "..\TWB\img_cache.h" |
||
71 | #include "..\TWB\parce_tag.h" |
||
72 | |||
73 | |||
4475 | leency | 74 | |
5747 | leency | 75 | void TWebBrowser::DrawStyle() |
5766 | leency | 76 | { |
4411 | leency | 77 | dword start_x, line_length, stolbec_len; |
6803 | leency | 78 | |
4411 | leency | 79 | |
80 | { |
||
81 | strcpy(#header, #line); |
||
7032 | leency | 82 | line = 0; |
4411 | leency | 83 | return; |
84 | } |
||
85 | if (t_html) && (!t_body) return; |
||
4637 | leency | 86 | |
4411 | leency | 87 | |
6803 | leency | 88 | { |
4411 | leency | 89 | start_x = stolbec * list.font_w + body_magrin + list.x; |
6794 | leency | 90 | stolbec_len = strlen(#line) * zoom; |
6803 | leency | 91 | line_length = stolbec_len * list.font_w; |
5768 | leency | 92 | |
4411 | leency | 93 | |
6794 | leency | 94 | if (style.b) WriteBufText(start_x+1, draw_y, list.font_type, text_colors[text_color_index], #line, buf_data); |
95 | if (style.s) DrawBuf.DrawBar(start_x, list.item_h / 2 - zoom + draw_y, line_length, zoom, text_colors[text_color_index]); |
||
6803 | leency | 96 | if (style.u) DrawBuf.DrawBar(start_x, list.item_h - zoom - zoom + draw_y, line_length, zoom, text_colors[text_color_index]); |
97 | if (link) { |
||
5519 | leency | 98 | DrawBuf.DrawBar(start_x, draw_y + list.item_h - calc(zoom*2), line_length, zoom, text_colors[text_color_index]); |
6803 | leency | 99 | PageLinks.AddText(start_x, draw_y + list.y, line_length, list.item_h - calc(zoom*2), UNDERLINE, zoom); //TODO: set bigger underline_h for style.h |
100 | } |
||
4411 | leency | 101 | stolbec += stolbec_len; |
4718 | leency | 102 | } |
4411 | leency | 103 | } |
104 | //============================================================================================ |
||
5747 | leency | 105 | void TWebBrowser::LoadInternalPage(dword bufpos, in_filesize){ |
106 | bufsize = in_filesize; |
||
107 | bufpointer = bufpos; |
||
108 | Prepare(); |
||
5766 | leency | 109 | } |
5747 | leency | 110 | //============================================================================================ |
111 | void TWebBrowser::Prepare(){ |
||
5766 | leency | 112 | word bukva[2]; |
4411 | leency | 113 | dword j; |
6803 | leency | 114 | byte ignor_param; |
4411 | leency | 115 | dword bufpos; |
5773 | leency | 116 | dword line_len; |
6803 | leency | 117 | style.b = style.u = style.s = style.h = style.blq = t_html = t_body = |
6794 | leency | 118 | style.li = link = ignor_text = text_color_index = text_colors[0] = style.li_tab = 0; |
5749 | leency | 119 | style.align = ALIGN_LEFT; |
5746 | leency | 120 | link_color_inactive = 0x0000FF; |
4491 | leency | 121 | link_color_active = 0xFF0000; |
122 | bg_color = 0xFFFFFF; |
||
6783 | leency | 123 | DrawBuf.Fill(bg_color); |
4475 | leency | 124 | PageLinks.Clear(); |
4504 | leency | 125 | strcpy(#header, #version); |
4411 | leency | 126 | draw_y = body_magrin; |
6794 | leency | 127 | stolbec = 0; |
4411 | leency | 128 | line = 0; |
129 | zoom = 1; |
||
6803 | leency | 130 | //for plaint text use CP866 for other UTF |
5749 | leency | 131 | if (strstri(bufpointer, "html")!=-1) |
6783 | leency | 132 | { |
5749 | leency | 133 | debugln(" found"); |
6783 | leency | 134 | style.pre = false; |
135 | cur_encoding = CH_NULL; |
||
6045 | leency | 136 | } |
5749 | leency | 137 | else |
138 | { |
||
139 | debugln("no "); |
||
6783 | leency | 140 | style.pre = true; |
141 | cur_encoding = CH_NULL; |
||
6045 | leency | 142 | } |
5749 | leency | 143 | for (bufpos=bufpointer ; (bufpos < bufpointer+bufsize) && (ESBYTE[bufpos]!=0) ; bufpos++;) |
5773 | leency | 144 | { |
4411 | leency | 145 | if (ignor_text) && (ESBYTE[bufpos]!='<') continue; |
5773 | leency | 146 | bukva = ESBYTE[bufpos]; |
4508 | leency | 147 | switch (bukva) |
4411 | leency | 148 | { |
149 | case 0x0a: |
||
150 | if (style.pre) |
||
5746 | leency | 151 | { |
4411 | leency | 152 | DrawStyle(); |
5781 | leency | 153 | line = NULL; |
6783 | leency | 154 | NewLine(); |
5781 | leency | 155 | break; |
4726 | leency | 156 | } |
4411 | leency | 157 | goto DEFAULT_MARK; |
6783 | leency | 158 | case '\9': |
4411 | leency | 159 | if (style.pre) //otherwise go to 0x0d |
6735 | leency | 160 | { |
4411 | leency | 161 | tab_len = strlen(#line) % 4; |
4725 | leency | 162 | if (!tab_len) tab_len = 4; |
163 | for (j=0; j |
||
4411 | leency | 164 | break; |
165 | } |
||
166 | goto DEFAULT_MARK; |
||
6783 | leency | 167 | case '&': // and so on |
4411 | leency | 168 | bufpos++; |
4508 | leency | 169 | tag=0; |
4411 | leency | 170 | for (j=0; (ESBYTE[bufpos]<>';') && (j<7); j++, bufpos++;) |
4508 | leency | 171 | { |
4411 | leency | 172 | bukva = ESBYTE[bufpos]; |
4508 | leency | 173 | chrcat(#tag, bukva); |
4411 | leency | 174 | } |
175 | if (bukva = GetUnicodeSymbol()) goto DEFAULT_MARK; |
||
4417 | leency | 176 | break; |
4411 | leency | 177 | case '<': |
178 | bufpos++; |
||
5749 | leency | 179 | if (!strncmp(bufpos,"!--",3)) |
5768 | leency | 180 | { |
4411 | leency | 181 | bufpos+=3; |
6986 | leency | 182 | while (strncmp(bufpos,"-->",3)!=0) && (bufpos < bufpointer + bufsize) |
183 | { |
||
184 | bufpos++; |
||
185 | } |
||
186 | bufpos+=3; |
||
187 | break; |
||
188 | } |
||
4411 | leency | 189 | tag = attr = tagparam = ignor_param = NULL; |
5768 | leency | 190 | while (ESBYTE[bufpos] !='>') && (bufpos < bufpointer + bufsize) //ïîëó÷àåì òåã è åãî ïàðàìåòðû |
6735 | leency | 191 | { |
4411 | leency | 192 | bukva = ESBYTE[bufpos]; |
4508 | leency | 193 | if (bukva == '\9') || (bukva == '\x0a') || (bukva == '\x0d') bukva = ' '; |
4411 | leency | 194 | if (!ignor_param) && (bukva <>' ') |
195 | { |
||
196 | if (strlen(#tag)+1 |
||
6686 | leency | 197 | } |
4411 | leency | 198 | else |
199 | { |
||
200 | ignor_param = true; |
||
201 | if (!ignor_text) && (strlen(#tagparam)+1 |
||
202 | } |
||
203 | bufpos++; |
||
4508 | leency | 204 | } |
4411 | leency | 205 | strlwr(#tag); |
206 | |||
207 | |||
208 | if (tagparam) GetNextParam(); |
||
4726 | leency | 209 | Perenos(); |
5768 | leency | 210 | DrawStyle(); |
5766 | leency | 211 | line = NULL; |
4677 | leency | 212 | if (tag) SetStyle(); |
6735 | leency | 213 | strlcpy(#oldtag, #tag, sizeof(oldtag)); |
6686 | leency | 214 | tag = attr = tagparam = ignor_param = NULL; |
5746 | leency | 215 | break; |
4411 | leency | 216 | default: |
217 | DEFAULT_MARK: |
||
218 | if (bukva<=15) bukva=' '; |
||
219 | line_len = strlen(#line); |
||
6021 | leency | 220 | if (!style.pre) && (bukva == ' ') |
5746 | leency | 221 | { |
4411 | leency | 222 | if (line[line_len-1]==' ') break; //no double spaces |
4726 | leency | 223 | if (!stolbec) && (!line) break; //no paces at the beginning of the line |
224 | } |
||
4411 | leency | 225 | if (line_len < sizeof(line)) chrcat(#line, bukva); |
4726 | leency | 226 | Perenos(); |
5768 | leency | 227 | } |
4411 | leency | 228 | } |
229 | DrawStyle(); |
||
5766 | leency | 230 | NewLine(); |
231 | if (list.first == 0) list.count = draw_y; |
||
6794 | leency | 232 | DrawPage(); |
4692 | leency | 233 | } |
4411 | leency | 234 | //============================================================================================ |
5747 | leency | 235 | void TWebBrowser::Perenos() |
4718 | leency | 236 | { |
237 | int perenos_num; |
||
238 | char new_line_text[4096]; |
||
239 | if (strlen(#line)*zoom + stolbec < list.column_max) return; |
||
6803 | leency | 240 | perenos_num = strrchr(#line, ' '); |
4718 | leency | 241 | if (!perenos_num) && (strlen(#line)*zoom>list.column_max) perenos_num=list.column_max/zoom; |
6803 | leency | 242 | strcpy(#new_line_text, #line + perenos_num); |
4718 | leency | 243 | line[perenos_num] = 0x00; |
244 | DrawStyle(); |
||
5766 | leency | 245 | strcpy(#line, #new_line_text); |
4718 | leency | 246 | NewLine(); |
247 | } |
||
248 | //============================================================================================ |
||
5747 | leency | 249 | void TWebBrowser::SetStyle() { |
5773 | leency | 250 | int left1 = body_magrin + list.x; |
6794 | leency | 251 | byte opened; |
4491 | leency | 252 | byte meta_encoding; |
4636 | leency | 253 | if (tag[0] == '/') |
4411 | leency | 254 | { |
255 | opened = 0; |
||
4491 | leency | 256 | strcpy(#tag, #tag+1); |
4411 | leency | 257 | } |
258 | else opened = 1; |
||
4491 | leency | 259 | if (istag("html")) { |
5749 | leency | 260 | t_html = opened; |
4637 | leency | 261 | return; |
4411 | leency | 262 | } |
263 | if (istag("script")) || (istag("style")) || (istag("binary")) || (istag("select")) { ignor_text = opened; return; } |
||
5749 | leency | 264 | if (istag("form")) if (!opened) ignor_text = false; |
5746 | leency | 265 | if(istag("title")) { |
5749 | leency | 266 | if (opened) header=NULL; |
4491 | leency | 267 | return; |
4411 | leency | 268 | } |
269 | if (ignor_text) return; |
||
270 | |||
271 | |||
5746 | leency | 272 | { |
4491 | leency | 273 | if (opened) strcat(#line, " \""); |
5746 | leency | 274 | if (!opened) strcat(#line, "\" "); |
275 | return; |
||
5749 | leency | 276 | } |
4491 | leency | 277 | //if (isattr("id=")) || (isattr("name=")) { //very bad: if the tag is not the last it wound work |
6803 | leency | 278 | //add anchor |
279 | //} |
||
280 | if (istag("body")) { |
||
5749 | leency | 281 | t_body = opened; |
4637 | leency | 282 | do{ |
4411 | leency | 283 | if (isattr("link=")) link_color_inactive = GetColor(#val); |
5746 | leency | 284 | if (isattr("alink=")) link_color_active = GetColor(#val); |
285 | if (isattr("text=")) text_colors[0]=GetColor(#val); |
||
286 | if (isattr("bgcolor=")) |
||
287 | { |
||
4411 | leency | 288 | bg_color = GetColor(#val); |
6783 | leency | 289 | DrawBuf.Fill(bg_color); |
4475 | leency | 290 | } |
4411 | leency | 291 | } while(GetNextParam()); |
292 | if (opened) && (cur_encoding==CH_NULL) { |
||
7032 | leency | 293 | cur_encoding = CH_UTF8; |
294 | debugln("Document has no information about encoding, UTF will be used"); |
||
295 | } |
||
296 | if (opened) { |
||
297 | if (strcmp(#header, #version) != 0) { |
||
7208 | leency | 298 | debugln("!!!!!!!!!!!!!!!!!!!!!!"); |
299 | ChangeCharset(charsets[cur_encoding], "CP866", #header); |
||
7056 | leency | 300 | sprintf(#header, "%s - %s", #header, #version); |
301 | } |
||
302 | DrawTitle(#header); |
||
7032 | leency | 303 | } |
304 | return; |
||
4411 | leency | 305 | } |
306 | if (istag("a")) { |
||
5749 | leency | 307 | if (opened) |
4491 | leency | 308 | { |
4411 | leency | 309 | if (link) IF(text_color_index > 0) text_color_index--; //åñëè ïðåäûäóùèé òåã à íå áûë çàêðûò |
6735 | leency | 310 | do{ |
4411 | leency | 311 | if (isattr("href=")) && (!strstr(#val,"javascript:")) |
6001 | leency | 312 | { |
4411 | leency | 313 | text_color_index++; |
314 | text_colors[text_color_index] = text_colors[text_color_index-1]; |
||
315 | link = 1; |
||
316 | text_colors[text_color_index] = link_color_inactive; |
||
4491 | leency | 317 | PageLinks.AddLink(#val); |
6795 | leency | 318 | } |
4411 | leency | 319 | } while(GetNextParam()); |
320 | } |
||
321 | else { |
||
322 | link = 0; |
||
323 | IF(text_color_index > 0) text_color_index--; |
||
324 | } |
||
325 | return; |
||
326 | } |
||
327 | if (istag("font")) { |
||
5749 | leency | 328 | if (opened) |
4491 | leency | 329 | { |
4411 | leency | 330 | text_color_index++; |
331 | text_colors[text_color_index] = text_colors[text_color_index-1]; |
||
332 | do{ |
||
333 | if (isattr("color=")) text_colors[text_color_index] = GetColor(#val); |
||
5749 | leency | 334 | } while(GetNextParam()); |
4411 | leency | 335 | } |
336 | else if (text_color_index > 0) text_color_index--; |
||
5749 | leency | 337 | return; |
4411 | leency | 338 | } |
339 | if (istag("div")) || (istag("header")) || (istag("article")) || (istag("footer")) { |
||
5746 | leency | 340 | IF(oldtag[0] != 'h') NewLine(); |
5749 | leency | 341 | return; |
4411 | leency | 342 | } |
343 | if (istag("p")) { |
||
5746 | leency | 344 | IF(oldtag[0] == 'h') return; |
4411 | leency | 345 | NewLine(); |
4692 | leency | 346 | IF(opened) NewLine(); |
347 | return; |
||
4411 | leency | 348 | } |
349 | if (istag("br")) { NewLine(); return; } |
||
5749 | leency | 350 | if (istag("tr")) { if (opened) NewLine(); return; } |
5990 | leency | 351 | if (istag("b")) || (istag("strong")) || (istag("big")) { style.b = opened; return; } |
5749 | leency | 352 | if (istag("u")) || (istag("ins")) { style.u=opened; return;} |
353 | if (istag("s")) || (istag("strike")) || (istag("del")) { style.s=opened; return; } |
||
354 | if (istag("dd")) { stolbec += 5; return; } |
||
355 | if (istag("blockquote")) { style.blq = opened; return; } |
||
356 | if (istag("pre")) || (istag("code")) { style.pre = opened; return; } |
||
357 | if (istag("img")) { ImgCache.Images( left1, draw_y, WB1.list.w); return; } |
||
6794 | leency | 358 | if (istag("h1")) || (istag("h2")) || (istag("h3")) || (istag("caption")) { |
7208 | leency | 359 | style.h = opened; |
5768 | leency | 360 | if (opened) |
4491 | leency | 361 | { |
4411 | leency | 362 | NewLine(); |
6794 | leency | 363 | draw_y += 10; |
364 | WB1.zoom=2; |
||
6803 | leency | 365 | WB1.list.font_type |= 10011001b; |
6045 | leency | 366 | if (isattr("align=")) && (isval("center")) style.align = ALIGN_CENTER; |
5746 | leency | 367 | if (isattr("align=")) && (isval("right")) style.align = ALIGN_RIGHT; |
368 | list.item_h = basic_line_h * 2; |
||
6794 | leency | 369 | } |
4411 | leency | 370 | else |
5768 | leency | 371 | { |
4411 | leency | 372 | NewLine(); |
6794 | leency | 373 | WB1.zoom=1; |
6803 | leency | 374 | WB1.list.font_type = 10011000b; |
6045 | leency | 375 | style.align = ALIGN_LEFT; |
5746 | leency | 376 | list.item_h = basic_line_h; |
6794 | leency | 377 | } |
4411 | leency | 378 | return; |
379 | } |
||
380 | if (istag("dt")) { |
||
5749 | leency | 381 | style.li = opened; |
5746 | leency | 382 | if (opened) NewLine(); |
5749 | leency | 383 | return; |
4411 | leency | 384 | } |
385 | if (istag("li")) || (istag("dt")) |
||
5773 | leency | 386 | { |
4411 | leency | 387 | style.li = opened; |
5746 | leency | 388 | if (opened) |
4491 | leency | 389 | { |
4411 | leency | 390 | NewLine(); |
4692 | leency | 391 | strcpy(#line, "\31 \0"); |
6803 | leency | 392 | } |
4411 | leency | 393 | return; |
394 | } |
||
395 | if (istag("ul")) || (istag("ol")) { |
||
5749 | leency | 396 | if (!opened) |
397 | { |
||
398 | style.li = opened; |
||
399 | style.li_tab--; |
||
400 | NewLine(); |
||
401 | } |
||
402 | else style.li_tab++; |
||
403 | } |
||
404 | if (istag("hr")) { |
||
405 | if (isattr("color=")) EDI = GetColor(#val); else EDI = 0x999999; |
||
5773 | leency | 406 | $push edi; |
407 | NewLine(); |
||
4692 | leency | 408 | $pop edi; |
5773 | leency | 409 | DrawBuf.DrawBar(5, draw_y - 1, list.w-10, 1, EDI); |
6794 | leency | 410 | NewLine(); |
4692 | leency | 411 | return; |
5773 | leency | 412 | } |
4411 | leency | 413 | if (istag("meta")) || (istag("?xml")) { |
5749 | leency | 414 | meta_encoding = CH_NULL; |
6045 | leency | 415 | do{ |
4411 | leency | 416 | if (isattr("charset=")) || (isattr("content=")) || (isattr("encoding=")) |
5746 | leency | 417 | { |
4411 | leency | 418 | strcpy(#val, #val[strrchr(#val, '=')]); //search in content= |
6735 | leency | 419 | strlwr(#val); |
5746 | leency | 420 | if (isval("utf-8")) || (isval("utf8")) meta_encoding = CH_UTF8; |
5749 | leency | 421 | else if (isval("koi8-r")) || (isval("koi8-u")) meta_encoding = CH_KOI8; |
5746 | leency | 422 | else if (isval("windows-1251")) || (isval("windows1251")) meta_encoding = CH_CP1251; |
423 | else if (isval("iso-8859-5")) || (isval("iso8859-5")) meta_encoding = CH_ISO8859_5; |
||
424 | else if (isval("dos")) || (isval("cp-866")) meta_encoding = CH_CP866; |
||
425 | } |
||
4411 | leency | 426 | } while(GetNextParam()); |
427 | if (meta_encoding!=CH_NULL) BufEncode(meta_encoding); |
||
6045 | leency | 428 | return; |
4411 | leency | 429 | } |
430 | } |
||
431 | |||
432 | |||
6803 | leency | 433 | { |
5704 | leency | 434 | if (cur_encoding == set_new_encoding) return; |
7032 | leency | 435 | if (o_bufpointer==0) |
5704 | leency | 436 | { |
437 | o_bufpointer = malloc(bufsize); |
||
438 | strcpy(o_bufpointer, bufpointer); |
||
439 | } |
||
440 | else |
||
441 | { |
||
442 | strcpy(bufpointer, o_bufpointer); |
||
443 | } |
||
444 | debugval("cur_encoding ", cur_encoding); |
||
7032 | leency | 445 | debugval("set_new_encoding", set_new_encoding); |
446 | cur_encoding = set_new_encoding; |
||
447 | bufpointer = ChangeCharset(charsets[cur_encoding], "CP866", bufpointer); |
||
448 | } |
||
5704 | leency | 449 | //============================================================================================ |
5747 | leency | 450 | void TWebBrowser::DrawScroller() |
4674 | leency | 451 | { |
4411 | leency | 452 | scroll_wv.max_area = list.count; |
4416 | leency | 453 | scroll_wv.cur_area = list.visible; |
454 | scroll_wv.position = list.first; |
||
455 | scroll_wv.all_redraw = 0; |
||
5519 | leency | 456 | scroll_wv.start_x = list.x + list.w; |
4486 | leency | 457 | scroll_wv.start_y = list.y; |
4508 | leency | 458 | scroll_wv.size_y = list.h; |
5678 | leency | 459 | scrollbar_v_draw(#scroll_wv); |
4416 | leency | 460 | } |
4411 | leency | 461 | //============================================================================================ |
5747 | leency | 462 | void TWebBrowser::NewLine() |
4692 | leency | 463 | { |
4475 | leency | 464 | dword onleft, ontop; |
6803 | leency | 465 | |
4692 | leency | 466 | |
6794 | leency | 467 | |
468 | |||
469 | ontop = draw_y + list.y; |
||
470 | if (t_html) && (!t_body) return; |
||
4637 | leency | 471 | draw_y += list.item_h; |
6794 | leency | 472 | if (style.blq) stolbec = 6; else stolbec = 0; |
5746 | leency | 473 | if (style.li) stolbec = style.li_tab * 5; |
474 | } |
||
4488 | leency | 475 | //============================================================================================ |
5747 | leency | 476 | bool istag(dword text) { if (!strcmp(#tag,text)) return true; else return false; } |
6803 | leency | 477 | bool isattr(dword text) { if (!strcmp(#attr,text)) return true; else return false; } |
478 | bool isval(dword text) { if (!strcmp(#val,text)) return true; else return false; } |
||
479 | //============================================================================================ |
||
5766 | leency | 480 | void TWebBrowser::DrawPage() |
481 | { |
||
482 | PutPaletteImage(list.first * DrawBuf.bufw * 4 + buf_data+8, DrawBuf.bufw, list.h, DrawBuf.bufx, DrawBuf.bufy, 32, 0); |
||
6794 | leency | 483 | DrawScroller(); |
5766 | leency | 484 | }>>=15)>>>>': |
485 | >7);>>')>> |