2007-04-20 08:19:47 +04:00
; SEE YOU File FAQ.txt and HISTORY. Good Like!
2007-04-13 11:03:50 +04:00
;;;;;;;;;;;;;;;;;;
include 'editbox.mac' ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> :) ᯥ樠<E1AFA5> 쭮 <20> <> <EFBFBD> editbox
;;;;;;;;;;;;;;;;;;
2007-04-20 08:19:47 +04:00
macro use_edit_box structure_of_potock,scr_h,scr_w
2006-12-13 08:18:25 +03:00
{
edit_box:
2007-04-13 11:03:50 +04:00
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>
2007-04-20 08:19:47 +04:00
shift_color equ [edi+16] ;=0x6a9480
2007-04-13 11:03:50 +04:00
ed_focus_border_color equ [edi+20] ;梥<> ࠬ<> <E0A0AC> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_blur_border_color equ [edi+24] ;梥<> <20> <> <20> <> ⨢<EFBFBD> <E2A8A2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_text_color equ [edi+28] ;梥<> ⥪<> <E2A5AA> <EFBFBD>
ed_max equ [edi+32] ;<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+36] ;㪠<> <E3AAA0> ⥫<EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
ed_flags equ [edi+40] ;䫠<> <E4ABA0>
ed_size equ [edi+42] ;<3B> <> <EFBFBD> -<2D> <> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD>
ed_pos equ [edi+46] ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_offset equ [edi+50] ;ᬥ饭<E1ACA5> <E9A5AD>
cl_curs_x equ [edi+54] ;<3B> ।<EFBFBD> <E0A5A4> <EFBFBD> 饥 <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20>
cl_curs_y equ [edi+58] ;<3B> ।<EFBFBD> <E0A5A4> <EFBFBD> 饥 <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20>
ed_shift_pos equ [edi+62] ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_shift_pos_old equ [edi+66] ;<3B> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2006-12-13 08:18:25 +03:00
;==========================================================
;=== <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> =================================
;==========================================================
.draw:
pusha
;--- <20> <> <EFBFBD> 㥬 ࠬ<> <E0A0AC> ---
2007-04-13 11:03:50 +04:00
call .draw_border ; <20> 㭪<EFBFBD> <E3ADAA> <EFBFBD> <20> ⠡<EFBFBD> <E2A0A1> 쭠
2006-12-13 08:18:25 +03:00
.draw_bg_cursor_text:
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 塞 ᬥ饭<E1ACA5> <E9A5AD> , <20> <20> <> <EFBFBD> <EFBFBD> ---
2007-04-13 11:03:50 +04:00
call .check_offset ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <E1ABA5> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> 樨 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> ⠡<EFBFBD> <E2A0A1> 쭠
2006-12-13 08:18:25 +03:00
;--- <20> <> <EFBFBD> 㥬 <20> <> <EFBFBD> <EFBFBD> ७<EFBFBD> <E0A5AD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ---
2007-04-13 11:03:50 +04:00
call .draw_bg ;<3B> <> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> ࠡ<> 祩 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-03-09 09:25:26 +03:00
;---- <20> <> <EFBFBD> 㥬 <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> , <20> <> shift <20> <20> <> <EFBFBD> <EFBFBD>
2007-04-13 11:03:50 +04:00
call .draw_shift
2006-12-13 08:18:25 +03:00
.draw_cursor_text:
;--- <20> <> <EFBFBD> 㥬 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ---
2007-04-13 11:03:50 +04:00
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> ----
test word ed_flags,ed_focus
je @f
call .draw_cursor
2006-12-13 08:18:25 +03:00
@@:
2007-04-13 11:03:50 +04:00
call .draw_text
edit_ex
;debug_func
2007-03-09 09:25:26 +03:00
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> -----------------
;----------------------------------------------------------
.draw_shift:
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_shift_bac ;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䫠<> <E4ABA0> , <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
jz @f
mov ebp,shift_color
mov ebx,dword ed_shift_pos
call .sh_cl_
@@: ret
2006-12-13 08:18:25 +03: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> ---
2007-04-13 11:03:50 +04:00
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>
2007-03-09 09:25:26 +03:00
;--- <20> <> <EFBFBD> 㥬 ⥪<> <E2A5AA> ---
2007-04-13 11:03:50 +04:00
@@: mov eax,4
mov ebx,ed_left
mov edx,ed_offset
add ebx,2
shl ebx,16
mov bx,ed_top
add ebx,4
mov ecx,ed_text_color
add edx,ed_text
int 0x40
2006-12-13 08:18:25 +03:00
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 13:00:37 +03:00
;edx - color
2006-12-13 08:18:25 +03:00
;----------------------------------------------------------
2007-02-13 13:09:13 +03:00
;<3B> 室 ⮫쪮 梥<> edx
2006-12-13 08:18:25 +03:00
.draw_bg:
2007-04-13 11:03:50 +04:00
mov ebx,ed_left
add ebx,1
shl ebx,16
mov bx,ed_width
sub ebx,1
mov edx,ed_color
2007-03-06 16:53:45 +03:00
.draw_bg_eax:
2007-04-13 11:03:50 +04:00
mov ecx,ed_top
mov eax,13
add ecx,1
shl ecx,16
mov cx,ed_height
dec ecx
int 0x40
2006-12-13 08:18:25 +03: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:
2007-04-13 11:03:50 +04:00
mov eax,ed_width ;<3B> <> <EFBFBD> <EFBFBD> 祬 <20> <> ਭ<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
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> ⮪
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
2006-12-13 08:18:25 +03:00
ret
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> --------------------------
;----------------------------------------------------------
2007-03-06 16:53:45 +03:00
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> ebp- 梥<>
2006-12-13 08:18:25 +03:00
.clear_cursor:
2007-04-13 11:03:50 +04:00
mov edx,ebp
mov ebx,cl_curs_x
mov ecx,cl_curs_y
jmp .draw_curs
2006-12-13 08:18:25 +03:00
.draw_cursor:
2007-04-20 08:19:47 +04:00
mov edx,ed_text_color
2007-04-13 11:03:50 +04:00
mov ebx,ed_pos
mov ecx,ed_offset
sub ebx,ecx
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
lea ebx,[ebx*2+ebx]
shl ebx,1
;imul ebx,6
add bx,ed_left
mov ecx,ed_top
inc ebx
add ecx,2
mov ebp,ebx
shl ebx,16
mov bx,bp
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
2006-12-13 08:18:25 +03:00
ret
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> ࠬ<> <E0A0AC> ----------------------------
;----------------------------------------------------------
.draw_border:
;--- 梥<> ࠬ<> <E0A0AC> ---
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_focus
mov edx,ed_focus_border_color
jne @f
mov edx,ed_blur_border_color
2006-12-13 08:18:25 +03:00
@@:
;--- ᢥ<> <E1A2A5> <EFBFBD> ---
2007-04-13 11:03:50 +04:00
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
2006-12-13 08:18:25 +03:00
;--- ᭨<> <E1ADA8> ---
2007-04-13 11:03:50 +04:00
mov esi,ecx
add ecx,ed_height
mov ebp,ecx
shl ecx,16
mov cx,bp
int 0x40
2006-12-13 08:18:25 +03:00
;--- <> <E1ABA5> ---
2007-04-13 11:03:50 +04:00
mov cx,si
mov ebp,ebx
sub bx,ed_width
int 0x40
2006-12-13 08:18:25 +03:00
;--- <20> <> ࠢ<EFBFBD> ---
2007-04-13 11:03:50 +04:00
mov ebx,ebp
shl ebx,16
mov bx,bp
int 0x40
2006-12-13 08:18:25 +03:00
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 16:03:48 +03:00
;--- eax = -1, <20> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> eax = 0, <20>
2006-12-13 08:18:25 +03:00
; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
;----------------------------------------------------------
.check_offset:
2007-02-15 16:54:30 +03:00
pusha
2007-04-13 11:03:50 +04:00
mov ecx,ed_pos
mov ebx,ed_offset
cmp ebx,ecx
ja .sub_8
2007-01-26 14:20:00 +03:00
2007-04-13 11:03:50 +04:00
push ebx
call .get_n ;<3B> <> <EFBFBD> <EFBFBD> 稬 <20> <> <EFBFBD> -<2D> <> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> ॣ<> <E0A5A3> <EFBFBD> edx:eax
pop ebx
mov edx,ebx
add edx,eax ;ed_offset+width editbox
inc edx ;<3B> <> <EFBFBD> <EFBFBD> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 쭮<EFBFBD> <ECADAE> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> ࠩ<EFBFBD> <E0A0A9> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> 樨
cmp edx,ecx
ja @f
2007-01-26 14:20:00 +03:00
2007-04-13 11:03:50 +04:00
mov edx,ed_size
cmp edx,ecx
je .add_end
2007-01-26 16:03:48 +03:00
2007-04-13 11:03:50 +04:00
sub edx,ecx
cmp edx,8
jbe .add_8
add ebx,8
jmp .chk_d
2007-01-26 14:20:00 +03:00
2007-04-13 11:03:50 +04:00
.sub_8: cmp ecx,0
je .sub_min
cmp ebx,8
jbe .sub_min
sub ebx,8 ;ebx=ed_offset
jmp .chk_d
2007-01-26 14:20:00 +03:00
.sub_min:
2007-04-13 11:03:50 +04:00
xor ebx,ebx
jmp .chk_d
2007-01-26 14:20:00 +03:00
2007-04-13 11:03:50 +04:00
.add_end:sub edx,eax
mov ebx,edx
jmp .chk_d
.add_8: add ebx,edx
.chk_d: mov ed_offset,ebx
call .draw_bg
and word ed_flags,ed_offset_cl
edit_ex
2007-01-26 14:20:00 +03:00
@@:
2007-04-13 11:03:50 +04:00
or word ed_flags,ed_offset_fl
edit_ex
2007-01-26 14:20:00 +03:00
;==========================================================
;=== <20> <> ࠡ<EFBFBD> ⪠ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> =================================
;==========================================================
.key:
pusha
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_focus ; <20> <20> <> <20> 䮪<> <E4AEAA> <EFBFBD> , <20> <> 室<EFBFBD> <E5AEA4>
je @b
2007-02-13 13:09:13 +03:00
;<3B> <EFBFBD> ઠ <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> shift
2007-04-13 11:03:50 +04:00
call .check_shift
2006-12-13 08:18:25 +03:00
;----------------------------------------------------------
;--- <20> <EFBFBD> <E0AEA2> 塞, <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> --------------------------------
;----------------------------------------------------------
2007-04-13 11:03:50 +04:00
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
2006-12-13 08:18:25 +03:00
;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> 誠 <20> <> <20> <> ࠡ<EFBFBD> <E0A0A1> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD>
2007-04-13 11:03:50 +04:00
;;;;;;;;;;;;;;;;;;;;;;;;;;;;
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
2006-12-13 08:18:25 +03:00
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> 㣠<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ---
2007-04-13 11:03:50 +04:00
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 13:00:37 +03:00
;<3B> <EFBFBD> ઠ <20> <> shift
2007-04-13 11:03:50 +04:00
@@: 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
pusha
2007-02-13 13:09:13 +03:00
;clear
2007-04-13 11:03:50 +04:00
mov ebp,edx ;ed_size
call .clear_bg
mov ebp,ed_color
mov ebx,dword ed_shift_pos
call .sh_cl_
2007-02-15 16:54:30 +03:00
2007-03-06 16:53:45 +03:00
.sh_nxt:popa
2007-04-13 11:03:50 +04:00
call .del_char
2007-01-24 13:00:37 +03:00
;;;;
2007-04-13 11:03:50 +04:00
mov eax,dword ed_shift_pos
mov ebx,ed_size
sub ebx,eax
mov ed_size,ebx
pop eax
2007-01-24 13:00:37 +03:00
; <20> <EFBFBD> <E0AEA2> 塞, <20> <> 室<EFBFBD> <E5AEA4> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-13 11:03:50 +04:00
@@: mov ecx,ed_size
mov edx, ed_max
test word ed_flags,ed_insert
jne @f
cmp ecx,edx
jae .no_figure
@@: mov ebx, ed_pos
cmp ebx,edx
jl @f ; <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> ࠢ<> <E0A0A2>
2006-12-13 08:18:25 +03:00
.no_figure:
2007-04-13 11:03:50 +04:00
edit_ex
.insert: test word ed_flags,ed_insert ;not word ed_insert
2007-01-24 13:00:37 +03:00
je .insert_1
2007-04-13 11:03:50 +04:00
and word ed_flags,ed_insert_cl
jmp .no_figure
2007-01-24 13:00:37 +03:00
.insert_1:
2007-04-13 11:03:50 +04:00
or word ed_flags,ed_insert
jmp .no_figure
2007-01-24 13:00:37 +03:00
.ins_v:
2007-04-13 11:03:50 +04:00
dec dword [ebp+42];ed_size ;processing is insert
sub esi,ecx
add esi,ebx
mov edi,esi
2007-02-13 13:09:13 +03:00
;clear
pusha
2007-04-13 11:03:50 +04:00
mov edi,ebp
mov ebp,ed_pos
call .clear_bg
2007-02-13 13:09:13 +03:00
popa
2007-04-13 11:03:50 +04:00
jmp .In_k
2006-12-13 08:18:25 +03:00
@@: ; ᤢ<> <E1A4A2> <EFBFBD> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ࠢ<EFBFBD>
2007-04-13 11:03:50 +04:00
mov ecx,ed_size
push edi eax
mov ebp,edi
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
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
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 13:00:37 +03:00
2007-04-13 11:03:50 +04:00
test word [ebp+40],ed_insert ;IF insert is enable <20> .<2E> . edi <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 㥬 <20> <> १ ebp
jne .ins_v
2007-02-13 13:09:13 +03:00
;clear
pusha
2007-04-13 11:03:50 +04:00
mov edi,ebp
mov ebp,ed_size
call .clear_bg
2007-02-13 13:09:13 +03:00
popa
2007-04-13 11:03:50 +04: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
2006-12-13 08:18:25 +03:00
; <20> <> ⠢<EFBFBD> 塞 <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 㤠, <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-13 11:03:50 +04:00
; 㢥<> <E3A2A5> 稢<EFBFBD> <E7A8A2> <EFBFBD> <20> <> <EFBFBD> 祭<EFBFBD> <E7A5AD> ࠧ<> <E0A0A7> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> 樨
inc dword ed_size
inc dword ed_pos
call .draw_all2
jmp .shift;.draw_cursor_text
.delete:
mov edx,ed_size
mov ecx,ed_pos
cmp edx,ecx
jg .bac_del
test word ed_flags,ed_shift_on
jne .del_bac
edit_ex
.bac_del:
call .del_char
jmp .draw_all
2006-12-13 08:18:25 +03:00
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> backspace ---
.backspace:
2007-04-13 11:03:50 +04:00
; <20> <EFBFBD> <E0AEA2> 塞, <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ?
mov ecx,ed_pos
test ecx,ecx
jnz .del_bac
test word ed_flags,ed_shift_on
jne .bac_del
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
edit_ex
.del_bac:
mov edx,ed_size
cmp edx,ecx ;if ed_pos=ed_size
je @f
dec ecx
call .del_char
@@: test word ed_flags,ed_shift_on
jne .bac_del
dec dword ed_pos
2006-12-13 08:18:25 +03:00
.draw_all:
2007-04-13 11:03:50 +04:00
push .shift;.draw_cursor_text;eax
2007-01-22 16:50:18 +03:00
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_shift_on
je @f
mov eax,dword ed_shift_pos
mov ebx,ed_size
sub ebx,eax
mov ed_size,ebx
2007-02-13 13:09:13 +03:00
2007-04-13 11:03:50 +04:00
mov ebp,ed_color
call .clear_cursor
call .check_offset
call .draw_bg
ret
@@: dec dword ed_size
2007-01-22 16:50:18 +03:00
2006-12-13 08:18:25 +03:00
.draw_all2:
2007-04-13 11:03:50 +04:00
and word ed_flags,ed_shift_cl
mov ebp,ed_color
call .clear_cursor
call .check_offset
mov ebp,ed_size
call .clear_bg
ret
2006-12-13 08:18:25 +03:00
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> left ---
2007-04-13 11:03:50 +04:00
.left: mov ebx,ed_pos
test ebx,ebx
jz .sh_st_of
or word ed_flags,ed_left_fl
call .sh_first_sh
dec dword ed_pos
call .sh_enable
jmp .draw_cursor_text
2006-12-13 08:18:25 +03:00
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> right ---
2007-04-13 11:03:50 +04:00
.right: mov ebx,ed_pos
cmp ebx,ed_size
je .sh_st_of
and word ed_flags,ed_right_fl
call .sh_first_sh
inc dword ed_pos
call .sh_enable
jmp .draw_cursor_text
2007-03-06 16:53:45 +03:00
.home:
2007-04-13 11:03:50 +04:00
mov ebx,ed_pos
test ebx,ebx
jz .sh_st_of
call .sh_first_sh
xor eax,eax
mov ed_pos,eax
call .sh_home_end
jmp .draw_cursor_text
2007-03-06 16:53:45 +03:00
.end:
2007-04-13 11:03:50 +04:00
mov ebx,ed_pos
cmp ebx,dword ed_size
je .sh_st_of
call .sh_first_sh
mov eax,ed_size
mov ed_pos,eax
call .sh_home_end
jmp .draw_cursor_text
2007-03-06 16:53:45 +03:00
;<3B> <> ࠡ<EFBFBD> ⪠ Shift <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ⭮<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-01-19 17:36:00 +03:00
.shift: ;;;;;;;SHIFT
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_shift
je .f_exit
2007-02-15 10:44:55 +03:00
2007-04-13 11:03:50 +04:00
@@: mov ebp,shift_color
or word ed_flags,ed_shift_bac ;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䫠<> <E4ABA0> , <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
mov ebx,dword ed_shift_pos
call .sh_cl_
jmp .draw_cursor_text
2007-02-15 10:44:55 +03:00
;;;;;;;;;;;;;;;;;;;;;
2007-04-13 11:03:50 +04:00
.f_exit:call .check_offset
and word ed_flags,ed_shift_cl
call .enable_null
jmp .draw_cursor_text
2007-02-15 10:44:55 +03:00
.sh_cl_:
2007-01-19 17:36:00 +03:00
;;;;;;SHIFT end
2007-03-06 16:53:45 +03:00
;<3B> <> ࠡ<EFBFBD> ⪠ <20> <> <EFBFBD> <EFBFBD> ⪨, <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> - <20> ࠢ<EFBFBD> <E0A0A2> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD>
2007-02-15 10:44:55 +03:00
;<3B> <> <EFBFBD> <20> <> ࠡ<EFBFBD> ⪨ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD>
2007-03-07 11:35:01 +03:00
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> ࠬ<EFBFBD> <E0A0AC> <EFBFBD> <EFBFBD> ebp=color ebx=ed_shift_pos
2007-04-13 11:03:50 +04:00
mov eax,dword ed_pos
cmp eax,ebx
2007-03-30 09:32:17 +04:00
2007-04-13 11:03:50 +04:00
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
2007-01-19 17:36:00 +03:00
.sh_n1:
2007-04-13 11:03:50 +04:00
call .check_offset
call .get_n
mov edx,eax ;size of ed_box
mov ecx,ed_offset
add eax,ecx ;eax = w_off= ed_offset+width
mov edx,eax ;save
pop ebx ;<3B> <> <EFBFBD> <EFBFBD> 襥
pop eax ;<3B> <> <EFBFBD> <EFBFBD> 襥
2007-01-19 17:36:00 +03:00
2007-04-13 11:03:50 +04:00
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 edx,ebx ;cࠢ<63> <E0A0A2> <EFBFBD> ࠧ<> <E0A0A7> <EFBFBD> w_off <20> <20> <> <EFBFBD> <EFBFBD> 訬
jb @f
sub ebx,ecx
jmp .nxt_f
@@: mov ebx,edx
sub ebx,ecx
jmp .nxt_f
.f_f:
sub eax,ecx
cmp edx,ebx ;cࠢ<63> <E0A0A2> <EFBFBD> ࠧ<> <E0A0A7> <EFBFBD> w_off <20> <20> <> <EFBFBD> <EFBFBD> 訬
jle @f
sub ebx,ecx
sub ebx,eax
jmp .nxt_f
2007-01-19 17:36:00 +03:00
@@:
2007-04-13 11:03:50 +04:00
mov ebx,edx
sub ebx,ecx
sub ebx,eax
2007-01-19 17:36:00 +03:00
.nxt_f:
2007-04-13 11:03:50 +04:00
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
inc ebx
mov edx,ebp;shift_color
2007-02-15 10:44:55 +03:00
2007-04-13 11:03:50 +04:00
call .draw_bg_eax
@@: call .enable_null
ret
2007-03-06 16:53:45 +03:00
;;;;;;;;;;;;;;;;;;;;;
;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> - <20> <> <EFBFBD> ⨥ <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD>
;;;;;;;;;;;;;;;;;;;;;
.drw_sim:
2007-04-13 11:03:50 +04:00
mov eax,dword ed_pos
call .draw_rectangle ;<3B> <> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 梥⮬
2007-03-06 16:53:45 +03:00
jmp @b
;;;;;;;;;;;;;;;;;;;;;
;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> ࠢ<EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> ⨨ shift
;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> :
;;;;;;;;;;
.draw_wigwag:
;<3B> 㭪<EFBFBD> <E3ADAA> <EFBFBD> <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> <20> <> ६<EFBFBD> <E0A5AC> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-13 11:03:50 +04:00
mov ebp,shift_color
call .clear_cursor
2007-01-22 16:50:18 +03:00
2007-04-13 11:03:50 +04:00
or word ed_flags,ed_shift_bac ;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䫠<> <E4ABA0> , <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
mov ebp,shift_color
mov eax,dword ed_pos
test word ed_flags,ed_left_fl
jz .low
jmp @f
2007-03-06 16:53:45 +03:00
;;;;;;;;;;
;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 㤠<> <E3A4A0> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <20> <> ࠢ<EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> ⨨ shift
;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> :
;;;;;;;;;;
.draw_wigwag_cl:
;<3B> 㭪<EFBFBD> <E3ADAA> <EFBFBD> <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> <20> <> ६<EFBFBD> <E0A5AC> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-13 11:03:50 +04:00
mov ebp,ed_color
call .clear_cursor
2007-03-06 16:53:45 +03:00
2007-04-13 11:03:50 +04:00
mov ebp,ed_color
mov eax,dword ed_pos
test word ed_flags,ed_left_fl
jz .low
@@: call .draw_rectangle ;<3B> <> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 訢<EFBFBD> <E8A8A2> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ret
.low: dec eax
jmp @b
2007-03-06 16:53:45 +03:00
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> ࠬ<EFBFBD> <E0A0AC> <EFBFBD> ebx - ed_pos
.sh_first_sh:
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_shift
je @f
mov dword ed_shift_pos_old,ebx
test word ed_flags,ed_shift_on
jne @f
mov dword ed_shift_pos,ebx
or word ed_flags,ed_shift_on
@@: ret
2007-03-06 16:53:45 +03:00
;<3B> <> ࠡ<EFBFBD> ⪠ <20> ࠩ<EFBFBD> <E0A0A9> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> editbox <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ⮬ shift
;<3B> ந<EFBFBD> <E0AEA8> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> ⨥ <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> , <20> <20> <> <EFBFBD> shift
;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> 室<EFBFBD> <E5AEA4>
.sh_st_of:
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_shift
jne @f
test word ed_flags,ed_shift_bac
2007-03-06 16:53:45 +03:00
je @f
2007-04-13 11:03:50 +04:00
mov ebp,ed_color
mov ebx,dword ed_shift_pos
call .sh_cl_ ;<3B> <> <EFBFBD> <EFBFBD> ⪠ <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> ࠣ<EFBFBD> <E0A0A3> <EFBFBD> <EFBFBD> <EFBFBD>
and word ed_flags,ed_shift_cl ; <20> <> <EFBFBD> <EFBFBD> ⪠ <20> <> ⮣<> <20> <> <EFBFBD> <20> <> ࠫ<EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD>
jmp .draw_cursor_text
2007-03-06 16:53:45 +03:00
@@:
2007-04-13 11:03:50 +04:00
and word ed_flags,ed_shift_off
edit_ex
2007-03-06 16:53:45 +03:00
;<3B> <EFBFBD> ઠ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ﭨ<EFBFBD> shift <20> <> <EFBFBD> <20> <> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ࠭<> <E0A0AD> <EFBFBD> ?
.sh_enable:
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_shift
jne .sh_ext_en ;<3B> <> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 襭<EFBFBD> <E8A5AD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD>
2007-01-24 13:00:37 +03:00
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_shift_bac
2007-02-15 10:44:55 +03:00
je @f
2007-04-13 11:03:50 +04:00
call .check_offset
2007-03-06 16:53:45 +03:00
2007-04-13 11:03:50 +04:00
mov ebp,ed_color
mov ebx,dword ed_shift_pos
call .sh_cl_ ;<3B> <> <EFBFBD> <EFBFBD> ⪠ <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> ࠣ<EFBFBD> <E0A0A3> <EFBFBD> <EFBFBD> <EFBFBD>
call .draw_wigwag_cl
and word ed_flags,ed_shift_cl ; 1<> <31> <EFBFBD> <20> <> <20> 㦭<EFBFBD>
ret
2007-03-06 16:53:45 +03:00
2007-04-13 11:03:50 +04:00
@@: mov ebp,ed_color
call .clear_cursor
call .check_offset
ret
.sh_ext_en:
call .check_offset
test word ed_flags,ed_offset_fl
je @f
2007-03-06 16:53:45 +03:00
;<3B> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 襭<EFBFBD> <E8A5AD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> <ECADA8> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> ⪠ <20> <>
2007-04-13 11:03:50 +04:00
mov eax,dword ed_shift_pos
mov ebx,dword ed_pos
mov ecx,dword ed_shift_pos_old
2007-03-06 16:53:45 +03:00
;<3B> <EFBFBD> ઠ <20> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 襭<EFBFBD> <E8A5AD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ⥩
2007-04-13 11:03:50 +04:00
cmp eax,ecx
je .1_shem
jb .smaller
cmp ecx,ebx
ja .1_shem
call .draw_wigwag_cl ;clear
jmp .sh_e_end
2007-03-06 16:53:45 +03:00
.smaller:
2007-04-13 11:03:50 +04:00
cmp ecx,ebx
jb .1_shem
call .draw_wigwag_cl ;clear
jmp .sh_e_end
2007-03-06 16:53:45 +03:00
;alike =
2007-04-13 11:03:50 +04:00
.1_shem: call .draw_wigwag
.sh_e_end: and word ed_flags,ed_shift_off
ret
@@: mov ebp,shift_color
mov ebx,dword ed_shift_pos
call .sh_cl_
jmp .sh_e_end
2007-03-06 16:53:45 +03:00
;<3B> 㭪<EFBFBD> <E3ADAA> <EFBFBD> <20> <> <EFBFBD> <20> <> ࠡ<EFBFBD> ⪨ shift <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ⨨ home and end
.sh_home_end:
2007-04-13 11:03:50 +04:00
mov ebp,ed_color
call .clear_cursor
test word ed_flags,ed_shift_bac
2007-03-06 16:53:45 +03:00
je @f
2007-04-13 11:03:50 +04:00
mov ebp,ed_color
mov ebx,dword ed_shift_pos_old
call .sh_cl_
2007-03-06 16:53:45 +03:00
2007-04-13 11:03:50 +04:00
@@: test word ed_flags,ed_shift
je .sh_exit_ ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD>
mov ebp,shift_color
mov ebx,dword ed_shift_pos
call .sh_cl_
or word ed_flags,ed_shift_bac ;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䫠<> <E4ABA0> , <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
jmp .sh_e_end
.sh_exit_: call .check_offset
ret
2007-02-13 13:09:13 +03:00
;<3B> 㭪<EFBFBD> <E3ADAA> <EFBFBD> <20> <> <EFBFBD> ᥭ<EFBFBD> <E1A5AD> 0 <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ed_size+1
.enable_null:
pusha
2007-04-13 11:03:50 +04:00
mov eax,ed_size
mov ebx,ed_text
2007-04-20 08:19:47 +04:00
test eax,eax
2007-04-13 11:03:50 +04:00
add eax,ebx
2007-04-20 08:19:47 +04:00
jne @f
2007-04-13 11:03:50 +04:00
inc eax
@@: xor ebx,ebx
mov [eax],bl
edit_ex
2007-03-07 11:35:01 +03:00
;- 㤠<> <E3A4A0> <EFBFBD> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD>
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> edx=ed_size;ecx=ed_pos
2006-12-13 08:18:25 +03:00
.del_char:
2007-04-13 11:03:50 +04:00
mov esi,ed_text
test word ed_flags,ed_shift_on
je @f
mov eax,dword ed_shift_pos
mov ebx,esi
cmp eax,ecx
jae .dh_n
2007-01-22 16:50:18 +03:00
2007-04-13 11:03:50 +04:00
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
add esi,ecx
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
mov dword 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 dword ed_shift_pos,ebp
jmp .del_ch_sh
2007-01-22 16:50:18 +03:00
2007-04-13 11:03:50 +04:00
@@: add esi,ecx ;㪠<> <E3AAA0> ⥫<EFBFBD> + ᬥ饭<E1ACA5> <E9A5AD> <20> ॠ<> 쭮<EFBFBD> <ECADAE> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
mov ebx,esi
inc esi
cld
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
sub edx,ecx
2007-01-22 16:50:18 +03:00
.del_ch_sh:
2007-04-13 11:03:50 +04:00
push edi
mov edi,ebx
2006-12-13 08:18:25 +03:00
@@:
2007-04-13 11:03:50 +04:00
lodsb
stosb
dec edx
jns @b
pop edi
ret
2007-02-13 13:09:13 +03:00
;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <E1ABA8> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 訢<EFBFBD> <E8A8A2> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
;ᮣ<> <E1AEA3> 襭<EFBFBD> <E8A5AD> <20> ebp - <20> <> ।<EFBFBD> <E0A5A4> <EFBFBD> <EFBFBD> <EFBFBD> ed_size
.clear_bg:
2007-04-13 11:03:50 +04:00
call .get_n ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ࠧ<> <E0A0A7> <EFBFBD> <20> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ਭ<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
push eax
mov ebx,ed_offset
add eax,ebx ;eax = w_off= ed_offset+width
mov ebx,ebp ;ed_size
cmp eax,ebx
jb @f
mov eax,ed_pos
sub ebx,eax
mov ecx,ed_offset
sub eax,ecx
jmp .nxt
@@: mov ebx,ed_pos
push ebx
sub eax,ebx
mov ebx,eax ;It is don't optimal
pop eax ;ed_pos
mov ecx,ed_offset
sub eax,ecx
2007-02-13 13:09:13 +03:00
.nxt:
2007-04-13 11:03:50 +04:00
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
2007-02-13 13:09:13 +03:00
2007-04-13 11:03:50 +04:00
@@: 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
mov edx,ed_color
call .draw_bg_eax
ret
2007-03-06 16:53:45 +03:00
;;;;;;;;;;;;;;;;;;;
;;; <20> <> ࠡ<EFBFBD> ⪠ <20> ਬ<EFBFBD> ⨢<EFBFBD> <E2A8A2>
;;;;;;;;;;;;;;;;;;;;
;<3B> <> <EFBFBD> <EFBFBD> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> , 梥<> <20> <> ।<EFBFBD> <E0A5A4> <EFBFBD> <EFBFBD> <EFBFBD> <20> ebp
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> ࠬ<EFBFBD> <E0A0AC> <EFBFBD> <EFBFBD> :
;eax=dword ed_pos
;ebp=-梥<> ed_color or shift_color
.draw_rectangle:
2007-04-13 11:03:50 +04:00
mov ecx,dword ed_offset
sub eax,ecx
lea ebx,[eax*2+eax]
shl ebx,1
inc ebx
add ebx,ed_left
shl ebx,16
mov bx,6
mov edx,ebp
call .draw_bg_eax
ret
2007-03-09 14:07:59 +03:00
;;;;;;;;;;;;;;;;;;
;;<3B> <EFBFBD> ઠ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> shift
;;;;;;;;;;;;;;;;;;
.check_shift:
pusha ;<3B> <> <EFBFBD> ࠭<EFBFBD> <E0A0AD> <20> <> <EFBFBD> ॣ<> <E0A5A3> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-13 11:03:50 +04:00
mcall 66,3,1
test al,0x03
je @f
2007-03-09 14:07:59 +03:00
or word ed_flags,ed_shift ;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䫠<>
2007-04-13 11:03:50 +04:00
@@:edit_ex
2006-12-13 08:18:25 +03:00
;==========================================================
;=== <20> <> ࠡ<EFBFBD> ⪠ <20> <> <EFBFBD> <EFBFBD> =======================================
;==========================================================
.mouse:
pusha
2007-04-13 11:03:50 +04:00
;debug
2006-12-13 08:18:25 +03:00
;----------------------------------------------------------
;--- <20> <> <EFBFBD> <EFBFBD> 砥<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ﭨ<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> -----------------------
2007-04-13 11:03:50 +04:00
;----------------------------------------------------------
mcall 37,2
2006-12-13 08:18:25 +03:00
;----------------------------------------------------------
;--- <20> <EFBFBD> <E0AEA2> 塞 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ﭨ<EFBFBD> ----------------------------------
;----------------------------------------------------------
2007-04-13 11:03:50 +04:00
test eax,1
jnz .mouse_left_button
and word ed_flags,ed_mouse_on_off
xor ebx,ebx
mov dword [mouse_flag],ebx
edit_ex
.mouse_left_button:
2007-04-04 10:40:20 +04:00
;----------------------------------------------------------
2007-04-13 11:03:50 +04:00
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <E0AEA2> <20> <> 䮪<> <E4AEAA> <EFBFBD> <EFBFBD> <E0AEA2> <20> <20> <> 㣨<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-04 10:40:20 +04:00
;----------------------------------------------------------
2007-04-13 11:03:50 +04:00
mov eax,dword [mouse_flag]
test eax,eax
jz @f
cmp eax,edi
je @f
jmp ._blur
2006-12-13 08:18:25 +03:00
;----------------------------------------------------------
2007-04-04 10:40:20 +04:00
;--- <20> <> <EFBFBD> <EFBFBD> 砥<EFBFBD> <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <20> ⭮<EFBFBD> <E2ADAE> ⥫쭮 0 <20> .<2E> <20> ᥩ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ࠭<EFBFBD>
2006-12-13 08:18:25 +03:00
;----------------------------------------------------------
2007-04-20 08:19:47 +04:00
@@: mcall 37,0
2006-12-13 08:18:25 +03:00
;----------------------------------------------------------
2007-04-04 10:40:20 +04:00
;--- <20> <20> <> 㤥ন<E3A4A5> <E0A6A8> <EFBFBD> <EFBFBD> <20> <> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> 誨, <20> <> ६<EFBFBD> <E0A5AC> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> , <20> <> <20> <> <EFBFBD> ࠧ<> <E0A0A7> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ?
;----------------------------------------------------------
2007-04-13 11:03:50 +04:00
mov ecx,structure_of_potock
test word ed_flags,ed_mouse_on
jne .mouse_wigwag
2007-04-04 10:40:20 +04:00
;----------------------------------------------------------
2006-12-13 08:18:25 +03:00
;--- <20> <EFBFBD> <E0AEA2> 塞, <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> edit box -------------
;----------------------------------------------------------
2007-04-13 11:03:50 +04:00
mov ebx,dword [ecx+38]
add ebx,ed_top
2007-04-20 08:19:47 +04:00
if scr_h eq
else
add ebx,scr_h
end if
2007-04-13 11:03:50 +04:00
cmp ax,bx
jl ._blur;.mouse_end_no_focus
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
add ebx,ed_height
cmp ax,bx
jg ._blur;.mouse_end_no_focus
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
shr eax,16
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
mov ebx,dword [ecx+34]
add ebx,ed_left
2007-04-20 08:19:47 +04:00
if scr_w eq
else
add ebx,scr_w
end if
2007-04-13 11:03:50 +04:00
cmp ax,bx
jl ._blur;.mouse_end_no_focus
2006-12-13 08:18:25 +03:00
2007-04-13 11:03:50 +04:00
add ebx,ed_width
cmp ax,bx
jg ._blur;.mouse_end_no_focus
2006-12-13 08:18:25 +03:00
;--- <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 塞 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ---
2007-04-13 11:03:50 +04:00
push eax
mov ebp,ed_color
call .clear_cursor
pop eax
2007-04-04 10:40:20 +04:00
._mvpos:
2007-04-13 11:03:50 +04:00
mov ecx,structure_of_potock
mov ebx,dword [ecx+34]
xor edx,edx
sub eax,ed_left
sub eax,ebx
2007-04-20 08:19:47 +04:00
if scr_w eq
else
add ebx,scr_w
sub eax,2
end if
2007-04-13 11:03:50 +04:00
mov ebx,6
div bx
add eax,ed_offset
cmp eax,ed_size
jna ._mshift
mov eax,ed_size
2007-04-04 10:40:20 +04:00
._mshift:
2007-03-09 14:07:59 +03:00
;;;;;;;
;;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> ࠡ<EFBFBD> ⪨ shift <20> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> shift
;;;;;;;
test word ed_flags,ed_shift_bac
2007-03-09 09:25:26 +03:00
je @f
2007-04-13 11:03:50 +04:00
mov ebp,dword ed_color
mov ebx,dword ed_shift_pos
push eax
call .sh_cl_
and word ed_flags,ed_shift_bac_cl
pop eax
2007-03-30 09:32:17 +04:00
@@:
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_mouse_on
jne @f
2007-03-30 09:32:17 +04:00
2007-04-13 11:03:50 +04:00
mov dword ed_shift_pos,eax
or word ed_flags,ed_mouse_on
mov dword ed_pos,eax
mov dword [mouse_flag],edi ;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 䨪<EFBFBD> <E4A8AA> <EFBFBD> <EFBFBD>
bts word ed_flags,1 ;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䮪<> <E4AEAA> <EFBFBD>
jmp .m_sh
@@:
cmp eax,dword ed_shift_pos ;<3B> <20> <> <EFBFBD> <EFBFBD> 樨 <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
je .mouse_ex
mov ed_pos,eax
mov ebp,dword shift_color
mov ebx,dword ed_shift_pos
call .sh_cl_
or word ed_flags,ed_mous_adn_b ;<3B> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <20> <> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> +shift_on +
.m_sh: call .draw_text
call .draw_cursor
2007-01-24 13:00:37 +03:00
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> 䮪<> <E4AEAA> <EFBFBD> ---------------------------
;----------------------------------------------------------
2007-04-13 11:03:50 +04:00
jmp .drc
2006-12-13 08:18:25 +03:00
._blur:
2007-04-13 11:03:50 +04:00
test word ed_flags,ed_always_focus
jne .mouse_ex
btr word ed_flags,1 ; <20> <20> <> <20> 䮪<> <E4AEAA> <EFBFBD> , <20> <> 室<EFBFBD> <E5AEA4>
jnc .mouse_ex
2007-03-09 09:25:26 +03:00
2007-04-13 11:03:50 +04:00
mov ebp,ed_color
call .clear_cursor
.drc: call .draw_border
2007-04-04 10:40:20 +04:00
.mouse_ex:
2007-04-13 11:03:50 +04:00
edit_ex
2006-12-13 08:18:25 +03:00
;----------------------------------------------------------
;--- <20> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> ࠧ<> 뢠<EFBFBD> <EBA2A0> <EFBFBD> 䮪<> <E4AEAA> <EFBFBD> --------------------------
;----------------------------------------------------------
;.blur:
;pusha
;._blur:
2007-04-13 11:03:50 +04:00
;btr ed_flags,1
;jnc @f
;call .draw_border
;call .clear_cursor
2006-12-13 08:18:25 +03:00
;@@:
2007-04-13 11:03:50 +04:00
;edit_ex
;----------------------------------------------------------
;--- <20> <> ࠡ<EFBFBD> ⪠ .mouse_wigwag
;----------------------------------------------------------
.mouse_wigwag:
shr eax,16
2007-04-13 12:20:30 +04:00
or word ed_flags,ed_shift_bac+ed_shift_on+ed_shift
2007-04-13 11:03:50 +04:00
;;;;;;;;;;;;;;;;;;
;;<3B> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> ࠡ<EFBFBD> ⪨ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ⥪<> <E2A5AA> <EFBFBD> , <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> ந<EFBFBD> 室<EFBFBD> <E5AEA4> <20> <> 室 <20> <> <20> ।<EFBFBD> <E0A5A4> <EFBFBD> editbox
;;;;;;;;;;;;;;;;;;
mov ecx,structure_of_potock
mov ebx,dword [ecx+34]
add ebx,ed_left
2007-04-20 08:19:47 +04:00
if scr_w eq
else
add ebx,scr_w
end if
cmp eax,ebx
jb .mleft
2007-04-13 11:03:50 +04:00
2007-04-20 08:19:47 +04:00
add ebx,ed_width
cmp eax,ebx
ja .mright
2007-04-13 11:03:50 +04:00
2007-04-20 08:19:47 +04:00
sub ebx,ed_width
2007-04-13 11:03:50 +04:00
xor edx,edx
sub eax,ebx ; <20> <> <EFBFBD> ⨬ <20> <> <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <20> <> 誨 <20> <> <20> <> <EFBFBD> <20> <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <EFBFBD> <20> <> editbox <20> <> <20> <> <EFBFBD> <20>
mov ebx,6
div ebx
;;;;;;;;;;;;;;;;;;
;;<3B> <> <EFBFBD> 楤<EFBFBD> <E6A5A4> <EFBFBD> <20> <> ࠡ<EFBFBD> ⪨ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ⥪<> <E2A5AA> <EFBFBD> , <20> <20> ।<EFBFBD> <E0A5A4> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> editbox
;;;;;;;;;;;;;;;;;;
;<3B> <> <EFBFBD> <EFBFBD> 稫<EFBFBD> <20> <> <EFBFBD> न<EFBFBD> <E0A4A8> <EFBFBD> <EFBFBD> <20> eax <20> <> 誨, <20> .<2E> . <20> 㤠 <20> <> <EFBFBD> <20> <> ६<EFBFBD> <E0A5AC> ⨫<EFBFBD> <E2A8AB> <EFBFBD>
;<3B> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 襭<EFBFBD> <E8A5AD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> <ECADA8> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> ⪠ <20> <>
2007-04-20 08:19:47 +04:00
add eax,ed_offset ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> ᬥ饭<E1ACA5> <E9A5AD>
cmp eax,dword ed_size ;<3B> <20> <> 諨 <20> <> <20> ।<EFBFBD> <E0A5A4> <EFBFBD> , <20> <> <20> <> 祣<EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ja .mwigvag
2007-04-13 11:03:50 +04:00
.mdraw:
mov dword ed_pos,eax ;<3B> <> <EFBFBD> ࠭<EFBFBD> <E0A0AD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> 祭<EFBFBD> <E7A5AD>
;<3B> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 襭<EFBFBD> <E8A5AD> <20> <> אַ㣮<EFACAE> 쭨<EFBFBD> <ECADA8> <EFBFBD> <20> <20> <> <EFBFBD> <EFBFBD> ⪠ <20> <>
2007-04-20 08:19:47 +04:00
mov ecx,dword ed_shift_pos
2007-04-13 11:03:50 +04:00
mov ebx,dword ed_shift_pos_old
mov dword ed_shift_pos_old,eax ;<3B> <> <EFBFBD> ᥬ <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> 祭<EFBFBD> <E7A5AD> <20> <> <EFBFBD> ன <20> <> <EFBFBD> <EFBFBD> 樨 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
;<3B> <EFBFBD> ઠ <20> <20> <> ᮢ<EFBFBD> <E1AEA2> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> 襭<EFBFBD> <E8A5AD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> ⥩
cmp ecx,ebx ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> 塞 <20> 㤠 <20> 뫮 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> 蠣 <20> <> <EFBFBD> <EFBFBD> <EFBFBD>
je .m1_shem ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> 뫮 ࠭<> <E0A0AD>
jb .msmaller ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뫮 ->
cmp ebx,eax ;<3B> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뫮 <20> <> <20> ⮣<EFBFBD> <- <20> <20> <> <EFBFBD> <20> <> <20> <EFBFBD> <E0AEA2> 塞 ᥩ<> <E1A5A9> <EFBFBD> <20> 㤠 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> ந<EFBFBD> 室<EFBFBD> <E5AEA4>
ja .m1_shem ;<3B> <20> 뫮 <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <- <20> <> <20> 㦭<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-20 08:19:47 +04:00
je .mwigvag ;<3B> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <20> 뫮, <20> <> <20> <> 祣<EFBFBD> <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-13 11:03:50 +04:00
mov ebp,ed_color ;<3B> <> <EFBFBD> <20> 㦭<EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> c ed_pos ed_shift_pos_old
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> ࠬ<EFBFBD> <E0A0AC> <EFBFBD> <EFBFBD> ebp=color ebx=ed_shift_pos
call .sh_cl_
jmp .mwigvag
.msmaller:
cmp ebx,eax
jb .m1_shem
mov ebp,ed_color
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> ࠬ<EFBFBD> <E0A0AC> <EFBFBD> <EFBFBD> ebp=color ebx=ed_shift_pos
call .sh_cl_
jmp .mwigvag
;alike =
.m1_shem:
mov ebp,shift_color
;<3B> 室<EFBFBD> <E5AEA4> <EFBFBD> <20> <> ࠬ<EFBFBD> <E0A0AC> <EFBFBD> <EFBFBD> ebp=color ebx=ed_shift_pos
2007-04-20 08:19:47 +04:00
mov ebx,ecx
2007-04-13 11:03:50 +04:00
call .sh_cl_
jmp .mwigvag
.mwigvag:
and word ed_flags,ed_shift_mcl
2007-04-20 08:19:47 +04:00
jmp .draw_cursor_text
2007-04-13 11:03:50 +04:00
; popa
; ret
.mleft:
2007-04-20 08:19:47 +04:00
mov eax,ed_pos
cmp eax,0
jbe .mwigvag
dec eax
call .check_offset
push eax
mov ebx,ed_shift_pos
mov ebp,shift_color
call .sh_cl_
pop eax
jmp .mdraw
2007-04-13 11:03:50 +04:00
.mright:
2007-04-20 08:19:47 +04:00
mov eax,ed_pos
mov ebx,ed_size
cmp eax,ebx
jae .mwigvag
inc eax
call .check_offset
mov ebx,ed_shift_pos
mov ebp,shift_color
push eax
call .sh_cl_
pop eax
jmp .mdraw
2007-04-13 11:03:50 +04:00
2006-12-13 08:18:25 +03:00
}
2007-03-07 11:35:01 +03:00
ed_figure_only= 1000000000000000b ;<3B> <> <EFBFBD> <EFBFBD> ᨬ<> <E1A8AC> <EFBFBD> <EFBFBD>
2007-03-06 16:53:45 +03:00
ed_always_focus= 100000000000000b
2007-03-07 11:35:01 +03:00
ed_focus= 10b ;䮪<> <E4AEAA> <20> ਫ<EFBFBD> <E0A8AB> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-03-06 16:53:45 +03:00
ed_shift_on= 1000b ;<3B> <20> <> <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> <EFBFBD> -<2D> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> shift,<2C> <20> <> <EFBFBD> <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> <EFBFBD> , <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> 㦥 <20> <> <EFBFBD> - <20> <> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> 㤥ন<E3A4A5> <E0A6A8> <EFBFBD> shift
2007-03-30 09:32:17 +04:00
ed_shift_on_off=1111111111110111b
2007-03-06 16:53:45 +03:00
ed_shift= 100b ;<3B> <> <EFBFBD> <EFBFBD> 砥<EFBFBD> <E7A0A5> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ⨨ <20> <> shift <20> .<2E> . <20> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
ed_shift_off= 1111111111111011b
ed_shift_bac= 10000b ;<3B> <> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> ⪨ <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> shift <20> .<2E> . <20> <> <EFBFBD> <20> <> ⠭<EFBFBD> <E2A0AD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD> <20> <> <EFBFBD> <20> <> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD>
2007-03-09 14:07:59 +03:00
ed_shift_bac_cl=1111111111101111b ;<3B> <> <EFBFBD> <EFBFBD> ⪠ <20> <> <EFBFBD> 㤠<> <E3A4A0> <EFBFBD> <EFBFBD> <EFBFBD> <20> 뤥<EFBFBD> <EBA4A5> <EFBFBD> <EFBFBD> <EFBFBD>
2007-03-06 16:53:45 +03:00
ed_shift_cl= 1111111111100011b
2007-04-13 12:20:30 +04:00
ed_shift_mcl= 1111111111111011b
2007-03-06 16:53:45 +03:00
ed_left_fl= 100000b
ed_right_fl= 1111111111011111b
2007-03-07 11:35:01 +03:00
ed_offset_fl= 1000000b
ed_offset_cl= 1111111110111111b
2007-03-06 16:53:45 +03:00
ed_insert= 10000000b
ed_insert_cl= 1111111101111111b
2007-03-30 09:32:17 +04:00
ed_mouse_on = 100000000b
2007-04-02 15:58:44 +04:00
ed_mous_adn_b= 100011000b
2007-03-30 09:32:17 +04:00
ed_mouse_on_off=1111111011111111b
2007-03-06 16:53:45 +03:00
ed_height=14 ; <20> <> <EFBFBD> <EFBFBD> <EFBFBD> <EFBFBD>
2007-04-20 08:19:47 +04:00
macro draw_edit_boxes start,_end,use_f9,structure_of_potock
2006-12-13 08:18:25 +03:00
{
2007-04-20 08:19:47 +04:00
if use_f9 eq
else
mcall 9,structure_of_potock,-1
end if
2007-04-13 11:03:50 +04:00
mov edi,start
2007-04-20 08:19:47 +04:00
mov ecx,((_end-start)/ed_struc_size)
2006-12-13 08:18:25 +03:00
@@:
2007-04-13 11:03:50 +04:00
call edit_box.draw
add edi,ed_struc_size
loop @b
2006-12-13 08:18:25 +03:00
}
2007-04-20 08:19:47 +04:00
macro mouse_edit_boxes start,_end
2006-12-13 08:18:25 +03:00
{
2007-04-13 11:03:50 +04:00
mov edi,start
2007-04-20 08:19:47 +04:00
mov ecx,((_end-start)/ed_struc_size)
2006-12-13 08:18:25 +03:00
@@:
2007-04-13 11:03:50 +04:00
call edit_box.mouse
add edi,ed_struc_size
loop @b
2006-12-13 08:18:25 +03:00
}
macro key_edit_boxes start,end
{
2007-04-13 11:03:50 +04:00
mov edi,start
mov ecx,((end-start)/ed_struc_size)
2006-12-13 08:18:25 +03:00
@@:
2007-04-13 11:03:50 +04:00
call edit_box.key
add edi,ed_struc_size
loop @b
2006-12-13 08:18:25 +03:00
}
2007-04-13 11:03:50 +04:00
ed_struc_size=70
struc edit_box width,left,top,color,shift_color,focus_border_color,\
blur_border_color,text_color,max,text,flags,size,pos
2006-12-13 08:18:25 +03:00
{
.width dd width
.left dd left
.top dd top
.color dd color
2007-04-13 11:03:50 +04:00
.shift_color dd shift_color
2006-12-13 08:18:25 +03:00
.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 17:36:00 +03:00
.text dd text
.flags dw flags+0
2007-03-09 11:41:43 +03:00
.size dd size+0
2007-04-13 11:03:50 +04:00
.pos dd pos+0
2006-12-13 08:18:25 +03:00
.offset dd 0
.cl_curs_x dd 0
.cl_curs_y dd 0
2007-03-06 16:53:45 +03:00
.shift dd 0
.shift_old dd 0
2006-12-13 08:18:25 +03:00
}
2007-03-09 09:25:26 +03:00
2006-12-13 08:18:25 +03:00
macro edit_boxes_set_sys_color start,end,color_table
{
2007-04-13 11:03:50 +04:00
mov edi,start
mov ecx,((end-start)/ed_struc_size)
mov esi,color_table
2006-12-13 08:18:25 +03:00
@@:
2007-04-13 11:03:50 +04:00
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
2007-02-01 10:20:59 +03:00
}
2007-04-20 08:19:47 +04:00
macro draw_edit_box ed_ptr,use_f9,structure_of_potock
2007-02-01 10:20:59 +03:00
{
2007-04-20 08:19:47 +04:00
if use_f9 eq
else
mcall 9,structure_of_potock,-1
end if
2007-02-01 10:20:59 +03:00
mov edi,ed_ptr
call edit_box.draw
}
macro mouse_edit_box ed_ptr
{
mov edi,ed_ptr
call edit_box.mouse
}
macro key_edit_box ed_ptr
{
mov edi,ed_ptr
call edit_box.key
2007-04-20 08:19:47 +04:00
}
macro default_box ed_ptr
{
pusha
; xor eax,eax
; mov ed_shift_pos,eax
; mov ed_shift_pos_old,eax
and word ed_flags,ed_shift_cl
; mov ed_offset,eax
popa
2006-12-13 08:18:25 +03:00
}