2007-01-26 12:20:00 +01:00
; <Lrz> 26.01.2007 <20> <> ଠ <EFBFBD> 쭠<EFBFBD> ࠡ<> <E0A0A1> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> ࠢ<EFBFBD> <E0A0A2> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> .check_offset
; <Lrz> 24.01.2007 <20> <> 䨪ᥫ <20> <> <EFBFBD> <EFBFBD> <20> 맢<EFBFBD> <EBA7A2> <EFBFBD> <EFBFBD> <20> <> <20> ࠢ<EFBFBD> <E0A0A2> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> )).
2007-01-22 14:50:18 +01:00
; <Lrz> 22.01.2007 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <20> <> <EFBFBD> ࠡ<> <E0A0A1> <EFBFBD> <20> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 㤠<> <E3A4A0> <EFBFBD> <EFBFBD> <EFBFBD> , <20> <> <EFBFBD> ४⭠<E0A5AA> ࠡ<> <E0A0A1> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 襩 del & backspase
; <Lrz> 20.01.2007 ॠ<> <E0A5A0> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> ⥪<> <E2A5AA> <EFBFBD> <20> <> shift
2006-12-13 06:18:25 +01:00
; <Lrz> 12.12.2006 ॠ<> <E0A5A0> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> প<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> insert <20> ᥣ<> <E1A5A3> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ࠡ<> ⠥<EFBFBD> !!!!
; <Lrz> 07.12.2006 <20> த<EFBFBD> <E0AEA4> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ࠡ<> <E0A0A1> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ࠡ<EFBFBD> ⪮<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ,<2C> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ࣫<EFBFBD> <E0A3AB> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 㭪樨, <20> <> <EFBFBD> <EFBFBD> ࠡ<EFBFBD> ⠭ <20> 뢮<EFBFBD> ⥪<> <E2A5AA> <EFBFBD> , <20> ⠪<> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> ᥭ<EFBFBD> <E1A5AD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> .
; <Lrz> 03.09.2006 <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> ⪠<EFBFBD> <E2AAA0> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> 16 <20> <> ⭮<EFBFBD> <20> <> <EFBFBD> 䬥⨪<E4ACA5> , <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD>
; <Lrz> 09.08.2006 <20> ந<EFBFBD> <E0AEA8> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ⨬<EFBFBD> <E2A8AC> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ࠡ<> <E0A0A1> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> DEL <20> Backspace, 㬥<> <E3ACA5> 襭 ࠧ<> <E0A0A7> <EFBFBD> <20> 믮<EFBFBD> <EBAFAE> 塞<EFBFBD> <EFA5AC> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> .
; <Lrz> 21.07.2006 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 㭪<EFBFBD> <E3ADAA> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> Del, ⥯<> <E2A5AF> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 㤠<> <E3A4A0> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> : <20> <> <EFBFBD> <EFBFBD> 客 <20> <> <EFBFBD> ᨬ (Maxxxx32) email: maxxxxm@mail.ru
; <20> <> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <E1ABA5> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> : 13.06.06 10:40
; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <> <E1A2AE> <20> ணࠬ<E0AEA3> <E0A0AC> use_edit_box,
; <20> <> <EFBFBD> <20> <> ⠢<EFBFBD> <E2A0A2> <20> <> <EFBFBD> <EFBFBD> 室<EFBFBD> <E5AEA4> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <20> <> <EFBFBD> <20> <> 襩 <20> ணࠬ<E0AEA3> <E0A0AC> .
; <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> :
; edit_box.draw - <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> ;
; edit_box.key - <20> <> ࠡ<EFBFBD> ⪠ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ;
; edit_box.mouse - <20> <> ࠡ<EFBFBD> ⪠ <20> <> <EFBFBD> <EFBFBD> ;
; edit_box.focus - <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䮪<> <E4AEAA> <EFBFBD> ;
; edit_box.blur - <20> <> <EFBFBD> ࠧ<> 뢠<EFBFBD> <EBA2A0> <EFBFBD> ;
; edit_box.get_n - <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ⢮ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ᮢ뢠<E1AEA2> <EBA2A0> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> .
; <20> <> <EFBFBD> <20> 맮<EFBFBD> <EBA7AE> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <20> ॣ<> <E0A5A3> <EFBFBD> <EFBFBD> <EFBFBD> edi <> <E1ABA5> <EFBFBD> <EFBFBD>
; <20> <> ⠢<EFBFBD> <E2A0A2> <EFBFBD> 㪠<> <E3AAA0> ⥫<EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> .
; <20> ਬ<EFBFBD> <E0A8AC> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> :
; some_edit edit_box 100,10,30,0x00ffffff,0,0x00aaaaaa,0,255,some_edit_text
; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> , <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> , <20> <> <EFBFBD> <EFBFBD> , 梥<> 䮭<> , 梥<> ࠬ<> <E0A0AC> , <20> <20> <> <EFBFBD> ࠭,
; 梥<> ࠬ<> <E0A0AC> , <20> <20> <> <20> <> <EFBFBD> ࠭, <20> <> <EFBFBD> ᨬ<EFBFBD> <E1A8AC> 쭮<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ⢮ ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> ,
; 㪠<> <E3AAA0> ⥫<EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> , <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> ࠭<EFBFBD> <E0A0AD> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> . <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
; <20> <> <EFBFBD> <EFBFBD> 稢<EFBFBD> <E7A8A2> <EFBFBD> <EFBFBD> <EFBFBD> <20> 㫥<EFBFBD> , <20> <> <EFBFBD> ਬ<EFBFBD> <E0A8AC> <20> <20> <> <EFBFBD> ᨬ<EFBFBD> <E1A8AC> 쭮<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ⢮ 255:
; some_edit_text:
; rb 256 ;255+1
; <20> ਬ<EFBFBD> <E0A8AC> <20> 맮<EFBFBD> <EBA7AE> <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> :
; mov edi,some_edit
; call edit_box.draw
; <20> <> <EFBFBD> <20> 맮<EFBFBD> <EBA7AE> <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> edit_box.key <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
; <20> <> 室<EFBFBD> <E5AEA4> <EFBFBD> <EFBFBD> <20> ah, <20> <> <20> <> <EFBFBD> <EFBFBD> <20> <> । <20> 맮<EFBFBD> <EBA7AE> <EFBFBD> <20> ⮩ <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <20> 맢<EFBFBD> <EBA7A2> <EFBFBD>
; 2-<2D> <> <20> <> ᥬ<EFBFBD> <E1A5AC> <EFBFBD> <20> 㭪<EFBFBD> <E3ADAA> <EFBFBD> , <20> <> <EFBFBD> ਬ<EFBFBD> <E0A8AC> :
; mov eax,2
; int 0x40
; mov edi,some_edit1
; call edit_box.key
; mov edi,some_edit2
; call edit_box.key
; <20> <> । <20> 맮<EFBFBD> <EBA7AE> <EFBFBD> <20> <> ࠡ<EFBFBD> <E0A0A1> 稪<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <> <E1ABA5> <EFBFBD> <EFBFBD> <20> <EFBFBD> <E0AEA2> <EFBFBD> <EFBFBD> <EFBFBD> , <> <EFA2AB> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD>
; <20> <> ⨢<EFBFBD> <E2A8A2> <EFBFBD> .
; <20> 饫箪 <20> <> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> ன<EFBFBD> <E0AEA9> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> ।<EFBFBD> <E0A5A4> <EFBFBD> <EFBFBD> <EFBFBD> edit box
; 䮪<> <E4AEAA> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> .
macro use_edit_box
{
edit_box:
ed_width equ [edi] ;<3B> <> ਭ<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_left equ [edi+4] ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <20>
ed_top equ [edi+8] ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <20>
ed_color equ [edi+12] ;梥<> 䮭<> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_focus_border_color equ [edi+16] ;梥<> ࠬ<> <E0A0AC> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_blur_border_color equ [edi+20] ;梥<> <20> <> <20> <> ⨢<EFBFBD> <E2A8A2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_text_color equ [edi+24] ;梥<> ⥪<> <E2A5AA> <EFBFBD>
2007-01-19 15:36:00 +01:00
ed_max equ [edi+28] ;<3B> <> <EFBFBD> -<2D> <> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> ᨬ<EFBFBD> <E1A8AC> 쭮 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_text equ [edi+32] ;㪠<> <E3AAA0> ⥫<EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
ed_flags equ [edi+36] ;䫠<> <E4ABA0>
ed_size equ [edi+38] ;<3B> <> <EFBFBD> -<2D> <> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD>
ed_pos equ [edi+42] ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_offset equ [edi+46] ;ᬥ饭<E1ACA5> <E9A5AD>
cl_curs_x equ [edi+50] ;<3B> ।<EFBFBD> <E0A5A4> <EFBFBD> 饥 <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20>
cl_curs_y equ [edi+54] ;<3B> ।<EFBFBD> <E0A5A4> <EFBFBD> 饥 <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20>
2007-01-24 11:00:37 +01:00
ed_shift_pos equ [edi+58]
2006-12-13 06:18:25 +01:00
ed_height=14 ; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-01-19 15:36:00 +01:00
shift_color=0x6a9480
2007-01-24 11:00:37 +01:00
ed_insert=10000b
ed_insert_cl=1111111111101111b
2006-12-13 06:18:25 +01:00
;==========================================================
;=== <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> =================================
;==========================================================
.draw:
pusha
;--- <20> <> <EFBFBD> 㥬 ࠬ<> <E0A0AC> ---
call .draw_border ; <20> 㭪<EFBFBD> <E3ADAA> <EFBFBD> <20> ⠡<EFBFBD> <E2A0A1> 쭠
.draw_bg_cursor_text:
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 塞 ᬥ饭<E1ACA5> <E9A5AD> , <20> <20> <> <EFBFBD> <EFBFBD> ---
call .check_offset ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <E1ABA5> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> 樨 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> ⠡<EFBFBD> <E2A0A1> 쭠
;--- <20> <> <EFBFBD> 㥬 <20> <> <EFBFBD> <EFBFBD> ७<EFBFBD> <E0A5AD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ---
call .draw_bg ;<3B> <> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> ࠡ<> 祩 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
.draw_cursor_text:
;--- <20> <> <EFBFBD> 㥬 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ---
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> ----
2007-01-19 15:36:00 +01:00
test word ed_flags,ed_focus
2006-12-13 06:18:25 +01:00
je @f
call .draw_cursor
@@:
call .draw_text
popa
ret
2007-01-24 11:00:37 +01:00
;.str:
; mov ecx,0x0a ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> ⥬<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <E1ABA5> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ॣ<> <E0A5A3> <EFBFBD> <EFBFBD> <EFBFBD> ebx,eax,ecx,edx <20> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> ࠬ<EFBFBD> <E0A0AC> <EFBFBD> <EFBFBD> eax - <20> <>
; ;<3B> <> <EFBFBD> ॢ<EFBFBD> <E0A5A2> <20> <> <20> ASCII <20> <> ப<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ecx=<3D> <> <EFBFBD> ⥬<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <E1ABA5> edi <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> 㤠 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 뢠<EFBFBD> <EBA2A0> , <20> 㤥<EFBFBD> <20> <> ப<EFBFBD> , <20> <> <EFBFBD> 祬 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ६<EFBFBD> <E0A5AC> <EFBFBD> <EFBFBD> <EFBFBD>
; cmp eax,ecx ;<3B> ࠢ<EFBFBD> <E0A0A2> <EFBFBD> <EFBFBD> <20> <20> eax <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 祬 <20> ecx <20> <> <20> <> ३<EFBFBD> <E0A5A9> <20> <> @@-1 <20> .<2E> . <20> <> pop eax
; jb @f
; xor edx,edx ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> edx
; div ecx ;ࠧ<> <E0A0A7> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> - <20> <> <EFBFBD> <EFBFBD> ⮪ <20> edx
; push edx ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> ⥪
; ;dec edi ;ᬥ饭<E1ACA5> <E9A5AD> <20> <> <EFBFBD> <EFBFBD> 室<EFBFBD> <E5AEA4> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ப<EFBFBD>
2007-01-26 12:20:00 +01:00
; call .str;<3B> <> ३<EFBFBD> <E0A5A9> <20> <> ᠬ<> ᥡ<> <20> .<2E> . <20> 맢<EFBFBD> <EBA7A2> <EFBFBD> ᠬ<> ᥡ<> <20> ⠪ <20> <> ⮣<> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <20> eax <20> <> <20> ⠭<EFBFBD> <E2A0AD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 祬 <20> ecx
2007-01-24 11:00:37 +01:00
; pop eax
; @@: ;cmp al,10 ;<3B> <EFBFBD> <E0AEA2> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> 祭<EFBFBD> <E7A5AD> <20> al 祬 10 (<28> <> <EFBFBD> <20> <> <EFBFBD> ⥬<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <E1ABA5> 10 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> - <20> <> 譠<EFBFBD> ))
; ;sbb al,$69 ;- <20> <> <EFBFBD> ⭮ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> ⠢<EFBFBD> <E2A0A2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> 㬠<EFBFBD> <E3ACA0> <EFBFBD> <EFBFBD> <20> .<2E> . <20> <20> <> <20> <> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> ࠡ<> ⠥<EFBFBD>
; ;das ;<3B> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <20> ந<EFBFBD> 室<EFBFBD> <E5AEA4> 㬥<> <E3ACA5> 襭<EFBFBD> <E8A5AD> al <20> <> 66h (<28> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ᠭ<EFBFBD> <20> <> 㣮<EFBFBD> )
; or al,0x30 ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 祬 <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD>
; stosb ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ॣ<> <E0A5A3> <EFBFBD> <EFBFBD> <EFBFBD> al <20> <20> 祪<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> es:edi
2007-01-26 12:20:00 +01:00
;
2007-01-24 11:00:37 +01:00
; ret ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 祭<> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 室 <20> .<2E> . <20> <> <EFBFBD> <EFBFBD> <20> <20> ⥪<EFBFBD> <20> ࠭<EFBFBD> <E0A0AD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> -<2D> <> <20> 맮<EFBFBD> <EBA7AE> <EFBFBD> <20> <> <20> ⮫쪮 ࠧ <20> <> <20> <20> 㤥<EFBFBD> <20> <> <EFBFBD> 뢠<EFBFBD> <EBA2A0> <EFBFBD> <EFBFBD>
2007-01-19 15:36:00 +01:00
2006-12-13 06:18:25 +01:00
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> ⥪<> <E2A5AA> <EFBFBD> --------------------------
;----------------------------------------------------------
.draw_text:
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 塞, <> 쪮 <20> <> <EFBFBD> <EFBFBD> 頥<EFBFBD> <E9A0A5> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> ---
;--- <20> ⮡<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> ---
call .get_n
mov esi,ed_size
mov ebx,ed_offset
sub esi,ebx
cmp eax,esi
jae @F
mov esi,eax ;<3B> ⮡<EFBFBD> <20> <> <20> <> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> <20> ।<EFBFBD> <E0A5A4> <EFBFBD> <20> <> ࠭<EFBFBD>
;--- <20> <> <EFBFBD> 㥬 ⥪<> <E2A5AA> ---
@@: mov eax,4
mov ebx,ed_left
add ebx,2
shl ebx,16
mov bx,ed_top
add ebx,4
mov ecx,ed_text_color
mov edx,ed_offset
add edx,ed_text
int 0x40
ret
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> 䮭<> ----------------------------
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
;eax
2007-01-24 11:00:37 +01:00
;edx - color
2006-12-13 06:18:25 +01:00
;----------------------------------------------------------
.draw_bg_eax:
2007-01-19 15:36:00 +01:00
;pusha
2006-12-13 06:18:25 +01:00
mov ecx,ed_top
add ecx,1
shl ecx,16
mov cx,13
mov eax,13
int 0x40
2007-01-19 15:36:00 +01:00
;popa
2007-01-22 14:50:18 +01:00
ret
2006-12-13 06:18:25 +01:00
jmp @f
.draw_bg:
2007-01-19 15:36:00 +01:00
;pusha
2006-12-13 06:18:25 +01:00
mov ebx,ed_left
add ebx,1
shl ebx,16
mov bx,ed_width
sub ebx,1
@@:
mov ecx,ed_top
add ecx,1
shl ecx,16
mov cx,ed_height
sub ecx,1
mov edx,ed_color
mov eax,13
int 0x40
2007-01-19 15:36:00 +01:00
;popa
2006-12-13 06:18:25 +01:00
ret
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> 祭<EFBFBD> <E7A5AD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ⢠ ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> <20> ⥪<> 饩 <20> <> ਭ<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> --------------
;----------------------------------------------------------
.get_n:
xor edx,edx ;१<> <E0A5A7> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ᯮ<EFBFBD> <E1AFAE> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> edx:eax <20> eax - <20> <> <EFBFBD> <EFBFBD> ⮪
mov eax,ed_width ;<3B> <> <EFBFBD> <EFBFBD> 祬 <20> <> ਭ<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
sub eax,4 ;<3B> <> <EFBFBD> ⨬ 4
mov ebx,6 ;<3B> <> <EFBFBD> <EFBFBD> 㧬<EFBFBD> <20> <> <EFBFBD> <EFBFBD> ⥫<EFBFBD>
div ebx ;ࠧ<> <E0A0A7> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> 6
ret
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> --------------------------
;----------------------------------------------------------
.clear_cursor:
mov edx,ed_color
2007-01-19 15:36:00 +01:00
test word ed_flags,ed_shift
je @f
mov edx,shift_color
@@:
2006-12-13 06:18:25 +01:00
mov ebx,cl_curs_x
mov ecx,cl_curs_y
jmp .draw_curs
.draw_cursor:
2007-01-19 15:36:00 +01:00
2006-12-13 06:18:25 +01:00
mov edx,ed_text_color
@@:
mov ebx,ed_pos
mov ecx,ed_offset
sub ebx,ecx
lea ebx,[ebx*2+ebx]
shl ebx,1
;imul ebx,6
add bx,ed_left
inc ebx
mov ebp,ebx
;push bx
shl ebx,16
mov bx,bp
;pop bx
mov ecx,ed_top
add ecx,2
mov ebp,ecx
shl ecx,16
mov cx,bp
add cx,ed_height-4
mov cl_curs_x,ebx
mov cl_curs_y,ecx
.draw_curs:
mov eax,38
int 0x40
ret
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> ࠬ<> <E0A0AC> ----------------------------
;----------------------------------------------------------
.draw_border:
;--- 梥<> ࠬ<> <E0A0AC> ---
2007-01-19 15:36:00 +01:00
test dword ed_flags,ed_focus
2006-12-13 06:18:25 +01:00
mov edx,ed_focus_border_color
jne @f
mov edx,ed_blur_border_color
@@:
;--- ᢥ<> <E1A2A5> <EFBFBD> ---
mov eax,38
mov ebx,ed_left
mov ecx,ebx
shl ebx,16
mov bx,cx
add bx,ed_width
mov ecx, ed_top
mov esi,ecx
shl ecx,16
mov cx,si
int 0x40
;--- ᭨<> <E1ADA8> ---
mov esi,ecx
add ecx,ed_height
mov ebp,ecx
shl ecx,16
mov cx,bp
int 0x40
;--- <> <E1ABA5> ---
mov cx,si
mov ebp,ebx
sub bx,ed_width
int 0x40
;--- <20> <> ࠢ<EFBFBD> ---
mov ebx,ebp
shl ebx,16
mov bx,bp
int 0x40
ret
;----------------------------------------------------------
;--- <20> <EFBFBD> ઠ, <20> <> 襫 <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> ࠭<EFBFBD> <E0A0AD> <EFBFBD> <20> , <20> <20> <> <EFBFBD> <EFBFBD> , ---
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 塞 ᬥ饭<E1ACA5> <E9A5AD> ------------------------------------
2007-01-26 14:03:48 +01:00
;--- eax = -1, <20> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> eax = 0, <20>
2006-12-13 06:18:25 +01:00
; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
;----------------------------------------------------------
.check_offset:
pushad
2007-01-26 12:20:00 +01:00
mov ecx,ed_pos
mov ebx,ed_offset
cmp ebx,ecx
ja .sub_8
push ebx
2006-12-13 06:18:25 +01:00
call .get_n ;<3B> <> <EFBFBD> <EFBFBD> 稬 <20> <> <EFBFBD> -<2D> <> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> ॣ<> <E0A5A3> <EFBFBD> edx:eax
pop ebx
2007-01-26 12:20:00 +01:00
mov edx,ebx
add edx,eax ;ed_offset+width editbox
cmp edx,ecx
ja @f
mov edx,ed_size
2007-01-26 14:03:48 +01:00
cmp edx,ecx
je .add_end
sub edx,ecx
2007-01-26 12:20:00 +01:00
cmp edx,8
jbe .add_8
2007-01-26 14:03:48 +01:00
add ebx,8
2007-01-26 12:20:00 +01:00
jmp .chk_d
.sub_8: cmp ecx,0
je .sub_min
cmp ebx,8
jbe .sub_min
sub ebx,8 ;ebx=ed_offset
jmp .chk_d
.sub_min:
xor ebx,ebx
jmp .chk_d
2007-01-26 14:03:48 +01:00
.add_end:sub edx,eax
mov ebx,edx
jmp .chk_d
.add_8: add ebx,edx
2007-01-24 11:00:37 +01:00
; ;----------- <20> ⫠<EFBFBD> <E2ABA0> <EFBFBD>
; pushad
; mov [data_of_code],0
2007-01-26 12:20:00 +01:00
; mov eax,ebx;ed_offset
2007-01-24 11:00:37 +01:00
; mov edi,data_of_code
; call .str
; ;<3B> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> 䮭<>
; mov eax,13
; mov ebx,178*65536+36
; mov ecx,28*65536+10
; xor edx,edx
; int 0x40
; ;<3B> 뢮<EFBFBD> <20> <> <EFBFBD> 祭<EFBFBD> <E7A5AD> <20> <> <20> <> ࠭
; mov eax,4
; mov ebx,180*65536+30
; mov ecx,0x10DDBBCC
; mov edx,data_of_code
; mov esi,4
; int 0x40
; popad
; ;----------- <20> ⫠<EFBFBD> <E2ABA0> <EFBFBD>
2007-01-26 12:20:00 +01:00
.chk_d: mov ed_offset,ebx
call .draw_bg
mov dword [esp+28],-1
popad
ret
@@:
mov dword [esp+28],0
popad
ret
;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; mov ebx,eax
; mov eax,ed_pos
; xor edx,edx
; idiv ebx
; xor edx,edx
; imul eax,ebx
; mov ed_offset,eax
; pop ebx
; cmp ax,bx
; je @f
;;;;;;;; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 訢<EFBFBD> <E8A8A2> <EFBFBD> <EFBFBD> <20> ᥩ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> <ECADA8>
; mov ebx,ed_left
; inc ebx
; shl ebx,16
; mov bx,ed_width
; dec ebx
; mov edx,ed_color
; call .draw_bg_eax
; mov dword [esp+28],0
;@@: popad
; ret
;==========================================================
;=== <20> <> ࠡ<EFBFBD> ⪠ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> =================================
;==========================================================
.key:
pusha
test word ed_flags,ed_focus ; <20> <20> <> <20> 䮪<> <E4AEAA> <EFBFBD> , <20> <> 室<EFBFBD> <E5AEA4>
je .no_figure ;@f
2007-01-24 11:00:37 +01:00
xor ecx,ecx
2007-01-19 15:36:00 +01:00
push eax
2007-01-24 11:00:37 +01:00
inc ecx
2007-01-19 15:36:00 +01:00
mov eax,66
mov ebx,3
int 0x40
test al,0x03
je @f
or word ed_flags,ed_shift
@@: pop eax
2006-12-13 06:18:25 +01:00
;----------------------------------------------------------
;--- <20> <EFBFBD> <E0AEA2> 塞, <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> --------------------------------
;----------------------------------------------------------
cmp ah,8
jz .backspace
cmp ah,0xb6
jz .delete
cmp ah,176
jz .left
cmp ah,179
jz .right
cmp ah,180
jz .home
cmp ah,181
jz .end
cmp ah,185 ;insert
jz .insert
;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> 誠 <20> <> <20> <> ࠡ<EFBFBD> <E0A0A1> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD>
;;;;;;;;;;;;;;;;;;;;;;;;;;;;
cmp ah,177
jz .no_figure
cmp ah,178
jz .no_figure
cmp ah,27 ;ESC - <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ))
jz .no_figure
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> 㣠<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ---
test word ed_flags,ed_figure_only ; ⮫쪮 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ?
jz @f
cmp ah,'0'
jb .no_figure
cmp ah,'9'
ja .no_figure
2007-01-24 11:00:37 +01:00
;<3B> <EFBFBD> ઠ <20> <> shift
test word ed_flags,ed_shift_on
je @f
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> edx=ed_size;ecx=ed_pos
push eax
mov edx,ed_size
mov ecx,ed_pos
call .del_char
;;;;
mov eax,ed_shift_pos
mov ebx,ed_size
sub ebx,eax
mov ed_size,ebx
pop eax
; <20> <EFBFBD> <E0AEA2> 塞, <20> <> 室<EFBFBD> <E5AEA4> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
@@: mov ecx,ed_size
2006-12-13 06:18:25 +01:00
mov edx, ed_max
2007-01-22 14:50:18 +01:00
cmp ecx,edx
jae .no_figure
2006-12-13 06:18:25 +01:00
mov ebx, ed_pos
cmp ebx,edx
jl @f ; <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> ࠢ<> <E0A0A2>
.no_figure:
popa
ret
2007-01-24 11:00:37 +01:00
.insert: test word ed_flags,ed_insert ;not word ed_insert
je .insert_1
and word ed_flags,ed_insert_cl
jmp .no_figure
.insert_1:
or word ed_flags,ed_insert
2006-12-13 06:18:25 +01:00
jmp .no_figure
2007-01-24 11:00:37 +01:00
.ins_v:
2006-12-13 06:18:25 +01:00
pop eax edi
dec dword ed_size ;processing is insert
push edi eax
sub esi,ecx
add esi,ebx
mov edi,esi
jmp .In_k
@@: ; ᤢ<> <E1A4A2> <EFBFBD> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ࠢ<EFBFBD>
mov ecx,ed_size
push edi eax
2007-01-24 11:00:37 +01:00
mov ebp,edi
2006-12-13 06:18:25 +01:00
mov esi,ed_text ; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ⥫<EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
;<3B> 㤥<EFBFBD> ࠡ<> <E0A0A1> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> ப<EFBFBD> <E0AEAA>
add esi,ecx ;add ed_size <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> max size
mov edi,esi
cmp ecx,ebx ;<3B> <20> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> = ⥪<> 饬<EFBFBD> ࠧ<> <E0A0A7> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ⠭<EFBFBD> <E2A0AD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> <20> .<2E> . <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> ⮨<EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
je .In_k
2007-01-24 11:00:37 +01:00
test word [ebp+36],ed_insert ;IF insert is enable <20> .<2E> . edi <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 㥬 <20> <> १ ebp
jne .ins_v
2006-12-13 06:18:25 +01:00
sub ecx,ebx ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> -<2D> <> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> ।<EFBFBD> <E0A5A4> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> .
inc edi ;<3B> <> <EFBFBD> <EFBFBD> ⨬ <20> <> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <20> <20> ࠢ<EFBFBD>
std
inc ecx
@@:
;--------
lodsb
stosb
;--------
loop @b
.In_k: cld
pop eax
mov al,ah
stosb
pop edi
; <20> <> ⠢<EFBFBD> 塞 <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 㤠, <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
; 㢥<> <E3A2A5> 稢<EFBFBD> <E7A8A2> <EFBFBD> <20> <> <EFBFBD> 祭<EFBFBD> <E7A5AD> ࠧ<> <E0A0A7> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> 樨
inc dword ed_size
inc dword ed_pos
2007-01-26 12:20:00 +01:00
call .draw_all2
jmp .shift;.draw_cursor_text
2006-12-13 06:18:25 +01:00
.delete:
mov edx,ed_size
mov ecx,ed_pos
cmp edx,ecx
2007-01-24 11:00:37 +01:00
jg .bac_del
2007-01-22 14:50:18 +01:00
test word ed_flags,ed_shift_on
jne .del_bac
2006-12-13 06:18:25 +01:00
popa
ret
2007-01-22 14:50:18 +01:00
.bac_del:
2007-01-24 11:00:37 +01:00
call .del_char
2006-12-13 06:18:25 +01:00
jmp .draw_all
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> backspace ---
.backspace:
; <20> <EFBFBD> <E0AEA2> 塞, <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ?
mov edx,ed_size
mov ecx,ed_pos
test ecx,ecx
2007-01-24 11:00:37 +01:00
jnz .del_bac
2007-01-22 14:50:18 +01:00
test word ed_flags,ed_shift_on
jne .bac_del
;jmp @b
2006-12-13 06:18:25 +01:00
popa
ret
2007-01-22 14:50:18 +01:00
.del_bac:
2007-01-24 11:00:37 +01:00
cmp edx,ecx ;if ed_pos=ed_size
2006-12-13 06:18:25 +01:00
je @f
dec ecx
call .del_char
2007-01-22 14:50:18 +01:00
@@: test word ed_flags,ed_shift_on
jne .bac_del
2006-12-13 06:18:25 +01:00
dec dword ed_pos
.draw_all:
2007-01-22 14:50:18 +01:00
push .shift;.draw_cursor_text;eax
test word ed_flags,ed_shift_on
je @f
mov eax,ed_shift_pos
mov ebx,ed_size
sub ebx,eax
mov ed_size,ebx
jmp .draw_all2
@@: dec dword ed_size
2006-12-13 06:18:25 +01:00
.draw_all2:
2007-01-23 06:35:15 +01:00
and word ed_flags,ed_shift_cl
2006-12-13 06:18:25 +01:00
call .clear_cursor
call .check_offset
2007-01-26 12:20:00 +01:00
;;;;;;;;;;;;;;;
cmp eax,0
je @f
call .draw_bg
ret
;;;;;;;;;;;;;;;
@@: call .get_n
2006-12-13 06:18:25 +01:00
push eax
mov ebx,ed_offset
add eax,ebx ;eax = w_off= ed_offset+width
2007-01-22 14:50:18 +01:00
mov ebx,ed_size
2006-12-13 06:18:25 +01:00
cmp eax,ebx
jb @f
2007-01-22 14:50:18 +01:00
mov eax,ed_pos
2006-12-13 06:18:25 +01:00
sub ebx,eax
mov ecx,ed_offset
sub eax,ecx
jmp .nxt
2007-01-22 14:50:18 +01:00
@@: mov ebx,ed_pos
2006-12-13 06:18:25 +01:00
push ebx
sub eax,ebx
2007-01-19 15:36:00 +01:00
mov ebx,eax ;It is don't optimal
2006-12-13 06:18:25 +01:00
pop eax ;ed_pos
mov ecx,ed_offset
sub eax,ecx
.nxt:
mov ebp,eax ;<3B> <EFBFBD> ઠ <20> <> <20> <> 室 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 訢<EFBFBD> <E8A8A2> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> ।<EFBFBD> <E0A5A4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
add ebp,ebx
pop edx
cmp ebp,edx
je @f
inc ebx
@@: mov edx,ebx
lea ebx,[eax*2+eax]
shl ebx,1
add ebx,ed_left
inc ebx
shl ebx,16
lea ecx,[edx*2+edx]
shl ecx,1
mov bx,cx
2007-01-22 14:50:18 +01:00
mov edx,ed_color
2006-12-13 06:18:25 +01:00
call .draw_bg_eax
2007-01-22 14:50:18 +01:00
ret
; jmp .shift
2006-12-13 06:18:25 +01:00
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> left ---
2007-01-22 14:50:18 +01:00
.left: call .sh_enable
mov ebx,ed_pos
2006-12-13 06:18:25 +01:00
test ebx,ebx
jz .nd_k
call .clear_cursor
dec dword ed_pos
jmp .nd_k
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> right ---
2007-01-22 14:50:18 +01:00
.right: call .sh_enable
mov ebx,ed_pos
2006-12-13 06:18:25 +01:00
cmp ebx,ed_size
je .nd_k
call .clear_cursor
inc dword ed_pos
jmp .nd_k
2007-01-22 14:50:18 +01:00
.home: call .sh_enable
mov ebx,ed_pos
2006-12-13 06:18:25 +01:00
test ebx,ebx
jz .nd_k
call .clear_cursor
xor eax,eax
mov ed_pos,eax
jmp .nd_k
2007-01-22 14:50:18 +01:00
.end: call .sh_enable
mov ebx,ed_pos
2006-12-13 06:18:25 +01:00
cmp ebx,dword ed_size
2007-01-24 11:00:37 +01:00
je .nd_k
2006-12-13 06:18:25 +01:00
call .clear_cursor
mov eax,ed_size
mov ed_pos,eax
.nd_k: call .check_offset
2007-01-19 15:36:00 +01:00
;test eax,eax
;jz .draw_bg_cursor_text
2006-12-13 06:18:25 +01:00
call .draw_cursor
2007-01-19 15:36:00 +01:00
.shift: ;;;;;;;SHIFT
2007-01-26 12:20:00 +01:00
call .draw_bg ;<3B> <> <20> <> ⨬<EFBFBD> <E2A8AC> 쭮
2007-01-19 15:36:00 +01:00
test word ed_flags,ed_shift
je .f_exit
;;;;;;SHIFT end
mov eax,dword ed_pos
mov ebx,dword ed_shift_pos
cmp eax,ebx
jae .sh_n
push eax ;<3B> <> <EFBFBD> <EFBFBD> 襥 <20> eax
push ebx ;<3B> <> <EFBFBD> <EFBFBD> 襥
jmp .sh_n1
;<3B> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
.sh_n: push ebx
push eax
.sh_n1:
; jmp .draw_all2
;;;;;;;;;;;;;;;;;;;;;;;;;
;call .clear_cursor
call .check_offset
call .get_n
mov edx,eax ;size of ed_box
; push eax
mov ecx,ed_offset
add eax,ecx ;eax = w_off= ed_offset+width
mov ebp,eax ;save
pop ebx ;<3B> <> <EFBFBD> <EFBFBD> 襥
pop eax ;<3B> <> <EFBFBD> <EFBFBD> 襥
cmp eax,ecx ;<3B> ࠢ<EFBFBD> <E0A0A2> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> 襣<EFBFBD> <20> offset.
jae .f_f ;<3B> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
xor eax,eax
cmp ebp,ebx ;cࠢ<63> <E0A0A2> <EFBFBD> ࠧ<> <E0A0A7> <EFBFBD> w_off <20> <20> <> <EFBFBD> <EFBFBD> 訬
jb @f
sub ebx,ecx
jmp .nxt_f
@@: mov ebx,ebp
sub ebx,ecx
jmp .nxt_f
.f_f:
sub eax,ecx
cmp ebp,ebx ;cࠢ<63> <E0A0A2> <EFBFBD> ࠧ<> <E0A0A7> <EFBFBD> w_off <20> <20> <> <EFBFBD> <EFBFBD> 訬
jle @f
sub ebx,ecx
sub ebx,eax
jmp .nxt_f
@@:
mov ebx,ebp
sub ebx,ecx
sub ebx,eax
.nxt_f:
2007-01-22 14:50:18 +01:00
mov edx,ebx
2007-01-19 15:36:00 +01:00
lea ebx,[eax*2+eax]
shl ebx,1
add ebx,ed_left
inc ebx
shl ebx,16
lea ecx,[edx*2+edx]
shl ecx,1
mov bx,cx
2007-01-22 14:50:18 +01:00
mov edx,shift_color
2007-01-19 15:36:00 +01:00
call .draw_bg_eax
and word ed_flags,1111111111111011b
jmp .draw_cursor_text
;;;;;;;;;;;;;;;;;;;;;
.f_exit: and word ed_flags,ed_shift_cl
jmp .draw_cursor_text
2007-01-22 14:50:18 +01:00
2007-01-24 11:00:37 +01:00
;<3B> <EFBFBD> ઠ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ﭨ<EFBFBD> shift <20> <> <EFBFBD> <20> <> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ࠭<> <E0A0AD> <EFBFBD> ?
2007-01-22 14:50:18 +01:00
.sh_enable:
test word ed_flags,ed_shift
je @f
test word ed_flags,ed_shift_on
2007-01-24 11:00:37 +01:00
jne .sh_ext_en
2007-01-22 14:50:18 +01:00
push dword ed_pos
pop dword ed_shift_pos
or word ed_flags,ed_shift_on
2007-01-24 11:00:37 +01:00
ret
@@: and word ed_flags,ed_shift_cl
.sh_ext_en: ret
2007-01-22 14:50:18 +01:00
2006-12-13 06:18:25 +01:00
;- 㤠<> <E3A4A0> <EFBFBD> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD>
2007-01-22 14:50:18 +01:00
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> edx=ed_size;ecx=ed_pos
2006-12-13 06:18:25 +01:00
.del_char:
mov esi,ed_text
2007-01-22 14:50:18 +01:00
test word ed_flags,ed_shift_on
je @f
mov eax,dword ed_shift_pos
mov ebx,esi
cmp eax,ecx
jae .dh_n
mov ed_pos,eax ;<3B> <> <EFBFBD> <20> <> <20> <> <20> 뫮 㡥<> <E3A1A5> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
mov ebp,ecx
sub ebp,eax
add ebx,eax ;eax <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
sub edx,ecx
2006-12-13 06:18:25 +01:00
add esi,ecx
2007-01-22 14:50:18 +01:00
mov ed_shift_pos,ebp
jmp .del_ch_sh
;<3B> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
.dh_n:
mov ebp,eax
sub ebp,ecx
add ebx,ecx
sub edx,eax
add esi,eax
mov ed_shift_pos,ebp
jmp .del_ch_sh
@@: add esi,ecx ;㪠<> <E3AAA0> ⥫<EFBFBD> + ᬥ饭<E1ACA5> <E9A5AD> <20> ॠ<> 쭮<EFBFBD> <ECADAE> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2006-12-13 06:18:25 +01:00
mov ebx,esi
inc esi
cld
sub edx,ecx
2007-01-22 14:50:18 +01:00
.del_ch_sh:
2006-12-13 06:18:25 +01:00
push edi
mov edi,ebx
@@:
lodsb
stosb
2007-01-22 14:50:18 +01:00
dec edx
2006-12-13 06:18:25 +01:00
jns @b
pop edi
ret
;==========================================================
;=== <20> <> ࠡ<EFBFBD> ⪠ <20> <> <EFBFBD> <EFBFBD> =======================================
;==========================================================
.mouse:
pusha
;----------------------------------------------------------
;--- <20> <> <EFBFBD> <EFBFBD> 砥<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ﭨ<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> -----------------------
;----------------------------------------------------------
mov eax,37
mov ebx,2
int 0x40
;----------------------------------------------------------
;--- <20> <EFBFBD> <E0AEA2> 塞 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ﭨ<EFBFBD> ----------------------------------
;----------------------------------------------------------
test eax,1
jnz .mouse_left_button
@@: popa
ret
.mouse_left_button:
;----------------------------------------------------------
;--- <20> <> <EFBFBD> <EFBFBD> 砥<EFBFBD> <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> -----------------------------
;----------------------------------------------------------
mov eax,37
xor ebx,ebx
inc ebx
int 0x40
;----------------------------------------------------------
;--- <20> <EFBFBD> <E0AEA2> 塞, <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> edit box -------------
;----------------------------------------------------------
mov ebx,ed_top
cmp ax,bx
jl ._blur;.mouse_end_no_focus
add bx,ed_height
cmp ax,bx
jg ._blur;.mouse_end_no_focus
shr eax,16
mov bx,ed_left
cmp ax,bx
jl ._blur;.mouse_end_no_focus
add bx,ed_width
cmp ax,bx
jg ._blur;.mouse_end_no_focus
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 塞 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ---
push eax
call .clear_cursor
pop eax
xor dx,dx
sub ax,ed_left
add ax,2
mov bx,6
div bx
add ax,ed_offset
cmp ax,ed_size
jna @f
mov ax,ed_size
@@:
mov ed_pos,ax
call .check_offset
call .draw_cursor
2007-01-24 11:00:37 +01:00
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䮪<> <E4AEAA> <EFBFBD> ---------------------------
;----------------------------------------------------------
bts word ed_flags,1
jc .mouse_pressed
call .draw_cursor
call .draw_border
2006-12-13 06:18:25 +01:00
.mouse_pressed:
popa
ret
;.mouse_end_no_focus:
; call .blur
;popa
;ret
2007-01-24 11:00:37 +01:00
;.blur:
;pusha
2006-12-13 06:18:25 +01:00
._blur:
2007-01-24 11:00:37 +01:00
btr word ed_flags,1 ; <20> <20> <> <20> 䮪<> <E4AEAA> <EFBFBD> , <20> <> 室<EFBFBD> <E5AEA4>
jnc @f
2006-12-13 06:18:25 +01:00
call .clear_cursor
call .draw_border
@@:
popa
ret
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> ࠧ<> 뢠<EFBFBD> <EBA2A0> <EFBFBD> 䮪<> <E4AEAA> <EFBFBD> --------------------------
;----------------------------------------------------------
;.blur:
;pusha
;._blur:
;btr ed_flags,1
;jnc @f
;call .draw_border
;call .clear_cursor
;@@:
;popa
;ret
}
ed_figure_only=1000000000000000b
ed_focus=10b
2007-01-19 15:36:00 +01:00
ed_shift_on=1000b
ed_shift=100b
2007-01-23 06:35:15 +01:00
ed_shift_cl=1111111111110011b
2006-12-13 06:18:25 +01:00
macro draw_edit_boxes start,end
{
mov edi,start
mov ecx,((end-start)/ed_struc_size)
@@:
call edit_box.draw
add edi,ed_struc_size
loop @b
}
macro mouse_edit_boxes start,end
{
mov edi,start
mov ecx,((end-start)/ed_struc_size)
@@:
call edit_box.mouse
add edi,ed_struc_size
loop @b
}
macro key_edit_boxes start,end
{
mov edi,start
mov ecx,((end-start)/ed_struc_size)
@@:
call edit_box.key
add edi,ed_struc_size
loop @b
}
2007-01-24 11:00:37 +01:00
ed_struc_size=62
2006-12-13 06:18:25 +01:00
struc edit_box width,left,top,color,focus_border_color,\
blur_border_color,text_color,max,text,flags,size
{
.width dd width
.left dd left
.top dd top
.color dd color
.focus_border_color dd focus_border_color
.blur_border_color dd blur_border_color
.text_color dd text_color
.max dd max
2007-01-19 15:36:00 +01:00
.text dd text
.flags dw flags+0
2006-12-13 06:18:25 +01:00
.size dd size+0
.pos dd 0
.offset dd 0
.cl_curs_x dd 0
.cl_curs_y dd 0
2007-01-19 15:36:00 +01:00
.shift dd 0
2006-12-13 06:18:25 +01:00
}
macro edit_boxes_set_sys_color start,end,color_table
{
mov edi,start
mov ecx,((end-start)/ed_struc_size)
mov esi,color_table
@@:
mov eax,[esi+36]
mov ebx,[esi+20]
mov ed_focus_border_color,eax
shr bh,1
shr bl,1
shr ah,1
shr al,1
add ah,bh
add al,bl
ror eax,16
ror ebx,16
shr bl,1
shr al,1
add al,bl
ror eax,16
mov ed_blur_border_color,eax
add edi,ed_struc_size
loop @b
}