kolibrios/programs/develop/examples/editbox/trunk/editbox.mac

52 lines
1.9 KiB
Plaintext
Raw Normal View History

; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>
macro edit_ex
{
popa
ret
}
macro debug
{
;----------- <20><EFBFBD><E2ABA0><EFBFBD>
pushad
; mov dword [ed_buffer.2],0
; mov eax,edi
mov eax,dword [ed_buffer.2]
mov edi,ed_buffer.3
call .str
;<3B><><EFBFBD><E1AEA2><EFBFBD><EFBFBD><>
mov eax,13
mov ebx,178*65536+70
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,ed_buffer.3
mov esi,8
int 0x40
popad
;----------- <20><EFBFBD><E2ABA0><EFBFBD>
}
macro debug_func
{
.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>
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
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
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>
}