Commit 03f29eed authored by Dmitry Bogatov's avatar Dmitry Bogatov

Import Upstream version 2.70

parent 3c0f89af
......@@ -3,7 +3,7 @@ for any purpose without royalty or fees in accordance with the terms of the
copyright.
-----------------------------------------------------------------------------
Copyright (c) 2000-2004 Albrecht Kleine
Copyright (c) 2000-2006 Albrecht Kleine
All rights reserved.
You may distribute under the terms of the GNU General Public License.
......
Mon Jan 23 18:14:21 2006 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm: bugfixed ^T key in empty file (WS edit mode)
-README: merged with README.UTF8
#214
-----------------------------------------------------------
Wed Jan 11 20:00:00 2006 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm: various changes:
*replace variable errno with _errno
for "make statc" working again
* chganged max filesize to 1024000
* bugfix handling ascii character 127
-Makefile: removed make distinations
test, dync and dync2
-/contrib directory: removed old stuff
-/bin directory: removed BeOS, QNX and Atheos stuff
#213
------------------------------------------------------------
Sun Jan 8 20:00:00 2006 Albrecht Kleine <kleine@ak.sax.de>
e3.asm: added UTF8 switcher at cost of 90 byte.
This turns the editor from UTF-8 mode to 7 bit mode
and back. Use the special keys:
^KU in WS mode / ^QV in Pico mode / ^Y in Nedit mode
^U in Emacs mode / ESC:u in vi mode
#212
------------------------------------------------------------
Sat Jan 7 20:31:02 2006 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm: improved handling of bad formated text
on UTF8 Unicode console (by complete ignoring this
characters).
Also added comments about some unused UTF8-runtime
switcher code.
#211
--------------------------------------------------------------
Wed Nov 23 17:41:00 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm: for error free assembling with current YASM
releases added "section .data", also in "make debug"
#210
-------------------------------------------------------------
Mon Oct 31 11:41:00 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm, e3.h: on NetBSD we are now using some
newer modern system calls: fstat (=279), lseek(=199)
#208,#209
--------------------------------------------------------------
Wed Oct 19 20:17:14 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm for NetBSD: replaced linux emulation with
native NetBSD interface
* changed push before int 80h
* added special .note.netbsd.ident (just like openbsd)
#207
***** released as v2.6.3 *****
--------------------------------------------------------------
Sun Oct 2 17:53:34 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm: added a "near" prefix to a jump
inside InputString (preventing jump distance overflow)
-e3.asm, e3.h, Makefile added special stuff
for running on newer NetBSD (1.6 or 2.0 )
Edit in Makefile: OS=NETBSD now possible.
(Thanks to Gabor Z. Papp for bug report.)
#206
--------------------------------------------------------------
Wed Aug 31 20:00:42 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm: bugfix re-introducing missing error messages
(AMD-64 version only)
Wed Aug 31 xx:xx:xx 2005 Christian Ostheimer
-e3.c: adapted to mipsel (fritz box fon)
#205 (Thanks to Christian Ostheimer !!!)
--------------------------------------------------------------
Sun Feb 27 01:04:56 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm added runtime checking of console status
(started this in #195). This solves some problems
running e3/UTF8 in non-UTF8-terminals like "rxvt".
[ We are trying to keep togeher the UTF-8 bytes
for 1 character also on non UTF-8 terminals. ]
#204
--------------------------------------------------------------
Sun Feb 20 10:30:02 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm bugfix: added forgotten line counter trigger
at four special keys (^S,^D,^A,^F).
Thanks for bug report to Pedro Gimeno Fortea !
-e3.asm: added check against empty string in filename
additional to checking arguments counter. This avoids
a problem of invoking e3 by Midnight Commander
(usually by pressing F14 in mc for editing a new file).
#203
***** released as v2.6.2 *****
--------------------------------------------------------------
Wed Jan 26 17:32:47 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm,e3.h: bugfixes in system calls for wait4,
execve, fstat, utime: moved data structure to 64bit
#202
------------------------------------------------------------
Mon Jan 24 21:36:38 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm, e3.h: changed kernel interfacing on AMD-64 code
for Linux from "int 80h" to syscall. The signal handler
is now set via "rt_sigaction" (was old "sigaction"),
because "sigaction" doesn't seem available.
Now e3-64bit can be traced with 'strace' again (no more
'strace32').
#201
-------------------------------------------------------------
Sun Jan 9 19:13:39 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm: repaired missing signal handler on
Linux/AMD-64 version. Thx to Andi Kleen.
#200
-------------------------------------------------------------
Mon Jan 3 18:00:48 2005 Albrecht Kleine <kleine@ak.sax.de>
-e3.asm, e3.h: continued 64 bit version, i. e.
fixed bugs in commandline reading and numerics
-e3.asm:added push ecx / pop ecx pair to save register ECX
......
......@@ -7,6 +7,7 @@ OS=LINUX
#OS=QNX
#OS=ATHEOS
#OS=W32 ** please use a separate make.bat for W9x **
#OS=NETBSD
# Set this to gzexe or upx if you want compression
# COMPRESS=gzexe
......@@ -137,28 +138,6 @@ yasm64: $(ASOURCES) Makefile
ln -sf e3 e3vi
ln -sf e3 e3ne
# selftest, linux only, assembled with a special option for using an input pipe
test:
ifeq ($(OS),LINUX)
$(NASM) -f bin -l e3.lst -o e3test e3.asm -DSELFTEST -DCRIPLED_ELF=1 -DLINUX -D$(EXMODE)
ifeq ($(COMPRESS),upx)
if which upx > /dev/null 2>&1 ; then \
upx -q -q -q -k -9 e3test ; \
fi ;
endif
ifeq ($(COMPRESS),gzexe)
if which gzexe > /dev/null 2>&1 ; then gzexe e3test; fi;
endif
if [ -f PIPE_IN ]; then rm PIPE_IN ; fi
if [ -f e3test~ ]; then rm e3test~ ; fi
chmod +x e3test
cat e3.h tests/e3test0 | ./e3test
clear
diff e3.h PIPE_IN && echo -e "\n\n\n**** THE TEST WAS SUCCESSFUL ****\n\n\n"
rm PIPE_IN e3test
endif
# next for cross asm for the ELKS people
elks:
nasm -w+orphan-labels -f as86 -o e3-16.o e3-16.asm -l e3-16.lst -D AS86 -D ELKS
......
README for mini editor e3 release 2.6.1 (aka 2.61)
README for mini editor e3 release 2.7.0 (aka 2.7)
(c) GPL 2000-05 Albrecht Kleine
(c) GPL 2000-06 Albrecht Kleine
kleine@ak.sax.de
alb.kleine@gmx.de (please use "e3" in mail subject line)
1. OVERVIEW
===========
e3 is a micro text editor with an executable code size between
......@@ -23,7 +22,7 @@ Also the user can calculate arithmetics inside the text.
e3's assembler version is available on 11 most important x86 OS,
see below for details.
Also available is an (alpha level) 32 bit native code assembler version
for StrongARM ("Advanced Risc Machine") CPUs.
for ARM CPUs in little endian mode.
There is also a GNU-C-written version for non-i386-Unix
and non-ARM-Linux platforms (e3.c) using Wordstar keybindings only.
This README doesn't further mention e3.c. (Just make it!)
......@@ -32,16 +31,16 @@ e3 is designed to be INDEPENDENT OF LIBC OR ANY OTHER library,
except on QNX and Win32.
It's been tested using the terminal console, but Xterm, Eterm,
kvt, rxvt, vt220 and vt100 should work too.
kvt, rxvt (no UTF8), vt220 and vt100 should work too.
Beginning in version 2.6.0 e3 does support UTF-8 coding of unicode
characters like this: α ( <---should be a greek alpha )
e3.asm it's been tested under several x86 32 bit OS:
* Linux kernels 2.0, 2.2, 2.4, 2.6
* FreeBSD 2.2, 3.1, 4.4, 5.0
* Linux kernels 2.x
* FreeBSD 2.x-5.0
* OpenBSD 3.4,
* NetBSD 1.51
* NetBSD 1.6,2.0
* BeOS 5PE
* Win98
* QNX RTP 6.1
......@@ -56,8 +55,8 @@ e3.s is tested under:
* ARM-linux kernel 2.4 (@zaurus PDA)
2a. BUILD on Linux/FreeBSD/BeOS/QNX/Atheos
==========================================
2a. BUILD on Linux/FreeBSD/NetBSD/BeOS/QNX/Atheos (32 bit)
==========================================================
A. For assembling of e3 you need NASM assembler.
B. If you don't like the default OS or destination (LINUX , /usr/local/ )
......@@ -89,12 +88,19 @@ F. Optional: some more editable options are on top of e3.h:
G. Take care:
If you are building your own e3 binary, be careful: some
NASM versions are producing oversized binaries, some won't
produce a e3.lst listing file: two bugs, but at all harmless.
NASM versions are producing oversized binaries.
2b. BUILD on Linux (64 bit)
===========================
A. For assembling of e3 you need YASM 0.4 assembler.
B. see 2a, except for make, this should be:
make yasm64
2b. BUILD on Win9x / ME / DOS
2c. BUILD on Win9x / ME / DOS
=============================
A. For assembling of e3 you need NASM assembler v0.98,
and ALINK (Anthony's Linker) and Win32 Import Library (win32.lib)
......@@ -112,20 +118,20 @@ C. Optional: some more editable options are on top of e3.h:
your favourite mode.
2c. BUILD on NetBSD,OpenBSD
===========================
Here are 2 Makefile for BSD-make included. See ./bin directory.
Also you need NASM. In general you don't need to change that files.
2d. BUILD on OpenBSD
====================
Here is a Makefile for BSD-make included. See ./bin directory.
Also you need NASM. In general you don't need to change that file.
2d. BUILD for ELKS
2e. BUILD for ELKS
==================
This is done usual on 32 bit x86 Linux systems either
by typing "make elks" or changing to elks/ and typing "make".
You need to have installed the ld86 linker (part of dev86 suite).
2e. BUILD for ARM Linux
2f. BUILD for ARM Linux
=======================
Simply type "make armlinux" on your x86 box.
You will need the ARM linux toolchain, at least
......@@ -141,27 +147,11 @@ Or adjust 'Makefile' and build e3arm on the destination ARM box.
3. RELEASE NOTES
================
Only changed Linux/ASM-version:
* First step: introduced building with YASM assembler,
see http://www.tortall.net/projects/yasm
So added new make destination: "make yasm"
* Second step: introduced building a 64-bit version
of e3 for Linux/AMD-64.
The program file says:
"e3_64: ELF 64-bit LSB executable, AMD x86-64,
version 1 (SYSV), statically linked, stripped"
* Both steps are using the sed stream editor.
Thus now we are using 2 converter scripts:
nasm to yasm: e3_nasm_yasm.sed
yasm to 64bit: e3_yasm_yasm64.sed
* Also fixed a bug first occurs running e3 under 2.6.8 kernels
during the Wait4 system call.
(This crashed sed filtering, e.g. by ^KP in WS mode.)
* some bugfixes
* AMD 64 bit version: yasm 0.4 can used again
* added runtime switching of UTF-8 edit mode,
see UTF8 section below.
* enhanced max filesize
......@@ -221,11 +211,14 @@ Some more examples:
1+1*2*3*4*5*6*7*8*9*10=3628801
7.627891*2.643189=20.161958
10000000000/8=1250000000
Some problems:
100000000000+1.00001=99999997953.00001 <--loss of precision!
8/0= <--not possible. You know.
(e3 says "beep")
100000000*100000000= <--overflow
Some specials:
Two specials:
12*p=37.699112 <--p is PI 3.14.....
r+20=57.699112 <--r is result of last calculation
......@@ -306,7 +299,51 @@ do NOT expect very high precision.
7. FILES
7. Notes on UTF-8 for the Linux/ASM-version
============================================
* By default now e3 does does support UTF-8 coding of unicode
characters like this: α (should be a greek alpha).
* You could disable UTF-8 support in e3 by editing e3.h at line 16:
from
%define UTF8
to
;;; %define UTF8
and run 'make' again.
* Running e3_with_disabled_UTF-support at a UTF-8 console
you will see two points .. for UTF-8 characters e.g. the greek alpha.
* If your terminal does _not_ support UTF-8 it is strongly
recommended to _disable_ UTF8-support in e3.h,
because output of some characters could be scrambled.
* e3 will _not_ convert your files from/to UTF-8 coding.
It does simply _use_ your terminal encodings.
* UTF-8 characters like © (c) will look very false on non-UTF-8 terminals,
but e3 can't help here. (So at first use a file converter.)
* If you simply call e3 without file argument the initial screen of e3
will tell you whether UTF8-support is built in:
MicroEditor e3 v2.7.0-UTF8 ©2000-06
vs.
MicroEditor e3 v2.7.0 (C)2000-06
* If it is a version with UTF8 and you are running
e3 in an UTF8 terminal, you can switch the editor
from UTF-8 mode to 7 bit mode and back.
Use the special keys:
^KU in WS mode
^QV in Pico mode
^Y in Nedit mode
^U in Emacs mode
ESC:u in vi mode
8. FILES
========
Makefile - (edit destination path and OS if desired)
e3.asm
......@@ -318,24 +355,21 @@ README - you are reading this
ChangeLog - version history
COPYING.GPL
COPYRIGHT - please read before using e3!
test/* - partial test suite
e3c/* - C stuff for non x86 systems, e.g. Alpha
contrib/* - useful things, e.g. e3.spec (== spec for building RPMs)
doswin9x/* - specials for DOS, Win9x and its derivates
elks/* - specials for ELKS
binaries/* - binaries separated for operating systems
armlinux/* - specials for Linux @ ARM RISC CPU
*.sed - special stuff for using YASM assembler
8. THANKS
9. THANKS
=========
Konstantin Boldyshev <konst at voshod.com>
Mark Zealey <mark at itsolve.co.uk>
Urs Rau <urs.rau at uk.om.org>
Terry Loveall <loveall at qwest.net>
David Douthitt <n9ubh at callsign.net>
Björn De Meyer <bjorn.demeyer at pandora.be>
Bjoern De Meyer <bjorn.demeyer at pandora.be>
Matthias Kopfermann <kopfermann at trio-hittfeld.de>
Tim Wegner <twegner at swbell.net>
Michele Andreoli <m.andreoli at tin.it>
......@@ -346,10 +380,10 @@ Philippe Corbes <philippe.corbes at laposte.net>
Charles Steinkuehler <charles at steinkuehler.net>
Adrian Bunk <bunk at fs.tum.de>
Joseph <joseph at randomnetworks.com>
Andi Kleen (at suse)
9. TM note
==========
10. TM note
===========
Some names are trademarks of their owners:
Linux BSD BeOS QNX Unix WordStar Unox DOS Win Alpha BSE Atheos ELKS ARM BEIN .. etc.
Some notes on UTF-8 for the Linux/ASM-version:
1.
By default now e3 does does support UTF-8 coding of unicode
characters like this: α (should be a greek alpha).
2.
You could disable UTF-8 support in e3 by editing e3.h at line 16:
from
%define UTF8 ;for UTF8 console or xterm e.g. @ Suse 9.1
to
;;; %define UTF8 ;for UTF8 console or xterm e.g. @ Suse 9.1
and run 'make' again.
3.
Running e3_with_disabled_UTF-support at a UTF-8 console
you will see two points .. for UTF-8 characters e.g. the greek alpha.
4.
If you terminal does _not_ support UTF-8 it is strongly
recommended to _disable_ UTF8-support in e3.h,
because output of some characters could be scrambled.
5.
e3 will _not_ convert your files from/to UTF-8 coding.
It does simply _use_ your terminal encodings.
UTF-8 characters like © (c) will look very false on non-UTF-8 terminals,
but e3 can't help here. (So at first use a file converter.)
6.
If you simply call e3 without file argument the initial screen of e3
will tell you whether UTF8-support is built in:
MicroEditor e3 v2.6.0-UTF8 GPL © 2000-04
vs.
MicroEditor e3 v2.6.0 GPL (C) 2000-04
BTW a runtime detection of UTF-8 console is planned, but not yet ready to use.
Enjoy!
Albrecht,
Jun/29/2004
......@@ -9,8 +9,15 @@
.equ MAKE_BACKUP,1 @(no value known)
.equ LESSWRITEOPS,1 @(no value known)
.equ UTF8,1 @(no value known)
.equ UTF8RTS,1 @(no value known)
.equ BEEP_IN_VI,1 @(no value known)
.equ USE_BUILTINHELP,1 @(no value known)
.ifndef LINUX
.endif
.ifndef UTF8
.endif
.ifdef NETBSD
.endif
.ifdef OPENBSD
.endif
.ifdef BEOS
......@@ -25,6 +32,7 @@
.equ TERMIOS_WSIZE,21523
.equ NCCS,19
.equ VMIN,6
.ifndef AMD64
.equ UIDGID_WORD,1 @(no value known)
.struct 0
stat_struc.st_dev:
......@@ -81,6 +89,7 @@ stat_struc.__unused5:
.equ SYS_ioctl,54
.equ SYS_dup2,63
.equ SYS_sigaction,67
.equ SYS_rt_sigaction,174
.equ SYS_readlink,85
.equ SYS_fchmod,94
.equ SYS_fchown,95
......@@ -88,6 +97,10 @@ stat_struc.__unused5:
.equ SYS_wait4,114
.equ SYS_select,142
.ifndef ARMCPU
.endif
.else
.endif
.ifndef ARMCPU
.else
.struct 0
utimbuf_struc.actime:
......@@ -102,6 +115,8 @@ utimbuf_struc.modtime:
.equ NEW_CURSOR_MGNT,1 @(no value known)
.purgem CURSORMGNT
.else
.ifdef AMD64
.endif
.endif
.equ SIGCONT,18
.equ SIGSTOP,19
......@@ -187,9 +202,12 @@ utimbuf_struc.modtime:
.endif
.else
.ifdef FREEBSD
.ifndef OPENBSD
.ifdef OPENBSD
.else
.endif
.ifndef OPENBSD
.ifdef OPENBSD
.endif
.ifdef NETBSD
.endif
.ifdef EX
.else
......@@ -308,8 +326,11 @@ _start: CALL SetTermStruc
.else
.ifdef DYN
.else
.ifdef SYS_sigaction
.ifdef SYS_rt_sigaction
CALL SetSigHandler
.else
.ifdef SYS_sigaction
.endif
.endif
.ifdef ATHEOS
.endif
......@@ -356,6 +377,32 @@ prog1:
.endif
.endif
.ifdef UTF8RTS
A_DR r2,getPos
ldr r12,= gPlen
stmfd r13!,{r12}
ldmfd r13!,{r3}
CALL WriteFile0
A_DR r2,screenbuffer
mov r12,#0xa
stmfd r13!,{r12}
ldmfd r13!,{r3}
CALL ReadFile0
mov r9,r2
add r9,r9,r0
mov r10,#0x2
sub r9,r9,r10
ldrB r12,[R9]
bic r0,r0,#0xFF
orr r0,r0,r12
mov r12,#0x33
mov r11,r0,lsl #24
mov r11,r11,lsr #24
subs r11,r11,r12
and r11,r11,#0xFF
bic r0,r0,#0xFF
orr r0,r0,r11
A_DR r12,isUTF8
strB r0,[r12]
.endif
ReStart:
CALL NewFile
......@@ -523,7 +570,7 @@ NormChar:
CALL ShowBl0
NOEM0:
.ifdef UTF8
.ifdef UTF8RTS
.ifdef UTF8RTSx_wont
.endif
mov r12,r0
and r12,r12,#0xFF
......@@ -561,7 +608,7 @@ OverWriteChar:
strb r0,[r4]
add r4,r4,r7
.ifdef UTF8
.ifdef UTF8RTS
.ifdef UTF8RTSx_wont
.endif
eors r0,r0,r0
mrs r8,CPSR
......@@ -732,9 +779,15 @@ CompJump2:
A_DR r10,jumptab1
add r9,r9,r10
ldrH r1,[R9]
.ifdef YASM
.ifdef AMD64
.else
.endif
.else
A_DR r11,_start
adds r1,r1,r11
.endif
stmfd r13!,{r14}
add r14,pc,#4
mov pc,r1
......@@ -940,6 +993,11 @@ SCloop: mrs r8,CPSR
msr CPSR_f,r12
.ifdef UTF8
.ifdef UTF8RTS
A_DR r12,isUTF8
mov r11,#0x0
ldrB r10,[r12]
cmp r10,r11
beq noUTF_C
.endif
ldrB r12,[r4]
bic r1,r1,#0xFF
......@@ -1095,7 +1153,7 @@ KDloopUTF8:
orrcc r12,r12,r8
msr CPSR_f,r12
.ifdef UTF8
.ifdef UTF8RTS
.ifdef UTF8RTSx_wont
.endif
mov r9,r4
add r9,r9,r0
......@@ -1160,7 +1218,7 @@ KeyEmaCtrlT:
KeyRight:
.ifdef UTF8
.ifdef UTF8RTS
.ifdef UTF8RTSx_wont
.endif
mrs r8,CPSR
and r8,r8,#0x20000000
......@@ -1202,6 +1260,7 @@ noUTF_E:
bhs KeyRightEnd
CALL IsViMode
beq KeyRightEnd
CALL CheckENum
CALL GoDown
KeyRNoMargin:
mrs r8,CPSR
......@@ -1217,6 +1276,7 @@ KeyCLeft3:
A_DR r11,sot
cmp r4,r11
bls KeyCLEnd
CALL CheckENum
mrs r8,CPSR
and r8,r8,#0x20000000
mov r11,#0x1
......@@ -1255,6 +1315,7 @@ KeyCLEnd:
KeyCRight3:
CALL CheckEof
bhs KeyCREnd
CALL CheckENum
b KQZ1
KeyCtrlQZ:
mov r12,#0x2f
......@@ -1606,8 +1667,7 @@ KeyCmddw:
CALL CountToWordBeginVIstyle
b NO_EM05
KeyCtrlY:
CALL CountToLineBegin
subs r4,r4,r0
CALL KeyHome
CALL CountToLineEnd
A_DR r12,mode
ldr r11,= WS
......@@ -2030,6 +2090,13 @@ KVI_KX: beq KeyCtrlKX
mov r11,r11,lsr #16
cmp r11,r12
beq KeyHelp
.ifdef UTF8RTS
mov r12,#0x75
mov r11,r0,lsl #16
mov r11,r11,lsr #16
cmp r11,r12
beq KeyUTF8switch
.endif
.ifndef USE_PIPE
RET
.else
......@@ -2197,7 +2264,7 @@ KeyVICmdPnLB:
KeyLeft:
.ifdef UTF8
.ifdef UTF8RTS
.ifdef UTF8RTSx_wont
.endif
mrs r8,CPSR
and r8,r8,#0x20000000
......@@ -2243,6 +2310,7 @@ noUTF_F:
beq KeyLeftEnd
CALL IsViMode
beq KeyLeftEnd
CALL CheckENum
CALL GoUp
KeyLNoMargin:
mrs r8,CPSR
......@@ -2436,10 +2504,16 @@ DispCharLoop:
bne DispCharL1
A_DR r12,kurspos
str r1,[r12]
A_DR r12,columne
strB r1,[r12]
A_DR r12,zloffst
ldr r0,[r12]
mov r12,r1
and r12,r12,#0xFF
mov r11,r0,lsl #24
mov r11,r11,lsr #24
adds r11,r11,r12
and r11,r11,#0xFF
bic r0,r0,#0xFF
orr r0,r0,r11
A_DR r12,columne
ldr r10,[r12]
adds r10,r10,r0
......@@ -2518,7 +2592,7 @@ ELZ3: ldr r12,= NEWLINE
mov r11,r11,lsr #24
cmp r11,r12
bhs ELZ9
mov r12,#0x2e
ELZ99: mov r12,#0x2e
bic r0,r0,#0xFF
orr r0,r0,r12
ELZ9:
......@@ -2528,7 +2602,20 @@ ELZ9:
mov r11,r11,lsr #24
cmp r11,r12
blo ELZ7
beq ELZ99
.ifndef UTF8
.else
.ifdef UTF8RTS
A_DR r12,isUTF8
mov r11,#0x0
ldrB r10,[r12]
cmp r10,r11
bne YXCVB
mov r12,#0x2e
bic r0,r0,#0xFF
orr r0,r0,r12
YXCVB:
.endif
.endif
ELZ7:
.endif
......@@ -2539,7 +2626,15 @@ ELZ7:
cmp r11,r12
bhs DispEndLine
.ifdef UTF8
mov r12,#0x0
bic r0,r0,#0xFF00
orr r0,r0,r12,lsl #8
.ifdef UTF8RTS
A_DR r12,isUTF8
mov r11,#0x0
ldrB r10,[r12]
cmp r10,r11
beq CountByte
.endif
stmfd r13!,{r0}
mov r12,#0xc0
......@@ -2554,31 +2649,12 @@ ELZ7:
mov r11,r11,lsr #24
cmp r11,r12
ldmfd r13!,{r0}
beq ELUTF8
noUTF_G: