Bloček - the world only DOS editor with Unicode support!
====================================================================================

1) THE FOREWORD
Bloček is a text editor for DOS with several unique features. Unlike the most DOS editors it works in graphic mode which brings many advantages. First of all it is not limited to 256 chars of the ASCII set like editors working in the text mode. Bloček can work with files coded in Unicode and using up the 65536 glyphs of the basic multilingual plane which is sufficient to nearly all present languages.
Besides that it still keeps the ability to work in the non-Unicode mode using the legacy DOS fonts from data files or using the hardware font the VGA graphic card efectively emulating the traditional text mode editors.
Bloček is also a image viewer - can display BMP, PCX, PNG, JPG and WMF vector files. In JPG files can show the EXIF tags and allows to copy the stored information to text window.
Bloček can open, display and edit many files simultaneusly and can process very big files with very long lines. It uses mainly proportional fonts but the unproportinal fonts are also available.
Other interresting features are the advanced and customizable word wrapping in the text files, the possibility to switch interface to multiple  language versions (at this moment are Czech, English and Russian versions are available) and many others.
The home site for Bloček is:       
   http://www.laaca.borec.cz/blocek
For questions, bug reports and ideas use my e-mail address: 
   Laaca@seznam.cz 
You can also contact me at the DOS ain’t dead forum at 
   http://www.bttr-software.de/forum/board.php


2) FONTS AND KEYBOARD
Hence Bloček is the DOS editor it tries to cooperate as much as possible with the DOS system settings and environment.
By the default setting (which can be changed) it loads the actual DOS charset and uses the DOS keyboard driver and uses some tricks how to utilize the DOS keyboard driver even after switching to Unicode mode. However except the default DOS driver can Bloček use its own keyboard drivers. You can anytime switch among them by clicking to language selector in the upper right corner of the screen (or by pressing the shortcut Alt+LShift).
For example, you have a DOS environment set to polish code page, using the polish charset and the DOS keyboard driver is set to polish language. But you need to write some text in russian language using cyrilic. In Bloček you can. You simply set the keyboard language to russian and then either switch the font to some non-Unicode cyrilic font or you convert the document into Unicode mode and you will have all the Unicode chars from the basic plane available.
The default fonts for Unicode and non-Unicode modes can be changed by editing the configuration file BLOCEK.CFG
For Unicode mode you can use the bundled fonts with extension UFN (located in the FONTY subdirectory). The default one is the file UNISMALL.UFN which is quite complete but you can use other UFN fonts but they currently contain much less chars.
For non-Unicode use the fonts with extensions CH or FN defining the codepage dependent charsets with 256 glyphs. Or you can use the current loaded VGA fonts used by DOS.


3) LIMITATIONS OF THE UNICODE SUPPORT
Bloček supports only the so called basic multilingual plane (BMP) of Unicode standard. But it covers virtually all present languages, except some less frequent east-Asian glyphs. The emoji pictures are currently not supported.
The combining diacritics marks are also not currently supported but it is not a big problem as the Unicode files usualy use the embeded diacritics marks. The only exception where is it realy missing are the emphasised cyrillic chars (but anyway, they are used very rarely)
There are supported all relevant standards for Unicode coding: UTF-8, UTF-16 LE and UTF-16 BE.
Also is supported the HTML Unicode reprezentation like &#269; for „c with carron“


4) BLOCK OPERATIONS AND CLIPBOARDS
The Block operations were reworked in the version 1.7. First of all, the text blocks can be selected not only in the edited text, but also in the single line input boxes or from most of the texts somewhere in GUI like in information windows.
The block can be selected in three ways
1)   By keyboard functions. For the key combination look bellow
2)   By dragging the mouse with pressed left button
3)   Go the same place of the text and press Shift+Left mouse button (LMB). The go to other place and again press the Shift+LMB. The space between these two locations will be selected as a block. (This mechanism works only in the edited text)

What you can do with selected blocks:
-    Delete them (CTRL-Del)
-    Use them as a scope for many search or conversion operations
-    Copy them into clipboard and eventualy paste them somewhere
Most of the editors use only one clipboard. Bloček has nine independend clipboards. For copying into clipboard press Ctrl+number 1-9 (it was inspired by Command and Conquer game) and the block will be copied into clipboard 1-9. The upper line shows which clipboards are used in
the menu. With Alt+number 1-9 you can paste defined clipboard in cursor position.
Or you can also click with the mouse to clipboars indicators in the upper menu line and follow the menu. However this variant will work only during the editing text – not from the information windows.


5) IMAGE VIEWER
Bloček is not only the text editor but also a picture viewer. It is possible to have simultaneusly opened several text editor windows and picture windows and fluently switch among them. However there is a limitation that Bloček runs in 16-bit color mode but most images in these days use the 24-bit color depth. So the color quality is a little bit reduced in the viewer. Also note that Bloček can the images only display - not modify.
Which image formats can Bloček load:
BMP, PCX, GIF, PNG
JPG - even with EXIF tags. Bloček is able to show to EXIF tags and copy the  information into clipboard and then to edited text (I am not aware about any other DOS program which knows the EXIF information)
WMF - still used but a little bit outdated vector format



6) CONFIGURATION
Bloček loads its configuration from two files: DEFAULT.CFG and BLOCEK.CFG
DEFAULT.CFG is a "factory setting" and shouldn't be changed. BLOCEK.CFG is user setting which has higher priority than the default one. In other words: if a variable will be found in both files, variant from BLOCEK.CFG will be used.
In the distribution archive is spread only DEFAULT.CFG - so getting a new version can't change your favourite setting. If Bloček is installed first time and no BLOCEK.CFG is present, it will be created from DEFAULT.CFG
If in future I add some new variable into DEFAULT.CFG, Bloček will detect it and copy this
setting into BLOCEK.CFG. Some of the settings

7) LOCALIZATION AND EXTENSIBILITY
All texts inside Bloček editor are loaded from external files located in the TRANSLAT subdirectory and named BLOCEK1.xx and BLOCEK2.xx (where „xx“ is the language specificator) It allows you to use various language mutations of Bloček. Now the czech, english and russian languages are supported. Bloček is open source program so feel free to create your own translations. In the past we had a turkish, french and hungary translations but they are not fully compatible with current version. The exact instruction for translating you can find in the file \TRANSLAT\HOWTO.TXT
The other localization features are the custom keyboard layouts and the Unicode and non-Unicode conversions filters.
All these files are in the KEY_TBL subdirectory. Feel free to create your own keyboard layouts. You have to create a new .KBT file and store it in the KEY_TBL subdirectory.
You can also create your own ASCII-Unicode conversion filters in .TBL format. They are already prepared for many languages but you can still need a filter between Unicode and some alternate non-Microsoft standard for extended ASCII. The description of the .TBL format and a small conversion utility for it is available in the KEY_TBL subdirectory.
And finally, you can define your own files with extension A8T which are used frou groupping of alternate ASCII coddings for single language. For example, for czech language is are used codepages 852 (Microsoft DOS), 1252 (Microsoft Windows), ISO-8859-2 (Unix) and 895 („Kamenicti“ standard for DOS). The A8T can group these coddings together to make easier the conversions between them.


8) TECHNICAL INFORMATION
The reasonable minimal hardware for running Bloček:
Pentium 100MHz, 16MB RAM, Graphic card with 1MB VRAM compatible with VESA VBE 1.2 and capable to run at least 800x600 16-bit, Mouse, DOS 5.0 or equivalent.
Bloček needs the 386 instruction set but supports MMX extensions when available. The 686 instructions are not used in the official builds. 
Bloček needs the DPMI server for handling the extended memory. There is bundled a CWSDPMI r7 server in Rayer’s modification (which disables VCPI) but you can use any other DPMI server (official CWSDPMI, HDPMI32,..). However you should prefer some with disk swapping.
Bloček  can use the long file name services when available (e.g. under Windows 95 or with proper DOS driver)
This program is written and complied in Freepascal (http://www.freepascal.org)
(actualy used version 3.0.4, for GO32V2 (DOS) 



9) KEYBOARD CONTROL
F10   - enter main menu
F1    - make a new file
F2    - save file
F3    - load file
Alt+F3 - close file
Alt+F1 - load this file (INFO.TXT)
Ctrl+F - search
Ctrl+S - search again
Ctrl+H - replace
Ctrl+A - select all document to block
Ctrl+K - char conversion functions
LShift+Alt - change keyboard layout
Ctrl+Alt+Up - select actual line to block
Ctrl+Alt+Down - word on the cursor to block
Ctrl+Alt+Left - all chars from cursor to left to block
Ctrl+Alt+Right - all chars from cursor to right to block
*arrows - moves cursor 
*Ctrl+PageUp - jumps on first line of the file 
*Ctrl+Home - dtto
*Ctrl+PageDown - jumps on last line of the file
*Ctrl+End  - dtto
*Ctrl+RightArrow - moves one word to right
*Ctrl+LeftArrow - moves one word to left
   These function keys (marked with the "*" char) can be combined with the <Shift> key.
   In such case is together with cursor movement also created or updated the text
   selection block.
Ctrl+Space - delete selected block
Ctrl+[1-7] - copy selected block of text into clipboard No 1-7
Alt+[1-7] - paste text from clipboard No 1-7 into cursor position

ESC   - quit
Alt+F2 - make a screenshot


MOUSE CONTROL:
a) In the document window
Left mouse button (LMB) click  - moves cursor on selected place in text
LMB click+shift - select beginning and end of the text block
LMB press and drag - interactive selection of the text block
Right mouse (RMB) click - shows information and optionaly a conversion menu for the char you clicked to

b) In panel with cards of opened files
LMB click - switches the main window to the specified file
RMB click - several actions with the specified file
(close, close all but this, show full file path)

c) In the clipboards indicators 
LMB click - menu for operations with the clipboard

d) All other buttons and other GUI elements use only left mouse button at this moment. The right one is not used currently.

e) As descibed above - from version 1.7 is possible the move windows by dragging their title bar with mouse.


10) GREETINGS
I would like to thank to:
Mircosoft (not Microsoft :-)) -- http://mircosoft.mzf.cz
  - started the project of GUI Wokna32 (in realmode Turbo pascal)
Venom
  - began work on graphics library VenomGFX
Mateusz Viste
  - provided the Unicode fonts
Tae Wong
  - corrections of the english texts
Christof Lange
  - made a tool for creating .TBL Unicode filters
KormaX
  - for hungarian translation
Thraex
  - for french and turkish translations
UFO
  - corrections of the russian texts
Stepan Hrbek (Dee)
  - for his utilities for FN fonts
Michael Knapp
  - for GraphX where I grabbed PNG loader
BearWindows
  - for code for reading WMF images
development team of FastDIB graphics library.
  - I used their smooth image scaling routines

...and to others for reporting bugs


11) VERSION HISTORY:

1.7
    + many improvements in the graphical user interface (GUI)
    + most of the windows can be moved by dragging the title bar by mouse
    + slovak keyboard layout
    + blocks of text can be selected by dragging the mouse with pressed left button
    + blocks of text can be selected not only in the edited text but also in most places of the GUI like information or help windows.
    + the scope of the Search or Search and Replace functions can be limited to text block only
    + many powerful conversion routines handling the code pages and Unicode
    * if the document is not in Unicode it is always in some defined DOS code page
    - The RAM size detection was wrong on some systems
    + Now can work even with graphic cards with non-continuous video memory (like GeForce RTX 2060)
    + can load and save with all three line-ending standards (CRLF, CR, LF)
    + can load and save Unicode files encoded in UTF-16LE and UTF-16BE
    + recognizes the Unicode BOMs (byte order marks)
    + customizable word wrapping
    + now can fixate the word-wrapping not only for the whole document but also for selected block only.
    + function for intelligent merging the legacy DOS style lines (78 or 80 chars) to word-wrapping blocks.  
    - better keyboard handler 
    - fixed bug in the conversion routine for 3-bytes long Unicode glyphs
    + conversion from HTML entities into Unicode chars
    + QR codes creation
    - Program can't be shot down by Ctrl-Break
    - fixed tabulators
    - corrected minor bugs in the color selection dialog
    - functions for moving to next word or to previous word now scroll the window if needed
    + the single-line text boxes can use the clipboards too (like f.e. in „Search and replace“ dialog)
    + more informations in the system information window 
    * the number of clipboards reduced to 7 (still more than enough) leaving more space on the upper line for menu
    x the language files for german, turkish, hungarian and french languages are not updated so they are moved from "public" TRANSLAT subdirectory to TRANSLAT\VER162 - they can partialy work after copying back into TRANSLAT

1.62
    - fixed a lot of typos in texts
    - fixed block operations on the single line blocks
    - solved "undeletable" first char of line which occurred in some situations
    + block conversions to make case up or low

1.61
    + Conversion of the extended ASCII or Unicode chars into HTML entities
    - fixed possible crash when opening large text file
    - fixed crash after pressing up arrow after menu activation by mouse
    * progress indicator now uses timer
     
1.6
    - fixed graphical glitch causing garbage in some circumstances when opening a new window
    - mouse sometimes caused noticeable slowdown of program
    - reenabled  the char typing using ALT + <codes on numeric keyboard>
    - fixed crash when "word wrapping" on empty file was selected
    - optimized the method for getting the hardware glyphs from graphic card
    + implemented function keys CTRL+right arrow and CTRL+left arrow
    + implemented function CTRL+A (select all)
    + CTRL+Del deletes selected block
    + selected blocks are now visible just in the text - not only in status line     
    + program language can be switched directly from menu system (no manual editing of conf. files is needed)     
    * not only the final compilation but also regular development is done with Freepascal 3.0.2

1.5c  
    + now can display the Exif info in JPEG files and export the Exif data
    + can resize big images to fit the screen optimally
    + can now properly display the semi-standard VGA fonts with used 7.bit in char definitions 
    - fixed few bugs which potentially could lead to crash
    - fixed some graph. glitches when ch*anging the image viewer and text editor modes
    - fixed "locking" of ALT and CTRL keys in some situations
    - fixed typos in english messages

1.4b 
    - fixed potential bug with keyboard handler and corrected system info window

1.4
    * detect DOS code page for using with Unicode
      (so "keyboard_mapping" variable in BLOCEK.CFG is now deprecated)
    * some VESA BIOSes or drivers are buggy so VESA3 functions can be disabled now
    + block operations - you have not only one clipboard but NINE clipboards!
    + System information window

1.37
    - Fixed conflict between DOS national keyboard driver and Bloček's internal
      keyboard driver. ("dead keys" watched by DOS was "stealed" and not processed
      by internal driver)
    - Fixed wrong displaying of text cursor in some situations. (this bug became more
      severe in previous version)
    + Now allows to define keys which are "semi-capslock dependent"
      (like ěĚ/2 in czech keyboard driver)
    * keyboard definition files are now much more user friendly so it is easier to
      define new ones
    + hungarian keyboard layout

1.36b
    - Fixed some annoying problems with charmap
    * More carefully avoids bugs of Freepascal 2.x.x - it is more stable now

1.35b
    * Now can work in banked modes too!
    - Prior versions with some screen drivers could download wrong fonts from VRAM.

1.34b
    - fixed some minor problems with line breaking in GUI
    - fixed wrong positions of points in radio button dialogs

1.34
    + Now can load vector image format .WMF
    - fixed occasional bug when shelling into DOS
    * compiled with current version of graphics library VenomGFX

1.33b
    + ASCII conversions
    + brasil keyboard layout
    + configurable menus
    + warns if no virtual memory is present
    * radically reworked all management of messages and texts
    * other invisible changes
    * for final compilation is used Freepascal 2.2.0a
    - crash when checking word wrapping with new file
    - filesector allows to manually select a file by writing its name
    - tabs work correctly now
    - thousands separator

1.32c
    + charmap
    + configuration management with default and user configuration files
    - few bugs fixed
    * files are opened gradually and loading can be canceled
    * quite a lot of code rewritten
    * better speed
    * for final compilation is used another compiler - Freepascal 2.1.4
    + more Unicode fonts (there is also a editor with TTF import available on my WWW)

1.31
    * reworked code for switching of opened files
    * better tabulators handling
    - more compatible searching files
    + russian keyboard driver knows letters "yo" and "YO"
    * all text windows now share one output buffer - saves a lot of memory
    - crash in Search again after Search without any occurrence of searched string
    * more careful checks if graphics card supports LFB

1.3c
    - functions Search, Search again, Replace and Fix word wrapping
    + better algorithms for scaling images (see Select filter in Options menu)
    + horizontal and vertical flip for images
    * scrolbars work more or less like in windows
    + changing to/from word wrapping mode keeps cursor position
    + checks if image files are corrupted
    - fixed some bugs in image viewing mode
    + added german keyboard driver
    - fixed czech keyboard driver
    * many invisible but important changes in GUI library
    + better error handler
    + expands tabs

1.2d
    + PNG reader
    + Ctrl+Alt+arrow functions
    - hopefuly fixed one text scrolling bug with word wrapping
    + Bloček can be now used as image viewer (BMP, PCX, GIF, PNG, JPG)
    - reports error when you try to write to read only drive
    - now can't become 15bpp x 16bpp graphics mode confusion

1.1.2
    + another Unicode font
    * Unicode fonts are much smaller now
    * Unicode fonts are now proportional
    + keyboard layout switching
    + GIF reader
    - some small bugs fixed (some left)
    + glyph info on right mouse button

1.1
    + word wrapping
    + conversion routines to/from Unicode coding
    - some small bugs corrected
    + automatic detection of Unicode text
    * some internal changes what will be visible later :-)
    ! most probably some new bugs around word wrapping

1.0.x
    gradual evolution

Last versions you can download here:
binary: http://www.laaca.borec.cz/soubory/blocek.rar
source: http://www.laaca.borec.cz/soubory/wokna32.rar

There is also a mirror available at:
http://www.laaca.sweb.cz/blocek.rar
http://www.laaca.sweb.cz/wokna32.rar

Laaca

------------------------------------------------------------------------------------- -

Here is the first article of the Universal Declaration of Human Rights in some of the
languages supported by Bloček:

Akuapem Twi:
Wɔɑwo ɑdesɑmmɑ nyinɑɑ sɛ nnipɑ ɑ wɔwɔ ɑhofɑdi. Wɔn nyinɑɑ wɔ nidi ne kyɛfɑ koro. Wɔwɔ
ɑdwene ne ɑhonim, nɑ ɛsɛ sɛ wobu wɔn ho wɔn ho sɛ ɑnuɑnom.

Armenian / Հայերեն:
Բոլոր մարդիկ ծնվում են ազատ ու հավասար իրենց արժանապատվությամբ ու իրավունքներով։ Նրանք
ունեն բանականություն ու խիղճ – միմյանց պետք է եղբայրաբար վերաբերվեն։

Czech / Česky:
Všichni lidé se rodí rovnými a svobodnými co to důstojnosti a práv. Jsou nadáni rozumem
a svědomím a mají spolu jednat v duchu bratrství.

English:
All human beings are born free and equal in dignity and rights. They are endowed with reason and conscience and should act towards one another in a spirit of brotherhood.

Estonian / Eesti:
Kõik inimesed sünnivad vabadena ja võrdsetena oma väärikuselt ja õigustelt. Neile on antud mõistus ja südametunnistus ja nende suhtumist üksteisesse peab kandma vendluse vaim.

French / Français:
Tous les êtres humains naissent libres et égaux en dignité et en droits. Ils sont doués
de raison et de conscience et doivent agir les uns envers les autres dans un esprit de fraternité.

Georgian / ქართული:
ყველა ადამიანი იბადება თავისუფალი და თანასწორი დავისი ღირსებითა და უფლებებით. მათ მინიჭებული
აქვთ გონება და სინდისი და ერთმანეთის მიმართ უნდა იქცეოდნენ ძმობის სულისკვეთებით.

Greek / Ελληνικά:
Όλοι οι άνθρωποι γεννιούνται ελεύθερποι και ίσοι στην αξιοπρέπεια και τα δικαιώματα. Είναι
προικισμένοι με λογική και συνείδηση, και οφείλουν να συμπεριφέρονται μεταξύ τους με
πνεύμα αδελφοσύνης.

Irish Gaelic / Teanga Gaelige:
Saoláitear na daoine uile saor agus coṁionann ina ndínit agus ina gcearta. Tá bauiḋ an
réasúin agus an ċoinsiasa acu agus dlíd iad féin d'iompar de ṁeon ḃrṫreaċais i leiṫ a
ċéile.

Latvian / Latviešu:
Visi cilvēki piedzimst brīvi um vienlīdzīgi savā pašcieņā un tiesībās. Viņi ir apveltīti ar
saprātu un sirdsapziņu, un viņiem jāizturas citam pret citu brālības garā.

Lithuanian / Lietuvių:
Visi žmonės gimsta laisvi ir lygūs savo orumu ir teisėmis. Jiems suteiktas protas ir sąžinė ir jie turi elgtis vienas kito atžvilgiu kaip broliai.

Maltese / Malti:
Il-bnedmin kollha jitwieldu ħielsa u ugwali fid-dignjità u d-drittjiet. Huma mogħnija bir-raġuni u bil-kuxjenza u għandhom iġibu ruħhom ma’ xulxin bi spirtu ta’ aħwa.

Polish / Polski:
Wszyscy ludzie rodzą się wolni i równi pod względem swej godności i swych praw. Są oni
obdarzeni rozumem i sumieniem i powinni postępować wobec innych w duchu braterstwa.

Portuguese / Português:
Todos os seres humanos nascem livres e iguais em dignidade e em direitos. Dotados de razão e de consciência, devem agir uns para com os outros em espírito de fraternidade.

Romanian / Română:
Toate ființele umane se nasc libere și egale în demnitate și în drepturi.
Ele sunt înzestrate cu rațiune și conștiință și trebuie să se comporte unele față de altele în
spiritul fraternității.

Russian / Русский:
Все люди рождаются свободными и равными в своем достоинстве и правах. Они наделены
разумом и совестью и должны поступать в отношении друг друга в духе братства.

Turkish / Türkçe:
Bütün insanlar hür, haysiyet ve haklar bakımından eşit doğarlar. Akıl ve vicdana sahiptirler ve birbirlerine karşı kardeşlik zihniyeti ile hareket etmelidirler.

Vietnamese / Tiếng Việt:
Tất cả mọi người sinh ra đều được tự do và bình đẳng về nhân phẩm và quyền. Mọi con
người đều được tạo hoá ban cho lý trí và lương tâm và cần phải đối xử với nhau trong
tình bằng hữu.


Bloček is also able to display other kinds of glyphs such as mathematical, dingbats, box drawings, musical and much more!
Have a fun with it :-)